[gecode-users] Linker errors when compiling Gecode with GCC on Windows

Mailing List Email mailinglistx at gmail.com
Sun May 12 16:24:04 CEST 2013


Hi all,

I'm trying to compile some Gecode code with GCC on Windows. I am getting
the following linking errors:

ccUI4ffQ.o:NoOverlap.cpp:(.text$_ZN6Gecode9ExceptionD2Ev[__ZN6Gecode9ExceptionD2Ev]+0xe):
undefined reference to `_imp___ZTVN6Gecode9ExceptionE'
ccUI4ffQ.o:NoOverlap.cpp:(.text$_ZN6Gecode15MemoryExhaustedC1Ev[__ZN6Gecode15MemoryExhaustedC1Ev]+0x1e):
undefined reference to  `_imp___ZN6Gecode9ExceptionC2EPKcS2_'
c:/test/mingw64-4.8/bin/../lib/gcc/i686-w64-mingw32/4.8.0/../../../../i686-w64-mingw32/bin/ld.exe:
C:\Users\Mana\AppData\Local\Temp\ccUI4ffQ.o: bad reloc address 0x1e in
section
`.text$_ZN6Gecode15MemoryExhaustedC1Ev[__ZN6Gecode15MemoryExhaustedC1Ev]'
collect2.exe: error: ld returned 1 exit status

I compiled Gecode myself on Windows using mingw. These errors occur no
matter what libraries I try to link. Always the same error.
For example, I've tried the following command line:

cls && g++ -isystem"C:\Program Files\Gecode\include"
-L"D:\Dropbox\Stuff\Projects\gecode-4.0.0\build" -Wall -std=c++11
NoOverlap.cpp SquarePacking.cpp -lgecodedriver -lgecodeflatzinc
-lgecodefloat -lgecodegist -lgecodeint -lgecodekernel -lgecodeminimodel
-lgecodesearch -lgecodeset -lgecodesupport

But it still gives the same error.
Any ideas?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.gecode.org/pipermail/users/attachments/20130512/f7fc886f/attachment.html>


More information about the users mailing list