Hello all,

I'm moving a project from static makefiles to using
autoconf/automake/libtool.   Everything is working great except for one
thing.

I need the ability to limit the dynamic symbols of a shared lib.  

The method (on Linux) I was using before was this:
gcc -g -uR -shared -Xlinker --version-script -Xlinker foo.mapfile -o
foo.so foo.o

I've tried this but it only limits the 'normal' symbols:
libfoo_la_LDFLAGS = -module -export-symbols foo.sym

nm --dynamic libfoo.so
still shows all the symbols and my program doesn't behave.

I have a system in which I dlopen a number of libs that all derive from
a common C++ base class.  This base class contains a few static
variables and functions that should be static to the lib not the whole
program. 

The motivation for moving to autoconf/make was to have a generic build
system for a project that currently needs to build on Linux and
Solairs.   I would like any solution to be generic across at least these
2 OSs.

Something like;
-export-dynamic-symbols SYMFILE 
is what I'm looking for.

Can anyone point me in the right direction.

Thanks,
Allen

Reply via email to