libtool-patches
[Top][All Lists]
Advanced

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

(non)recursive mode fixups


From: Ralf Wildenhues
Subject: (non)recursive mode fixups
Date: Mon, 7 Nov 2005 16:32:59 +0100
User-agent: Mutt/1.5.11

Hi Gary,

nonrecursive mode is cool.  Thanks for all your commits!

It has a few warts, though, but also another cool thing can be fixed
now.

First the good thing: in principle, libltdl can do fine without an
AC_CONFIG_HEADER at all:

--- libltdl/Makefile.inc        2005-10-26 12:42:05.000000000 +0200
+++ libltdl/Makefile.inc        2005-11-07 16:13:55.000000000 +0100
@@ -26,7 +26,7 @@
 
 # -I$(srcdir) is needed for user that built libltdl with a sub-Automake
 # (not as a sub-package!) using 'nostdinc':
-AM_CPPFLAGS           += -DHAVE_CONFIG_H -DLT_CONFIG_H='<$(LT_CONFIG_H)>' \
+AM_CPPFLAGS           += -DLT_CONFIG_H='<$(LT_CONFIG_H)>' \
                          -DLTDL -I. -I$(srcdir) -Ilibltdl \
                          -I$(srcdir)/libltdl -I$(srcdir)/libltdl/libltdl
 AM_LDFLAGS            += -no-undefined
diff -u m4/ltdl.m4 
/mount/endor/wildenhu/download/software/libtool/install/libtool-2.1/share/aclocal/ltdl.m4
--- libltdl/m4/ltdl.m4  2005-11-07 15:49:08.000000000 +0100
+++ libltdl/m4/ltdl.m4  2005-11-07 16:18:01.000000000 +0100
@@ -273,10 +273,10 @@
 dnl _LTDL_MODE specific code must be evaluated at least once:
 _LTDL_MODE_DISPATCH
 
-# In order that ltdl.c can compile, run AC_CONFIG_HEADERS for the user
-# if they did not call it themself.  This is so that ltdl.h can pick up
-# the parent projects config.h file, The first file in AC_CONFIG_HEADERS
-# must contain the definitions required by ltdl.c.
+# In order that ltdl.c can compile, find out the first AC_CONFIG_HEADERS
+# the user used.  This is so that ltdl.h can pick up the parent projects
+# config.h file, The first file in AC_CONFIG_HEADERS must contain the
+# definitions required by ltdl.c.
 # FIXME: Remove use of undocumented AC_LIST_HEADERS (2.59 compatibility).
 AC_CONFIG_COMMANDS_PRE([dnl
 m4_pattern_allow([^LT_CONFIG_H$])dnl
@@ -284,11 +284,7 @@
     [LT_CONFIG_H=AH_HEADER],
     [m4_ifset([AC_LIST_HEADERS],
            [LT_CONFIG_H=`echo "AC_LIST_HEADERS" | $SED 's,^[[      ]]*,,;s,[[ 
:]].*$,,'`],
-       [LT_CONFIG_H=config.h
-       dnl subproject mode libltdl has its own config.h...
-       m4_if(_LTDL_MODE, [subproject],
-               [],
-           [AC_CONFIG_HEADERS([config.h:config-h.in])])])])])
+       [])])])
 AC_SUBST([LT_CONFIG_H])
 
 AC_CHECK_HEADERS([memory.h unistd.h dl.h sys/dl.h dld.h mach-o/dyld.h],



Now the warts:  This works:  (Note no autoheader!)

cat >configure.ac <<EOF
AC_INIT([nonrec-test],1,[devnull])
LT_CONFIG_LTDL_DIR([libltdl],[nonrecursive])
AM_INIT_AUTOMAKE([foreign])
AC_PROG_CC
LT_INIT
LT_WITH_LTDL
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
EOF
cat >Makefile.am <<EOF
ACLOCAL_AMFLAGS = -I libltdl/m4
AM_CPPFLAGS =
AM_LDFLAGS =
EXTRA_DIST =
CLEANFILES =
MOSTLYCLEANFILES =
noinst_LTLIBRARIES =
lib_LTLIBRARIES =
EXTRA_LTLIBRARIES =
BUILT_SOURCES =
include libltdl/Makefile.inc
EOF
libtoolize --ltdl --install --nonrecursive
aclocal -I libltdl/m4
automake -a
autoconf
./configure
make

But this then fails:
make dist

The dist target currently needs all these files to exist:
libltdl/m4/lt~obsolete.m4 libltdl/aclocal.m4 libltdl/configure.ac
libltdl/configure libltdl/config-h.in libltdl/Makefile.in
libltdl/Makefile.am

If I touch them, "make distcheck" passes.

Can you fix this?  Then, (non)recursive mode will be really usable!

Cheers,
Ralf




reply via email to

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