gcc 3.2 & linking
I have been using my redhat 8.0 box for some coding because of certain requirements.
Now redhat 8.0 uses gcc3.2 etc. And I'm having trouble linking libraries that require libstdc++ and compat-libstdc++. Particularly, compiling STLport libraries that someone has used in their code.
Lots of 'undefined references' to __throw and other error handling functions. Are these ones that C++ provide?
So, my question are:
Is gcc3.2 etc fully backward compatible?
Are my linking problems due to paths that are different in the 8.0 distro?
Is there a problem because STLport is distributed as a binary?
something like this. This isn't my code. It compiles OK on redhat 7.2/gcc 2.96.
All associated static and dynamic libraries are in /usr/lib.
libstdc++ etc to blame?
gcc -DNDEBUG -O3 -s -L/lib -L/usr/lib -L. -lstlport_gcc -luuid -lpthread -lxml2 -ldb_cxx -lstdc++ -lcurl test.c -lmyclient -o test
myclientimpl.o(.text+0xbef6): undefined reference to `__cp_pop_exception'
myclientimpl.o(.text+0xbf38): undefined reference to `__eh_rtime_match'
myclientimpl.o(.text+0xbf48): undefined reference to `__start_cp_handler'
myclientimpl.o(.text+0xbfb1): undefined reference to `__throw'
myclientimpl.o(.text+0xbfd4): undefined reference to `__builtin_delete'
myclientimpl.o(.text+0xbfe6): undefined reference to `_STL::__node_alloc<true, 0>::_M_deallocate(void *, unsigned int)'
myclientimpl.o(.text+0xc001): undefined reference to `__cp_pop_exception'
myclientimpl.o(.text+0xc011): undefined reference to `__throw'
Sorry changed g++ to gcc. Using g++, however, has the same effect.