bug-libtool
[Top][All Lists]
Advanced

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

Re: [PATCH] Standalone libltdl Build


From: Gary V. Vaughan
Subject: Re: [PATCH] Standalone libltdl Build
Date: Thu, 14 Oct 2004 09:28:51 +0100
User-agent: Mozilla Thunderbird 0.8 (Macintosh/20040913)

Hi Noah!

Noah Misch wrote:
Today I bootstrapped CVS m4 from CVS autoconf, automake, and libtool, and the
compilation failed in the included libltdl:

<snip>
Making all in libltdl
cp ../../libltdl/argz_.h argz.h-t
mv argz.h-t argz.h
make  all-recursive
Making all in loaders
make  all-am
source='../../../libltdl/loaders/dyld.c' object='dyld.lo' libtool=yes \
DEPDIR=.deps depmode=gcc /bin/sh ../../../libltdl/config/depcomp \
/bin/sh ../libtool --tag=CC --mode=compile cc -DHAVE_CONFIG_H="<config.h>" 
-DLTDL -I. -I../../../libltdl/loaders -I..  -I.. -I../../../libltdl -I.. 
-I../../../libltdl/loaders/..   -g -O2 -c -o dyld.lo ../../../libltdl/loaders/dyld.c
 cc "-DHAVE_CONFIG_H=<config.h>" -DLTDL -I. -I../../../libltdl/loaders -I.. 
-I.. -I../../../libltdl -I.. -I../../../libltdl/loaders/.. -g -O2 -c 
../../../libltdl/loaders/dyld.c -Wp,-MD,.deps/dyld.TPlo  -fno-common -DPIC -o .libs/dyld.o
../../../libltdl/lt_dlloader.h:33: header file 'libltdl/lt_system.h' not found
<snip similar errors>

lt_system.h is in $(top_srcdir) of the standalone libltdl build, so the
preprocessor does not find it.  Building libltdl with the libtool build process
masks this problem since $(top_srcdir) is then that of libtool, allowing the
location of the headers to become $(top_srcdir)/libltdl.

Ah, good catch!  Thanks.

How about this fix (against HEAD)?  I omitted the renames from the diff.

2004-10-06  Noah Misch  <address@hidden>

        * configure.ac: Configure libltdl as an ordinary sub-project with
        its own ``configure''.

        * ltdl/lt_dlloader.h ltdl/lt_error.h ltdl/lt_system.h ltdl/ltdl.h:
        Moved from here...
        * ltdl/api/libltdl/lt_dlloader.h ltdl/api/libltdl/lt_error.h
        ltdl/api/libltdl/lt_system.h ltdl/api/ltdl.h: ...to here.
        * ltdl/Makefile.am: Add ``-I''s for new header directories to
        AM_CPPFLAGS.  Update header references.
        * ltdl/loaders/Makefile.am: Likewise, and remove unneeded ``-I''s.
        * m4/ltdl.m4: Update $LTDLINCL to reflect new directory structure.

        * NEWS: Updated.

Hmmm... I don't want to go back down this road if I can avoid it, because by not using libltdl configure.ac (and this will be especially
true when we've moved to an Autotest testsuite) we save shipping another
aclocal.m4, configure, ltmain.sh etc.

I think the right way to catch a regression like this is by adding a new test that builds a standalone libltdl with the user's autotools. The test coverage of libltdl is particularly poor right now, so I would hope
that such a test might open the door for better libltdl test cases all
round.

I'll commit a more conservative fix to branch-2-0 and HEAD soon.

Cheers,
        Gary.
--
Gary V. Vaughan      ())_.  address@hidden,gnu.org}
Research Scientist   ( '/   http://tkd.kicks-ass.net
GNU Hacker           / )=   http://www.gnu.org/software/libtool
Technical Author   `(_~)_   http://sources.redhat.com/autobook

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]