From af3bace2dcddaf078f1b6f14095263c84abd4589 Mon Sep 17 00:00:00 2001 From: Alexandre Duret-Lutz Date: Fri, 10 Jan 2003 18:15:18 +0000 Subject: [PATCH] * Makefile.am (maintainer-check): Do not require SHELL=/bin/sh after $MAKE -e. * tests/ansi3.test, tests/ansi5.test, tests/cond22.test, tests/man2.test, tests/subobj3.test, tests/suffix8.test, tests/suffix11.test: Do not set SHELL=/bin/sh after $MAKE -e. $SHELL is overridden by tests/defs, so it won't hurt even if $MAKE -e uses the $SHELL envvar. * tests/ansi.test, tests/insh2.test, tests/texinfo.test, tests/texinfo8.test: Use SHELL=$SHELL, not SHELL=/bin/sh. Reported by Richard Dawe. --- ChangeLog | 11 +++++++++++ Makefile.am | 17 +++++------------ Makefile.in | 11 +++-------- THANKS | 1 + lib/elisp-comp | 2 ++ tests/ansi.test | 4 ++-- tests/ansi3.test | 4 ++-- tests/ansi5.test | 4 ++-- tests/cond22.test | 4 ++-- tests/insh2.test | 4 ++-- tests/man2.test | 6 +++--- tests/subobj3.test | 4 ++-- tests/suffix11.test | 4 ++-- tests/suffix8.test | 4 ++-- tests/texinfo.test | 4 ++-- tests/texinfo8.test | 4 ++-- 16 files changed, 45 insertions(+), 43 deletions(-) diff --git a/ChangeLog b/ChangeLog index 57dacf7c..94abffe2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,16 @@ 2003-01-10 Alexandre Duret-Lutz + * Makefile.am (maintainer-check): Do not require SHELL=/bin/sh + after $MAKE -e. + * tests/ansi3.test, tests/ansi5.test, tests/cond22.test, + tests/man2.test, tests/subobj3.test, tests/suffix8.test, + tests/suffix11.test: Do not set SHELL=/bin/sh after $MAKE -e. + $SHELL is overridden by tests/defs, so it won't hurt even + if $MAKE -e uses the $SHELL envvar. + * tests/ansi.test, tests/insh2.test, tests/texinfo.test, + tests/texinfo8.test: Use SHELL=$SHELL, not SHELL=/bin/sh. + Reported by Richard Dawe. + Build elisp files all at once instead of one by one. * automake.in (handle_emacs_lisp): Define am__ELFILES. Add elc-stamp to all's dependencies. diff --git a/Makefile.am b/Makefile.am index b89fd048..8efc2ded 100644 --- a/Makefile.am +++ b/Makefile.am @@ -2,8 +2,8 @@ ## Makefile for Automake. -## Copyright (C) 1995, 1996, 1997, 1998, 1999, 2001, 2002 Free -## Software Foundation, Inc. +## Copyright (C) 1995, 1996, 1997, 1998, 1999, 2001, 2002, 2003 +## Free Software Foundation, Inc. ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -213,24 +213,17 @@ maintainer-check: automake aclocal ## recursive targets are used. Better use an envvar. SHELL is an exception, ## POSIX says it can't come from the environment. @if grep -E '\$$MAKE .*(SHELL=.*=|=.*SHELL=)' $(srcdir)/tests/*.test; then \ - echo 'Rewrite "$$MAKE foo=bar SHELL=/bin/sh" as "foo=bar $$MAKE -e SHELL=/bin/sh"' 1>&2; \ + echo 'Rewrite "$$MAKE foo=bar SHELL=$$SHELL" as "foo=bar $$MAKE -e SHELL=$$SHELL"' 1>&2; \ echo ' in the above lines, it is more portable.' 1>&2; \ exit 1; \ fi @if grep -v SHELL $(srcdir)/tests/*.test | grep '\$$MAKE .*=' ; then \ - echo 'Rewrite "$$MAKE foo=bar" as "foo=bar $$MAKE -e SHELL=/bin/sh" in the above lines,' 1>&2; \ + echo 'Rewrite "$$MAKE foo=bar" as "foo=bar $$MAKE -e" in the above lines,' 1>&2; \ echo 'it is more portable.' 1>&2; \ exit 1; \ fi -## On NetBSD (1.5) and OSF, the $SHELL variable is still inherited from -## the environment. - @if grep '$$MAKE.* -e' $(srcdir)/tests/*.test | grep -v '-e.*SHELL' ; then \ - echo 'Always overwrite SHELL when using "$$MAKE -e".' 1>&2; \ - echo 'Use "$$MAKE -e SHELL=/bin/sh" in the above lines.' 1>&2; \ - exit 1; \ - fi @if grep 'SHELL=.*\$$MAKE' $(srcdir)/tests/*.test; then \ - echo '$$MAKE ignores the SHELL envvar, use "$$MAKE SHELL=/bin/sh" in' 1>&2; \ + echo '$$MAKE ignores the SHELL envvar, use "$$MAKE SHELL=$$SHELL" in' 1>&2; \ echo 'the above lines.' 1>&2; \ exit 1; \ fi diff --git a/Makefile.in b/Makefile.in index c2b5d54c..9ec14ce0 100644 --- a/Makefile.in +++ b/Makefile.in @@ -790,22 +790,17 @@ maintainer-check: automake aclocal exit 1; \ fi @if grep -E '\$$MAKE .*(SHELL=.*=|=.*SHELL=)' $(srcdir)/tests/*.test; then \ - echo 'Rewrite "$$MAKE foo=bar SHELL=/bin/sh" as "foo=bar $$MAKE -e SHELL=/bin/sh"' 1>&2; \ + echo 'Rewrite "$$MAKE foo=bar SHELL=$$SHELL" as "foo=bar $$MAKE -e SHELL=$$SHELL"' 1>&2; \ echo ' in the above lines, it is more portable.' 1>&2; \ exit 1; \ fi @if grep -v SHELL $(srcdir)/tests/*.test | grep '\$$MAKE .*=' ; then \ - echo 'Rewrite "$$MAKE foo=bar" as "foo=bar $$MAKE -e SHELL=/bin/sh" in the above lines,' 1>&2; \ + echo 'Rewrite "$$MAKE foo=bar" as "foo=bar $$MAKE -e" in the above lines,' 1>&2; \ echo 'it is more portable.' 1>&2; \ exit 1; \ fi - @if grep '$$MAKE.* -e' $(srcdir)/tests/*.test | grep -v '-e.*SHELL' ; then \ - echo 'Always overwrite SHELL when using "$$MAKE -e".' 1>&2; \ - echo 'Use "$$MAKE -e SHELL=/bin/sh" in the above lines.' 1>&2; \ - exit 1; \ - fi @if grep 'SHELL=.*\$$MAKE' $(srcdir)/tests/*.test; then \ - echo '$$MAKE ignores the SHELL envvar, use "$$MAKE SHELL=/bin/sh" in' 1>&2; \ + echo '$$MAKE ignores the SHELL envvar, use "$$MAKE SHELL=$$SHELL" in' 1>&2; \ echo 'the above lines.' 1>&2; \ exit 1; \ fi diff --git a/THANKS b/THANKS index 78754ee5..deaa7e17 100644 --- a/THANKS +++ b/THANKS @@ -173,6 +173,7 @@ Ralph Schleicher rs@purple.UL.BaWue.DE Ramón García Fernández ramon@jl1.quim.ucm.es Rich Wales richw@webcom.com Richard Boulton richard@tartarus.org +Richard Dawe rich@phekda.freeserve.co.uk Rob Savoye rob@cygnus.com Robert Bihlmeyer robbe@orcus.priv.at Robert Boehne rboehne@ricardo-us.com diff --git a/lib/elisp-comp b/lib/elisp-comp index 031f00df..6a8a6553 100755 --- a/lib/elisp-comp +++ b/lib/elisp-comp @@ -43,6 +43,8 @@ fi tempdir=elc.$$ + + # Cleanup the temporary directory on exit. trap 'status=$?; rm -rf "$tempdir" && exit $status' 0 trap '(exit $?); exit' 1 2 13 15 diff --git a/tests/ansi.test b/tests/ansi.test index 780a3689..0575e626 100755 --- a/tests/ansi.test +++ b/tests/ansi.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002 +# Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002, 2003 # Free Software Foundation, Inc. # # This file is part of GNU Automake. @@ -41,4 +41,4 @@ $ACLOCAL || exit 1 $AUTOMAKE || exit 1 $FGREP -v @SET_MAKE@ Makefile.in > Makefile.sed -$MAKE -s -f Makefile.sed SHELL=/bin/sh magic | grep 'ansi2knr\.c' +$MAKE -s -f Makefile.sed SHELL=$SHELL magic | grep 'ansi2knr\.c' diff --git a/tests/ansi3.test b/tests/ansi3.test index e10a7986..2bc57042 100755 --- a/tests/ansi3.test +++ b/tests/ansi3.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 1998, 1999, 2001, 2002 Free Software Foundation, Inc. +# Copyright (C) 1998, 1999, 2001, 2002, 2003 Free Software Foundation, Inc. # # This file is part of GNU Automake. # @@ -57,5 +57,5 @@ $ACLOCAL \ && $AUTOCONF \ && $AUTOMAKE -a \ && CC='gcc' ./configure \ - && ANSI2KNR=./ansi2knr U=_ $MAKE -e SHELL=/bin/sh \ + && ANSI2KNR=./ansi2knr U=_ $MAKE -e \ && ./hello diff --git a/tests/ansi5.test b/tests/ansi5.test index 4e50458b..f10deba8 100755 --- a/tests/ansi5.test +++ b/tests/ansi5.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 2001, 2002 Free Software Foundation, Inc. +# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. # # This file is part of GNU Automake. # @@ -90,6 +90,6 @@ done mv one/Makefile one/Makefile.old sed -e 's,ANSI2KNR =,ANSI2KNR = ./ansi2knr,' < one/Makefile.old > one/Makefile -U=_ $MAKE -e SHELL=/bin/sh +U=_ $MAKE -e ./one/joe ./two/maude diff --git a/tests/cond22.test b/tests/cond22.test index f911e8ce..dc1289d2 100755 --- a/tests/cond22.test +++ b/tests/cond22.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 2002 Free Software Foundation, Inc. +# Copyright (C) 2002, 2003 Free Software Foundation, Inc. # # This file is part of GNU Automake. # @@ -68,6 +68,6 @@ $ACLOCAL $AUTOCONF $AUTOMAKE ./configure -OBJEXT=oo $MAKE -e SHELL=/bin/sh echo > output +OBJEXT=oo $MAKE -e echo > output cat output $FGREP 'BEG: one.oo two.oo three.oo three2.oo :END' output diff --git a/tests/insh2.test b/tests/insh2.test index 6c867914..4742205d 100755 --- a/tests/insh2.test +++ b/tests/insh2.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002 +# Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002, 2003 # Free Software Foundation, Inc. # # This file is part of GNU Automake. @@ -33,4 +33,4 @@ $ACLOCAL || exit 1 $AUTOMAKE || exit 1 $FGREP -v @SET_MAKE@ Makefile.in > Makefile.sed -$MAKE -s -f Makefile.sed SHELL=/bin/sh magic | grep install-sh +$MAKE -s -f Makefile.sed SHELL=$SHELL magic | grep install-sh diff --git a/tests/man2.test b/tests/man2.test index e8318d38..eba1bee6 100755 --- a/tests/man2.test +++ b/tests/man2.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 2002 Free Software Foundation, Inc. +# Copyright (C) 2002, 2003 Free Software Foundation, Inc. # # This file is part of GNU Automake. # @@ -42,13 +42,13 @@ $AUTOMAKE # Let's play with $DESTDIR too, it shouldn't hurt. ./configure --prefix='' -DESTDIR="`pwd`/=inst" $MAKE -e SHELL=/bin/sh install +DESTDIR="`pwd`/=inst" $MAKE -e install test -f ./=inst/man/man2/foo.2 test -f ./=inst/man/man4/foo.4 test -f ./=inst/man/man4/bar.4 -DESTDIR="`pwd`/=inst" $MAKE -e SHELL=/bin/sh uninstall +DESTDIR="`pwd`/=inst" $MAKE -e uninstall test ! -f ./=inst/man/man2/foo.2 test ! -f ./=inst/man/man4/foo.4 diff --git a/tests/subobj3.test b/tests/subobj3.test index 3a60ec7c..6950ef0a 100755 --- a/tests/subobj3.test +++ b/tests/subobj3.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc. +# Copyright (C) 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. # # This file is part of GNU Automake. # @@ -61,5 +61,5 @@ $ACLOCAL \ && $AUTOCONF \ && $AUTOMAKE -a \ && ./configure \ - && ANSI2KNR=./ansi2knr U=_ $MAKE -e SHELL=/bin/sh \ + && ANSI2KNR=./ansi2knr U=_ $MAKE -e \ && ./hello diff --git a/tests/suffix11.test b/tests/suffix11.test index 4dac1e52..1ba71ba5 100755 --- a/tests/suffix11.test +++ b/tests/suffix11.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 2002 Free Software Foundation, Inc. +# Copyright (C) 2002, 2003 Free Software Foundation, Inc. # # This file is part of GNU Automake. # @@ -56,7 +56,7 @@ grep 'Inference rules can have only one target before the colon' stderr # But this should work anyway. $AUTOMAKE -a -Wno-portability ./configure -env OBJEXT=foo $MAKE -e SHELL=/bin/sh print >stdout +env OBJEXT=foo $MAKE -e print >stdout cat stdout grep 'BEGIN: foo.foo :END' stdout grep 'BEGIN: bar.foo :END' stdout diff --git a/tests/suffix8.test b/tests/suffix8.test index a798dbea..7a475285 100755 --- a/tests/suffix8.test +++ b/tests/suffix8.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 2002 Free Software Foundation, Inc. +# Copyright (C) 2002, 2003 Free Software Foundation, Inc. # # This file is part of GNU Automake. # @@ -73,7 +73,7 @@ $ACLOCAL $AUTOCONF $AUTOMAKE -a ./configure -env OBJEXT=foo $MAKE -e SHELL=/bin/sh print >stdout +env OBJEXT=foo $MAKE -e print >stdout cat stdout grep 'BEGIN: foo.foo :END' stdout grep 'BEGIN: bar.lo :END' stdout diff --git a/tests/texinfo.test b/tests/texinfo.test index 478ccf97..4d3949ed 100755 --- a/tests/texinfo.test +++ b/tests/texinfo.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002 +# Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002, 2003 # Free Software Foundation, Inc. # # This file is part of GNU Automake. @@ -37,4 +37,4 @@ $ACLOCAL || exit 1 $AUTOMAKE || exit 1 $FGREP -v @SET_MAKE@ Makefile.in > Makefile.sed -$MAKE -s -f Makefile.sed SHELL=/bin/sh magic | grep 'texinfo\.tex' +$MAKE -s -f Makefile.sed SHELL=$SHELL magic | grep 'texinfo\.tex' diff --git a/tests/texinfo8.test b/tests/texinfo8.test index cee156c4..db9aebc5 100755 --- a/tests/texinfo8.test +++ b/tests/texinfo8.test @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc. +# Copyright (C) 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. # # This file is part of GNU Automake. # @@ -49,7 +49,7 @@ $AUTOMAKE -a || exit 1 $FGREP -v @SET_MAKE@ sub/Makefile.in > sub/Makefile.sed test -f sub/texinfo.tex && -$MAKE -s -f sub/Makefile.sed SHELL=/bin/sh magic | grep 'texinfo\.tex' +$MAKE -s -f sub/Makefile.sed SHELL=$SHELL magic | grep 'texinfo\.tex' stat=$? exit $stat -- 2.43.5