automake-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Automake-commit] [SCM] GNU Automake branch, master, updated. v1.12.1-19


From: Stefano Lattarini
Subject: [Automake-commit] [SCM] GNU Automake branch, master, updated. v1.12.1-193-g67abae4
Date: Mon, 02 Jul 2012 19:21:19 +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=67abae49732991b596e6fa6d9d93a925720abe64

The branch, master has been updated
       via  67abae49732991b596e6fa6d9d93a925720abe64 (commit)
       via  18dac9077caa49f69aa39e306b146ae700e14e9c (commit)
       via  53d49841f875a7a1e86a874ee5e5d171872ac733 (commit)
       via  d7d983b0276e903b492054d99cbbd6918279cb6a (commit)
      from  22786e467794bb1ee0daf4f47b59de7db612204b (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 67abae49732991b596e6fa6d9d93a925720abe64
Author: Stefano Lattarini <address@hidden>
Date:   Mon Jul 2 21:05:34 2012 +0200

    contrib: check-html: pass flags to rst2html invocations
    
    Related to automake bug#11287.
    
    * contrib/t/check-html.am (.log.html): Here, passing $(AM_RST2HTMLFLAGS)
    and $(RST2HTMLFLAGS) (in that order).
    
    Signed-off-by: Stefano Lattarini <address@hidden>

commit 18dac9077caa49f69aa39e306b146ae700e14e9c
Author: Stefano Lattarini <address@hidden>
Date:   Mon Jul 2 20:58:23 2012 +0200

    contrib: simple improvements to check-html
    
    Related to automake bug#11287.
    
    * contrib/t/check-html.am (.log.html): Do not look for $RST2HTML in
    the environment, looking for $(RST2HTML) should be enough (also, the
    pre-existing code was broken, because it single-quoted $RST2HTML).
    Fix the loop-and-search implementation to be more similar to the
    one in 'contrib/t/parallel-tests-html.sh'.  Prefer 'mv -f' over bare
    'mv'.  Do not break the recipe in
    
    Signed-off-by: Stefano Lattarini <address@hidden>

commit 53d49841f875a7a1e86a874ee5e5d171872ac733
Author: Stefano Lattarini <address@hidden>
Date:   Mon Jul 2 20:33:03 2012 +0200

    coverage: check-html can be used recursively
    
    Addresses the main part of Automake bug#11287.
    
    * contrib/t/parallel-tests-html-recursive.sh: New test.
    * contrib/t/local.am: Add it.
    
    Signed-off-by: Stefano Lattarini <address@hidden>

commit d7d983b0276e903b492054d99cbbd6918279cb6a
Author: Stefano Lattarini <address@hidden>
Date:   Mon Jul 2 17:24:24 2012 +0200

    tests: tests for stuff in contrib goes in 'contrib/t'
    
    * t/help-multilib.sh: Move ...
    * contrib/t/help-multilib.sh: .. here. Remove a now-obsolete
    "FIXME" comment.
    * t/multlib.sh: Move ...
    * contrib/t/multilib.sh: .. here.  Remove a now-obsolete
    "FIXME" comment.
    * t/parallel-test2.sh: Move ...
    * contrib/t/parallel-tests-html.sh: .. here.  Remove a
    now-obsolete "FIXME" comment.
    * contrib/t/local.am: New, basically defining the list of
    tests for stuff in 'contrib/'.
    * t/list-of-tests.mk, Makefile.am: Adjust.
    * .gitignore: Update.
    * syntax-checks.mk (xtests): Likewise.
    
    Signed-off-by: Stefano Lattarini <address@hidden>

-----------------------------------------------------------------------

Summary of changes:
 .gitignore                                         |    3 +
 Makefile.am                                        |    5 +
 contrib/check-html.am                              |   21 ++--
 {t => contrib/t}/help-multilib.sh                  |    2 -
 t/ar-lib7.sh => contrib/t/local.am                 |   33 ++---
 t/multlib.sh => contrib/t/multilib.sh              |    2 -
 contrib/t/parallel-tests-html-recursive.sh         |  163 ++++++++++++++++++++
 .../t/parallel-tests-html.sh                       |    2 -
 syntax-checks.mk                                   |    2 +-
 t/list-of-tests.mk                                 |    3 -
 10 files changed, 194 insertions(+), 42 deletions(-)
 rename {t => contrib/t}/help-multilib.sh (89%)
 copy t/ar-lib7.sh => contrib/t/local.am (61%)
 mode change 100755 => 100644
 rename t/multlib.sh => contrib/t/multilib.sh (96%)
 create mode 100755 contrib/t/parallel-tests-html-recursive.sh
 rename t/parallel-tests2.sh => contrib/t/parallel-tests-html.sh (96%)

diff --git a/.gitignore b/.gitignore
index df004ba..eae55ce 100644
--- a/.gitignore
+++ b/.gitignore
@@ -45,6 +45,9 @@
 /t/*.dir
 /t/*.log
 /t/*.trs
+/contrib/t/*.dir
+/contrib/t/*.log
+/contrib/t/*.trs
 /t/pm/*.log
 /t/pm/*.trs
 /t/perf/*.log
diff --git a/Makefile.am b/Makefile.am
index 860e7ac..f05e82d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -379,6 +379,11 @@ EXTRA_DIST += gen-testsuite-part
 $(generated_TESTS): $(srcdir)/gen-testsuite-part
 $(srcdir)/t/testsuite-part.am: $(srcdir)/gen-testsuite-part Makefile.am
 
+# Hand-written tests for stuff in 'contrib/'.
+include $(srcdir)/contrib/t/local.am
+TESTS += $(contrib_TESTS)
+EXTRA_DIST += $(contrib_TESTS)
+
 # Static dependencies valid for each test case.
 check_SCRIPTS = t/wrap/aclocal-$(APIVERSION) t/wrap/automake-$(APIVERSION)
 dist_check_DATA = \
diff --git a/contrib/check-html.am b/contrib/check-html.am
index 4495ac0..36a5dbe 100644
--- a/contrib/check-html.am
+++ b/contrib/check-html.am
@@ -29,18 +29,17 @@ mostlyclean-check-html:
        rm -f $(TEST_SUITE_HTML)
 
 .log.html:
-       @list='$(RST2HTML) $$RST2HTML rst2html rst2html.py';            \
-       for r2h in $$list; do                                           \
-         if ($$r2h --version) >/dev/null 2>&1; then                    \
-           R2H=$$r2h;                                                  \
-         fi;                                                           \
-       done;                                                           \
-       if test -z "$$R2H"; then                                        \
-         echo >&2 "cannot find rst2html, cannot create $@";            \
+       @list='$(RST2HTML) rst2html rst2html.py';                       \
+       while :; do                                                     \
+         for r2h in $$list; do                                         \
+           if ($$r2h --version) >/dev/null 2>&1; then break 2;         \
+           else :; fi;                                                 \
+         done;                                                         \
+         echo "cannot find rst2html, cannot create $@" >&2;            \
          exit 2;                                                       \
-       fi;                                                             \
-       $$R2H $< >address@hidden
-       @mv address@hidden $@
+       done;                                                           \
+       $$r2h $(AM_RST2HTMLFLAGS) $(RST2HTMLFLAGS) $< >address@hidden           
\
+         && mv -f address@hidden $@
 
 # Be sure to run check first, and then to convert the result.
 # Beware of concurrent executions.  Run "check" not "check-TESTS", as
diff --git a/t/help-multilib.sh b/contrib/t/help-multilib.sh
similarity index 89%
rename from t/help-multilib.sh
rename to contrib/t/help-multilib.sh
index d4f6402..3e89bbe 100755
--- a/t/help-multilib.sh
+++ b/contrib/t/help-multilib.sh
@@ -16,8 +16,6 @@
 
 # Make sure that our macro 'AM_ENABLE_MULTILIB' adds proper text to
 # the configure help screen.
-# FIXME: the features tested by this script has been moved in contrib.
-# FIXME: We should move this script accordingly.
 
 . ./defs || exit 1
 
diff --git a/t/ar-lib7.sh b/contrib/t/local.am
old mode 100755
new mode 100644
similarity index 61%
copy from t/ar-lib7.sh
copy to contrib/t/local.am
index c27cabf..3859c70
--- a/t/ar-lib7.sh
+++ b/contrib/t/local.am
@@ -1,34 +1,25 @@
-#! /bin/sh
-# Copyright (C) 2011-2012 Free Software Foundation, Inc.
-#
+# Copyright (C) 1995-2012 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/>.
 
-# Test if automake warns if ar-lib is missing when AM_PROG_AR is used.
-
-. ./defs || exit 1
-
-cat >> configure.ac << 'END'
-AM_PROG_AR
-END
-
-:> Makefile.am
-
-$ACLOCAL
-AUTOMAKE_fails
-
-grep '^configure\.ac:.*ar-lib.*not found' stderr
+# Automake: tests for stuff in 'contrib/'.
 
-$AUTOMAKE --add-missing
+## Relative to the top-level directory.
+contrib_testsuite_dir = contrib/t
 
-:
+contrib_TESTS = \
+  $(contrib_testsuite_dir)/parallel-tests-html.sh \
+  $(contrib_testsuite_dir)/parallel-tests-html-recursive.sh \
+  $(contrib_testsuite_dir)/help-multilib.sh \
+  $(contrib_testsuite_dir)/multilib.sh
diff --git a/t/multlib.sh b/contrib/t/multilib.sh
similarity index 96%
rename from t/multlib.sh
rename to contrib/t/multilib.sh
index 778db14..fef1ec2 100755
--- a/t/multlib.sh
+++ b/contrib/t/multilib.sh
@@ -16,8 +16,6 @@
 
 # Check multilib support.
 # Based on a test case from Ralf Corsepius.
-# FIXME: the features tested by this script has been moved in contrib.
-# FIXME: We should move this script accordingly.
 
 required='gcc GNUmake'
 . ./defs || exit 1
diff --git a/contrib/t/parallel-tests-html-recursive.sh 
b/contrib/t/parallel-tests-html-recursive.sh
new file mode 100755
index 0000000..12d967e
--- /dev/null
+++ b/contrib/t/parallel-tests-html-recursive.sh
@@ -0,0 +1,163 @@
+#! /bin/sh
+# Copyright (C) 2012 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/>.
+
+# Recursive use of 'check-html'.  See Automake bug#11287.
+
+. ./defs || exit 1
+
+# Try the variants that are tried in check-html.am.
+while :; do
+  for r2h in $RST2HTML rst2html rst2html.py; do
+    echo "$me: running $r2h --version"
+    $r2h --version && break 2
+    : For shells with busted 'set -e'.
+  done
+  skip_all_ "no proper rst2html program found"
+done
+unset r2h
+
+cp "$am_top_srcdir"/contrib/check-html.am . \
+  || fatal_ "cannot fetch 'check-html.am' from contrib"
+
+cat >> configure.ac << 'END'
+AM_EXTRA_RECURSIVE_TARGETS([check-html])
+AC_CONFIG_FILES([sub/Makefile sub/more/Makefile])
+AC_OUTPUT
+END
+
+cat > Makefile.am << 'END'
+SUBDIRS = sub
+EXTRA_DIST = $(TESTS)
+TEST_SUITE_LOG = mylog.log
+TESTS = foo.test bar.sh mu
+XFAIL_TESTS = bar.sh
+check_SCRIPTS = bla
+bla:
+       echo '#!/bin/sh' > address@hidden
+       echo 'echo Blah Blah Blah' >> address@hidden
+       chmod a+x,a-w address@hidden
+       mv -f address@hidden $@
+CLEANFILES = bla
+include $(srcdir)/check-html.am
+END
+
+mkdir sub
+echo SUBDIRS = more > sub/Makefile.am
+
+mkdir sub/more
+cat > sub/more/Makefile.am << 'END'
+include $(top_srcdir)/check-html.am
+TEST_EXTENSIONS = .test .sh
+TESTS = sh.sh test.test
+LOG_COMPILER = true
+test.log: sh.log
+nodist_check_DATA = x.txt
+$(nodist_check_DATA):
+       echo $@ > $@
+CLEANFILES = $(nodist_check_DATA)
+EXTRA_DIST = $(TESTS)
+END
+
+cat > foo.test <<'END'
+#! /bin/sh
+./bla
+exit 77
+END
+
+cat > bar.sh <<'END'
+#! /bin/sh
+echo "this is $0"
+exit 1
+END
+
+cat > mu <<'END'
+#! /bin/sh
+set -x
+test -f sub/more/test.log
+test -f sub/more/sh.log
+END
+
+cat > sub/more/test.test << 'END'
+#!/bin/sh
+echo "this is $0"
+set -x
+test -f sh.log
+test -f x.txt
+exit 77
+END
+
+cat > sub/more/sh.sh << 'END'
+#!/bin/sh
+set -x
+test ! -f test.log
+test -f x.txt
+END
+
+
+cat > sub/more/mu << 'END'
+#!/bin/sh
+exit 99
+END
+
+chmod a+x foo.test bar.sh mu sub/more/test.test sub/more/sh.sh
+
+$ACLOCAL
+$AUTOCONF
+$AUTOMAKE -a
+
+./configure
+
+$MAKE check-html
+grep 'Blah Blah Blah' mylog.html
+grep 'this is .*bar\.sh' mylog.html
+grep 'this is .*test\.test' sub/more/test-suite.html
+# check-html should cause check_SCRIPTS and check_DATA to be created.
+test -f bla
+test -f sub/more/x.txt
+
+# "make clean" should remove HTML files.
+$MAKE clean
+test ! -e mylog.html
+test ! -e sub/more/test-suite.html
+test ! -e bla
+test ! -e sub/more/x.txt
+
+# Create HTML output for individual tests.
+
+$MAKE bla
+$MAKE foo.html bar.sh.html
+grep 'Blah Blah Blah' foo.html
+grep 'this is .*bar\.sh' bar.sh.html
+test ! -e mu.hml
+
+ocwd=$(pwd) || fatal_ "getting current workind directory"
+( cd sub/more \
+    && $MAKE sh.html \
+    && test -f sh.html \
+    && test ! -e test.html \
+    && $MAKE test.html \
+    && grep 'this is .*test\.test' test.html) || exit 1
+
+# HTML output removed by mostlyclean.
+$MAKE check-html
+test -f mylog.html
+test -f sub/more/test-suite.html
+$MAKE mostlyclean
+find . -name '*.html' | grep . && exit 1
+
+$MAKE distcheck
+
+:
diff --git a/t/parallel-tests2.sh b/contrib/t/parallel-tests-html.sh
similarity index 96%
rename from t/parallel-tests2.sh
rename to contrib/t/parallel-tests-html.sh
index ae9bd38..e7abc66 100755
--- a/t/parallel-tests2.sh
+++ b/contrib/t/parallel-tests-html.sh
@@ -17,8 +17,6 @@
 # Check parallel-tests features:
 #  - check-html
 #  - recheck-html
-# FIXME: the features tested by this script has been moved in contrib.
-# FIXME: We should move this script accordingly.
 
 . ./defs || exit 1
 
diff --git a/syntax-checks.mk b/syntax-checks.mk
index 052547c..6ebaf69 100644
--- a/syntax-checks.mk
+++ b/syntax-checks.mk
@@ -27,7 +27,7 @@ xtests := $(shell \
    fi; \
    for d in $$dirs; do \
      for s in tap sh; do \
-       ls $$d/t/*.$$s $$d/t/ax/*.$$s 2>/dev/null; \
+       ls $$d/t/ax/*.$$s $$d/t/*.$$s $$d/contrib/t/*.$$s 2>/dev/null; \
      done; \
    done | sort)
 
diff --git a/t/list-of-tests.mk b/t/list-of-tests.mk
index 7b0bd97..08919da 100644
--- a/t/list-of-tests.mk
+++ b/t/list-of-tests.mk
@@ -487,7 +487,6 @@ t/help-depend2.sh \
 t/help-dmalloc.sh \
 t/help-init.sh \
 t/help-lispdir.sh \
-t/help-multilib.sh \
 t/help-python.sh \
 t/help-silent.sh \
 t/help-upc.sh \
@@ -676,7 +675,6 @@ t/mkinst2.sh \
 t/mkinst3.sh \
 t/mmode.sh \
 t/mmodely.sh \
-t/multlib.sh \
 t/no-extra-makefile-code.sh \
 t/no-outdir-option.sh \
 t/nobase.sh \
@@ -731,7 +729,6 @@ t/parallel-am2.sh \
 t/parallel-am3.sh \
 t/serial-tests.sh \
 t/parallel-tests.sh \
-t/parallel-tests2.sh \
 t/parallel-tests3.sh \
 t/parallel-tests5.sh \
 t/parallel-tests6.sh \


hooks/post-receive
-- 
GNU Automake



reply via email to

[Prev in Thread] Current Thread [Next in Thread]