This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Shared library that needs stuff from another library...



I am building some s/w I want to put into a shared library. It is a C++
class library that uses stuff that is in libstdc++.

If I build gcc with -enable-shared, everything builds fine.

If I build gcc without -enable-shared my shared library doesn't quite make
it, g++ exits with lots of complaints about "relocations remain against
allocatable but non-writable sections".

Is there a way (link flag?) to build my shared lib against a statically
built libstdc++, i.e., when I build my lib, the linker pulls in the stuff
my lib needs from libstdc++.a?

I would rather not have to distribute libstdc++.so with our product...

Thanks,
Mark Crosland


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]