Re: Linking on AIX

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I tried "ar tv" on libubic.a and I get what I think is correct:

rwxr-xr-x  1409/105   7391044 Aug 16 10:59 2005 libubic.so.0
rw-r--r--  1409/105   210082 Aug 02 10:56 2005 Fasta.o
rw-r--r--  1409/105   293687 Aug 02 10:56 2005 FastaLoader.o
rw-r--r--  1409/105   332056 Aug 02 10:56 2005 Dbrc.o
rw-r--r--  1409/105   237825 Aug 02 10:56 2005 MysqlDb.o
rw-r--r--  1409/105   309442 Aug 02 10:56 2005 Tax.o
rw-r--r--  1409/105    69525 Aug 02 10:56 2005 TaxonIdName.o
rw-r--r--  1409/105    93349 Aug 02 10:56 2005 TaxGet.o
rw-r--r--  1409/105      648 Aug 02 10:56 2005 Tclap.o
rw-r--r--  1409/105   265350 Aug 02 10:56 2005 Stats.o
rw-r--r--  1409/105    81579 Aug 02 10:56 2005 StatsDb.o

Yet, libubic.a remains in the hidden directory lib/.libs which I would have expected to have been included with the installed library libubic.a. This seems odd to me and make me wonder how libubic.a can find this .so file. I tried to copy it into the install directory along with the installed libubuic.a but without any change to my linking problem.

Also in this hidden directory is libubic.exp. A good chunk of this file contains names prepended with underscores, such as "_Allocate__3stdHc_UlPc_Pc", but there are other names without an underscore such as "TaxonId__11TaxonIdNameCFv".
Is this the export list that you suggest I modify/create?

Much appreciated,

John Ling

David Edelsohn wrote:

	Traditional AIX shared libraries are achives of shared objects.
If you look at the archive with "ar tv" or the AIX "dump -H" command, you
should see the shared object .so file as a member of the archive.

	The GCC C++ ABI name mangling prepends an underscore to symbols.
AIX's default behavior for exporting symbols from shared libaries does not
export symbols with prepended underscores.  You probably need to
explicitly create an export list of the symbols that should be exported
from the shared object inside the archive library.

David



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux