News:

When registered with our forums, feel free to send a "here I am" post here to differ human beings from SPAM bots.

Main Menu

Compiling wxWidget 2.8.6 for Code::Blocks

Started by ironhead, November 24, 2007, 01:31:35 AM

Previous topic - Next topic

ironhead

Hey All,

This is somewhat off topic, but I'm having a hard time getting wxWiget 2.8.6 to compile.  During the compile I get:


windres --use-temp-file -i../../src/msw/version.rc -ogcc_mswudll\monodll_version_rc.o    --define __
WXMSW__      --define _UNICODE   --include-dir ..\..\lib\gcc_dll\mswu --include-dir ..\../include --
define WXDLLNAME=wxmsw28u_gcc_custom --include-dir ..\../src/tiff --include-dir ..\../src/jpeg --inc
lude-dir ..\../src/png --include-dir ..\../src/zlib  --include-dir ..\../src/regex --include-dir ..\
../src/expat/lib --define wxUSE_BASE=1 --define WXMAKINGDLL
../../src/msw/version.rc:12:24: wx/version.h: No such file or directory
windres: gcc exited with status 1
mingw32-make: *** [gcc_mswudll\monodll_version_rc.o] Error 1


what I don't understand is that wx/version.h is in the '..\../include' directory which is included with above as part of a '--include-dir'.  I didn't have this problem with 2.8.4.  I'm compiling using MinGW on a XP Pro box.

Has anyone else had this problem?  If so, is there a way around it?

Cheers!

Chris

TDragon

This is a bug in the latest MinGW release of binutils; downgrade to binutils-2.17.50-20060824-1.
[url="https://jmeubank.github.io/tdm-gcc/"]https://jmeubank.github.io/tdm-gcc/[/url] - TDM-GCC compiler suite for Windows (GCC 9.2.0 2020-03-08, 32/64-bit, no extra DLLs)

ironhead


ironhead

#3
I've got wxWidgets 2.8.6 to compile and I am now attempting to compile Code::Blocks.  I've hit another snag tough.  I now get the following error:


C:\Source\wxWidgets-2.8.6\include\wx\fs_mem.h|68|undefined reference to `_imp___ZTV17wxMemoryFSHandler'|


Which is odd because the line it's complaining about is defining the wxMemoryFSHandler class.

EDIT:  I really should take a closer look before posting, this is a linker error while building codeblocks.exe.  I've reverted to using the 3.4.5 version of gcc/g++ when compiling as opposed to version 4.2.1, is there something that needs to be tweaked to compile with 4.2.1?

Chris

ironhead

I saw a same error in another thread in the forum and it mentioned that the wxWidgets lib compiled with 3.4.5 wouldn't work with 4.2.1, which makes sense.  I had thought I had taken care of it with:


mingw32-make -f makefile.gcc USE_XRC=1 SHARED=1 MONOLITHIC=1 BUILD=release UNICODE=1 CC=gcc-dw2


but I had for got to take care the g++ compiler, hence the error.  I modified my wxWidgets make command to:


mingw32-make -f makefile.gcc USE_XRC=1 SHARED=1 MONOLITHIC=1 BUILD=release UNICODE=1 CC=gcc-dw2 CXX=g++-dw2


and everything is fine now.

Cheers!

Chris