Re: [PATCH 01/10] tests: migrate legacy tests/cdemo tests to Autotest.
Hi Chuck, On 26 Nov 2011, at 11:39, Charles Wilson wrote: > On 11/25/2011 4:10 AM, Gary V. Vaughan wrote: >> As usual, subject to feedback, I'll push this whole series in >> 72 hours or so. Make distcheck passes for me on my Mac 10.7 and >> my Arch Linux x86_64 machines, but it would be great if folks with > > a) This is a big holiday weekend in the US, so...a bit more than 72 hours is > indicated. Most of us will still be catching up on post-holiday $realjob > stuff by the time 72 hours expires. Ah, didn't think of that. Sure, I will be busy myself for a week or two, so I won't push for at least a week, probably more. > b) cygwin? mingw? msvc? All of the "old tests" have seen a LARGE number of > tweaks to ensure their proper operation on the various w32 platforms. Have > you done ANY testing there, at all, or are you relying on the rest of us to > do that work for you? I'm afraid I don't have (or want) access to any Windows machines, so I'm afraid that I am relying on you guys to tell me if I screwed up. Of course I'm not expecting you to debug or fix my mistakes for me, and I'm not anticipating any new problems, since everything is merely migrated from legacy testsuite to Autotest testsuite, with minimal changes required to keep everything working on my main machines. Although I do normally have access to more machines, the flooding in Bangkok has made any use of my Internet connection other than email intolerably slow... hence the recent flurry of work on libtool (which I can do offline, queueing emails for when my connection is next up) to fill my time while I wait for things to get back to normal. The reason I'll be too busy to do much more of that over the next week or two, is that last night I actually had a full-speed connection to the US again, so I'm anticipating playing catchup at $realjob myself. > Sorry if I seem a bit short, but I'm rather annoyed to see my queue get > filled with hours upon hours of work in the middle of a holiday. Please don't feel that it's your responsibility to painstakingly pick through every patch I post... I'd be more than happy just to get the test logs from anything I put on alpha.gnu.org for the architectures I don't use to help me restabilize the code closer to a release. Enjoy the rest of your holiday, and sorry for working so much on libtool recently: although my objective with the recent modernisations has been to try to decruft libtool a little, and to make the barrier to contribution much lower than it is currently if at all possible. I rarely have the chance to put a lot of time into libtool, and things will slow down considerably again now if my Internet connection really is back to (something like) normal again. I have another 20 or so patches left incubating in my unpublished queue, and I will be done for now after those are polished and pushed over the next month or two. Cheers, -- Gary V. Vaughan (gary AT gnu DOT org)
Re: [PATCH 01/10] tests: migrate legacy tests/cdemo tests to Autotest.
On 11/25/2011 4:10 AM, Gary V. Vaughan wrote: As usual, subject to feedback, I'll push this whole series in 72 hours or so. Make distcheck passes for me on my Mac 10.7 and my Arch Linux x86_64 machines, but it would be great if folks with a) This is a big holiday weekend in the US, so...a bit more than 72 hours is indicated. Most of us will still be catching up on post-holiday $realjob stuff by the time 72 hours expires. b) cygwin? mingw? msvc? All of the "old tests" have seen a LARGE number of tweaks to ensure their proper operation on the various w32 platforms. Have you done ANY testing there, at all, or are you relying on the rest of us to do that work for you? Sorry if I seem a bit short, but I'm rather annoyed to see my queue get filled with hours upon hours of work in the middle of a holiday. -- Chuck
[PATCH] m4: fix logic error leading to -fno-rtti being added wrongly.
Applied as the obvious fix for an error in translation in commit 962aa919. * m4/libtool.m4 (_LT_COMPILER_OPTION): Negate comparison so that compiler flags are added correctly. Signed-off-by: Gary V. Vaughan --- m4/libtool.m4 |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/m4/libtool.m4 b/m4/libtool.m4 index 007492c..4be85a5 100644 --- a/m4/libtool.m4 +++ b/m4/libtool.m4 @@ -1532,7 +1532,7 @@ AC_CACHE_CHECK([$1], [$2], $RM conftest* ]) -if test yes != "[$]$2"; then +if test yes = "[$]$2"; then m4_if([$5], , :, [$5]) else m4_if([$6], , :, [$6]) -- 1.7.7.4 Cheers, -- Gary V. Vaughan (gary AT gnu DOT org)
[PATCH] maint: Fix generated ChangeLog typos.
Applied as obvious. * build-aux/git-log-fix: Spell Stefano Lattarini's name correctly. Don't use my home email address for GNU commits. Signed-off-by: Gary V. Vaughan --- build-aux/git-log-fix | 19 +++ 1 files changed, 19 insertions(+), 0 deletions(-) diff --git a/build-aux/git-log-fix b/build-aux/git-log-fix index 9ac3ced..810c021 100644 --- a/build-aux/git-log-fix +++ b/build-aux/git-log-fix @@ -2,6 +2,11 @@ # option. It specifies what changes to make to each given SHA1's commit # log and metadata, using Perl-eval'able expressions. +11d16ab06c36948c053c507f5f9e06ff3de221c7 +# Date: Fri Nov 25 14:39:57 2011 +0700 +# Spell Stefano's name correctly. +s|Steffano|Stefano| + a5ef08182ce0fb80b8adcff5872f190afd915908 # Date: Wed Nov 16 12:13:55 2011 +0700 # Fix a typo. @@ -17,8 +22,20 @@ e8db92c345b99acd9c6984a321fc241ed1d01d23 # Email address of Reporters is in THANKS. s|(Reported by .*?) *<.*>|$1.| +c188507816c4b43f3411677116ce4ab4b926958e +# Date: Mon Nov 7 23:43:56 2011 +0700 +# Use canonical gnu email address. +s|vaughan\.pe|gnu.org|g + +fdb4c546784aebacaf697ebd5f96e0d91c566597 +# Date: Tue Oct 18 13:20:53 2011 +0700 +# Use canonical gnu email address. +s|vaughan\.pe|gnu.org|g + 0fe4d0740effaec9d08ee9683fb493d8ad0bd8b5 # Date: Mon Oct 17 16:43:18 2011 +0700 +# Use canonical gnu email address. +s|vaughan\.pe|gnu.org|g; # No empty lines in a single commit. s|\n\n|\n|g; # Fix a typo. @@ -26,6 +43,8 @@ s|soure|source| 789817d512111d063981446efc7493ce87696bb3 # Date: Mon Oct 17 12:40:55 2011 +0700 +# Use canonical gnu email address. +s|vaughan\.pe|gnu.org|g; # No empty lines in a single commit. s|\n\n|\n|g -- 1.7.7.4 Cheers, -- Gary V. Vaughan (gary AT gnu DOT org)
Re: [PATCH 01/10] tests: migrate legacy tests/cdemo tests to Autotest.
On Friday 25 November 2011, Gary V wrote: > On 25 Nov 2011, at 18:59, Stefano Lattarini wrote: > > On Friday 25 November 2011, Gary V wrote: > >> > >> The best reason I can find for keeping the various demo directories > >> around (despite the fact we already make use of the much better test > >> harness of Autotest for all our new test cases) from the last time > >> I wanted to migrate everything out of the legacy testsuite, was that > >> it exercises the distribution manager's autotools combination on the > >> testers machine, where the Autotests always use the users autotools. > >> That's no argument as far as I can see: we want tests to fail as > >> early as possible on a users machine to help him know things are not > >> going to work properly if he keeps going - and having the legacy > >> suite pass is only encouraging users to fight with broken installs. > >> > >> This series of patches migrates all 9 of the demo directory test > >> groups into Autotest, and allows us to remove most of the legacy > >> testsuite cruft at the end. > >> > > Just my 2 cents: I'd like to see the test scripts converted one at > > the time, rather than one group at the time (and assuming that this > > is feasible), as I found your huge patches basically un-reviewable > > in their present state. > > The legacy tests are in sets that can't be broken apart without leaving > the tree in an inconsistent state part way through that set. > Oh. I thought you could convert them one at the time instead, but they are inter-dependent, this could become more cumbersome, if not almost impossible. > I could break them up a little more tho', if you think that would help, > so instead of converting one demo directory all at once, then a final > patch to clean out the configury cruft... there'd be 9 sets of patches > each containing almost everything in the current patch, except the > deletion of the the files in the given test/demo directory, followed by > a series of tiny patches each adding a dozen lines like this: > > +## --- ## > +## Mdemo conf. ## > +## --- ## > + > +AT_SETUP([ltdl load shared and static modules]) > + > +_LT_SETUP > + > +_LT_CHECK_CONFIG([], [^build_old_libs=yes], [^build_libtool_libs=yes]) > +_LT_CHECK_EXECUTE > +_LT_CHECK_INSTALL > +_LT_CHECK_UNINSTALL > + > +AT_CLEANUP > > plus removing the equivalent legacy set of 3 *.test files, and then a > final patch to delete the given test/demo tree, and relevant lines from > Makefile.am. > > It'll take me a while to go through and do that, and we'll end up with > 10 large patches each setting up a new tests/demo.at file, about 25 > tiny patches per the above, then 10 small patches each removing one of > the tests/demo trees, and then the final cruft cleanout patch unchanged. > > If that will make a big difference, let me know and I'll retract these > patches and post 50 or so to replace them in a week or two when I've > gone through and broken out the tiny per-test-group sets per the above. > Nah, let's forget about this. I thought that breaking up your patches further could be done easily and naturally, but if it is not the case, I see no real gain in the extra churn. > >> There's still a few legacy tests > >> left at the end, which I'll tackle later, but at least maintenance > >> is a whole lot easier now that we don't need to wait for 9 additional > >> directories to autoreconf every time we run bootstrap, or distcheck, > >> or roll up a distribution tarball to test on the local network. > >> > >> This is all in keeping with the theme of most of the patches I've > >> posted this year, to make libtool easier and more fun to maintain > >> and contribute to, in the hope of getting more people involved. > >> > >> As usual, subject to feedback, I'll push this whole series in > >> 72 hours or so. Make distcheck passes for me on my Mac 10.7 and > >> my Arch Linux x86_64 machines, but it would be great if folks with > >> access to other machines could give it a spin to see whether I > >> broke any of the tests during migration... if you'd like a pre- > >> rolled distro with my pending patches applied to do that, then > >> please do ask. > >> > > If you want to send me such a tarball, I might run the testsuite on > > Solaris 10, Cygwin 1.5.25, NetBSD 5.1 and OpenBSD 4.6 at least. > > Much appreciated. Tarballs here: > > http://vaughan.pe/libtool/libtool-2.4.2.135-aa59c.tar.gz > http://vaughan.pe/libtool/libtool-2.4.2.135-aa59c.tar.xz > > > But > > then you should allow for more than three days for sending feedback > > -- at least a week. > > That's fine, and running on those arches would be a great help in > giving me confidence the migration didn't break anything. > > It'll take me at least a week to redo everything into smaller pieces > anyway... (unless you think the time spent here will not make much > difference to your review). But do let me know either way :) > Done above :-) Don't bother in breaking up the series. > And thanks
Re: [PATCH 01/10] tests: migrate legacy tests/cdemo tests to Autotest.
On 25 Nov 2011, at 18:59, Stefano Lattarini wrote: > Hi Gary. Hi Stefano, > On Friday 25 November 2011, Gary V wrote: >> The best reason I can find for keeping the various demo directories >> around (despite the fact we already make use of the much better test >> harness of Autotest for all our new test cases) from the last time >> I wanted to migrate everything out of the legacy testsuite, was that >> it exercises the distribution manager's autotools combination on the >> testers machine, where the Autotests always use the users autotools. >> That's no argument as far as I can see: we want tests to fail as >> early as possible on a users machine to help him know things are not >> going to work properly if he keeps going - and having the legacy >> suite pass is only encouraging users to fight with broken installs. >> >> This series of patches migrates all 9 of the demo directory test >> groups into Autotest, and allows us to remove most of the legacy >> testsuite cruft at the end. >> > Just my 2 cents: I'd like to see the test scripts converted one at > the time, rather than one group at the time (and assuming that this > is feasible), as I found your huge patches basically un-reviewable > in their present state. The legacy tests are in sets that can't be broken apart without leaving the tree in an inconsistent state part way through that set. I could break them up a little more tho', if you think that would help, so instead of converting one demo directory all at once, then a final patch to clean out the configury cruft... there'd be 9 sets of patches each containing almost everything in the current patch, except the deletion of the the files in the given test/demo directory, followed by a series of tiny patches each adding a dozen lines like this: +## --- ## +## Mdemo conf. ## +## --- ## + +AT_SETUP([ltdl load shared and static modules]) + +_LT_SETUP + +_LT_CHECK_CONFIG([], [^build_old_libs=yes], [^build_libtool_libs=yes]) +_LT_CHECK_EXECUTE +_LT_CHECK_INSTALL +_LT_CHECK_UNINSTALL + +AT_CLEANUP plus removing the equivalent legacy set of 3 *.test files, and then a final patch to delete the given test/demo tree, and relevant lines from Makefile.am. It'll take me a while to go through and do that, and we'll end up with 10 large patches each setting up a new tests/demo.at file, about 25 tiny patches per the above, then 10 small patches each removing one of the tests/demo trees, and then the final cruft cleanout patch unchanged. If that will make a big difference, let me know and I'll retract these patches and post 50 or so to replace them in a week or two when I've gone through and broken out the tiny per-test-group sets per the above. >> There's still a few legacy tests >> left at the end, which I'll tackle later, but at least maintenance >> is a whole lot easier now that we don't need to wait for 9 additional >> directories to autoreconf every time we run bootstrap, or distcheck, >> or roll up a distribution tarball to test on the local network. >> >> This is all in keeping with the theme of most of the patches I've >> posted this year, to make libtool easier and more fun to maintain >> and contribute to, in the hope of getting more people involved. >> >> As usual, subject to feedback, I'll push this whole series in >> 72 hours or so. Make distcheck passes for me on my Mac 10.7 and >> my Arch Linux x86_64 machines, but it would be great if folks with >> access to other machines could give it a spin to see whether I >> broke any of the tests during migration... if you'd like a pre- >> rolled distro with my pending patches applied to do that, then >> please do ask. >> > If you want to send me such a tarball, I might run the testsuite on > Solaris 10, Cygwin 1.5.25, NetBSD 5.1 and OpenBSD 4.6 at least. Much appreciated. Tarballs here: http://vaughan.pe/libtool/libtool-2.4.2.135-aa59c.tar.gz http://vaughan.pe/libtool/libtool-2.4.2.135-aa59c.tar.xz > But > then you should allow for more than three days for sending feedback > -- at least a week. That's fine, and running on those arches would be a great help in giving me confidence the migration didn't break anything. It'll take me at least a week to redo everything into smaller pieces anyway... (unless you think the time spent here will not make much difference to your review). But do let me know either way :) And thanks also for offering to make the time to look them over. Cheers, -- Gary V. Vaughan (gary AT gnu DOT org)
Re: [PATCH 01/10] tests: migrate legacy tests/cdemo tests to Autotest.
Hi Gary. On Friday 25 November 2011, Gary V wrote: > The best reason I can find for keeping the various demo directories > around (despite the fact we already make use of the much better test > harness of Autotest for all our new test cases) from the last time > I wanted to migrate everything out of the legacy testsuite, was that > it exercises the distribution manager's autotools combination on the > testers machine, where the Autotests always use the users autotools. > That's no argument as far as I can see: we want tests to fail as > early as possible on a users machine to help him know things are not > going to work properly if he keeps going - and having the legacy > suite pass is only encouraging users to fight with broken installs. > > This series of patches migrates all 9 of the demo directory test > groups into Autotest, and allows us to remove most of the legacy > testsuite cruft at the end. > Just my 2 cents: I'd like to see the test scripts converted one at the time, rather than one group at the time (and assuming that this is feasible), as I found your huge patches basically un-reviewable in their present state. > There's still a few legacy tests > left at the end, which I'll tackle later, but at least maintenance > is a whole lot easier now that we don't need to wait for 9 additional > directories to autoreconf every time we run bootstrap, or distcheck, > or roll up a distribution tarball to test on the local network. > > This is all in keeping with the theme of most of the patches I've > posted this year, to make libtool easier and more fun to maintain > and contribute to, in the hope of getting more people involved. > > As usual, subject to feedback, I'll push this whole series in > 72 hours or so. Make distcheck passes for me on my Mac 10.7 and > my Arch Linux x86_64 machines, but it would be great if folks with > access to other machines could give it a spin to see whether I > broke any of the tests during migration... if you'd like a pre- > rolled distro with my pending patches applied to do that, then > please do ask. > If you want to send me such a tarball, I might run the testsuite on Solaris 10, Cygwin 1.5.25, NetBSD 5.1 and OpenBSD 4.6 at least. But then you should allow for more than three days for sending feedback -- at least a week. Regards, Stefano
Re: [PATCH 02/10] tests: migrate legacy tests/demo tests to Autotest.
Only a quick incomplete review ... On Friday 25 November 2011, Gary V wrote: > +{ > +test -n "$objdir" || exit 1 > +$lt_INSTALL -d "$objdir/temp/libs" > +cp -f libhello.la "$objdir/temp" > +cp -f "$objdir"/libhello.* "$objdir/lt-hell$EXEEXT" "$objdir/temp/libs" > +trap "func_restore_files" 0 1 2 13 15 > Quoting autoconf manual: With AIX sh, a trap on 0 installed in a shell function triggers at function exit rather than at script. (I see this is code has only been moved by your patch, so you might want to fix it in a follow-up?) > + > +/* At some point, cygwin will stop defining __CYGWIN32__, but b19 and > + * earlier do not define __CYGWIN__. This snippit allows us to check > s/snippit/snippet/ (I see this is code has only been moved by your patch, so you might want to fix it in a follow-up?) > + * for __CYGWIN__ reliably for both current, old, and (probable) future > + * releases. > + */ Regards, Stefano
Re: [PATCH 1/7] syntax-check: fix violations and implement sc_useless_quotes_in_case.
On 21 Nov 2011, at 21:47, Gary V. Vaughan wrote: > I'll push the whole series in 72 hours or so as usual. Pushed. > [[snip]] > > Contrary to popular belief, Bourne shell does not resplit case > expressions after expansion, so if there are no shell unquoted > shell metacharacters or whitespace, the quotes are useless. > * cfg.mk (sc_useless_quotes_in_case): New syntax-check rule to > ensure we don't reintroduce useless quoted case expressions. > * build-aux/ltmain.m4sh, m4/libtool.m4, tests/bindir.at, > tests/darwin.at, tests/defs.m4sh, tests/demo-hardcode.test, > tests/demo-nopic.test, tests/link-2.test, tests/quote.test, > tests/sysroot.at: Remove spurious quotes. > > Signed-off-by: Gary V. Vaughan > --- > build-aux/ltmain.m4sh| 12 ++-- > cfg.mk |8 > m4/libtool.m4|2 +- > tests/bindir.at |4 ++-- > tests/darwin.at |2 +- > tests/defs.m4sh |2 +- > tests/demo-hardcode.test |4 ++-- > tests/demo-nopic.test|6 +++--- > tests/link-2.test|2 +- > tests/quote.test |8 > tests/sysroot.at |2 +- > 11 files changed, 30 insertions(+), 22 deletions(-) Cheers, -- Gary V. Vaughan (gary AT gnu DOT org)
[PATCH 09/10] tests: migrate legacy tests/fcdemo tests to Autotest.
Along with the demise of the last demo directory, so all the cruft for re-autotooling and distributing the additional directories is no longer necessary. * tests/fcdemo.at: New autotest groups, based on... * tests/fcdemo-conf.test, tests/fcdemo-exec.test, tests/fcdemo-make.test, tests/fcdemo-shared-exec.test, tests/fcdemo-shared-make.test, tests/fcdemo-shared.test, tests/fcdemo-static-exec.test, tests/fcdemo-static-make.test, tests/fcdemo-static.test: ...these legacy tests, now removed. * tests/fcdemo/Makefile.am, tests/fcdemo/README, tests/fcdemo/configure.ac, tests/fcdemo/cprogram.c, tests/fcdemo/foo.h, tests/fcdemo/fooc.c, tests/fcdemo/foof.f90, tests/fcdemo/foof2.f90, tests/fcdemo/foof3.f90, tests/fcdemo/fprogram.f90: Remove. * configure.ac (CONF_SUBDIRS, DIST_MAKEFILE_LIST): Remove. * Makefile.am (DIST_SUBDIRS, FC_TESTS, clean-local-legacy) (configure-subdirs, distclean-recursive, distdir) (fake-distclean-legacy, $(DIST_MAKEFILE_LIST)): Remove. (COMMON_TESTS): Rename from this... (TESTS): ...to this. Signed-off-by: Gary V. Vaughan --- .gitignore|1 - Makefile.am | 64 +--- configure.ac | 11 -- tests/fcdemo-conf.test| 42 - tests/fcdemo-exec.test| 35 tests/fcdemo-make.test| 36 - tests/fcdemo-shared-exec.test |3 - tests/fcdemo-shared-make.test |3 - tests/fcdemo-shared.test | 42 - tests/fcdemo-static-exec.test |3 - tests/fcdemo-static-make.test |3 - tests/fcdemo-static.test | 42 - tests/fcdemo.at | 346 + tests/fcdemo/.gitignore |2 - tests/fcdemo/Makefile.am | 75 - tests/fcdemo/README | 12 -- tests/fcdemo/configure.ac | 78 - tests/fcdemo/cprogram.c | 54 --- tests/fcdemo/foo.h| 54 --- tests/fcdemo/fooc.c | 41 - tests/fcdemo/foof.f90 | 10 -- tests/fcdemo/foof2.f90| 12 -- tests/fcdemo/foof3.f90| 12 -- tests/fcdemo/fprogram.f90 | 31 24 files changed, 350 insertions(+), 662 deletions(-) delete mode 100755 tests/fcdemo-conf.test delete mode 100755 tests/fcdemo-exec.test delete mode 100755 tests/fcdemo-make.test delete mode 100755 tests/fcdemo-shared-exec.test delete mode 100755 tests/fcdemo-shared-make.test delete mode 100755 tests/fcdemo-shared.test delete mode 100755 tests/fcdemo-static-exec.test delete mode 100755 tests/fcdemo-static-make.test delete mode 100755 tests/fcdemo-static.test create mode 100644 tests/fcdemo.at delete mode 100644 tests/fcdemo/.gitignore delete mode 100644 tests/fcdemo/Makefile.am delete mode 100644 tests/fcdemo/README delete mode 100644 tests/fcdemo/configure.ac delete mode 100644 tests/fcdemo/cprogram.c delete mode 100644 tests/fcdemo/foo.h delete mode 100644 tests/fcdemo/fooc.c delete mode 100644 tests/fcdemo/foof.f90 delete mode 100644 tests/fcdemo/foof2.f90 delete mode 100644 tests/fcdemo/foof3.f90 delete mode 100644 tests/fcdemo/fprogram.f90 diff --git a/.gitignore b/.gitignore index f337328..c8db98e 100644 --- a/.gitignore +++ b/.gitignore @@ -48,7 +48,6 @@ Makefile Makefile.in \#*# -_inst-*demo _libs acinclude.m4 aclocal.m4 diff --git a/Makefile.am b/Makefile.am index 670bbd4..7f75f38 100644 --- a/Makefile.am +++ b/Makefile.am @@ -323,14 +323,6 @@ libtool: $(ltmain_sh) $(config_status) $(dotversion) cd '$(top_builddir)' && '$(SHELL)' ./config.status '$@'; \ fi -.PHONY: configure-subdirs -configure-subdirs distdir: $(DIST_MAKEFILE_LIST) -$(DIST_MAKEFILE_LIST): - $(AM_V_at)dir=`echo '$@' |'$(SED)' 's|^[^/]*$$|.|;s|/[^/]*$$||'`; \ - test -d "$$dir" || mkdir "$$dir" || exit 1; \ - abs_srcdir=`$(lt__cd) '$(srcdir)' && pwd`; \ - (cd "$$dir" && "$$abs_srcdir/$$dir/configure" --with-dist) || exit 1 - ## ## ## Libltdl. ## @@ -695,6 +687,7 @@ TESTSUITE_AT= tests/testsuite.at \ tests/cmdline_wrap.at \ tests/pic_flag.at \ tests/f77demo.at \ + tests/fcdemo.at \ tests/darwin.at \ tests/dumpbin-symbols.at \ tests/deplibs-mingw.at \ @@ -790,7 +783,7 @@ check-interactive: $(testsuite_deps_uninstalled) check-noninteractive: check-noninteractive-old check-noninteractive-new # We need to remove any file droppings left behind by testsuite -clean-local: clean-local-legacy +clean-local: -$(CD_TESTDIR); \ test -f "$$abs_srcdir/$(TESTSUITE)" && \ '$(SHELL)' "$$abs_srcdir/$(TESTSUITE)" --clean @@ -805,27 +798,7 @@ clean-local: clean-local-legacy # using the new framework above. When the migration is # complete this section should be removed. -FC_TESTS = \ - tests/fcdemo-static.test \ - tests/fcdemo-static-make.test \ - tests/fcdemo-static-exec.test \ -
[PATCH 10/10] bootstrap: remove support for `-r' and `reconf_dirs'.
With all those extra demo directories out of the way, we can revert to a more canonical bootstrap process, and jettison the cruft that was only there to work around the pain of needing to autoreconf 11 directories. Bootstrap is now an order of magnitude faster. * bootstrap.conf (require_ltdl_dir): New function. Factored out of `libtool_build_prerequisites'. (libtool_build_prerequisites): Adjust. (func_reconfigure): Use `require_ltdl_dir' to determine the name of the other directory we need to autoreconf during bootstrap. (libtool_options_prep, libtool_parse_options) (libtool_validate_options): Remove. Signed-off-by: Gary V. Vaughan --- bootstrap.conf | 175 +--- 1 files changed, 41 insertions(+), 134 deletions(-) diff --git a/bootstrap.conf b/bootstrap.conf index f7bc1ac..8763a33 100644 --- a/bootstrap.conf +++ b/bootstrap.conf @@ -1,4 +1,4 @@ -# bootstrap.conf (GNU Libtool) version 2011-11-21 +# bootstrap.conf (GNU Libtool) version 2011-11-24 # # Copyright (C) 2010, 2011 Free Software Foundation, Inc. # Written by Gary V. Vaughan, 2010 @@ -109,15 +109,16 @@ require_bootstrap_uptodate=: # func_reconfigure # -- -# In addition to needing to autoreconf several directories, Libtool -# provides `libtoolize' and doesn't use `autopoint', so we can use a -# somewhat simpler `func_reconfigure' implementation. +# In addition to needing to autoreconf two directories, Libtool provides +# `libtoolize' and doesn't use `autopoint', so we can use a somewhat +# simpler `func_reconfigure' implementation than bootstrap's version. func_reconfigure () { $debug_cmd $require_autoheader $require_build_aux +$require_ltdl_dir $require_macro_dir # Only need this from the top level directory @@ -126,127 +127,19 @@ func_reconfigure () export LIBTOOLIZE func_verbose "export LIBTOOLIZE='$LIBTOOLIZE'" -# Also bootstrap any additional directories that were specified with -# `reconfdirs' in the environment. -save_IFS=$IFS -IFS=, -for sub in $opt_reconf_dirs; do - IFS=$save_IFS - my_autoreconf_options= - $opt_copy || func_append my_autoreconf_options " --symlink" - $opt_force && func_append my_autoreconf_options " --force" - $opt_verbose && func_append my_autoreconf_options " --verbose" - func_show_eval "$AUTORECONF$my_autoreconf_options --install $sub" \ -'exit $?' -done -IFS=$save_IFS -} - - - -## --- ## -## Hook functions. ## -## --- ## - -# `bootstrap' itself takes care of the arguments it recognises, so we only -# have to handle additional options here. Setting exit_cmd to anything -# other than `:', will tell `bootstrap' to exit after printing it's own -# option loop parser errors. Best not to use any time-consuming $require_ -# functions here, otherwise they will be run even if we only need to -# process `--version'. - -# libtool_options_prep [ARG...] -# - -# Preparation for supporting additional options in Libtool bootstrap, -# before the option parsing loop. -libtool_options_prep () -{ -$debug_cmd - -# Extend the existing usage message -usage_message=$usage_message' -Libtool Specific Options: - -r, --reconf-dirs=DIR1,DIR2,... - limit the directories to be bootstrapped to - the comma-delimited list of DIR1,DIR2,... -' - -# autoreconf all directories by default -test -n "$reconfdirs" \ - || reconfdirs=". libltdl `ls -1d tests/*demo tests/*demo[0-9]`" - -# pass back the list of options we consumed -func_quote_for_eval ${1+"$@"} -libtool_options_prep_result=$func_quote_for_eval_result -} -func_add_hook func_options_prep libtool_options_prep +my_autoreconf_options= +$opt_copy || func_append my_autoreconf_options " --symlink" +$opt_force && func_append my_autoreconf_options " --force" +$opt_verbose && func_append my_autoreconf_options " --verbose" +func_show_eval "$AUTORECONF$my_autoreconf_options --install ." \ + 'exit $?' -# libtool_parse_options [ARG...] -# -- -# Provide handling for additional Libtool options inside the main option -# parsing loop. -libtool_parse_options () -{ -$debug_cmd - -# this inner loop lets us handle `-r.' in a single iteration -while test $# -gt 0; do - opt=$1 - shift - - case $opt in ---reconf-dirs|--reconfdirs|-r) - test $# = 0 && func_missing_arg $opt && break - # squash spaces so that delimiter is just `,' and nothing else - opt_reconf_dirs=`echo "$1" |$SED 's|, *|,|g'` - shift - ;; - -# Separate arguments to short options: --r*) func_split_short_opt "$opt" - set dummy "$func_split_short_opt_name" "$func_split_short_opt_arg" ${1+"$@"} - shift - ;; - -*)
[PATCH 08/10] tests: migrate legacy tests/f77demo tests to Autotest.
* tests/f77demo.at: New autotest groups, based on... * tests/f77demo-conf.test, tests/f77demo-exec.test, tests/f77demo-make.test, tests/f77demo-shared-exec.test, tests/f77demo-shared-make.test, tests/f77demo-shared.test, tests/f77demo-static-exec.test, tests/f77demo-static-make.test, tests/f77demo-static.test: ...these legacy tests, now removed. * tests/f77demo/Makefile.am, tests/f77demo/README, tests/f77demo/configure.ac, tests/f77demo/cprogram.c, tests/f77demo/foo.h, tests/f77demo/fooc.c, tests/f77demo/foof.f, tests/f77demo/foof2.f, tests/f77demo/foof3.f, tests/f77demo/fprogram.f: Remove. * configure.ac (CONF_SUBDIRS): Remove tests/f77demo. Signed-off-by: Gary V. Vaughan --- Makefile.am| 41 +- configure.ac |2 +- tests/f77demo-conf.test| 34 tests/f77demo-exec.test| 35 - tests/f77demo-make.test| 36 - tests/f77demo-shared-exec.test |3 - tests/f77demo-shared-make.test |3 - tests/f77demo-shared.test | 34 tests/f77demo-static-exec.test |3 - tests/f77demo-static-make.test |3 - tests/f77demo-static.test | 34 tests/f77demo.at | 332 tests/f77demo/.gitignore |2 - tests/f77demo/Makefile.am | 65 tests/f77demo/README | 12 -- tests/f77demo/configure.ac | 71 - tests/f77demo/cprogram.c | 53 --- tests/f77demo/foo.h| 53 --- tests/f77demo/fooc.c | 41 - tests/f77demo/foof.f | 10 -- tests/f77demo/foof2.f | 12 -- tests/f77demo/foof3.f | 12 -- tests/f77demo/fprogram.f | 31 23 files changed, 339 insertions(+), 583 deletions(-) delete mode 100755 tests/f77demo-conf.test delete mode 100755 tests/f77demo-exec.test delete mode 100755 tests/f77demo-make.test delete mode 100755 tests/f77demo-shared-exec.test delete mode 100755 tests/f77demo-shared-make.test delete mode 100755 tests/f77demo-shared.test delete mode 100755 tests/f77demo-static-exec.test delete mode 100755 tests/f77demo-static-make.test delete mode 100755 tests/f77demo-static.test create mode 100644 tests/f77demo.at delete mode 100644 tests/f77demo/.gitignore delete mode 100644 tests/f77demo/Makefile.am delete mode 100644 tests/f77demo/README delete mode 100644 tests/f77demo/configure.ac delete mode 100644 tests/f77demo/cprogram.c delete mode 100644 tests/f77demo/foo.h delete mode 100644 tests/f77demo/fooc.c delete mode 100644 tests/f77demo/foof.f delete mode 100644 tests/f77demo/foof2.f delete mode 100644 tests/f77demo/foof3.f delete mode 100644 tests/f77demo/fprogram.f diff --git a/Makefile.am b/Makefile.am index 2f9b90b..670bbd4 100644 --- a/Makefile.am +++ b/Makefile.am @@ -694,6 +694,7 @@ TESTSUITE_AT= tests/testsuite.at \ tests/stresstest.at \ tests/cmdline_wrap.at \ tests/pic_flag.at \ + tests/f77demo.at \ tests/darwin.at \ tests/dumpbin-symbols.at \ tests/deplibs-mingw.at \ @@ -768,9 +769,7 @@ installcheck-local: $(testsuite_deps) AUTOTEST_PATH='$(exec_prefix)/bin' check-noninteractive-old: - $(AM_V_at)'$(MAKE)' $(AM_MAKEFLAGS) check-TESTS TESTS='$(NONINTERACTIVE_TESTS)' -check-interactive-old: - $(AM_V_at)'$(MAKE)' $(AM_MAKEFLAGS) check-TESTS TESTS='$(INTERACTIVE_TESTS)' + $(AM_V_at)'$(MAKE)' $(AM_MAKEFLAGS) check-TESTS TESTS='$(TESTS)' # Run only noninteractive parts of the new testsuite. check-noninteractive-new: $(testsuite_deps_uninstalled) @@ -781,14 +780,13 @@ check-noninteractive-new: $(testsuite_deps_uninstalled) $(TESTSUITEFLAGS) # Run only interactive parts of the new testsuite. -check-interactive-new: $(testsuite_deps_uninstalled) +check-interactive: $(testsuite_deps_uninstalled) $(AM_V_at)$(CD_TESTDIR); \ CONFIG_SHELL='$(SHELL)' '$(SHELL)' "$$abs_srcdir/$(TESTSUITE)" \ $(TESTS_ENVIRONMENT) $(BUILDCHECK_ENVIRONMENT) \ -k interactive -k recursive INNER_TESTSUITEFLAGS=',interactive' \ $(TESTSUITEFLAGS) -check-interactive: check-interactive-old check-interactive-new check-noninteractive: check-noninteractive-old check-noninteractive-new # We need to remove any file droppings left behind by testsuite @@ -807,26 +805,6 @@ clean-local: clean-local-legacy # using the new framework above. When the migration is # complete this section should be removed. -F77_TESTS = \ - tests/f77demo-static.test \ - tests/f77demo-static-make.test \ - tests/f77demo-static-exec.test \ - tests/f77demo-conf.test \ - tests/f77demo-make.test \ - tests/f77demo-exec.test \ - tests/f77demo-shared.test \ - tests/f77demo-shared-make.test \ - tests/f77demo-shared-exec.test - -tests/f77demo-shared-exec.log: tes
[PATCH 07/10] tests: migrate legacy tests/mdemo2 tests to Autotest.
This test was just a small non-ltdl aware library to load a library from the legacy mdemo test, which in turn used ltdl to call functions from modules. No need to create a whole other test group with copies of everything from mdemo setup - just tack the additional test on the end of the mdemo group. * tests/mdemo.at (link with library that loads ltdl modules): New test, based on... * tests/mdemo2-conf.test, tests/mdemo-exec.test, tests/mdemo-make.test: ...these legacy tests, now removed. * tests/mdemo2/Makefile.am, tests/mdemo2/README, tests/mdemo2/configure.ac, tests/mdemo2/main.c: Remove. * configure.ac (CONF_SUBDIRS): Remove tests/mdemo2. * Makefile.am: Adjust. Signed-off-by: Gary V. Vaughan --- Makefile.am |9 + configure.ac |3 +- tests/mdemo.at| 83 + tests/mdemo2-conf.test| 34 -- tests/mdemo2-exec.test| 35 --- tests/mdemo2-make.test| 35 --- tests/mdemo2/.gitignore |2 - tests/mdemo2/Makefile.am | 53 tests/mdemo2/README |4 -- tests/mdemo2/configure.ac | 62 - tests/mdemo2/main.c | 46 - 11 files changed, 85 insertions(+), 281 deletions(-) delete mode 100755 tests/mdemo2-conf.test delete mode 100755 tests/mdemo2-exec.test delete mode 100755 tests/mdemo2-make.test delete mode 100644 tests/mdemo2/.gitignore delete mode 100644 tests/mdemo2/Makefile.am delete mode 100644 tests/mdemo2/README delete mode 100644 tests/mdemo2/configure.ac delete mode 100644 tests/mdemo2/main.c diff --git a/Makefile.am b/Makefile.am index fe21b6e..2f9b90b 100644 --- a/Makefile.am +++ b/Makefile.am @@ -854,14 +854,7 @@ COMMON_TESTS = \ tests/objectlist.test \ tests/quote.test \ tests/suffix.test \ - tests/tagtrace.test \ - tests/mdemo2-conf.test \ - tests/mdemo2-make.test \ - tests/mdemo2-exec.test - -tests/mdemo2-exec.log: tests/mdemo2-make.log -tests/mdemo2-make.log: tests/mdemo2-conf.log \ - tests/mdemo-dryrun.log + tests/tagtrace.test INTERACTIVE_TESTS = NONINTERACTIVE_TESTS = $(COMMON_TESTS) diff --git a/configure.ac b/configure.ac index f031fb6..fe76f2d 100644 --- a/configure.ac +++ b/configure.ac @@ -126,8 +126,7 @@ AC_SUBST([pkgaux_scripts]) # All subdirectories that are configured on demand, but that must be # included in the distribution. -CONF_SUBDIRS="tests/f77demo tests/fcdemo \ - tests/mdemo2" +CONF_SUBDIRS="tests/f77demo tests/fcdemo" AC_SUBST([CONF_SUBDIRS]) DIST_MAKEFILE_LIST= diff --git a/tests/mdemo.at b/tests/mdemo.at index d1ece9f..12c762d 100644 --- a/tests/mdemo.at +++ b/tests/mdemo.at @@ -103,6 +103,12 @@ mdemo_static_DEPENDENCIES = $(mdemo_DEPENDENCIES) libtool: $(LIBTOOL_DEPS) $(SHELL) ./config.status --recheck + +include $(srcdir)/mdemo.mk +]]) + +AT_DATA([mdemo.mk], +[[# Don't abort for lack of mdemo.mk ]]) AT_DATA([foo.h], @@ -780,3 +786,80 @@ force_dry_run=false _LT_CHECK_UNINSTALL AT_CLEANUP + +## --- ## +## Mdemo2. ## +## --- ## + +AT_SETUP([link with library that loads ltdl modules]) + +_LT_SETUP + +AT_DATA([mdemo.mk], +[[bin_PROGRAMS += mdemo2 mdemo2_static + +# Create a version of mdemo2 that links a library that does dlopen. +mdemo2_LDFLAGS = -export-dynamic "-dlopen" force +mdemo2_LDADD = libmlib.la + +# Create a statically linked version of mdemo. +mdemo2_static_SOURCES = mdemo2.c +mdemo2_static_LDFLAGS = $(STATIC) $(mdemo2_LDFLAGS) +mdemo2_static_LDADD = $(mdemo2_LDADD) +mdemo2_static_DEPENDENCIES = $(mdemo2_DEPENDENCIES) +]]) + +AT_DATA([mdemo2.c], +[[#include +#include "ltdl.h" + +extern int mlib_func (int, char **); + +int main (int argc, char **argv) +{ + int ret = 0; + + printf ("Welcome to GNU libtool mdemo2!\n"); + if (argc < 2) { +fprintf (stderr, "usage: %s module [module...]\n", argv[0]); + } + + /* This must be called in the program to get the preloaded symbols */ + LTDL_SET_PRELOADED_SYMBOLS(); + + ret = mlib_func(argc, argv); + + return ret; +} +]]) + +AT_DATA([expout], +[[Welcome to GNU libtool mdemo2! +module name: foo1 +module reference count: 1 +** This is foolib 1 ** +hello returned: 57616 +hello is ok! +cos (0.0) = 1 +sub() called +foo1 is ok! +module name: libfoo2 +module reference count: 1 +** This is foolib 2 ** +hello returned: 57616 +hello is ok! +sin (0.0) = 0 +sub() called +foo2 is ok! +]]) + +_LT_CHECK_CONFIG + +LT_AT_MAKE + +LT_AT_EXEC_CHECK([./mdemo2_static], 0, [expout], [], +[./foo1.la ./libfoo2.la | $EGREP -v '^module filename: ']) +LT_AT_EXEC_CHECK([./mdemo2], 0, [expout], [], +[./foo1.la ./libfoo2.la | $EGREP -v '^module filename: ']) + +AT_CLEANUP diff --git a/tests/mdemo2-conf.test b/tests/mdemo2-conf.test deleted file mode 100755 index e37..000 --- a/tests/mdemo2-conf.test +++ /dev/null @@ -1,3
[PATCH 05/10] tests: migrate legacy tests/pdemo tests to Autotest.
This test was a thinly veiled copy of the basic legacy demo-conf.test series, with the addition of long file names that are not unique in the first 17 characters of their name, mashed up with the cmdline_wrap.at max_cmd_len limits. Migrating to Autotest means that this test will be automatically rerun with max_cmd_len=24 as cmdline_wrap.at recurses through the whole testsuite, so the migrated pdemo test is now simply another test case in demo.at with longer file names. * test/demo.at (linking with long file names): New test, based on... * tests/pdemo-conf.test, tests/pdemo-exec.test, tests/pdemo-inst.test, tests/pdemo-make.test: ...these legacy tests, now removed. * tests/pdemo/Makefile.am, tests/pdemo/configure.ac, tests/pdemo/foo.h, tests/pdemo/longer_file_name_dlmain.c, tests/pdemo/longer_file_name_foo.c, tests/pdemo/longer_file_name_foo2.c, tests/pdemo/longer_file_name_hell1.c, tests/pdemo/longer_file_name_hell2.c, tests/pdemo/longer_file_name_hello.c, tests/pdemo/longer_file_name_main.c: Remove. * configure.ac (CONF_SUBDIRS): Remove tests/pdemo. * Makefile.am: Adjust. Signed-off-by: Gary V. Vaughan --- Makefile.am |9 -- configure.ac |2 +- tests/demo.at | 115 ++ tests/pdemo-conf.test | 47 - tests/pdemo-exec.test | 36 --- tests/pdemo-inst.test | 38 --- tests/pdemo-make.test | 34 --- tests/pdemo/.gitignore|3 - tests/pdemo/Makefile.am | 171 - tests/pdemo/configure.ac | 73 -- tests/pdemo/foo.h | 102 tests/pdemo/longer_file_name_dlmain.c | 97 --- tests/pdemo/longer_file_name_foo.c| 38 --- tests/pdemo/longer_file_name_foo2.c | 35 --- tests/pdemo/longer_file_name_hell1.c | 25 - tests/pdemo/longer_file_name_hell2.c | 24 - tests/pdemo/longer_file_name_hello.c | 36 --- tests/pdemo/longer_file_name_main.c | 47 - 18 files changed, 116 insertions(+), 816 deletions(-) delete mode 100755 tests/pdemo-conf.test delete mode 100755 tests/pdemo-exec.test delete mode 100755 tests/pdemo-inst.test delete mode 100755 tests/pdemo-make.test delete mode 100644 tests/pdemo/.gitignore delete mode 100644 tests/pdemo/Makefile.am delete mode 100644 tests/pdemo/configure.ac delete mode 100644 tests/pdemo/foo.h delete mode 100644 tests/pdemo/longer_file_name_dlmain.c delete mode 100644 tests/pdemo/longer_file_name_foo.c delete mode 100644 tests/pdemo/longer_file_name_foo2.c delete mode 100644 tests/pdemo/longer_file_name_hell1.c delete mode 100644 tests/pdemo/longer_file_name_hell2.c delete mode 100644 tests/pdemo/longer_file_name_hello.c delete mode 100644 tests/pdemo/longer_file_name_main.c diff --git a/Makefile.am b/Makefile.am index ac76788..4279389 100644 --- a/Makefile.am +++ b/Makefile.am @@ -868,10 +868,6 @@ COMMON_TESTS = \ tests/mdemo2-conf.test \ tests/mdemo2-make.test \ tests/mdemo2-exec.test \ - tests/pdemo-conf.test \ - tests/pdemo-make.test \ - tests/pdemo-exec.test \ - tests/pdemo-inst.test \ tests/mdemo-shared.test \ tests/mdemo-shared-make.test \ tests/mdemo-shared-exec.test \ @@ -900,11 +896,6 @@ tests/mdemo2-exec.log: tests/mdemo2-make.log tests/mdemo2-make.log: tests/mdemo2-conf.log \ tests/mdemo-dryrun.log -tests/pdemo-inst.log: tests/pdemo-exec.log -tests/pdemo-exec.log: tests/pdemo-make.log -tests/pdemo-make.log: tests/pdemo-conf.log - - INTERACTIVE_TESTS = NONINTERACTIVE_TESTS = $(COMMON_TESTS) if HAVE_F77 diff --git a/configure.ac b/configure.ac index ab0fc04..d3908c8 100644 --- a/configure.ac +++ b/configure.ac @@ -127,7 +127,7 @@ AC_SUBST([pkgaux_scripts]) # All subdirectories that are configured on demand, but that must be # included in the distribution. CONF_SUBDIRS="tests/f77demo tests/fcdemo \ - tests/mdemo tests/mdemo2 tests/pdemo" + tests/mdemo tests/mdemo2" AC_SUBST([CONF_SUBDIRS]) DIST_MAKEFILE_LIST= diff --git a/tests/demo.at b/tests/demo.at index 347889d..751c9db 100644 --- a/tests/demo.at +++ b/tests/demo.at @@ -800,3 +800,118 @@ AT_CHECK([$unset LIBTOOL LIBTOOLIZE; $MAKE hell$EXEEXT libhello_la_OBJECTS=hello [1], [ignore], [ignore]) AT_CLEANUP + + +## --- ## +## Pdemo conf. ## +## --- ## + +AT_SETUP([linking with long file names]) + +_LT_SETUP + +AT_DATA([Makefile.am], +[[AUTOMAKE_OPTIONS = no-dependencies foreign +ACLOCAL_AMFLAGS = -I m4 + +# Build a libtool library, libhello.la for installation in libdir. +lib_LTLIBRARIES = libhello.la +libhello_la_SOURCES = longer_file_name_hello.c longer_file_name_foo.c longer_file_name_foo2.c +libhello_la_LIBADD = $(LIBM) +l
[PATCH 04/10] tests: migrate legacy tests/tagdemo tests to Autotest.
* tests/tagdemo.at: New autotest groups, based on... tests/tagdemo-conf.test, tests/tagdemo-exec.test, tests/tagdemo-make.test, tests/tagdemo-shared-exec.test, tests/tagdemo-shared-make.test, tests/tagdemo-shared.test, tests/tagdemo-static-exec.test, tests/tagdemo-static-make.test, tests/tagdemo-static.test, tests/tagdemo-undef-exec.test, tests/tagdemo-undef-make.test, tests/tagdemo-undef.test: ...these legacy tests, now removed. * tests/tagdemo/.gitignore, tests/tagdemo/Makefile.am, tests/tagdemo/README, tests/tagdemo/baz.cpp, tests/tagdemo/baz.h, tests/tagdemo/configure.ac, tests/tagdemo/conv.cpp, tests/tagdemo/conv.h, tests/tagdemo/foo.cpp, tests/tagdemo/foo.h, tests/tagdemo/main.cpp: Remove. * configure.ac (CONF_SUBDIRS): Remove tests/tagdemo. * Makefile.am: Adjust. Signed-off-by: Gary V. Vaughan --- Makefile.am| 32 +--- configure.ac |2 +- tests/tagdemo-conf.test| 34 tests/tagdemo-exec.test| 34 tests/tagdemo-make.test| 34 tests/tagdemo-shared-exec.test |3 - tests/tagdemo-shared-make.test |3 - tests/tagdemo-shared.test | 34 tests/tagdemo-static-exec.test |3 - tests/tagdemo-static-make.test |3 - tests/tagdemo-static.test | 34 tests/tagdemo-undef-exec.test |3 - tests/tagdemo-undef-make.test |3 - tests/tagdemo-undef.test | 50 - tests/tagdemo.at | 408 tests/tagdemo/.gitignore |1 - tests/tagdemo/Makefile.am | 63 -- tests/tagdemo/README |6 - tests/tagdemo/baz.cpp | 38 tests/tagdemo/baz.h| 46 - tests/tagdemo/configure.ac | 96 -- tests/tagdemo/conv.cpp | 32 --- tests/tagdemo/conv.h | 35 tests/tagdemo/foo.cpp | 68 --- tests/tagdemo/foo.h| 59 -- tests/tagdemo/main.cpp | 79 26 files changed, 411 insertions(+), 792 deletions(-) delete mode 100755 tests/tagdemo-conf.test delete mode 100755 tests/tagdemo-exec.test delete mode 100755 tests/tagdemo-make.test delete mode 100755 tests/tagdemo-shared-exec.test delete mode 100755 tests/tagdemo-shared-make.test delete mode 100755 tests/tagdemo-shared.test delete mode 100755 tests/tagdemo-static-exec.test delete mode 100755 tests/tagdemo-static-make.test delete mode 100755 tests/tagdemo-static.test delete mode 100755 tests/tagdemo-undef-exec.test delete mode 100755 tests/tagdemo-undef-make.test delete mode 100755 tests/tagdemo-undef.test create mode 100644 tests/tagdemo.at delete mode 100644 tests/tagdemo/.gitignore delete mode 100644 tests/tagdemo/Makefile.am delete mode 100644 tests/tagdemo/README delete mode 100644 tests/tagdemo/baz.cpp delete mode 100644 tests/tagdemo/baz.h delete mode 100644 tests/tagdemo/configure.ac delete mode 100644 tests/tagdemo/conv.cpp delete mode 100644 tests/tagdemo/conv.h delete mode 100644 tests/tagdemo/foo.cpp delete mode 100644 tests/tagdemo/foo.h delete mode 100644 tests/tagdemo/main.cpp diff --git a/Makefile.am b/Makefile.am index 28eee5c..ac76788 100644 --- a/Makefile.am +++ b/Makefile.am @@ -681,6 +681,7 @@ TESTSUITE_AT= tests/testsuite.at \ tests/subproject.at \ tests/nonrecursive.at \ tests/recursive.at \ + tests/tagdemo.at \ tests/template.at \ tests/ctor.at \ tests/exceptions.at \ @@ -805,32 +806,6 @@ clean-local: clean-local-legacy # using the new framework above. When the migration is # complete this section should be removed. -CXX_TESTS = \ - tests/tagdemo-static.test \ - tests/tagdemo-static-make.test \ - tests/tagdemo-static-exec.test \ - tests/tagdemo-conf.test \ - tests/tagdemo-make.test \ - tests/tagdemo-exec.test \ - tests/tagdemo-shared.test \ - tests/tagdemo-shared-make.test \ - tests/tagdemo-shared-exec.test \ - tests/tagdemo-undef.test \ - tests/tagdemo-undef-make.test \ - tests/tagdemo-undef-exec.test - -tests/tagdemo-undef-exec.log: tests/tagdemo-undef-make.log -tests/tagdemo-undef-make.log: tests/tagdemo-undef.log -tests/tagdemo-undef.log: tests/tagdemo-shared-exec.log -tests/tagdemo-shared-exec.log: tests/tagdemo-shared-make.log -tests/tagdemo-shared-make.log: tests/tagdemo-shared.log -tests/tagdemo-shared.log: tests/tagdemo-exec.log -tests/tagdemo-exec.log:tests/tagdemo-make.log -tests/tagdemo-make.log:tests/tagdemo-conf.log -tests/tagdemo-conf.log:tests/tagdemo-static-exec.log -tests/tagdemo-static-exec.log: tests/tagdemo-static-make.log -tests/tagdemo-static-make.log: tests/tagdemo-static.log - F77_TESTS = \ tests/f77demo-static.test \ tests/f77demo-static-make.test \ @@ -932,9 +907,6 @@ tests/pde
[PATCH 01/10] tests: migrate legacy tests/cdemo tests to Autotest.
The best reason I can find for keeping the various demo directories around (despite the fact we already make use of the much better test harness of Autotest for all our new test cases) from the last time I wanted to migrate everything out of the legacy testsuite, was that it exercises the distribution manager's autotools combination on the testers machine, where the Autotests always use the users autotools. That's no argument as far as I can see: we want tests to fail as early as possible on a users machine to help him know things are not going to work properly if he keeps going - and having the legacy suite pass is only encouraging users to fight with broken installs. This series of patches migrates all 9 of the demo directory test groups into Autotest, and allows us to remove most of the legacy testsuite cruft at the end. There's still a few legacy tests left at the end, which I'll tackle later, but at least maintenance is a whole lot easier now that we don't need to wait for 9 additional directories to autoreconf every time we run bootstrap, or distcheck, or roll up a distribution tarball to test on the local network. This is all in keeping with the theme of most of the patches I've posted this year, to make libtool easier and more fun to maintain and contribute to, in the hope of getting more people involved. As usual, subject to feedback, I'll push this whole series in 72 hours or so. Make distcheck passes for me on my Mac 10.7 and my Arch Linux x86_64 machines, but it would be great if folks with access to other machines could give it a spin to see whether I broke any of the tests during migration... if you'd like a pre- rolled distro with my pending patches applied to do that, then please do ask. * tests/cdemo.at: New Autotest groups, based on... * tests/cdemo-conf.test, tests/cdemo-exec.test, tests/cdemo-make.test, tests/cdemo-shared-exec.test, tests/cdemo-shared-make.test, tests/cdemo-shared.test, tests/cdemo-static-exec.test, tests/cdemo-static-make.test, tests/cdemo-static.test, tests/cdemo-undef-exec.test, tests/cdemo-undef-make.test, tests/cdemo-undef.test: ...these legacy test cases, now removed. tests/cdemo/Makefile.am, tests/cdemo/README, tests/cdemo/configure.ac, tests/cdemo/foo.c, tests/cdemo/foo.h, tests/cdemo/main.c: Remove. * configure.ac (CONF_SUBDIRS): Remove tests/cdemo. * Makefile.am: Adjust. Signed-off-by: Gary V. Vaughan --- Makefile.am | 29 +-- configure.ac |2 +- tests/cdemo-conf.test| 34 --- tests/cdemo-exec.test| 34 --- tests/cdemo-make.test| 34 --- tests/cdemo-shared-exec.test |3 - tests/cdemo-shared-make.test |3 - tests/cdemo-shared.test | 34 --- tests/cdemo-static-exec.test |3 - tests/cdemo-static-make.test |3 - tests/cdemo-static.test | 34 --- tests/cdemo-undef-exec.test |3 - tests/cdemo-undef-make.test |3 - tests/cdemo-undef.test | 49 -- tests/cdemo.at | 201 ++ tests/cdemo/.gitignore |1 - tests/cdemo/Makefile.am | 53 --- tests/cdemo/README |4 - tests/cdemo/configure.ac | 63 - tests/cdemo/foo.c| 42 - tests/cdemo/foo.h| 37 tests/cdemo/main.c | 45 -- 22 files changed, 205 insertions(+), 509 deletions(-) delete mode 100755 tests/cdemo-conf.test delete mode 100755 tests/cdemo-exec.test delete mode 100755 tests/cdemo-make.test delete mode 100755 tests/cdemo-shared-exec.test delete mode 100755 tests/cdemo-shared-make.test delete mode 100755 tests/cdemo-shared.test delete mode 100755 tests/cdemo-static-exec.test delete mode 100755 tests/cdemo-static-make.test delete mode 100755 tests/cdemo-static.test delete mode 100755 tests/cdemo-undef-exec.test delete mode 100755 tests/cdemo-undef-make.test delete mode 100755 tests/cdemo-undef.test create mode 100644 tests/cdemo.at delete mode 100644 tests/cdemo/.gitignore delete mode 100644 tests/cdemo/Makefile.am delete mode 100644 tests/cdemo/README delete mode 100644 tests/cdemo/configure.ac delete mode 100644 tests/cdemo/foo.c delete mode 100644 tests/cdemo/foo.h delete mode 100644 tests/cdemo/main.c diff --git a/Makefile.am b/Makefile.am index c55dfdd..77941ac 100644 --- a/Makefile.am +++ b/Makefile.am @@ -630,13 +630,14 @@ TESTSUITE = tests/testsuite TESTSUITE_AT = tests/testsuite.at \ tests/getopt-m4sh.at \ tests/libtoolize.at \ + tests/cdemo.at \ + tests/convenience.at \ tests/help.at \ tests/duplicate_members.at \ tests/duplicate_conv.at \ tests/duplicate_deps.at \ tests/flags.at \ tests/inherited_flags.at \ - tests/convenience.at \ tests/link-order.at \
[PATCH 4/4] libtoolize: refactor copying filter creation.
Prevent the various require_filter functions from becoming too long by factoring common code into new functions. * libtoolize (func_make_relative_dir_filter) (func_make_relative_ltdl_filter): New functions. Generalize and consolidate the various similar snippets for concatenating together the sed scripts for func_copy filtering. (require_filter_Makefile_am, require_filter_aclocal_m4) (require_filter_configure_ac): Simplify. (require_ltdl_relative_aux_dir): Remove. (require_ltdl_relative_macro_dir): Ditto. Signed-off-by: Gary V. Vaughan --- libtoolize.m4sh | 167 +-- 1 files changed, 89 insertions(+), 78 deletions(-) diff --git a/libtoolize.m4sh b/libtoolize.m4sh index bfa84f3..83b5001 100644 --- a/libtoolize.m4sh +++ b/libtoolize.m4sh @@ -1093,6 +1093,66 @@ func_autoconf_configure () } +# func_make_relative_dir_filter CURRDIR SRCDIR DESTDIR [PREFIX [SUFFIX]] +# -- +# Make a sed script suitable for appending to a copy filter, which will +# replace occurrences of CURRDIR with the relative path from SRCDIR to +# DESTDIR if they are different, otherwise the result is the empty +# string: +# +#func_make_relative_dir_filter ltdl config ../build-aux +# => 's|\.\./build-aux|../config|g' +#func_make_relative_dir_filter ltdl ltdl/m4 ../m4 +# => 's|\.\./m4|m4|g' +#func_make_relative_dir_filter libltdl build-aux ../build-aux +# => '' +# +# If PREFIX (and SUFFIX) are passed they are prepended (and appended) +# to the match and replacement expressions literally: +# +#func_make_relative_dir_filter ltdl ltdl/m4 ../m4 '-I ' ' ' +# => 's|-I \.\./m4 |-I m4 |g' +func_make_relative_dir_filter () +{ +$debug_cmd + +my_currdir=$1 +my_srcdir=$2 +my_destdir=$3 + +func_relative_path "$my_srcdir" "$my_destdir" + +if test "$my_currdir" = "$func_relative_path_result"; then + func_make_relative_dir_filter_result= +else + my_match_currdir=`$ECHO "$my_currdir" |$SED "$sed_make_literal_regex"` + + # Avoid substituting with `dir/./file' when current dir is `.'. + if test . = "$my_currdir"; then +func_make_relative_dir_filter_result=" + s|$4$my_match_currdir/$5|$4$5|g" + else +func_make_relative_dir_filter_result=" + s|$4$my_match_currdir$5|$4$func_relative_path_result$5|g" + fi +fi +} + +# func_make_relative_ltdl_filter CURRDIR DESTDIR [PREFIX [SUFFIX]] +# +# As `func_make_relative_dir_filter' optimised for the common case where +# SRCDIR is `$ltdl_dir'. +func_make_relative_ltdl_filter () +{ +$debug_cmd + +$require_ltdl_dir + +func_make_relative_dir_filter "$1" "$ltdl_dir" "$2" "$3" "$4" +func_make_relative_ltdl_filter_result=$func_make_relative_dir_filter_result +} + + ## ## ## Resource management. ## ## ## @@ -1115,38 +1175,6 @@ func_autoconf_configure () # # After that, the rest appear in asciibetical order. -for base in aux_dir macro_dir; do - - # require_ltdl_relative_aux_dir - # require_ltdl_relative_macro_dir - # --- - # Set ltdl_relative_aux_dir to the relative path from $ltdl_dir to - # the parent project auxiliary directory, and similarly for relative - # macro directory. - r=ltdl_relative_$base# _r_esource acquired by calling this function - v=require_$r # _v_ariable pointing to the function - f=func_$v# _f_unction name - eval $v'='$f' - '$f' () - { -$debug_cmd - -$require_ltdl_dir -$require_'$base' - -func_relative_path "$ltdl_dir" "$'$base'" -'$r'=$func_relative_path_result - -test -n "$'$r'" && func_verbose "'$r'='\'\$$r\''" - -'$v'=: - }' - # Some of these functions need to acquire the resource managed by the - # lexically preceding function; $o serves that purpose. - o=$r - -done - for base in '' ltdl_; do if test ltdl_ = "$base"; then p='$pkgltdldir/'; else p=; fi @@ -1453,31 +1481,23 @@ func_require_filter_Makefile_am () ;; subproject) -$require_ltdl_ac_aux_dir +# Adjust default relative macro_dir paths. $require_ltdl_am_macro_dir -$require_ltdl_relative_aux_dir -$require_ltdl_relative_macro_dir - -test "$ltdl_am_macro_dir" = "$ltdl_relative_macro_dir" || { - my_am_macro_dir_regex=`$ECHO "\ -$ltdl_am_macro_dir" |$SED "$sed_make_literal_regex"` - - Makefile_am_filter=" -/^ACLOCAL_AMFLAGS = /{ - s| -I $my_am_macro_dir_regex\$| -I $ltdl_relative_macro_dir| -} -s|dir)/$my_am_macro_dir_regex|dir)/$ltdl_relative_macro_dir|g" -} - -test "$ltdl_ac_aux_dir" = "$ltdl_relative_aux_dir" || { - my_aux_dir_regex=`$ECHO "\ -$ltdl_ac_aux_dir" |$SED "$sed_make_literal_regex"` - Makefi
[PATCH 3/4] maint: pick XSI funcs at runtime, not configure time.
Determine, on a function by function basis, what XSI features are available in the shell that is actually running the script, rather than the one that was picked at configure time by the re-execution engine. * m4/libtool.m4 (_LT_PROG_FUNCTION_REPLACE) (_LT_PROG_REPLACE_SHELLFNS): Remove. (_LT_CHECK_SHELL_FEATURES): Remove tests for XSI and += support. * build-aux/general.m4sh (func_append, func_append_quoted) (func_arith, func_len, func_basename, func_dirname) (func_dirname_and_basename, func_stripname): List both enhanced and fallback implementations, and choose one based on whether the enhanced features required by the fastest version are available. * build-aux/getopt.m4sh (func_split_short_opt) (func_split_long_opt): Ditto. * build-aux/ltmain.m4sh (func_lo2o, func_xform): Ditto. * tests/getopt-m4sh.at: Add tests for enhanced and fallback implementations of func_arith, func_len, func_stripname and func_dirname_and_basename. * NEWS: Updated. Signed-off-by: Gary V. Vaughan --- NEWS |4 + build-aux/general.m4sh | 162 --- build-aux/getopt.m4sh | 38 ++-- build-aux/ltmain.m4sh | 33 -- m4/libtool.m4 | 117 +-- tests/getopt-m4sh.at | 116 -- 6 files changed, 256 insertions(+), 214 deletions(-) diff --git a/NEWS b/NEWS index 0479a34..ecd4fa1 100644 --- a/NEWS +++ b/NEWS @@ -49,6 +49,10 @@ NEWS - list of user-visible changes between releases of GNU Libtool mode is selected; `--standalone' never worked, and is no longer accepted. - Libtool and libtoolize no longer choke on paths with a comma in them. + - In the case where $SHELL does not have the same enhanced features +(e.g. the ability to parse `var+=append') as $CONFIG_SHELL, libtool +will now correctly fallback to using only vanilla shell features +instead of failing with a parse at startup. ** Important incompatible changes: diff --git a/build-aux/general.m4sh b/build-aux/general.m4sh index eeda222..648315d 100644 --- a/build-aux/general.m4sh +++ b/build-aux/general.m4sh @@ -73,63 +73,114 @@ IFS=" $lt_nl" dirname='s|/[^/]*$||' basename='s|^.*/||' - -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ +: ${_use_fast_funcs=":"} + +if $_use_fast_funcs && (eval 'x=a; x+=" b"; test "a b" = "$x"') 2>/dev/null +then + # func_append var value + # Append VALUE to the end of shell variable VAR. + eval 'func_append () + { +eval "$1+=\$2" + }' + + # func_append_quoted var value + # Quote VALUE and append to the end of shell variable VAR, separated + # by a space. + eval 'func_append_quoted () + { +func_quote_for_eval "$2" +eval "$1+=\\ \$func_quote_for_eval_result" + }' +else + func_append () + { eval "$1=\$$1\$2" -} # func_append may be replaced by extended shell implementation + } - -# func_append_quoted var value -# Quote VALUE and append to the end of shell variable VAR, separated -# by a space. -func_append_quoted () -{ + func_append_quoted () + { func_quote_for_eval "$2" eval "$1=\$$1\\ \$func_quote_for_eval_result" -} # func_append_quoted may be replaced by extended shell implementation + } +fi # func_arith arithmetic-term... -func_arith () -{ +if $_use_fast_funcs && (eval 'x=$(( 1 + 1 )); test 2 = "$x"') 2>/dev/null +then + eval 'func_arith () + { +func_arith_result=$(( $* )) + }' +else + func_arith () + { func_arith_result=`expr "$@"` -} # func_arith may be replaced by extended shell implementation + } +fi # func_len string # STRING may not start with a hyphen. -func_len () -{ +if $_use_fast_funcs && (eval 'x=12; test 2 = "${#x}"') 2>/dev/null +then + eval 'func_len () + { +func_len_result=${#1} + }' +else + func_len () + { func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` -} # func_len may be replaced by extended shell implementation + } +fi -# func_dirname file append nondir_replacement -# Compute the dirname of FILE. If nonempty, add APPEND to the result, -# otherwise set result to NONDIR_REPLACEMENT. -func_dirname () -{ -func_dirname_result=`$ECHO "$1" | $SED "$dirname"` -if test "X$func_dirname_result" = "X$1"; then - func_dirname_result=$3 -else - func_append func_dirname_result $2 -fi -} # func_dirname may be replaced by extended shell implementation +if $_use_fast_funcs \ +&& (eval 'x=a/x/b; a=${x%/*}; b=${x##*/}; test ba/x = "$a$b"') 2>/dev/null +then + # If this shell supports suffix pattern removal, then use it to avoid + # forking. Hide the definitions single quotes in case the shell chokes + # on unsupported syntax... + + _b='func_basename_result=${1##*/}' + _d='case $1 in +*/*) func_dirname_result=${1%/*}$2 ;; +* ) func_dirname_result=$3;; + esac' + +else + # ...otherwise fall back to using sed. + + _b='func_basename_result=
[PATCH 2/4] maint: share useful functions from general.m4sh.
* build-aux/ltmain.m4sh (func_append, func_append_quoted) (func_arith, func_len): Removed from here... * build-aux/general.m4sh (func_append, func_append_quoted) (func_arith, func_len): ...and added to here. (func_dirname, func_dirname_and_basename, func_normal_abspath) (func_relative_path): Use func_append. * tests/getopt-m4sh.at (_LT_AT_FALLBACK_FUNC_EXTRACT): Removed. Fallback functions are now in any m4sh generated file automatically. Signed-off-by: Gary V. Vaughan --- build-aux/general.m4sh | 42 ++ build-aux/ltmain.m4sh | 31 --- tests/getopt-m4sh.at | 14 -- 3 files changed, 38 insertions(+), 49 deletions(-) diff --git a/build-aux/general.m4sh b/build-aux/general.m4sh index 566dc39..eeda222 100644 --- a/build-aux/general.m4sh +++ b/build-aux/general.m4sh @@ -73,6 +73,40 @@ IFS=" $lt_nl" dirname='s|/[^/]*$||' basename='s|^.*/||' + +# func_append var value +# Append VALUE to the end of shell variable VAR. +func_append () +{ +eval "$1=\$$1\$2" +} # func_append may be replaced by extended shell implementation + + +# func_append_quoted var value +# Quote VALUE and append to the end of shell variable VAR, separated +# by a space. +func_append_quoted () +{ +func_quote_for_eval "$2" +eval "$1=\$$1\\ \$func_quote_for_eval_result" +} # func_append_quoted may be replaced by extended shell implementation + + +# func_arith arithmetic-term... +func_arith () +{ +func_arith_result=`expr "$@"` +} # func_arith may be replaced by extended shell implementation + + +# func_len string +# STRING may not start with a hyphen. +func_len () +{ +func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` +} # func_len may be replaced by extended shell implementation + + # func_dirname file append nondir_replacement # Compute the dirname of FILE. If nonempty, add APPEND to the result, # otherwise set result to NONDIR_REPLACEMENT. @@ -82,7 +116,7 @@ func_dirname () if test "X$func_dirname_result" = "X$1"; then func_dirname_result=$3 else - func_dirname_result=$func_dirname_result$2 + func_append func_dirname_result $2 fi } # func_dirname may be replaced by extended shell implementation @@ -113,7 +147,7 @@ func_dirname_and_basename () if test "X$func_dirname_result" = "X$1"; then func_dirname_result=$3 else - func_dirname_result=$func_dirname_result$2 + func_append func_dirname_result $2 fi func_basename_result=`$ECHO "$1" | $SED -e "$basename"` } # func_dirname_and_basename may be replaced by extended shell implementation @@ -212,7 +246,7 @@ func_normal_abspath () ;; *) # Actual path component, append it. - func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent +func_append func_normal_abspath_result "/$func_normal_abspath_tcomponent" ;; esac done @@ -268,7 +302,7 @@ func_relative_path () func_relative_path_result=$func_stripname_result func_stripname '/' '/' "$func_relative_path_tcancelled" if test -n "$func_stripname_result"; then -func_relative_path_result=$func_relative_path_result/$func_stripname_result +func_append func_relative_path_result "/$func_stripname_result" fi # Normalisation. If bindir is libdir, return `.' else relative path. diff --git a/build-aux/ltmain.m4sh b/build-aux/ltmain.m4sh index 160d8af..b88c984 100644 --- a/build-aux/ltmain.m4sh +++ b/build-aux/ltmain.m4sh @@ -148,37 +148,6 @@ extracted_serial=0 # left over by shells. exec_cmd= -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ -eval "$1=\$$1\$2" -} # func_append may be replaced by extended shell implementation - -# func_append_quoted var value -# Quote VALUE and append to the end of shell variable VAR, separated -# by a space. -func_append_quoted () -{ -func_quote_for_eval "$2" -eval "$1=\$$1\\ \$func_quote_for_eval_result" -} # func_append_quoted may be replaced by extended shell implementation - - -# func_arith arithmetic-term... -func_arith () -{ -func_arith_result=`expr "$@"` -} # func_arith may be replaced by extended shell implementation - - -# func_len string -# STRING may not start with a hyphen. -func_len () -{ -func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` -} # func_len may be replaced by extended shell implementation - # func_lo2o object func_lo2o () diff --git a/tests/getopt-m4sh.at b/tests/getopt-m4sh.at index 5eec5c2..81160db 100644 --- a/tests/getopt-m4sh.at +++ b/tests/getopt-m4sh.at @@ -53,18 +53,6 @@ $SED "s|@LN_S\@|$LN_S|g;s|@SED\@|$SED|g" t-options > options ])# _LT_AT_GETOPT_M4SH_SETUP -# _LT_AT_FALLBACK_FUNC_EXTRACT(FUNC-NAME) -# --- -# Extract the fallback function FUNC-NAME from ltmain.m4sh -m4_define([_LT_AT_FALLBACK_FUNC_EXTRACT], -[dnl {{ -$SED '/^# func_dirname /q' options >
[PATCH 1/4] libtoolize: rename and reorder copy filter functions.
This short series of changesets refactors the copy filtering process to be more managable and easily extensible (which comes in handy for some of the later changesets still incubating in my queue), with a slight detour in the middle to generalize and tidy up the XSI support the filter functions make use of. I'll push the whole series in 72 hours or so subject to feedback. Keep all the sorted copy filtering functions together by renaming them to have `_filter' first. * libtoolize.m4sh (require_Makefile_am_filter) (require_Makefile_inc_filter, require_aclocal_m4_filter) (require_configure_ac_filter): Renamed from these... (require_filter_Makefile_am, require_filter_ltdl_mk) (require_filter_aclocal_m4, require_filter_configure_ac): ...to these, respectively. Move the definitions to maintain asciibetical ordering of require functions. Signed-off-by: Gary V. Vaughan --- libtoolize.m4sh | 274 +++--- 1 files changed, 137 insertions(+), 137 deletions(-) diff --git a/libtoolize.m4sh b/libtoolize.m4sh index 31bbf3e..bfa84f3 100644 --- a/libtoolize.m4sh +++ b/libtoolize.m4sh @@ -787,8 +787,8 @@ func_install_pkgltdl_files () pkgltdl_header="putting libltdl files in \`$ltdl_dir'." fi -$require_Makefile_am_filter -$require_Makefile_inc_filter +$require_filter_Makefile_am +$require_filter_ltdl_mk # Copy ltdl sources appropriate to the requested ltdl_mode. for file in $pkgltdl_files; do @@ -796,23 +796,23 @@ func_install_pkgltdl_files () case $file in Makefile.am|Makefile.in) test nonrecursive = "$ltdl_mode" && continue - my_copy_filter=$Makefile_am_filter + my_copy_filter=$filter_Makefile_am ;; ltdl.mk) test nonrecursive = "$ltdl_mode" || continue - my_copy_filter=$Makefile_inc_filter + my_copy_filter=$filter_ltdl_mk ;; aclocal.m4) test subproject = "$ltdl_mode" && { -$require_aclocal_m4_filter +$require_filter_aclocal_m4 # Always copy aclocal.m4, otherwise regenerating it can # overwrite the destination if it is symlinked. ( opt_copy=: func_copy "$file" "$pkgltdldir" "$ltdl_dir" \ -pkgltdl_header "$aclocal_m4_filter" +pkgltdl_header "$filter_aclocal_m4" ) } continue @@ -824,13 +824,13 @@ func_install_pkgltdl_files () configure) test subproject = "$ltdl_mode" && { -$require_configure_ac_filter +$require_filter_configure_ac # Always copy configure, otherwise regenerating it can # overwrite the destination if it is symlinked. ( opt_copy=: func_copy "$file" "$pkgltdldir" "$ltdl_dir" \ -pkgltdl_header "$configure_ac_filter" +pkgltdl_header "$filter_configure_ac" ) } continue @@ -838,8 +838,8 @@ func_install_pkgltdl_files () configure.ac) test subproject = "$ltdl_mode" || continue - $require_configure_ac_filter - my_copy_filter=$configure_ac_filter + $require_filter_configure_ac + my_copy_filter=$filter_configure_ac ;; esac @@ -1245,98 +1245,6 @@ for base in '' ltdl_; do done -# require_Makefile_am_filter -# -- -# Set `Makefile_am_filter' ready for passing to func_copy when libltdl's -# stock Makefile.am contents need to be filtered to work in recursive -# mode. -require_Makefile_am_filter=func_require_Makefile_am_filter -func_require_Makefile_am_filter () -{ -$debug_cmd - -$require_ltdl_mode - -case $ltdl_mode in - recursive) -Makefile_am_filter=' -/^[^#]/{ - s|(LIBOBJS)|(ltdl_LIBOBJS)|g - s|(LTLIBOBJS)|(ltdl_LTLIBOBJS)|g -}' -;; - - subproject) -$require_ltdl_ac_aux_dir -$require_ltdl_am_macro_dir -$require_ltdl_relative_aux_dir -$require_ltdl_relative_macro_dir - -test "$ltdl_am_macro_dir" = "$ltdl_relative_macro_dir" || { - my_am_macro_dir_regex=`$ECHO "\ -$ltdl_am_macro_dir" |$SED "$sed_make_literal_regex"` - - Makefile_am_filter=" -/^ACLOCAL_AMFLAGS = /{ - s| -I $my_am_macro_dir_regex\$| -I $ltdl_relative_macro_dir| -} -s|dir)/$my_am_macro_dir_regex|dir)/$ltdl_relative_macro_dir|g" -} - -test "$ltdl_ac_aux_dir" = "$ltdl_relative_aux_dir" || { - my_aux_dir_regex=`$ECHO "\ -$ltdl_ac_aux_dir" |$SED "$sed_make_literal_regex"` - - Makefile_am_filter="$Makefile_am_filter -s|$my_aux_dir_regex|$ltdl_relative_aux_dir|g -s|/\./|/|g - " -} -;; -esac - -require_Makefile_am_filter=: -} - - -# require_Makefile_inc_
FYI: [PATCH] maint: quote $file correctly in bootstrap.
From: "Gary V. Vaughan" Applied as obvious. * bootstrap (func_insert_sorted_if_absent): Don't forget the double quotes, since we can't control the content of $file. Reported by Steffano Lattarini. Signed-off-by: Gary V. Vaughan --- bootstrap |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bootstrap b/bootstrap index 8776e21..6ae2feb 100755 --- a/bootstrap +++ b/bootstrap @@ -2051,13 +2051,13 @@ func_insert_sorted_if_absent () for file do - test -f $file || touch $file + test -f "$file" || touch "$file" func_grep_q "$str" "$file" \ && func_verbose "inserting \`$str' into \`$file'" - echo "$str" |sort -u - $file |func_cmp_s - $file \ -|| echo "$str" |sort -u - $file -o $file \ + echo "$str" |sort -u - "$file" |func_cmp_s - "$file" \ +|| echo "$str" |sort -u - "$file" -o "$file" \ || func_permissions_error "$file" done } -- 1.7.7.4 Cheers, -- Gary V. Vaughan (gary AT gnu DOT org)
FYI: [PATCH] build: fix a quoting bug when regenerating with bootstrap_edit.
Applied as obvious. * Makefile.am (m4/ltversion.m4, build-aux/ltmain.sh): The bootstrap_edit make macro already contains double quotes, so when echoing it, don't surround it with more double quotes since it is not escaped. Signed-off-by: Gary V. Vaughan --- Makefile.am |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.am b/Makefile.am index 2c6cf81..5420510 100644 --- a/Makefile.am +++ b/Makefile.am @@ -152,7 +152,7 @@ $(ltversion_m4): $(ltversion_in) $(dotversion) serial=`$(git_commit_count)`; \ fi; \ if test 0 = '$(V)'; then echo " GEN " $@; \ - else echo "$(bootstrap_edit) '$(ltversion_in)' > '$@'"; fi; \ + else echo $(bootstrap_edit) "'$(ltversion_in)' > '$@'"; fi; \ $(bootstrap_edit) '$(ltversion_in)' > '$@'; \ chmod a-w '$@'; \ fi @@ -179,7 +179,7 @@ $(ltmain_sh): $(ltmain_m4sh) $(sh_files) $(dotversion) if $$rebuild; then \ rm -f '$@'; \ if test 0 = '$(V)'; then echo " GEN " $@; \ - else echo "$(LT_M4SH) '$(ltmain.m4sh)' | $(ltmain_sh_edit) > '$@'"; fi; \ + else echo "$(LT_M4SH) '$(ltmain.m4sh)' |" $(ltmain_sh_edit) "> '$@'"; fi; \ $(LT_M4SH) '$(ltmain_m4sh)' | $(ltmain_sh_edit) > '$@'; \ chmod a-w '$@'; \ fi -- 1.7.7.4 Cheers, -- Gary V. Vaughan (gary AT gnu DOT org)