This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
How can I link several static libraries into single shared library?
- From: michael kapelko <kornerr at gmail dot com>
- To: binutils at sourceware dot org
- Date: Tue, 11 May 2010 14:09:19 +0700
- Subject: How can I link several static libraries into single shared library?
Hi.
I want to link several static libraries into single shared library.
So far I'm trying to link ALURE(http://kcat.strangesoft.net/alure.html)
static library into my shared library:
g++ -shared -o libmj.so /usr/local/lib/libalure.a
But that leaves my libmj.so of 6K size, while libalure.a is of 1.5M.
Looks like linker discards all unused symbols from libalure.
How do I force it to put *ALL* symbols from libalure.a into my libmj.so?
Thanks.