Developer forums (C::B DEVELOPMENT STRICTLY!) > Contributions to C::B

Updating wxWidgets project wizard

(1/6) > >>

PB:
I have updated wxWidgets project wizard, with the main aim being to improve user experience on MS Windows with GCC.

Here is what I did:

Remove support for obsolete wxWidgets versions 2.6 and 2.8.

Improve linking on MSW:
* Allow linking with libraries introduced in wxWidgets 2.9: PropertyGrid, Ribbon, STC, and WebView.
* Allow linking with OpenGL for the monolithic build too.
* Do not offer to link with the 3rd party libraries (image formats, expat, regex, scintilla, zip), they are not needed for the DLL build and required for the static build.
* Allow linking with Winsock2 instead of Winsock.

By default, assume Unicode will be used and the generated application will be GUI instead of console one.

Make more options persistent and other minor improvements.


I believe the above improves the wizard and I am not aware of any real drawbacks. I have noticed that GitHub has a mirror code repository, which accepts PRs, so I submitted it there: https://github.com/obfuscated/codeblocks_sf/pull/21


There is certainly a room for further improvement and code cleanup. I was also itching to remove support for the ancient Open Watcom and Borland compilers (as I doubt these are supported by modern wxWidgets), but I let that be (for now?).


If anyone is interested in discussing the changes or, hopefully merging the update to Code::Blocks, I would gladly hear them out.

stahta01:
PB: I wish you luck in getting at least some of the wxWidgets Wizard changes applied; I gave up on getting any of my changes applied a few years back.

Tim S.

oBFusCATed:
I've posted some comments.

PB:
I have addressed all the comments in the PR and will wait for further input.

One of the questions asked there was: GCC on Windows may not be the best, what about clang?

I have no experience with clang but I installed MSYS2 package mingw-w64-x86_64-clang and built wxWidgets with it, using the mingw makefile. When trying to run the wizard with clang, there were errors, as function OnLeave_WxConf() does not test for clang. After hacking it, i.e., making the same settings for clang as for GCC, the wizard successfully finishes.

However, it seems that clang used as gcc cannot compile the windows resource:

--- Quote ---windres.exe -ID:\Dev\Desktop\!Lib\wxWidgets-GIT\include -ID:\Dev\Desktop\!Lib\wxWidgets-GIT\lib\gcc_dll_clang\mswud  -J rc -O coff -i C:\dev\cb-tests\TEST-C~2\resource.rc -o obj\Debug\resource.res
clang++.exe -LD:\Dev\Desktop\!Lib\wxWidgets-GIT\lib\gcc_dll_clang -o bin\Debug\test-clang10s.exe  obj\Debug\test_clang10sApp.o obj\Debug\test_clang10sMain.o obj\Debug\resource.res  -lwxmsw31ud_webview -lwxmsw31ud_stc -lwxmsw31ud_propgrid -lwxmsw31ud_ribbon -lwxmsw31ud_richtext -lwxmsw31ud_xrc -lwxmsw31ud_aui -lwxmsw31ud_media -lwxbase31ud_net -lwxmsw31ud_gl -lwxmsw31ud_qa -lwxbase31ud_xml -lwxmsw31ud_adv -lwxmsw31ud_html -lwxmsw31ud_core -lwxbase31ud -Wl,--subsystem,windows
llvm-rc: Error in 24 statement (ID 1):
Is a directory
windres: error: llvm-rc failed

--- End quote ---

The same error was there when I tried to build a wxWidgets sample using GCC makefile too, so it is not a C::B issue.

To conclude, I think clang may not be usable with this wizard, modified or original.

BTW, it seems that clang debugger uses a different interface than GDB, is this supported by C::B?

oBFusCATed:
The main question concerning the wizard is if checking for gcc derived compiler matches clang. If it doesn't then all is good. :)


--- Quote from: PB on May 23, 2021, 01:05:27 pm ---BTW, it seems that clang debugger uses a different interface than GDB, is this supported by C::B?

--- End quote ---
Not yet.

p.s. how do you build wx? Just set CC and CXX env variables?
p.p.s. why are you using mingw-clang, when there is a official clang release?

Navigation

[0] Message Index

[#] Next page

Go to full version