Subject: Re: libtool question...
To: Nick Hudson <>
From: Todd Vierling <>
List: tech-pkg
Date: 03/21/2001 15:58:19
On Wed, 21 Mar 2001, Nick Hudson wrote:

: 	$ libtool --config | grep ^deplibs_check_method=
: 	$ file /usr/lib/

Could we possibly simplify the deplibs_check_method to something more like
the following (in libtool.m4/configure)?  We shouldn't be using file(1), if
possible, since its output could easily change between releases and

From my reading of the file_magic handling in, this should be
adequate.  The ELF linker searches for a file ending in ".so"--typically a
symlink, and the a.out linker searches for a file with a two-part version

As to whether this really should test for a shared object file:  If the
filename matches a linkable library, and it isn't physically a shared
object, let the linker try to use it and fail, as it would without the
presence of libtool.  That will point out important installation snafus on
the compiling system.


  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
    [lt_cv_deplibs_check_method='file_magic ^lib[^\.]\.so$'
    [lt_cv_deplibs_check_method='file_magic ^lib[^\.]\.so\.[0-9]+\.[0-9]+$'
  lt_cv_file_magic_test_file=`echo /usr/lib/*`

-- Todd Vierling <>  *  Wasabi NetBSD:  Run with it.
-- NetBSD 1.5 now available on CD-ROM  --