kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #12641
Glew linking errors
I've spent the last few days working to compile Kicad product and I'm so
close I can taste it. Currently, the compile is 100% complete, but now
the link is failing with messages regarding OpenGL.
Linking CXX executable pcbnew.exe
..\common\libgal.a(opengl_gal.cpp.obj):opengl_gal.cpp:(.text+0x2831):
undefined
reference to `_imp____GLEW_VERSION_2_1'
..\common\libgal.a(opengl_gal.cpp.obj):opengl_gal.cpp:(.text+0x2a0f):
undefined
reference to `_imp____GLEW_EXT_framebuffer_object'
..\common\libgal.a(opengl_gal.cpp.obj):opengl_gal.cpp:(.text+0x2a1d):
undefined
reference to `_imp____GLEW_ARB_vertex_buffer_object'
c:/tdm-gcc-32/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe:
..\co
mmon\libgal.a(opengl_gal.cpp.obj): bad reloc address 0x2 in section
`.text$_ZN5b
oost6detail17sp_counted_impl_pIN5KIGFX11VERTEX_ITEMEED1Ev[__ZN5boost6detail17sp_
counted_impl_pIN5KIGFX11VERTEX_ITEMEED1Ev]'
It looks like I've linked the wrong library for Glew. In Cmake I set
GLEW_GLEW_LIBRARY = glew-1.10.0/lib/Release/Win32/glew32.lib
Is this setting correct?
What else might be causing these errors?
The complete build output is below.
Any help is greatly appreciated.
Thanks,
David
[100%] Building CXX object
pcbnew/CMakeFiles/pcbnew.dir/__/common/base_units.cpp
.obj
Linking CXX executable pcbnew.exe
..\common\libgal.a(opengl_gal.cpp.obj):opengl_gal.cpp:(.text+0x2831):
undefined
reference to `_imp____GLEW_VERSION_2_1'
..\common\libgal.a(opengl_gal.cpp.obj):opengl_gal.cpp:(.text+0x2a0f):
undefined
reference to `_imp____GLEW_EXT_framebuffer_object'
..\common\libgal.a(opengl_gal.cpp.obj):opengl_gal.cpp:(.text+0x2a1d):
undefined
reference to `_imp____GLEW_ARB_vertex_buffer_object'
c:/tdm-gcc-32/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe:
..\co
mmon\libgal.a(opengl_gal.cpp.obj): bad reloc address 0x2 in section
`.text$_ZN5b
oost6detail17sp_counted_impl_pIN5KIGFX11VERTEX_ITEMEED1Ev[__ZN5boost6detail17sp_
counted_impl_pIN5KIGFX11VERTEX_ITEMEED1Ev]'
c:/tdm-gcc-32/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe:
final
link failed: Invalid operation
collect2.exe: error: ld returned 1 exit status
pcbnew\CMakeFiles\pcbnew.dir\build.make:5348: recipe for target
'pcbnew/pcbnew.e
xe' failed
mingw32-make[3]: *** [pcbnew/pcbnew.exe] Error 1
CMakeFiles\Makefile2:832: recipe for target
'pcbnew/CMakeFiles/pcbnew.dir/all' f
ailed
mingw32-make[2]: *** [pcbnew/CMakeFiles/pcbnew.dir/all] Error 2
CMakeFiles\Makefile2:844: recipe for target
'pcbnew/CMakeFiles/pcbnew.dir/rule'
failed
mingw32-make[1]: *** [pcbnew/CMakeFiles/pcbnew.dir/rule] Error 2
Makefile:370: recipe for target 'pcbnew' failed
mingw32-make: *** [pcbnew] Error 2
Follow ups