[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: 279-gary-LT_CONFIG_LTDL_DIR.diff
From: |
Ralf Wildenhues |
Subject: |
Re: 279-gary-LT_CONFIG_LTDL_DIR.diff |
Date: |
Thu, 29 Sep 2005 16:52:17 +0200 |
User-agent: |
Mutt/1.5.11 |
Hi Gary,
* Gary V. Vaughan wrote on Thu, Sep 29, 2005 at 11:19:41AM CEST:
> Ralf Wildenhues wrote:
> >* Gary V. Vaughan wrote on Tue, Sep 27, 2005 at 03:36:43PM CEST:
> >>I'm not sure I understand how the aclocal.m4 problem came
> >>to be:
> >
> >(The aclocal.m4 problem is orthogonal; let's discuss it elsewhere).
>
> Okay. I'd like to fix this in a separate patch.
I had previously thought this wasn't a Libtool bug at all..
*snip*
> >Then, there's a bug: --without-included-ltdl leads to
> >| checking for ltdl.h... yes
> >| checking for lt_dlcaller_register in -lltdl... yes
> >| checking whether to use included libltdl... no
> >
> >and
> >| LIBLTDL = -lltdl
> >...
> >| LTDLINCL = -I${top_srcdir}/ltdl/
> >
> >which is wrong -- the include path should not be changed here.
> >I'll provide a few more data points to reproduce this (it's ok if you
> >want to fix this in a separate patch).
>
> I've fixed it here. Nice catch btw. :-)
Thank you.
*big snip of all fixed items*
> Okay to commit?
I really don't want this to be a neverending story, ;)
but there are some more issues.
- One is the following (only happens if sub/ltdl does not exist):
$ libtoolize --copy --ltdl
*snip*
libtoolize: copying file `sub/ltdl/config/ltmain.sh'
libtoolize: `./ltmain.sh' is already up to date.
libtoolize: putting macros in AC_CONFIG_MACRO_DIR, `sub/ltdl/m4'.
libtoolize: copying file `sub/ltdl/m4/libtool.m4'
/bin/sed: can't read sub/ltdl/m4/argz.m4: No such file or directory
/bin/sed: can't read sub/ltdl/m4/ltdl.m4: No such file or directory
I believe it is fixed with the following patch. OK to apply?
(By the way, the use of global variables prefixed with my_ really sucks
here; I also needed some time to realize that you are actually not using
them wrongly.)
* libtoolize.m4sh (func_included_files): Do not recurse
non-existent files.
Index: libtoolize.m4sh
===================================================================
RCS file: /cvsroot/libtool/libtool/libtoolize.m4sh,v
retrieving revision 1.34
diff -u -r1.34 libtoolize.m4sh
--- libtoolize.m4sh 27 Sep 2005 13:09:20 -0000 1.34
+++ libtoolize.m4sh 29 Sep 2005 14:04:51 -0000
@@ -453,13 +500,13 @@
if test -f "$my_searchfile"; then
$ECHO "X$my_searchfile" | $Xsed
- fi
- # Only recurse when we don't care if all the variables we use get
- # trashed, since they are in global scope.
- for my_filename in `$SED "$my_sed_include" "$my_searchfile"`; do
- func_included_files $my_filename
- done
+ # Only recurse when we don't care if all the variables we use get
+ # trashed, since they are in global scope.
+ for my_filename in `$SED "$my_sed_include" "$my_searchfile"`; do
+ func_included_files $my_filename
+ done
+ fi
}
- The other problems are connected to the AC_CONFIG_SUBDIRS call in
LT_WITH_LTDL, is both wrong there, and does not work.
Wrong in the sense that, should non-subpackage libltdl ever work, it
should still be possible to use LT_WITH_LTDL (this is what Bob
complained about originally). IOW: the decision whether libltdl is to
be a subpackage or not must be done in a new macro. And the default
should of course be that libltdl _is_ a subpackge (backwards
compatible). This may be fixed in an another patch though, it's not
a regression introduced by this one.
The other thing is, that calling toplevel configure does not recurse
into the subdir: To reproduce:
cat >configure.ac <<EOF
AC_INIT(a,1,b)
AM_INIT_AUTOMAKE
AC_CONFIG_SRCDIR(foo.c)
AC_PROG_CC
LT_CONFIG_LTDL_DIR(sub/ltdl)
LT_WITH_LTDL
AC_LIB_LTDL
AM_PROG_LIBTOOL
AC_CONFIG_FILES(Makefile)
AC_OUTPUT
EOF
cat >Makefile.am <<EOF
ACLOCAL_AMFLAGS = -I sub/ltdl/m4
lib_LTLIBRARIES = foo.la
foo_la_LDFLAGS = -module -avoid-version
SUBDIRS = sub/ltdl
EOF
touch foo.c
libtoolize --copy --ltdl
aclocal -I sub/ltdl/m4
autoheader
automake --foreign --add
autoconf
./configure # does not invoke sub/ltdl/configure
Here's a possible reason:
grep _LTDL_DIR Makefile configure
| Makefile:subdirs = _LTDL_DIR
| configure:ac_subdirs_all='_LTDL_DIR'
| configure:subdirs="$subdirs _LTDL_DIR"
So it does not work. Adding
AC_CONFIG_SUBDIRS(sub/ltdl)
to configure.ac fails as well, though:
| configure.ac:8: error: `sub/ltdl' is already registered with
AC_CONFIG_SUBDIRS.
| autoconf/status.m4:871: AC_CONFIG_SUBDIRS is expanded from...
| sub/ltdl/m4/ltdl.m4:192: LT_WITH_LTDL is expanded from...
| configure.ac:8: the top level
If you decide you want to fix this in a subsequent patch, then fine;
but note the tree will be unusable for libltdl-users in-between, so
I ask you to commit them together.
- The fourth item is very similar to the second: autoreconf breaks
(use it instead of my manual calls of the autotools):
| autoreconf: configure.ac: tracing
| autoreconf: configure.ac: subdirectory _LTDL_DIR not present
| autoreconf: configure.ac: not running libtoolize: --install not given
- The fifth thing is, that I can't seem to disable the included ltdl:
--without-included-ltdl
--with-included-ltdl=no
-without-included-ltdl
-with-included-ltdl=no
all end up with
| checking whether to use included libltdl... yes
I believe this worked in the last iteration of your patch.
It's a twisted maze. :-/
Cheers,
Ralf