Re: libtool 2.1a failed mdemo-make.test on Solaris
Bruno Haible <[EMAIL PROTECTED]> writes: > You are right, the presence of $(ARGZ_H) in $(BUILT_SOURCES) makes this > rule unnecessary. (Historically, the rule predates the use of BUILT_SOURCES.) > Thanks for the hint. I propose this patch in gnulib. Thanks; I installed that. At the same time I cleaned up minor English-language glitches in the associated comments (e.g., "an "). ___ bug-gnulib mailing list bug-gnulib@gnu.org http://lists.gnu.org/mailman/listinfo/bug-gnulib
Re: libtool 2.1a failed mdemo-make.test on Solaris
Alexandre Duret-Lutz wrote: > Bruno> all-local $(libfoo_la_OBJECTS): $(ARGZ_H) > > Hmmm, why do you need this since $(ARGZ_H) is already in > $(BUILT_SOURCES), and "all" depends on $(BUILT_SOURCES)? You are right, the presence of $(ARGZ_H) in $(BUILT_SOURCES) makes this rule unnecessary. (Historically, the rule predates the use of BUILT_SOURCES.) Thanks for the hint. I propose this patch in gnulib. Bruno 2005-07-22 Bruno Haible <[EMAIL PROTECTED]> * modules/alloca-opt (Makefile.am): Remove explicit dependency on $(ALLOCA_H), redundant through BUILT_SOURCES. * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H), redundant through BUILT_SOURCES. * modules/byteswap (Makefile.am): Remove explicit dependency on $(BYTESWAP_H), redundant through BUILT_SOURCES. * modules/fnmatch (Makefile.am): Remove explicit dependency on $(FNMATCH_H), redundant through BUILT_SOURCES. * modules/getopt (Makefile.am): Remove explicit dependency on $(GETOPT_H), redundant through BUILT_SOURCES. * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H), redundant through BUILT_SOURCES. * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H), redundant through BUILT_SOURCES. * modules/stdbool (Makefile.am): Remove explicit dependency on $(STDBOOL_H), redundant through BUILT_SOURCES. * modules/stdint (Makefile.am): Remove explicit dependency on $(STDINT_H), redundant through BUILT_SOURCES. * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES. Remove explicit dependency on $(SYSEXITS_H). Reported by Alexandre Duret-Lutz <[EMAIL PROTECTED]>. *** modules/alloca-opt 29 Sep 2004 22:10:44 - 1.1 --- modules/alloca-opt 22 Jul 2005 19:30:39 - *** *** 18,24 # We need the following in order to create an when the system # doesn't have one that works with the given compiler. - all-local $(lib_OBJECTS): $(ALLOCA_H) alloca.h: alloca_.h cp $(srcdir)/alloca_.h [EMAIL PROTECTED] mv [EMAIL PROTECTED] $@ --- 18,23 *** modules/argz22 Sep 2004 16:23:27 - 1.3 --- modules/argz22 Jul 2005 19:30:39 - *** *** 17,23 # We need the following in order to create an when the system # doesn't have one that works with the given compiler. - all-local $(lib_OBJECTS): $(ARGZ_H) argz.h: argz_.h cp $(srcdir)/argz_.h [EMAIL PROTECTED] mv [EMAIL PROTECTED] $@ --- 17,22 *** modules/byteswap1 May 2005 14:13:02 - 1.1 --- modules/byteswap22 Jul 2005 19:30:39 - *** *** 16,22 # We need the following in order to create a when the system # doesn't have one. - all-local $(lib_OBJECTS): $(BYTESWAP_H) byteswap.h: byteswap_.h cp $(srcdir)/$< [EMAIL PROTECTED] mv [EMAIL PROTECTED] $@ --- 16,21 *** modules/fnmatch 6 May 2005 17:22:45 - 1.8 --- modules/fnmatch 22 Jul 2005 19:30:39 - *** *** 21,27 # We need the following in order to create an when the system # doesn't have one that supports the required API. - all-local $(lib_OBJECTS): $(FNMATCH_H) fnmatch.h: fnmatch_.h cp $(srcdir)/fnmatch_.h [EMAIL PROTECTED] mv [EMAIL PROTECTED] $@ --- 21,26 *** modules/getopt 6 Jul 2005 15:58:47 - 1.8 --- modules/getopt 22 Jul 2005 19:30:39 - *** *** 20,26 # We need the following in order to create an when the system # doesn't have one that works with the given compiler. - all-local $(lib_OBJECTS): $(GETOPT_H) getopt.h: getopt_.h cp $(srcdir)/getopt_.h [EMAIL PROTECTED] mv [EMAIL PROTECTED] $@ --- 20,25 *** modules/glob29 May 2005 16:56:02 - 1.1 --- modules/glob22 Jul 2005 19:30:39 - *** *** 28,34 # We need the following in order to create an when the system # doesn't have one that works with the given compiler. - all-local $(lib_OBJECTS): $(GLOB_H) glob.h: glob_.h cp $(srcdir)/glob_.h [EMAIL PROTECTED] mv [EMAIL PROTECTED] $@ --- 28,33 *** modules/poll22 Sep 2004 15:11:04 - 1.5 --- modules/poll22 Jul 2005 19:30:39 - *** *** 17,23 # We need the following in order to create an when the system # doesn't have one. - all-local $(lib_OBJECTS): $(POLL_H) poll.h: poll_.h cp $(srcdir)/poll_.h [EMAIL PROTECTED] mv [EMAIL PROTECTED] $@ --- 17,22 *** modules/stdbool 22 Sep 2004 15:11:04 - 1.10 --- modules/stdbool 22 Jul 2005 19:30:39 - *** *** 17,23 # We need the following in order to create an when the system # doesn't have one that works. - all-local $(lib_OBJECTS): $(STDBOOL_H) stdbool.h: stdbool_.h sed -e 's/@''HAVE__BOOL''@/$(HAVE
Re: [bug-gnulib] Re: libtool 2.1a failed mdemo-make.test on Solaris
>>> "Bruno" == Bruno Haible <[EMAIL PROTECTED]> writes: [...] Bruno> all-local $(libfoo_la_OBJECTS): $(ARGZ_H) Hmmm, why do you need this since $(ARGZ_H) is already in $(BUILT_SOURCES), and "all" depends on $(BUILT_SOURCES)? -- Alexandre Duret-Lutz ___ bug-gnulib mailing list bug-gnulib@gnu.org http://lists.gnu.org/mailman/listinfo/bug-gnulib
Re: [bug-gnulib] Re: libtool 2.1a failed mdemo-make.test on Solaris
Hi Bruno, * Bruno Haible wrote on Mon, Jul 11, 2005 at 01:23:26PM CEST: > > The modules in gnulib are normally used in a directory that creates a > single library, say libfoo.la, and in this case a line like > > all-local $(lib_OBJECTS): $(ARGZ_H) > > is meant to be changed to > > all-local $(libfoo_la_OBJECTS): $(ARGZ_H) > > If, in the case of libltdl, the directory creates several libraries, then > yes your patch looks OK: Thanks. Fortunately, meanwhile I have found a different, IMHO easier way to fix this instead. Your comment is still valuable as clarification of allowed usage. Cheers, Ralf > > +## Make sure argz.h will be created before it is needed: > > +lib_OBJECTS = \ > > + $(dlopen_la_OBJECTS) \ > > + $(dld_link_la_OBJECTS) \ > > + $(dyld_la_OBJECTS) \ > > + $(load_add_on_la_OBJECTS) \ > > + $(loadlibrary_la_OBJECTS) \ > > + $(shl_load_la_OBJECTS) \ > > + $(libltdl_la_OBJECTS) \ > > + $(libltdlc_la_OBJECTS) > > + ___ bug-gnulib mailing list bug-gnulib@gnu.org http://lists.gnu.org/mailman/listinfo/bug-gnulib
Re: [bug-gnulib] Re: libtool 2.1a failed mdemo-make.test on Solaris
Ralf Wildenhues wrote: > It's a bit tricky to reproduce: You > need a system which has no argz.h, then configure, then `make check' > without prior make. If you had ever run `make' before in this build > tree, even after `make clean' the dependency information is stored in > libltdl/.deps/*.Plo, and thus hides this bug. > > Now the gnulib snippet in libltdl/Makefile.am leaves us with the > possibility of using the lib_OBJECTS variable to fix this(?). > > Several questions (thus the crosspost to all of these lists): > - Is it ok/supposed by gnulib to use lib_OBJECTS for this? > - Is it ok by Automake to use the *_OBJECTS variables it created, > i.e., may they be treates as exported interface? The modules in gnulib are normally used in a directory that creates a single library, say libfoo.la, and in this case a line like all-local $(lib_OBJECTS): $(ARGZ_H) is meant to be changed to all-local $(libfoo_la_OBJECTS): $(ARGZ_H) If, in the case of libltdl, the directory creates several libraries, then yes your patch looks OK: > +## Make sure argz.h will be created before it is needed: > +lib_OBJECTS = \ > + $(dlopen_la_OBJECTS) \ > + $(dld_link_la_OBJECTS) \ > + $(dyld_la_OBJECTS) \ > + $(load_add_on_la_OBJECTS) \ > + $(loadlibrary_la_OBJECTS) \ > + $(shl_load_la_OBJECTS) \ > + $(libltdl_la_OBJECTS) \ > + $(libltdlc_la_OBJECTS) > + Bruno ___ bug-gnulib mailing list bug-gnulib@gnu.org http://lists.gnu.org/mailman/listinfo/bug-gnulib
Re: libtool 2.1a failed mdemo-make.test on Solaris
[ this thread starts at http://lists.gnu.org/archive/html/libtool/2005-06/msg00169.html ] Hi Sven, others, * Sven Verdoolaege wrote on Thu, Jun 23, 2005 at 09:11:36AM CEST: > On Thu, Jun 23, 2005 at 08:31:48AM +0200, Ralf Wildenhues wrote: > > > > It's this version that fails on solaris. > > > > Let's see: ls libltdl/argz.h created by running `make' in $top_builddir? > > Yes. I ran "make check" without a "make" first. > This seems to work on Linux... Yes, but that works only because GNU/Linux has argz.h. > Running make first makes tests/mdemo-make.test pass on Solaris. Ah, ok. Thanks for this report. It's a bit tricky to reproduce: You need a system which has no argz.h, then configure, then `make check' without prior make. If you had ever run `make' before in this build tree, even after `make clean' the dependency information is stored in libltdl/.deps/*.Plo, and thus hides this bug. Now the gnulib snippet in libltdl/Makefile.am leaves us with the possibility of using the lib_OBJECTS variable to fix this(?). Several questions (thus the crosspost to all of these lists): - Is it ok/supposed by gnulib to use lib_OBJECTS for this? - Is it ok by Automake to use the *_OBJECTS variables it created, i.e., may they be treates as exported interface? all-local cannot be used as it is executed too late. We could, however, just require the user to type `make' before `make check'. Ugly. Or call `$(MAKE) all-local' from mdemo first, and have a trivial all-local target in libltdl, if above requests are not confirmed. Ugly as well. FYI: libtool/tests/mdemo/Makefile.am has this: | libmlib_la_SOURCES = mlib.c | libmlib_la_LIBADD = @LIBLTDL@ "-dlopen" foo1.la "-dlopen" libfoo2.la | libmlib_la_LDFLAGS = -no-undefined | libmlib_la_DEPENDENCIES = @LIBLTDL@ libsub.la foo1.la libfoo2.la | ## use @LIBLTDL@ because some broken makes do not accept macros in targets | ## we can only do this because our LIBLTDL does not contain ${top_builddir} | top_distdir = ../.. | @LIBLTDL@: $(top_distdir)/libtool $(top_distdir)/libltdl/libtool \ | $(top_distdir)/libltdl/config.h $(srcdir)/$(top_distdir)/libltdl/ltdl.c \ | $(srcdir)/$(top_distdir)/libltdl/ltdl.h | (cd $(top_distdir)/libltdl; $(MAKE) `echo $(LIBLTDL) | sed 's,.*\.\./libltdl/,,g'`) and libltdl/Makefile.am has this: | ## --- ## | ## Gnulib Makefile.am snippets ## | ## --- ## | | ## ((( gnulib module argz | BUILT_SOURCES += $(ARGZ_H) | EXTRA_DIST += argz_.h | | # We need the following in order to create an when the system | # doesn't have one that works with the given compiler. | all-local $(lib_OBJECTS): $(ARGZ_H) | argz.h: argz_.h | cp $(srcdir)/argz_.h [EMAIL PROTECTED] | mv [EMAIL PROTECTED] $@ | MOSTLYCLEANFILES += argz.h argz.h-t | ## ))) gnulib module argz and the objects below libltdl will all depend on argz.h. Thanks, Ralf Proposed patch: Index: libltdl/Makefile.am === RCS file: /cvsroot/libtool/libtool/libltdl/Makefile.am,v retrieving revision 1.80 diff -u -r1.80 Makefile.am --- libltdl/Makefile.am 22 Apr 2005 10:10:30 - 1.80 +++ libltdl/Makefile.am 23 Jun 2005 08:35:27 - @@ -102,6 +102,17 @@ ## Make sure these will be cleaned even when they're not built by default: CLEANFILES = libltdl.la libltdlc.la libdlloader.la +## Make sure argz.h will be created before it is needed: +lib_OBJECTS = \ + $(dlopen_la_OBJECTS) \ + $(dld_link_la_OBJECTS) \ + $(dyld_la_OBJECTS) \ + $(load_add_on_la_OBJECTS) \ + $(loadlibrary_la_OBJECTS) \ + $(shl_load_la_OBJECTS) \ + $(libltdl_la_OBJECTS) \ + $(libltdlc_la_OBJECTS) + ## --- ## ## Gnulib Makefile.am snippets ## ___ bug-gnulib mailing list bug-gnulib@gnu.org http://lists.gnu.org/mailman/listinfo/bug-gnulib