bug#8969: improve synchronization between examples in the manual and test cases
On Wednesday 06 July 2011, Ralf Wildenhues wrote: * Stefano Lattarini wrote on Wed, Jul 06, 2011 at 10:32:56AM CEST: Oops, sorry. Fixed by the attached patch. OK for maint? I'll wait the customary 72 hours before pushing. Thanks. OK, but please remove all the comments about tar unportability in the tests. It's so obvious. ;-) OK done. (and there are probably a dozen other places in the Automake source tree that you'd have to put the comment at as well, for any amount of consistency. I think having one comment, the one that already exists in lib/am/distdir.am, is fully sufficient.) I'm ok with fixing the manual also, although it's usually clear for people still having to use those vendor tars (and inconvenient for the rest). Yes, I'd say we leave the examples in manual untouched. Agreed? OK. Subject: [PATCH] tests: portability fixes in tests on amhello examples * tests/amhello-binpkg.test: Don't use tar xzf too.tag.gz to extract a gzip-compressed tarball, that's unportable to some tar implementations; use the gzip -dc fo.tar.gz | tar xf - idiom instead. * tests/amhello-cflags.test: Likewise. * tests/amhello-cross-compile.test: Likewise. Thanks, Ralf Pushed now. Thanks, Stefano
bug#9026: Supporting $ACLOCAL_PATH?
Hello, On an FHS-style system, all macros are picked up from /usr/share/aclocal. Conversely, on a Stow/Nix-style installation, macros are to be found in /foo/automake/share/aclocal, /bar/guile/share/aclocal, /baz/pkg-config/share/aclocal, etc. It seems to me that the latter calls for user environment-specific settings, which an $ACLOCAL_PATH environment variable would handily support [0]. WDYT? Bruno rightfully noted the importance of having a reproducible way of producing tarballs, and user-specific environment settings appear to go counter this goal. However, there will always be a need for this kind of setting on Stow/Nix-style systems, AFAICS. Thanks, Ludo’. [0] In fact Nixpkgs/NixOS has a wrapper around ‘aclocal’ that does exactly this (see https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/development/tools/misc/automake/builder.sh.)
bug#9026: Supporting $ACLOCAL_PATH?
tags 9026 patch thanks On Friday 08 July 2011, Ludovic Courtès wrote: Hello, Hi Ludovic, thanks for the report. On an FHS-style system, all macros are picked up from /usr/share/aclocal. Conversely, on a Stow/Nix-style installation, macros are to be found in /foo/automake/share/aclocal, /bar/guile/share/aclocal, /baz/pkg-config/share/aclocal, etc. It seems to me that the latter calls for user environment-specific settings, which an $ACLOCAL_PATH environment variable would handily support [0]. WDYT? Bruno rightfully noted the importance of having a reproducible way of producing tarballs, and user-specific environment settings appear to go counter this goal. However, there will always be a need for this kind of setting on Stow/Nix-style systems, AFAICS. Thanks, Ludo’. [0] In fact Nixpkgs/NixOS has a wrapper around ‘aclocal’ that does exactly this (see https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/development/tools/misc/automake/builder.sh.) JFTR, there's a pending patch series by Paolo Bonzini that introduces exactly the feature you're requesting: http://lists.gnu.org/archive/html/automake-patches/2010-11/msg00089.html I'm highly in favor of having the series applied to maint ASAP, but we should wait for Ralf's ACK before doing that (and probably he won't be avaiable this weekend). Regards, Stefano
bug#9026: Supporting $ACLOCAL_PATH?
Ludovic Courtès wrote: ... having a reproducible way of producing tarballs, and user-specific environment settings appear to go counter this goal. Not only that. Also, it is important for distributors to be able to regenerate the 'configure' file of packages, for a variety of reasons. They can only do so if the tarball contains the _complete_ source code of the configure file, that is, all the .m4 files that were used to create it, except the .m4 files of Automake and Autoconf. Have you ever tried to rebuild the configure file of a package that did not package pkgconfig.m4 or glib.m4? It's a nightmare. Therefore, please don't encourage maintainers to omit nontrivial .m4 files from the tarball. Adding support $ACLOCAL_PATH would do exactly that. Bruno -- In memoriam Jean Moulin http://en.wikipedia.org/wiki/Jean_Moulin
bug#9026: Supporting $ACLOCAL_PATH?
Hi Bruno. On Friday 08 July 2011, Bruno Haible wrote: Ludovic Courtès wrote: ... having a reproducible way of producing tarballs, and user-specific environment settings appear to go counter this goal. Not only that. Also, it is important for distributors to be able to regenerate the 'configure' file of packages, for a variety of reasons. They can only do so if the tarball contains the _complete_ source code of the configure file, that is, all the .m4 files that were used to create it, except the .m4 files of Automake and Autoconf. Have you ever tried to rebuild the configure file of a package that did not package pkgconfig.m4 or glib.m4? It's a nightmare. Therefore, please don't encourage maintainers to omit nontrivial .m4 files from the tarball. Adding support $ACLOCAL_PATH would do exactly that. Following your line of thinking, we should also drop the support for the `dirlist' special file then. The fact that a feature can be misused is IMHO not a good reason against its introduction, if it can also be used legitimately and profitably. Also, a conscientious user would anyway add `--install -I m4' to his ACLOCAL_AMFLAGS, so that third-party m4 files would be copied in the local m4 directory (and thus automatically distributed by automake). I say we should instead follow the UNIX practice of giving the user enough rope to hang himself, but advise him not to do so; metaphors aside, this means we should implement $ACLOCAL_PATH, but also vouch your concerns clearly and strongly in the manual (as usual, patches welcome ;-) Regards, Stefano
bug#9026: Supporting $ACLOCAL_PATH?
Hi Stefano, I say we should instead follow the UNIX practice of giving the user enough rope to hang himself, but advise him not to do so This is a good attitude for the many features with which a developer can only harm himself and which cause no harm to others. But with $ACLOCAL_PATH he can harm the freedom of the distributors of his package; I think this requires special consideration. Bruno -- In memoriam Jean Moulin http://en.wikipedia.org/wiki/Jean_Moulin
bug#9026: Supporting $ACLOCAL_PATH?
Hi Stefano, Also, a conscientious user would anyway add `--install -I m4' to his ACLOCAL_AMFLAGS, so that third-party m4 files would be copied in the local m4 directory (and thus automatically distributed by automake). Hey, the --install option is something I need to mention in the GNU gettext documentation. I wasn't aware of it up to now. 2011-07-08 Bruno Haible br...@clisp.org * gettext.texi (aclocal): Recommend the use of aclocal's --install option. Suggested by Stefano Lattarini stefano.lattar...@gmail.com. --- gettext-tools/doc/gettext.texi.orig Fri Jul 8 23:22:44 2011 +++ gettext-tools/doc/gettext.texi Fri Jul 8 23:22:39 2011 @@ -7990,6 +7990,18 @@ @noindent to your top level @file{Makefile.am}. +If you are using GNU @code{automake} 1.10 or newer, it is even easier: +Add the line + +@example +ACLOCAL_AMFLAGS = --install -I m4 +@end example + +@noindent +to your top level @file{Makefile.am}, and run @samp{aclocal --install -I m4}. +This will copy the needed files to the @file{m4/} subdirectory automatically, +before updating @file{aclocal.m4}. + These macros check for the internationalization support functions and related informations. Hopefully, once stabilized, these macros might be integrated in the standard Autoconf set, because this -- In memoriam Jean Moulin http://en.wikipedia.org/wiki/Jean_Moulin
Re: bug#8969: improve synchronization between examples in the manual and test cases
On Wednesday 06 July 2011, Ralf Wildenhues wrote: * Stefano Lattarini wrote on Wed, Jul 06, 2011 at 10:32:56AM CEST: Oops, sorry. Fixed by the attached patch. OK for maint? I'll wait the customary 72 hours before pushing. Thanks. OK, but please remove all the comments about tar unportability in the tests. It's so obvious. ;-) OK done. (and there are probably a dozen other places in the Automake source tree that you'd have to put the comment at as well, for any amount of consistency. I think having one comment, the one that already exists in lib/am/distdir.am, is fully sufficient.) I'm ok with fixing the manual also, although it's usually clear for people still having to use those vendor tars (and inconvenient for the rest). Yes, I'd say we leave the examples in manual untouched. Agreed? OK. Subject: [PATCH] tests: portability fixes in tests on amhello examples * tests/amhello-binpkg.test: Don't use tar xzf too.tag.gz to extract a gzip-compressed tarball, that's unportable to some tar implementations; use the gzip -dc fo.tar.gz | tar xf - idiom instead. * tests/amhello-cflags.test: Likewise. * tests/amhello-cross-compile.test: Likewise. Thanks, Ralf Pushed now. Thanks, Stefano
[FYI] {testsuite-work} [PATCH] tests: remove redundant settings of `errexit' shell flag
* tests/amhello-binpkg.test: Do not set the `errexit' shell flag, as it is already set by `tests/defs'. * tests/amhello-cflags.test: Likewise. * tests/amhello-cross-compile.test: Likewise. * tests/ansi2knr-deprecation.test: Likewise. * tests/autodist-no-duplicate.test: Likewise. * tests/distcheck-configure-flags-am.test: Likewise. * tests/distcheck-configure-flags-subpkg.test: Likewise. * tests/distcheck-configure-flags.test: Likewise. * tests/distcheck-hook.test: Likewise. * tests/distcheck-hook2.test: Likewise. * tests/parallel-tests-am_tests_environment.test: Likewise. * tests/parallel-tests-harderror.test: Likewise. * tests/parallel-tests-log-compiler-example.test: Likewise. * tests/parallel-tests-log-override-1.test: Likewise. * tests/parallel-tests-log-override-2.test: Likewise. * tests/parallel-tests-log-override-recheck.test: Likewise. * tests/primary-prefix-couples-documented-valid.test: Likewise. * tests/primary-prefix-couples-force-valid.test: Likewise. * tests/primary-prefix-invalid-couples.test: Likewise. * tests/primary-prefix-valid-couples.test: Likewise. * tests/remake-subdir-from-subdir.test: Likewise. * tests/remake-subdir-gnu.test: Likewise. * tests/remake-subdir-long-time.test: Likewise. * tests/remake-subdir.test: Likewise. * tests/remake-subdir2.test: Likewise. * tests/silent-configsite.test: Likewise. * tests/tests-environment-backcompat.test: Likewise. --- ChangeLog | 32 tests/amhello-binpkg.test |2 - tests/amhello-cflags.test |2 - tests/amhello-cross-compile.test |2 - tests/ansi2knr-deprecation.test|2 - tests/autodist-no-duplicate.test |2 - tests/distcheck-configure-flags-am.test|2 - tests/distcheck-configure-flags-subpkg.test|2 - tests/distcheck-configure-flags.test |2 - tests/distcheck-hook.test |2 - tests/distcheck-hook2.test |2 - tests/parallel-tests-am_tests_environment.test |2 - tests/parallel-tests-harderror.test|2 - tests/parallel-tests-log-compiler-example.test |2 - tests/parallel-tests-log-override-1.test |2 - tests/parallel-tests-log-override-2.test |2 - tests/parallel-tests-log-override-recheck.test |2 - tests/primary-prefix-couples-documented-valid.test |2 - tests/primary-prefix-couples-force-valid.test |2 - tests/primary-prefix-invalid-couples.test |2 - tests/primary-prefix-valid-couples.test|2 - tests/remake-subdir-from-subdir.test |2 - tests/remake-subdir-gnu.test |2 - tests/remake-subdir-long-time.test |2 - tests/remake-subdir.test |2 - tests/remake-subdir2.test |2 - tests/silent-configsite.test |2 - tests/tests-environment-backcompat.test|2 - 28 files changed, 32 insertions(+), 54 deletions(-) diff --git a/ChangeLog b/ChangeLog index 9b92575..56a1d7c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,37 @@ 2011-07-08 Stefano Lattarini stefano.lattar...@gmail.com + tests: remove redundant settings of `errexit' shell flag + * tests/amhello-binpkg.test: Do not set the `errexit' shell + flag, as it is already set by `tests/defs'. + * tests/amhello-cflags.test: Likewise. + * tests/amhello-cross-compile.test: Likewise. + * tests/ansi2knr-deprecation.test: Likewise. + * tests/autodist-no-duplicate.test: Likewise. + * tests/distcheck-configure-flags-am.test: Likewise. + * tests/distcheck-configure-flags-subpkg.test: Likewise. + * tests/distcheck-configure-flags.test: Likewise. + * tests/distcheck-hook.test: Likewise. + * tests/distcheck-hook2.test: Likewise. + * tests/parallel-tests-am_tests_environment.test: Likewise. + * tests/parallel-tests-harderror.test: Likewise. + * tests/parallel-tests-log-compiler-example.test: Likewise. + * tests/parallel-tests-log-override-1.test: Likewise. + * tests/parallel-tests-log-override-2.test: Likewise. + * tests/parallel-tests-log-override-recheck.test: Likewise. + * tests/primary-prefix-couples-documented-valid.test: Likewise. + * tests/primary-prefix-couples-force-valid.test: Likewise. + * tests/primary-prefix-invalid-couples.test: Likewise. + * tests/primary-prefix-valid-couples.test: Likewise. + * tests/remake-subdir-from-subdir.test: Likewise. + * tests/remake-subdir-gnu.test: Likewise. + * tests/remake-subdir-long-time.test: Likewise. + * tests/remake-subdir.test: Likewise. + * tests/remake-subdir2.test: Likewise. + * tests/silent-configsite.test: Likewise. + *
[FYI] {testsuite-work} tests defs: more uses of $top_testsrcdir
* tests/autodist-stamp-vti.test: Use `$top_testsrcdir' instead of `$testsrcdir/..'. * tests/repeated-options.test: Likewise. * tests/suffix5.test: Likewise. * tests/vtexi3.test: Likewise. --- ChangeLog |9 + tests/autodist-stamp-vti.test |2 +- tests/repeated-options.test |2 +- tests/suffix5.test|2 +- tests/vtexi3.test |2 +- 5 files changed, 13 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index b3709ec..73077c7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,14 @@ 2011-07-08 Stefano Lattarini stefano.lattar...@gmail.com + tests defs: more uses of $top_testsrcdir + * tests/autodist-stamp-vti.test: Use `$top_testsrcdir' instead + of `$testsrcdir/..'. + * tests/repeated-options.test: Likewise. + * tests/suffix5.test: Likewise. + * tests/vtexi3.test: Likewise. + +2011-07-08 Stefano Lattarini stefano.lattar...@gmail.com + self tests: fix typo in comment * tests/self-check-exit.test: Fix typo in heading comments. diff --git a/tests/autodist-stamp-vti.test b/tests/autodist-stamp-vti.test index 2984372..1dc91c7 100755 --- a/tests/autodist-stamp-vti.test +++ b/tests/autodist-stamp-vti.test @@ -46,7 +46,7 @@ END # Required when using Texinfo. : texinfo.tex -cp $testsrcdir/../lib/mdate-sh . +cp $top_testsrcdir/lib/mdate-sh . $ACLOCAL $AUTOCONF diff --git a/tests/repeated-options.test b/tests/repeated-options.test index 4667d0d..999c9e1 100755 --- a/tests/repeated-options.test +++ b/tests/repeated-options.test @@ -58,7 +58,7 @@ int main (void) } END -cp $testsrcdir/../lib/compile . +cp $top_testsrcdir/lib/compile . $ACLOCAL $AUTOMAKE --foreign --foreign -Wall 2stderr || { cat stderr 2; Exit 1; } diff --git a/tests/suffix5.test b/tests/suffix5.test index e9d733d..c0566a9 100755 --- a/tests/suffix5.test +++ b/tests/suffix5.test @@ -45,7 +45,7 @@ END : ltmain.sh -cp $testsrcdir/../lib/config.guess $testsrcdir/../lib/config.sub . +cp $top_testsrcdir/lib/config.guess $top_testsrcdir/lib/config.sub . $ACLOCAL $AUTOMAKE diff --git a/tests/vtexi3.test b/tests/vtexi3.test index 04fb7d7..da0278b 100755 --- a/tests/vtexi3.test +++ b/tests/vtexi3.test @@ -65,7 +65,7 @@ END # Required when using Texinfo. : texinfo.tex -cp $testsrcdir/../lib/mdate-sh . +cp $top_testsrcdir/lib/mdate-sh . $ACLOCAL $AUTOCONF -- 1.7.2.3
[FYI] {maint} fix typo in recent ChangeLog entry
--- ChangeLog |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/ChangeLog b/ChangeLog index c77326d..114df2d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -17,7 +17,7 @@ * tests/amhello-cflags.test: New test. * tests/amhello-cross-compile.test: Likewise. * tests/amhello-binpkg.test: Likewise. - * tests/tests-environment-backcompat: Likewise. + * tests/tests-environment-backcompat.test: Likewise. * tests/parallel-tests-log-compiler-example.test: Likewise. * tests/Makefile.am (TESTS): Update. -- 1.7.2.3
Re: libtool relink problem
On Thu, 30 Jun 2011 14:38:49 +0200, Pippijn van Steenhoven wrote: On Wed, Jun 29, 2011 at 05:14:19PM +0200, Emmanuel Engelhart wrote: From: Pippijn van Steenhovenpip8...@gmail.com Date: Mon, Jun 20, 2011 at 4:55 PM Subject: Re: libtool relink problem To: automake@gnu.org On Sun, Jun 19, 2011 at 03:40:06PM +0530, Santhosh Thottingal wrote: Hi, I am facing a problem with libtool. While installing it complains a relink required and while doing so it tries to link against the shared library instead of static library. Well, the problem is better explained in this thread http://sourceware.org/ml/automake/2004-07/msg00127.html with example code. I am facing exactly the same problem. I saw a similar problem in this thread also http://www.mail-archive.com/libtool@gnu.org/msg00782.html Is there a solution available for this? Thanks Santhosh Hi Santhosh, I suggest writing your *_LTLIBRARIES with a comment in front, perhaps with # to differ between disabled and enabled libraries. Then using grep(1) to extract the names and the same tools to extract the dependencies. You can then use tsort(1) to topologically sort the libraries and write the actual ${dir}_LTLIBRARIES to an included .am file. Semantically, this is what I do. In reality, I wrote a preprocessor for automake that does this, but I don't suggest using it, as it's beta and very much tailored to my needs. Hi Pippijn Thank you for taking time and trying to help us... because we really get stucked. I tried to understand your answer but I honestly think I'm not good enough with automake to be able to understand and apply your methodology. I also doubt that the other cases given by Santhosh are the same as our, although the symptom is. From my understanding the previously described issues occur if the dependences are not compiled in the right order. I think this is not our problem because at the moment the error occurs, I know the dependence is already compiled. The issue occurs if the dependencies are not _installed_ in the right order. So, I'm sure the file $(top_builddir)/src/ctpp2/src/libctpp2.la exists. As you noted, the dependency has been compiled and linked, but for installation, it has to be relinked: libtool: relink: g++ -shared -nostdlib ^^ The above occurs in make install. So my question is why automake replaces the path with libcttp2.la in -lctpp2, replacing a static linking with a dynamic one? It's related to rpath linking. The resulting binaries are relinked to include $(libdir) as rpath, so that installed binaries can be called and libraries loaded without listing $(libdir) in LD_LIBRARY_PATH or ld.so.conf. It looks like you are using a recursive make, in your project. Are you sure that libcttp2.la exists in $(libdir)? As an experiment, try make install in libctpp2's $(builddir) and then make install in $(top_builddir). So problem was fixed by using the noinst prefix for the ctpp2 code. If I correctly have understood the autotools behaviour it seems that if you don't use noinst prefix, the autotools install the libraries. In our case this does not make sense as the *.la files are only linked one time during the software compilation and not used afterwards (for example from thirds projects). Thx you again Pippijn vor your help, without your answer I wouldn't have discover that the static lib were installed. Regards Emmanuel