bolt:~/pub/fox-1.2.9/tests andy$ gltest dyld: gltest Undefined symbols: __ZTVN10__cxxabiv117__class_type_infoE
Also running otool -L and nm -m on gltest might be useful in order to see which library is different at runtime than at linktime and which library these undefined symbols are supposed to come from.
bolt:~/pub/fox-1.2.9/tests andy$ otool -L gltest gltest: is not an object file bolt:~/pub/fox-1.2.9/tests andy$
bolt:~/pub/fox-1.2.9/tests andy$ otool -L /usr/bin/gcc
/usr/bin/gcc:
/usr/lib/libiconv.2.dylib (compatibility version 5.0.0, current version 5.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 71.0.0)
bolt:~/pub/fox-1.2.9/tests andy$
Hmmm. Whatever g++ produced does not seem to be inspectable but this may be related to the prebinding warning?
I rebuilt the library and removed some of the suggestions I had picked up from the internet on how to get around problems with OSX linking. The library failed to link with lots of internal C++ symbols. I explicitly added -lstdc++ and this resolved the symbols. Why doesn't linking with g++ do this?
Now gltest links but with warnings about opengl system libraries:
bolt:~/pub/fox-1.2.9/tests andy$ make gltest
/bin/sh ../libtool --mode=link g++ -DHAVE_XSHM_H=1 -D_GNU_SOURCE -DHAVE_ZLIB_H=1 -DHAVE_BZ2LIB_H=1 -DHAVE_XCURSOR_H=1 -Wall -W -Wmissing-prototypes -Woverloaded-virtual -Wformat -DHAVE_GL_H=1 -DSUN_OGL_NO_VERTEX_MACROS -DHPOGL_SUPPRESS_FAST_API -DHAVE_GLU_H=1 -I/usr/X11R6/include -o gltest gltest.o ../src/libFOX-1.2.la -lm -L/usr/X11R6/lib -ldl -lpthread -lz -lbz2 -lm -lGL -lGLU
g++ -DHAVE_XSHM_H=1 -D_GNU_SOURCE -DHAVE_ZLIB_H=1 -DHAVE_BZ2LIB_H=1 -DHAVE_XCURSOR_H=1 -Wall -W -Wmissing-prototypes -Woverloaded-virtual -Wformat -DHAVE_GL_H=1 -DSUN_OGL_NO_VERTEX_MACROS -DHPOGL_SUPPRESS_FAST_API -DHAVE_GLU_H=1 -I/usr/X11R6/include -o .libs/gltest gltest.o -L../src/.libs -lFOX-1.2 -L/usr/X11R6/lib -lXext -lX11 -lXcursor -lstdc++ -ldl -lpthread -lz -lbz2 -lm -lGL -lGLU
ld: warning prebinding disabled because of symbols overridden in dependent dynamic shared libraries:
/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/ libGLU.dylib(quad.o) definition of _gluCylinder
/usr/X11R6/lib/libGLU.dylib(quad.o) definition of _gluCylinder
ld: warning prebinding disabled because of symbols overridden in dependent dynamic shared libraries:
/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/ libGLU.dylib(quad.o) definition of _gluDeleteQuadric
/usr/X11R6/lib/libGLU.dylib(quad.o) definition of _gluDeleteQuadric
ld: warning prebinding disabled because of symbols overridden in dependent dynamic shared libraries:
/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/ libGLU.dylib(quad.o) definition of _gluDisk
/usr/X11R6/lib/libGLU.dylib(quad.o) definition of _gluDisk
ld: warning prebinding disabled because of symbols overridden in dependent dynamic shared libraries:
/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/ libGLU.dylib(quad.o) definition of _gluNewQuadric
/usr/X11R6/lib/libGLU.dylib(quad.o) definition of _gluNewQuadric
ld: warning prebinding disabled because of symbols overridden in dependent dynamic shared libraries:
/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/ libGLU.dylib(quad.o) definition of _gluQuadricDrawStyle
/usr/X11R6/lib/libGLU.dylib(quad.o) definition of _gluQuadricDrawStyle
ld: warning prebinding disabled because of symbols overridden in dependent dynamic shared libraries:
/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/ libGLU.dylib(quad.o) definition of _gluQuadricOrientation
/usr/X11R6/lib/libGLU.dylib(quad.o) definition of _gluQuadricOrientation
ld: warning prebinding disabled because of symbols overridden in dependent dynamic shared libraries:
/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/ libGLU.dylib(quad.o) definition of _gluSphere
/usr/X11R6/lib/libGLU.dylib(quad.o) definition of _gluSphere
creating gltest
bolt:~/pub/fox-1.2.9/tests andy$
Why has not prebinding for the opengl library worked while not prebinding for the fox library failed with obscure internal C++ symbols? Is C++ the problem? Or the combination of C++ and C?
gltest ran for a while but segmentation faults on exit. I can trace this but things are clearly not right. Suggestions?
------------------------------------------------------- This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170 Project Admins to receive an Apple iPod Mini FREE for your judgement on who ports your project to Linux PPC the best. Sponsored by IBM. Deadline: Sept. 24. Go here: http://sf.net/ppc_contest.php _______________________________________________ Fink-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/fink-devel