[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
building a libtool library from standard objects doesn't fail!
From: |
Gary V. Vaughan |
Subject: |
building a libtool library from standard objects doesn't fail! |
Date: |
Mon, 23 Feb 2004 13:53:00 +0000 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6b) Gecko/20031205 Thunderbird/0.4 |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I'm auditing doc/libtool.texi in preparation for the release :-)
According to the manual:
~ Again, the libtool library name differs from the standard name (it
~ has a `.la' suffix instead of a `.a' suffix). The arguments to libtool
~ are the same ones you would use to produce an executable named
~ `libhello.la' with your compiler (*note Link mode::):
~ a23$ libtool --mode=link gcc -g -O -o libhello.la foo.o hello.o
~ libtool: cannot build libtool library `libhello.la' from non-libtool
objects
~ a23$
~ Aha! Libtool caught a common error... trying to build a library
~ from standard objects instead of library objects. This doesn't matter
~ for static libraries, but on shared library systems, it is of great
~ importance.
And yet:
~ ~/devel/savannah/libtool/tests/demo $ ./libtool link gcc -g -O -o
libhello.la foo.o hello.o
~ *** Warning: Linking the shared library libhello.la against the non-libtool
~ *** objects foo.o hello.o is not portable!
~ ar cru .libs/libhello.a
~ ranlib .libs/libhello.a
~ creating libhello.la
~ (cd .libs && rm -f libhello.la && ln -s ../libhello.la libhello.la)
~ ~/devel/savannah/libtool/tests/demo $ ar t .libs/libhello.a
~ ~/devel/savannah/libtool/tests/demo $ ls -l .libs
~ total 9
~ -rw-r--r-- 1 gary gary 9516 Feb 23 13:31 foo.o
~ -rw-r--r-- 1 gary gary 9436 Feb 23 13:31 hello.o
~ -rw-r--r-- 1 gary gary 8 Feb 23 13:34 libhello.a
~ lrwxrwxrwx 1 gary gary 14 Feb 23 13:34 libhello.la ->
../libhello.la
~ ~/devel/savannah/libtool/tests/demo $
BUG 1: The manual does not match what the user will see if they try it
BUG 2: Libtool makes an empty ar archive
ChangeLog archaeology doesn't reveal anything.
Cheers,
Gary.
- --
Gary V. Vaughan ())_. address@hidden,gnu.org}
Research Scientist ( '/ http://www.oranda.demon.co.uk
GNU Hacker / )= http://www.gnu.org/software/libtool
Technical Author `(_~)_ http://sources.redhat.com/autobook
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFAOgW8FRMICSmD1gYRAhafAKCofyqWd0nM0wSuaKxeoS7sgYpycwCcC+QR
0x7ofL82Qkht3isVHkNqMPU=
=3SLI
-----END PGP SIGNATURE-----
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- building a libtool library from standard objects doesn't fail!,
Gary V. Vaughan <=