Developer forums (C::B DEVELOPMENT STRICTLY!) > Contributions to C::B
Undefined references when linking "devel\wxscintilla.dll"
ivan_ijh:
I have a problem linking wxscintilla.
Version: svn build rev 4767
My input (link) libraries are:
"wxmsw28$(WX_SUFFIX)" is actually "libwxmsw28u.a" and "gdi32" are installed from "wxPack".
I'm using "GNU GCC Compiler" .
And here is a Built Log:
--- Quote ----------------- Build: scintilla in Code::Blocks ---------------
Linking dynamic library: devel\wxscintilla.dll
.objs\sdk\wxscintilla\src\PlatWX.o: In function `ZN4Font6CreateEPKciibbb':
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:109: undefined reference to `_imp___ZN19wxEncodingConverter22GetPlatformEquivalentsE14wxFontEncodingi'
.objs\sdk\wxscintilla\src\PlatWX.o: In function `ZN11SurfaceImpl10InitPixMapEiiP7SurfacePv':
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:222: undefined reference to `_imp___ZN8wxBitmapC1Eiii'
.objs\sdk\wxscintilla\src\PlatWX.o: In function `ZN11SurfaceImpl7ReleaseEv':
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:229: undefined reference to `_imp__wxNullBitmap'
.objs\sdk\wxscintilla\src\PlatWX.o: In function `ZN11SurfaceImpl9PenColourE15ColourAllocated':
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:247: undefined reference to `_imp___ZN5wxPenC1ERK8wxColourii'
.objs\sdk\wxscintilla\src\PlatWX.o: In function `ZN11SurfaceImpl11BrushColourE15ColourAllocated':
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:251: undefined reference to `_imp___ZN7wxBrushC1ERK8wxColouri'
.objs\sdk\wxscintilla\src\PlatWX.o: In function `ZN11SurfaceImpl13FillRectangleE10PRectangle15ColourAllocated':
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:293: undefined reference to `_imp___ZN10wxStockGDI6GetPenENS_4ItemE'
.objs\sdk\wxscintilla\src\PlatWX.o: In function `ZN11SurfaceImpl13FillRectangleE10PRectangleR7Surface':
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:298: undefined reference to `_imp___ZN7wxBrushC1Ev'
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:300: undefined reference to `_imp___ZN7wxBrushC1ERK8wxBitmap'
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:302: undefined reference to `_imp___ZN10wxStockGDI9GetColourENS_4ItemE'
D:/cvs_projects/codeblocks/trunk/src/sdk/wxscintilla/src/PlatWX.cpp:302: undefined reference to `_imp___ZN7wxBrushC1ERK8wxColouri'
..........................
--- End quote ---
(and much more..)
All these symbols exists in link libraries, but without "_imp_" prefix (added later by linker I suppose)
stahta01:
--- Quote from: ivan_ijh on January 07, 2008, 05:04:56 am ---All these symbols exists in link libraries, but without "_imp_" prefix (added later by linker I suppose)
--- End quote ---
The compiler and linker are both involved in creating the "_imp_" prefix. But, I think of it mainly being the compiler; the dllexport and dllimport keywords are used in this.
Which version of wxWidgets are you using?
What steps did you follow to compile it?
Which wxPack file did you download?
I also need to know which version of MinGW is being used?
You can normally get this by running this command for MinGW GCC before version 4.0
The MinGW GCC 4.x versions requires a different command, sometimes.
--- Code: ---gcc -v
--- End code ---
Tim S
ivan_ijh:
--- Quote from: stahta01 on January 07, 2008, 08:21:25 am ---Which version of wxWidgets are you using?
What steps did you follow to compile it?
Which wxPack file did you download?
I also need to know which version of MinGW is being used?
--- End quote ---
I tried with two packages of wxWidgets with same result :
1) 2.8 - from "wxPack_v2.8.7.03.exe"
2) 2.8.7 from "wxWidgets-2.8.7.tar.gz" downloaded from wxWidgets site
and compiled with this miniGW :
--- Quote ---gcc -v
Reading specs from D:/programming/MinGW/bin/../lib/gcc/mingw32/3.4.5/specs
Configured with: ../gcc-3.4.5/configure --with-gcc --with-gnu-ld --with-gnu-as -
-host=mingw32 --target=mingw32 --prefix=/mingw --enable-threads --disable-nls --
enable-languages=c,c++,f77,ada,objc,java --disable-win32-registry --disable-shar
ed --enable-sjlj-exceptions --enable-libgcj --disable-java-awt --without-x --ena
ble-java-gc=boehm --disable-libgcj-debug --enable-interpreter --enable-hash-sync
hronization --enable-libstdcxx-debug
Thread model: win32
gcc version 3.4.5 (mingw special)
--- End quote ---
in C::B i'm using maybe :
--- Quote ---gcc -v
Configured with: ../gcc/configure --with-gcc --with-gnu-ld --with-gnu-as --host=
mingw32 --target=mingw32 --prefix=/mingw --enable-threads --disable-nls --enable
-languages=c,c++,f77,ada,objc,java --disable-win32-registry --disable-shared --e
nable-sjlj-exceptions --enable-libgcj --disable-java-awt --without-x --enable-ja
va-gc=boehm --disable-libgcj-debug --enable-interpreter --enable-hash-synchroniz
ation --enable-libstdcxx-debug
Thread model: win32
gcc version 3.4.4 (mingw special)
--- End quote ---
Well..wxPack as I know, it is not necessary to build anything.
MortenMacFly:
--- Quote from: ivan_ijh on January 07, 2008, 05:04:56 am ---I have a problem linking wxscintilla.
--- End quote ---
Try moving the wxscintilla lib before and after the wx lib (I don't recall what's right - but only *one* way is correct). The order of libraries that depend on each other matters in the linker settings!
stahta01:
--- Quote from: ivan_ijh on January 07, 2008, 02:29:51 pm ---gcc version 3.4.4 (mingw special)
--- End quote ---
Where did you get gcc version 3.4.4 (mingw special)?
Edit: Found it, RC2 had 3.4.4 with it.
I am downloading it now to test with wxPack.
I am still testing, but it appears to be an issue in the compiler gcc version 3.4.4 (mingw special) at first testing.
The wxPack works OK, so the issue is the compiler; please upgrade to 3.4.5 to use that wxPack.
Tim S
Navigation
[0] Message Index
[#] Next page
Go to full version