Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Code::Blocks can build against wxGTK/Win 3.2.0

(1/2) > >>

stahta01:
I have gotten Code::Blocks core project to build with minor edits.
https://github.com/stahta01/codeblocks_sfmirror/tree/wxMSW-msys2

Edit: The above repo was just to test the MINGW-packages below!!!!!!!!!!!!!

I likely did a few edits that was not needed.

I did it to test this wxWidgets 3.2.0 package.
https://github.com/msys2/MINGW-packages/pull/12224

Code::Blocks IDE was the only large app I know would compile with wxGTK/Win with only minor edits.

Edit: Other that looking about about box I did no testing


--- Code: ---Name                    : Code::Blocks
Version                 : svn-r12852
SDK Version             : 2.19.0
Scintilla Version       : 3.7.5
Author                  : The Code::Blocks Team
E-mail                  : info@codeblocks.org
Website                 : https://www.codeblocks.org
OS                      : Windows 10 (build 19044), 64-bit edition
Scaling factor          : 1.000000
Detected scaling factor : 1.250000
Display PPI             : 120x120
Display count           : 2
Display 0 (\\.\DISPLAY1): XY=[1600,0]; Size=[1700,960];
Display 1 (\\.\DISPLAY2): XY=[0,0]; Size=[1280,1024]; Primary

wxWidgets Library (wxGTK port)
Version 3.2.0 (Unicode: wchar_t, debug level: 1),
compiled at Jul 28 2022 04:54:56

Runtime version of toolkit used is 3.24.
Compile-time GTK+ version is 3.24.34.

--- End code ---

Edit2: Ran into wxGetKeyState() issues; very fast. So, the CB built with wxGTK/Win is not very usable till that is fixed.

Tim S.

BlueHazzard:
What does this mean? Could we provide a package over msys with this?
msys isn't using wxGTK by default or?

 
--- Quote ---Ran into wxGetKeyState() issues
--- End quote ---
So you can not type?

[Edit:] I see mostly only ifdef changes, so this should be straight forward if we want to integrate it. I am just no fan of the new project files  :-\ we should try to remove project files instead of adding them...

stahta01:

--- Quote from: BlueHazzard on July 29, 2022, 12:20:44 am ---What does this mean? Could we provide a package over msys with this?
msys isn't using wxGTK by default or?

 
--- Quote ---Ran into wxGetKeyState() issues
--- End quote ---
So you can not type?

[Edit:] I see mostly only ifdef changes, so this should be straight forward if we want to integrate it. I am just no fan of the new project files  :-\ we should try to remove project files instead of adding them...

--- End quote ---

The wxWidgets 3.2.0 package I did an PR on for MSys2 supplies both wxMSW and wxGTK-gtk3; I needed a way to test the wxGTK.
I know that 2 to 3 years ago the CB was close to compiling with wxGTK/Win; so I used CB to test it.
I have no plans to submit the CB projects I have in the repo above. Or the code changes.
But, I do consider it a example way to build CB projects for other software.

wxGetKeyState() returns shift/control/alt etc.
I did not even try to type; the assert messages about wxGetKeyState() happened when trying to build an previously created CB project with a single printf statement.

But, the PR seems to supply the private wxMSW headers needed to build the Code::Blocks core project.
If anyone uses MSys2, please test my PR and give feedback on the wx3.2 or wx3.0 PRs
3.2 https://github.com/msys2/MINGW-packages/pull/12224
3.0 https://github.com/msys2/MINGW-packages/pull/12194

I hope I finally have package names the MSys2 folks will support.

Tim S.

AndrewCot:
I am cloning the branch now and will be giving it a go.

AndrewCot:
I loved how I could build C::B without having to build wxWidgets and therefore it would make it a heck of allot better for newbies as they do not always get the parameters and/or the steps right.

I downloaded the MINGW64 artifact from last night's build.
Needed to do the following in order to do the build:

* pacman -U *.zst --overwrite "*"
* set global variable "cb_relase_type" to:"-g -O0 -ggdb"  (quotes added for readability)
* Needed to install mingw-w64-x86_64-drmingw
CodeBlocks_wxGTK32-msys2.cbp


* Loaded CodeBlocks_wxGTK32-msys2.cbp
* Build succeeded
* In a command prompt cd into D:\Andrew_Development\Work_Installers\stahta01_wxMSW-msys2\src directory
* Run update32_GTK3.bat, but in my environment the strip failed a expected as I do not have it in the path.
* Needed to copy a large number of DLL's to get the codeblocks.exe to work "standalone"
* Could compile simple hello world test
* Could debug test app if I setup the compiler config from the nightly build due to compiler dialog crash (see next item)
* Crash when entering compiler setup dialog. Conclusion - allot easier to build and test C::B than the existing requirement to build wxWidgets
Smaller Size - Possibly smaller in that the nightly directory with DLL's is 172MB (approx) and the output32_GTK3 is approx 148Mb on disk. Needs more investigation to double check.

CodeBlocks_wxMSW32-msys2.cbp

* Loaded CodeBlocks_wxMSW32-msys2.cbp
* re-build succeeded (done just in case the wxGTK3 left some files that could cause issues)
* In a command prompt cd into D:\Andrew_Development\Work_Installers\stahta01_wxMSW-msys2\src directory
* Run update32_MSW.bat., but in my environment the strip failed a expected as I do not have it in the path.
* Needed to copy a large number of DLL's to get the codeblocks.exe to work "standalone"
* Had to add  two more DLL's: exchndl.dll & mgwhelp.dll (I am using a batch file to do the copy)
* Could compile simple hello world test
* Could debug test app
* The BIG one: No crash when entering compiler setup dialog.
Conclusion - allot easier to build and test C::B than the existing requirement to build wxWidgets
Smaller Size - Possibly smaller in that the nightly directory with DLL's is 172MB (approx) and the output32_MSW is approx 150Mb on disk. Needs more investigation to double check.


Going Forward
Why do you not want to run with getting the Windows (wxWidgets 3.2 only IMHO) build changed to use the new packages and therefore stopping the requirement to build a wxWidgets in order to build  C::B?

Navigation

[0] Message Index

[#] Next page

Go to full version