[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Automake-commit] [SCM] GNU Automake branch, testsuite-work, updated. v1
From: |
Stefano Lattarini |
Subject: |
[Automake-commit] [SCM] GNU Automake branch, testsuite-work, updated. v1.11-977-gcc9a67f |
Date: |
Mon, 27 Jun 2011 13:48:50 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Automake".
http://git.sv.gnu.org/gitweb/?p=automake.git;a=commitdiff;h=cc9a67f2fd5e0c422fb0bae819cb70708253b030
The branch, testsuite-work has been updated
via cc9a67f2fd5e0c422fb0bae819cb70708253b030 (commit)
via d49776091458ca8affb5defa3c766c354bb09efe (commit)
via 404882ab2ac0a9447f6eccb2fa218df70582f488 (commit)
via 5755b7bcbd3892eb6aa31542fc7e2435a0de11ab (commit)
via 1f2e5599a81965c3d7da88995f70455e8fcb8e30 (commit)
via c1040a74c10a9a011a04ad0d347b61465c5ee194 (commit)
via 9478566087f83d1fac2c9a7629898a3d39a05fdd (commit)
via cb3e1296ac8a01fcf4b38d10584f218722655e1c (commit)
via 72d36af268fa7bee24466e21d2d543d8d1ce7b1c (commit)
via 555ce8b7686c798b0cc599b218955147b0d4c5ea (commit)
via 1c3614c6d47b4428c39a784dda7f2641cfc8f6d6 (commit)
via 1e005df1553b0211a1a8c2ef0e6d62eb41ce0ba5 (commit)
from 1ed48303b1c6f7a086a60b3b99bfafc25fbde3aa (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit cc9a67f2fd5e0c422fb0bae819cb70708253b030
Merge: 1ed4830 d497760
Author: Stefano Lattarini <address@hidden>
Date: Mon Jun 27 15:38:18 2011 +0200
Merge branch 'master' into testsuite-work
* master:
docs: avoid a footnote, some related rewordings and improvements
docs: minor cosmetic fixes
help: improve text about automatically-distributed files
refactor: split 'usage' subroutine in automake
tests: fix bug in 'autodist.test'
maintcheck: extend 'sc_tests_plain_*' checks
tests: interactions between TESTS_ENVIRONMENT and LOG_COMPILER
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 67 +++++++++++++++++
Makefile.am | 24 ++++++
Makefile.in | 21 ++++++
automake.in | 95 +++++++++++++------------
doc/automake.texi | 42 +++++++-----
tests/Makefile.am | 2 +
tests/Makefile.in | 2 +
tests/autodist-no-duplicate.test | 52 ++++++++++++++
tests/autodist-subdir.test | 27 +-------
tests/autodist.test | 31 +--------
tests/tests-environment-and-log-compiler.test | 75 +++++++++++++++++++
11 files changed, 321 insertions(+), 117 deletions(-)
create mode 100755 tests/autodist-no-duplicate.test
create mode 100755 tests/tests-environment-and-log-compiler.test
diff --git a/ChangeLog b/ChangeLog
index 26e43d3..3c79637 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,70 @@
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ docs: avoid a footnote, some related rewordings and improvements
+ * doc/automake.texi (Dist): Reword the part about automatically
+ distributed files to avoid a footnote. Since we are at it, extend
+ a bit, and add an example and a reference to a relevant test case.
+
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ docs: minor cosmetic fixes
+ * doc/automake.texi: Break few overly long lines, throughout the
+ file.
+ ("Simple Tests"): Move @vindex for XFAIL_TESTS to the correct
+ position, i.e., before and not after the paragraph where it is
+ introduced.
+ ("Options" @item ansi2knr): Use @pxref instead of @xref. This
+ fixes a texinfo warning.
+ ("Other things Automake recognizes" @item AM_C_PROTOTYPES): Use
+ @pxref instead of @ref.
+
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ help: improve text about automatically-distributed files
+ This change fixes automake bug#7819.
+ * automake.in (usage): Distinguish between files that are always
+ automatically distributed when found, and those which are only
+ "under certain conditions".
+ * doc/automake.texi (Basics of Distribution): Update accordingly.
+ * tests/autodist-subdir.test: Update.
+ * tests/autodist-no-duplicate.test: Likewise.
+ * tests/autodist.test: Likewise.
+ (configure.in): Remove useless call to AM_MAINTAINER_MODE.
+
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ refactor: split 'usage' subroutine in automake
+ This change is related to automake bug#7819.
+ * automake.in (print_autodist_files): New subroutine,
+ extracted from ...
+ (usage): ... this, which now uses it.
+ * tests/autodist-no-duplicate.test: New test.
+ * tests/Makefile.am (TESTS): Update.
+
+2011-06-23 Stefano Lattarini <address@hidden>
+
+ tests: fix bug in 'autodist.test'
+ * tests/autodist.test: Avoid spurious failure due to no
+ `defs-static' file being found in the parent directory.
+
+2011-06-21 Stefano Lattarini <address@hidden>
+
+ maintcheck: extend 'sc_tests_plain_*' checks
+ * Makefile.am (sc_tests_plain_autom4te): New check.
+ (sc_tests_plain_autoreconf): Likewise.
+ (sc_tests_plain_autoheader): Likewise.
+ (syntax_check_rules): Update.
+
+2011-06-21 Stefano Lattarini <address@hidden>
+
+ tests: interactions between TESTS_ENVIRONMENT and LOG_COMPILER
+ * tests/tests-environment-and-log-compiler.test: New test,
+ checking that we can use variables and functions set by
+ TESTS_ENVIRONMENT and AM_TESTS_ENVIRONMENT in LOG_COMPILER
+ and LOG_FLAGS (for tests both with and without registered
+ extensions).
+ * tests/Makefile.am (TESTS): Update.
+
2011-06-24 Stefano Lattarini <address@hidden>
tests: make 'subst-no-trailing-empty-line.test' more robust
diff --git a/Makefile.am b/Makefile.am
index 94c732c..09706ff 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -189,6 +189,9 @@ sc_tests_plain_make \
sc_tests_plain_autoconf \
sc_tests_plain_autoupdate \
sc_tests_plain_automake \
+sc_tests_plain_autom4te \
+sc_tests_plain_autoheader \
+sc_tests_plain_autoreconf \
sc_tests_here_document_format \
sc_tests_Exit_not_exit \
sc_tests_automake_fails \
@@ -457,6 +460,27 @@ sc_tests_plain_automake:
exit 1; \
fi
+## Tests should never call autoheader directly.
+sc_tests_plain_autoheader:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoheader\>'; then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTOHEADER"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
+## Tests should never call autoreconf directly.
+sc_tests_plain_autoreconf:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoreconf\>'; then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTORECONF"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
+## Tests should never call autom4te directly.
+sc_tests_plain_autom4te:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autom4te\>';
then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTOM4TE"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
## Tests should only use END and EOF for here documents
## (so that the next test is effective).
sc_tests_here_document_format:
diff --git a/Makefile.in b/Makefile.in
index 30fe9e1..2374ab9 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -318,6 +318,9 @@ sc_tests_plain_make \
sc_tests_plain_autoconf \
sc_tests_plain_autoupdate \
sc_tests_plain_automake \
+sc_tests_plain_autom4te \
+sc_tests_plain_autoheader \
+sc_tests_plain_autoreconf \
sc_tests_here_document_format \
sc_tests_Exit_not_exit \
sc_tests_automake_fails \
@@ -1204,6 +1207,24 @@ sc_tests_plain_automake:
exit 1; \
fi
+sc_tests_plain_autoheader:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoheader\>'; then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTOHEADER"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
+sc_tests_plain_autoreconf:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[
]*autoreconf\>'; then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTORECONF"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
+sc_tests_plain_autom4te:
+ @if grep -v '^#' $(srcdir)/tests/*.test | grep ':[ ]*autom4te\>';
then \
+ echo 'Do not run "automake" in the above tests. Use "$$AUTOM4TE"
instead.' 1>&2; \
+ exit 1; \
+ fi
+
sc_tests_here_document_format:
@if grep '<<' $(srcdir)/tests/*.test | grep -v 'END' | grep -v 'EOF';
then \
echo 'Use here documents with "END" and "EOF" only, for
greppability.' 1>&2; \
diff --git a/automake.in b/automake.in
index 7827680..517eea9 100644
--- a/automake.in
+++ b/automake.in
@@ -8366,6 +8366,50 @@ sub generate_makefile ($$)
################################################################
+# Helper function for usage().
+sub print_autodist_files (@)
+{
+ my @lcomm = sort (&uniq (@_));
+
+ my @four;
+ format USAGE_FORMAT =
+ @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<<
+ $four[0], $four[1], $four[2], $four[3]
+.
+ local $~ = "USAGE_FORMAT";
+
+ my $cols = 4;
+ my $rows = int(@lcomm / $cols);
+ my $rest = @lcomm % $cols;
+
+ if ($rest)
+ {
+ $rows++;
+ }
+ else
+ {
+ $rest = $cols;
+ }
+
+ for (my $y = 0; $y < $rows; $y++)
+ {
+ @four = ("", "", "", "");
+ for (my $x = 0; $x < $cols; $x++)
+ {
+ last if $y + 1 == $rows && $x == $rest;
+
+ my $idx = (($x > $rest)
+ ? ($rows * $rest + ($rows - 1) * ($x - $rest))
+ : ($rows * $x));
+
+ $idx += $y;
+ $four[$x] = $lcomm[$idx];
+ }
+ write;
+ }
+}
+
+
# Print usage information.
sub usage ()
{
@@ -8399,51 +8443,12 @@ Library files:
";
Automake::ChannelDefs::usage;
- my ($last, @lcomm);
- $last = '';
- foreach my $iter (sort ((@common_files, @common_sometimes)))
- {
- push (@lcomm, $iter) unless $iter eq $last;
- $last = $iter;
- }
-
- my @four;
- print "\nFiles which are automatically distributed, if found:\n";
- format USAGE_FORMAT =
- @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<< @<<<<<<<<<<<<<<<<
- $four[0], $four[1], $four[2], $four[3]
-.
- $~ = "USAGE_FORMAT";
-
- my $cols = 4;
- my $rows = int(@lcomm / $cols);
- my $rest = @lcomm % $cols;
-
- if ($rest)
- {
- $rows++;
- }
- else
- {
- $rest = $cols;
- }
-
- for (my $y = 0; $y < $rows; $y++)
- {
- @four = ("", "", "", "");
- for (my $x = 0; $x < $cols; $x++)
- {
- last if $y + 1 == $rows && $x == $rest;
-
- my $idx = (($x > $rest)
- ? ($rows * $rest + ($rows - 1) * ($x - $rest))
- : ($rows * $x));
-
- $idx += $y;
- $four[$x] = $lcomm[$idx];
- }
- write;
- }
+ print "\nFiles automatically distributed if found " .
+ "(always):\n";
+ print_autodist_files @common_files;
+ print "\nFiles automatically distributed if found " .
+ "(under certain conditions):\n";
+ print_autodist_files @common_sometimes;
print '
Report bugs to <@PACKAGE_BUGREPORT@>.
diff --git a/doc/automake.texi b/doc/automake.texi
index 59ddcfd..afb7b33 100644
--- a/doc/automake.texi
+++ b/doc/automake.texi
@@ -84,7 +84,8 @@ section entitled ``GNU Free Documentation License.''
@c Put the macros in the function index.
@syncodeindex ac fn
address@hidden Put everything else into one index (arbitrarily chosen to be the
concept index).
address@hidden Put everything else into one index (arbitrarily chosen to be the
address@hidden concept index).
@syncodeindex op cp
@syncodeindex tr cp
@syncodeindex cm cp
@@ -3036,8 +3037,9 @@ this way, e.g., @code{AC_PATH_XTRA} defines
@code{X_CFLAGS} and
if @code{AC_PATH_XTRA} is called.
@item AM_C_PROTOTYPES
-This is required when using the deprecated de-ANSI-fication feature; see
address@hidden @emph{It will be removed} in the next major Automake release.
+This is required when using the deprecated de-ANSI-fication feature;
address@hidden @emph{It will be removed} in the next major Automake
+release.
@item AM_CONDITIONAL
This introduces an Automake conditional (@pxref{Conditionals}).
@@ -5855,8 +5857,8 @@ needs to be avoided: when a target should not be built
from sources.
We already saw such an example in @ref{true}; this happens when all
the constituents of a target have already been compiled and just need
to be combined using a @code{_LDADD} variable. Then it is necessary
-to define an empty @code{_SOURCES} variable, so that @command{automake} does
not
-compute a default.
+to define an empty @code{_SOURCES} variable, so that @command{automake}
+does not compute a default.
@example
bin_PROGRAMS = target
@@ -6839,8 +6841,9 @@ If no directory prefix is given, the files are assumed to
be in the
current directory.
Note that automatic de-ANSI-fication will not work when the package is
-being built for a different host architecture. That is because
@command{automake}
-currently has no way to build @command{ansi2knr} for the build machine.
+being built for a different host architecture. That is because
address@hidden currently has no way to build @command{ansi2knr}
+for the build machine.
@c FIXME: this paragraph might be better moved to an `upgrading' section.
@cindex @code{LTLIBOBJS} and @code{ansi2knr}
@@ -6934,10 +6937,10 @@ bin_PROGRAMS = liver$(EXEEXT)
The targets Automake generates are likewise given the @samp{$(EXEEXT)}
extension.
-The variables @code{TESTS} and @code{XFAIL_TESTS} (@pxref{Simple Tests}) are
also
-rewritten if they contain filenames that have been declared as programs
-in the same @file{Makefile}. (This is mostly useful when some programs
-from @code{check_PROGRAMS} are listed in @code{TESTS}.)
+The variables @code{TESTS} and @code{XFAIL_TESTS} (@pxref{Simple Tests})
+are also rewritten if they contain filenames that have been declared as
+programs in the same @file{Makefile}. (This is mostly useful when some
+programs from @code{check_PROGRAMS} are listed in @code{TESTS}.)
However, Automake cannot apply this rewriting to @command{configure}
substitutions. This means that if you are conditionally building a
@@ -8317,14 +8320,19 @@ is run. The default setting is @option{--best}.
@cmindex include
For the most part, the files to distribute are automatically found by
Automake: all source files are automatically included in a distribution,
-as are all @file{Makefile.am}s and @file{Makefile.in}s. Automake also
+as are all @file{Makefile.am} and @file{Makefile.in} files. Automake also
has a built-in list of commonly used files that are automatically
included if they are found in the current directory (either physically,
-or as the target of a @file{Makefile.am} rule). This list is printed by
address@hidden --help}. Also, files that are read by @command{configure}
+or as the target of a @file{Makefile.am} rule); this list is printed by
address@hidden --help}. Note that some files in this list are actually
+distributed only if other certain conditions hold (for example,
address@hidden The following example is covered by autodist-config-headers.test.
+the @file{config.h.top} and @file{config.h.bot} files are automatically
+distributed only if, e.g., @samp{AC_CONFIG_HEADERS([config.h])} is used
+in @file{configure.ac}). Also, files that are read by @command{configure}
(i.e.@: the source files corresponding to the files specified in various
Autoconf macros such as @code{AC_CONFIG_FILES} and siblings) are
-automatically distributed. Files included in @file{Makefile.am}s (using
+automatically distributed. Files included in a @file{Makefile.am} (using
@code{include}) or in @file{configure.ac} (using @code{m4_include}), and
helper scripts installed with @samp{automake --add-missing} are also
distributed.
@@ -8684,10 +8692,10 @@ parallel-tests}).
@cindex Tests, expected failure
@cindex Expected test failure
address@hidden XFAIL_TESTS
You may define the variable @code{XFAIL_TESTS} to a list of tests
(usually a subset of @code{TESTS}) that are expected to fail. This will
reverse the result of those tests.
address@hidden XFAIL_TESTS
Automake ensures that each file listed in @code{TESTS} is built before
any tests are run; you can list both source and derived programs (or
@@ -9180,7 +9188,7 @@ implies options @option{readme-alpha} and
@option{check-news}.
@itemx @address@hidden/ansi2knr}
@cindex Option, @option{ansi2knr}
@opindex ansi2knr
-Turn on the deprecated de-ANSI-fication feature (@xref{ANSI}). Note
+Turn on the deprecated de-ANSI-fication feature (@pxref{ANSI}). Note
that that feature and this option @emph{will be removed} in the next
major Automake release.
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 292031f..e1487e2 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -214,6 +214,7 @@ autodist-acconfig-no-subdir.test \
autodist-aclocal-m4.test \
autodist-config-headers.test \
autodist-configure-no-subdir.test \
+autodist-no-duplicate.test \
autodist-stamp-vti.test \
autohdr.test \
autohdr2.test \
@@ -1009,6 +1010,7 @@ tar3.test \
target-cflags.test \
targetclash.test \
tests-environment-fd-redirect.test \
+tests-environment-and-log-compiler.test \
txinfo.test \
txinfo2.test \
txinfo3.test \
diff --git a/tests/Makefile.in b/tests/Makefile.in
index c1a920b..8555866 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -502,6 +502,7 @@ autodist-acconfig-no-subdir.test \
autodist-aclocal-m4.test \
autodist-config-headers.test \
autodist-configure-no-subdir.test \
+autodist-no-duplicate.test \
autodist-stamp-vti.test \
autohdr.test \
autohdr2.test \
@@ -1297,6 +1298,7 @@ tar3.test \
target-cflags.test \
targetclash.test \
tests-environment-fd-redirect.test \
+tests-environment-and-log-compiler.test \
txinfo.test \
txinfo2.test \
txinfo3.test \
diff --git a/tests/autodist-no-duplicate.test b/tests/autodist-no-duplicate.test
new file mode 100755
index 0000000..81464c0
--- /dev/null
+++ b/tests/autodist-no-duplicate.test
@@ -0,0 +1,52 @@
+#! /bin/sh
+# Copyright (C) 2011 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
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# Check that there are no duplicates in the list of files automatically
+# distributed by automake.
+
+. ./defs || Exit 1
+
+set -e
+
+re='Files .*automatically distributed.*if found'
+
+# The automake manual states that the list of automatically-distributed
+# files should be given by `automake --help'.
+
+list1=`$AUTOMAKE --help \
+ | sed -n "/^$re.*always/,/^ *$/p" \
+ | sed 1d`
+list1=`echo $list1`
+
+list2=`$AUTOMAKE --help \
+ | sed -n "/^$re.*under certain conditions/,/^ *$/p" \
+ | sed 1d`
+list2=`echo $list2`
+
+test -n "$list1"
+test -n "$list2"
+
+st=0
+for i in 1 2; do
+ eval list=\${list$i}
+ for f in $list; do echo $f; done | sort > files$i.lst
+ uniq files$i.lst > files$i.uniq
+ cat files$i.lst
+ cat files$i.uniq
+ diff files$i.lst files$i.uniq || st=1
+done
+
+Exit $st
diff --git a/tests/autodist-subdir.test b/tests/autodist-subdir.test
index 09dcc82..6c0a1d5 100755
--- a/tests/autodist-subdir.test
+++ b/tests/autodist-subdir.test
@@ -37,33 +37,8 @@ $AUTOCONF
# The automake manual states that the list of automatically-distributed
# files should be given by `automake --help'.
list=`$AUTOMAKE --help \
- | sed -n '/^Files .*automatically distributed.*if found/,/^ *$/p' \
+ | sed -n '/^Files.*automatically distributed.*if found.*always/,/^
*$/p' \
| sed 1d`
-list=`for f in $list; do
- case $f in
- configure|configure.in|configure.ac)
- # See test 'autodist-configure-no-subdir.test'.
- ;;
- aclocal.m4)
- # This file should be distributed only when it is a real
- # dependency for configure. Anyway, not a check to be
- # performed in this test.
- ;;
- acconfig.h)
- # Works only when it really exists, not when it is a
- # target in Makefile.am.
- ;;
- stamp-vti)
- # Works only when using info_TEXINFOS and version.texi.
- ;;
- config.h.bot|config.h.top)
- # Works only when the AC_CONFIG_HADERS macro is used.
- ;;
- *)
- echo $f
- ;;
- esac
- done`
# Normalize whitespace, just in case.
list=`echo $list`
diff --git a/tests/autodist.test b/tests/autodist.test
index 681be09..f6fa6fd 100755
--- a/tests/autodist.test
+++ b/tests/autodist.test
@@ -23,15 +23,13 @@
# Ensure we are run from the right directory.
# (The last thing we want is to delete some random user files.)
-test -f ../defs-static
+test -f ../defs-static && test -f ../defs || Exit 99
rm -f *
cat > configure.in <<END
AC_INIT([$me], [1.0])
AC_CONFIG_AUX_DIR([.])
AM_INIT_AUTOMAKE
-## Will avoid useless regeneration of aclocal.m4, configure, etc.
-AM_MAINTAINER_MODE
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
END
@@ -42,33 +40,8 @@ $AUTOCONF
# The automake manual states that the list of automatically-distributed
# files should be given by `automake --help'.
list=`$AUTOMAKE --help \
- | sed -n '/^Files .*automatically distributed.*if found/,/^ *$/p' \
+ | sed -n '/^Files.*automatically distributed.*if found.*always/,/^
*$/p' \
| sed 1d`
-list=`for f in $list; do
- case $f in
- configure|configure.in|configure.ac)
- # See test 'autodist-configure-no-subdir.test'.
- ;;
- aclocal.m4)
- # This file should be distributed only when it is a real
- # dependency for configure. Anyway, not a check to be
- # performed in this test.
- ;;
- acconfig.h)
- # Works only when it really exists, not when it is a
- # target in Makefile.am.
- ;;
- stamp-vti)
- # Works only when using info_TEXINFOS and version.texi.
- ;;
- config.h.bot|config.h.top)
- # Works only when the AC_CONFIG_HADERS macro is used.
- ;;
- *)
- echo $f
- ;;
- esac
- done`
# Normalize whitespace, just in case.
list=`echo $list`
diff --git a/tests/tests-environment-and-log-compiler.test
b/tests/tests-environment-and-log-compiler.test
new file mode 100755
index 0000000..3753bb9
--- /dev/null
+++ b/tests/tests-environment-and-log-compiler.test
@@ -0,0 +1,75 @@
+#! /bin/sh
+# Copyright (C) 2011 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
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# parallel-tests: check that we can use variables and functions set
+# by TESTS_ENVIRONMENT and AM_TESTS_ENVIRONMENT in LOG_COMPILER and
+# LOG_FLAGS (for tests both with and without registered extensions).
+
+parallel_tests=yes
+. ./defs || Exit 1
+
+cat >> configure.in << 'END'
+AC_OUTPUT
+END
+
+unset v0 v1 v2 v3 v4 || :
+
+cat > Makefile.am << 'END'
+TESTS_ENVIRONMENT = am__f3 () { echo 3; }; v0='$(srcdir)' v1=1; :;
+AM_TESTS_ENVIRONMENT = v2=2; v4=4 && am__f5 () { echo 5; }; :;
+
+LOG_COMPILER = $$v0/log-compiler $$v1
+AM_LOG_FLAGS = $$v2 `am__f3`
+LOG_FLAGS = $$v4 `am__f5`
+
+TEST_LOG_COMPILER = $$v0/test-log-compiler $$v2
+AM_TEST_LOG_FLAGS = `am__f5` $$v1
+TEST_LOG_FLAGS = $$v4 `am__f3`
+
+EXTRA_DIST = log-compiler test-log-compiler
+
+TESTS = a b.test
+$(TESTS):
+END
+
+cat > log-compiler << 'END'
+#! /bin/sh
+echo "$0: $*"
+test x"$1$2$3$4$5" = x"12345"
+END
+
+cat > test-log-compiler << 'END'
+#! /bin/sh
+echo "$0: $*"
+test x"$1$2$3$4$5" = x"25143"
+END
+
+chmod a+x test-log-compiler log-compiler
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE -a
+
+./configure
+
+$MAKE -n check # For debugging.
+VERBOSE=yes $MAKE check
+cat a.log
+cat b.log
+
+VERBOSE=yes $MAKE distcheck
+
+:
hooks/post-receive
--
GNU Automake
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Automake-commit] [SCM] GNU Automake branch, testsuite-work, updated. v1.11-977-gcc9a67f,
Stefano Lattarini <=