codelite build wxwidgets program no "-lwxmsw32ud_qa" error

82 Views Asked by At

OS : windows 11, CPU : AMD, wxWidgets 3.2.4 Release, the given link (msys2-x86_64-20231026.exe) of msys2 site, default package is ucrt64 version, gcc info : gcc.exe (Rev2, Built by MSYS2 project) 13.2.0.

I followed the guide on the official site,

mingw32-make -f makefile.gcc SHARED=1 UNICODE=1 BUILD=debug,

codelite version 17.0.0, and the compiler, enviroment variable, workspace settings all done well.

the problem is next, when I try to build the sample wxwidget program generated by codelite, the build omitted error that: "... ld.exe: cannot find -lwxmsw32ud_qa: No such file or directory".

C:/etc/msys64/ucrt64/bin/mingw32-make.exe -j12 -e -f  Makefile
"----------Building project:[ wx - Debug ]----------"
mingw32-make[1]: Entering directory 'C:/dev/codelite/gui/wx'
C:/etc/msys64/ucrt64/bin/g++.exe -o ..\build-Debug\bin\wx.exe @../build-Debug/wx/ObjectsList.txt -L.   -mwindows -LC:/Downloads/wxwidgets323/lib/gcc_dll -pipe -lwxmsw32ud_xrc -lwxmsw32ud_webview -lwxmsw32ud_html -lwxmsw32ud_qa -lwxmsw32ud_adv -lwxmsw32ud_core -lwxbase32ud_xml -lwxbase32ud_net -lwxbase32ud
C:/etc/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lwxmsw32ud_qa: No such file or directory
collect2.exe: error: ld returned 1 exit status
mingw32-make[1]: *** [wx.mk:84: ..\build-Debug\bin\wx.exe] Error 1
mingw32-make: *** [Makefile:5: All] Error 2
mingw32-make[1]: Leaving directory 'C:/dev/codelite/gui/wx'
=== build completed successfully (0 errors, 0 warnings) ===

what's "-lwxmsw32ud_qa"? if the failure is the ucrt64 version of make or gcc problem? or it's from codelite?

I have strugled 3 days, still can't fixing it, need help!

thanks for any reply!

1

There are 1 best solutions below

0
On

I fixed it myself by do a new compilation, I was know nothing about make. Thank you HolyBlackCat, you've give me the hint, install, I didn't found the official site mention about it.

I keep research, and found and followed an artical use cmake, did a fresh new compile, after that run 'mingw32-make install', in codelite set its environment viarable to 'WXCFG=gcc_x64_dll\mswud', build and run, it popup up twice says missing 'wxbase32ud_gcc_custom.dll' and 'wxmswd32ud_core_gcc_custom.dll', then keep researching and found the answer, I add the path of 'wxwidgets\lib\gcc_dll' to windows system virable, run the sample program again, the gui apeared, success!