Merge branch 'maint'
authorStefano Lattarini <stefano.lattarini@gmail.com>
Wed, 14 Mar 2012 21:29:59 +0000 (22:29 +0100)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Wed, 14 Mar 2012 21:35:29 +0000 (22:35 +0100)
* maint:
  tests: avoid spurious failures in get-sysconf.test
  scripts: bump the depcomp scriptversion
  sync: some auxiliary files synced from upstream
  coverage: an empty foo_PRIMARY should create directory $(foodir)
  coverage: make sure am__py_compile is defined when needed
  coverage: expose automake bug#10997
  coverage: expose automake bug#10975
  getopt: relax version requirement for perl

+ Extra non-trivial edits:

* tests/dist-pr109765.test: Use 'configure.ac', not 'configure.in'.
* tests/instdir-cond.test: Likewise.
* tests/instdir-empty.test: Likewise.

Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
1  2 
lib/depcomp
tests/Makefile.am
tests/dist-pr109765.test
tests/get-sysconf.test
tests/instdir-cond.test
tests/instdir-empty.test
tests/list-of-tests.mk
tests/python.test

diff --cc lib/depcomp
@@@ -1,9 -1,10 +1,9 @@@
  #! /bin/sh
  # depcomp - compile a program generating dependencies as side-effects
  
- scriptversion=2012-02-03.15; # UTC
+ scriptversion=2012-03-12.15; # UTC
  
 -# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009, 2010,
 -# 2011, 2012 Free Software Foundation, Inc.
 +# Copyright (C) 1999-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
  # You should have received a copy of the GNU General Public License
  # along with this program.  If not, see <http://www.gnu.org/licenses/>.
  
 +# Run the tests with the shell detected at configure time.
 +LOG_COMPILER = $(SHELL)
 +
 +TEST_EXTENSIONS = .pl .test .tap
 +TEST_LOG_COMPILER = $(LOG_COMPILER)
 +TAP_LOG_COMPILER = $(LOG_COMPILER)
 +PL_LOG_COMPILER = $(PERL)
 +AM_PL_LOG_FLAGS = -Mstrict -I $(top_builddir)/lib -I $(top_srcdir)/lib -w
 +
 +TAP_LOG_DRIVER = AM_TAP_AWK='$(AWK)' $(SHELL) $(top_srcdir)/lib/tap-driver.sh
 +
 +AM_TAP_LOG_DRIVER_FLAGS = --merge
 +
 +EXTRA_DIST = ax/is ChangeLog-old
 +
 +TESTS = ## Will be updated later.
 +
  XFAIL_TESTS = \
  all.test \
 -auxdir2.test \
 +yacc-bison-skeleton-cxx.test \
 +yacc-bison-skeleton.test \
  cond17.test \
 -dist-auxfile.test \
 -dist-auxfile-2.test \
 -dist-pr109765.test \
  gcj6.test \
 +override-conditional-2.test \
++dist-pr109765.test \
+ instdir-cond.test \
  java-nobase.test \
  objext-pr10128.test \
 +parallel-tests-many.test \
  pr8365-remake-timing.test \
  lex-subobj-nodep.test \
  remake-am-pr10111.test \
index 0000000,d656d56..f1f97be
mode 000000,100755..100755
--- /dev/null
@@@ -1,0 -1,44 +1,44 @@@
 -echo AC_OUTPUT >> configure.in
+ #! /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/>.
+ # Expose automake bug#10975: when several "dist-*" targets are invoked
+ # on the make command line, the first one ends up removing the distdir,
+ # so that the latter ones fail.
+ required=bzip2
+ . ./defs || Exit 1
+ set -e
++echo AC_OUTPUT >> configure.ac
+ : > Makefile.am
+ $ACLOCAL  || fatal_ "aclocal failed"
+ $AUTOCONF || fatal_ "autoconf failed"
+ $AUTOMAKE || fatal_ "automake failed"
+ ./configure
+ $MAKE dist-gzip dist-bzip2
+ gzip -dc $distdir.tar.gz | tar tf - > one || { cat one; Exit 1; }
+ cat one
+ bzip2 -dc $distdir.tar.gz | tar tf - > two || { cat two; Exit 1; }
+ cat two
+ $FGREP "$distdir/Makefile.am" one
+ diff one two
+ :
@@@ -35,15 -41,17 +34,21 @@@ elif test -f "$top_testsrcdir"/ChangeLo
      /^[^\t]/ { exit(0); }
      { print }
    ' "$top_testsrcdir"/ChangeLog || st=1
+ else
+   # Some non-common but possibly valid setup (see for example the Homebrew
+   # problem reported in automake bug#10866); so just give an harmless
+   # warning instead of failing.
+   warn_ "no .git directory nor ChangeLog file found, some info won't" \
+         "be available"
  fi
  $PERL -V || st=1
 +# It's OK for the user not to have the TAP::Parser module; this can
 +# happen with older perl installation, or on MinGW/MSYS.
 +$PERL -e 'use TAP::Parser; print $TAP::Parser::VERSION, "\n"' || :
 +
  cat "$top_testbuilddir/config.log" || st=1
 -cat "$testbuilddir/aclocal-$APIVERSION" || st=1
 -cat "$testbuilddir/automake-$APIVERSION" || st=1
 +cat "$testbuilddir/wrap/aclocal-$APIVERSION" || st=1
 +cat "$testbuilddir/wrap/automake-$APIVERSION" || st=1
  
  if test $st -eq 0; then
    # This test SKIPs, so that all the information it has gathered and
index 0000000,8d83f88..1cbd5bb
mode 000000,100644..100644
--- /dev/null
@@@ -1,0 -1,49 +1,49 @@@
 -cat >> configure.in << 'END'
+ #! /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/>.
+ # Check against automake bug#10997: directories holding only
+ # conditionally-installed files should not be created unconditionally.
+ . ./defs || Exit 1
+ set -e
++cat >> configure.ac << 'END'
+ AM_CONDITIONAL([ENABLE_FOO], [false])
+ AC_OUTPUT
+ END
+ : > foo
+ : > bar
+ cat > Makefile.am << 'END'
+ if ENABLE_FOO
+ pkgdata_DATA = foo
+ pkglibexec_SCRIPTS = bar
+ endif
+ END
+ $ACLOCAL
+ $AUTOMAKE
+ $AUTOCONF
+ ./configure --prefix="`pwd`/inst"
+ $MAKE install
+ test ! -d inst/share/instdir-cond
+ test ! -d inst/libexec/instdir-cond
+ :
index 0000000,f699583..b6eab65
mode 000000,100644..100644
--- /dev/null
@@@ -1,0 -1,58 +1,58 @@@
 -echo AC_OUTPUT >> configure.in
+ #! /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/>.
+ # An empty "foo_PRIMARY" declaration should cause "make install" to create
+ # directory $(foodir).  Suggested in discussion on automake bug#10997.
+ . ./defs || Exit 1
+ set -e
++echo AC_OUTPUT >> configure.ac
+ cat > Makefile.am << 'END'
+ pkgdata_DATA =
+ libexec_SCRIPTS =
+ END
+ $ACLOCAL
+ $AUTOMAKE
+ $AUTOCONF
+ cwd=`pwd`
+ ./configure --prefix="$cwd/inst"
+ $MAKE install
+ test -d inst/share/$me
+ test -d inst/libexec
+ rm -rf inst
+ $MAKE install-exec
+ test ! -d inst/share
+ test -d inst/libexec
+ rm -rf inst
+ $MAKE install-data
+ test -d inst/share/$me
+ test ! -d inst/libexec
+ rm -rf inst
+ ./configure --prefix=/foo
+ $MAKE install DESTDIR=$cwd/dest
+ test -d dest/foo/share/$me
+ test -d dest/foo/libexec
+ :
@@@ -345,8 -332,7 +345,9 @@@ dist-included-parent-dir.test 
  dist-missing-am.test \
  dist-missing-included-m4.test \
  dist-missing-m4.test \
 +dist-readonly.test \
 +dist-repeated.test \
+ dist-pr109765.test \
  distcleancheck.test \
  distcom2.test \
  distcom3.test \
@@@ -24,13 -26,26 +24,30 @@@ cat > Makefile.am << 'END
  python_PYTHON = foo.py
  END
  
+ cat > Makefile2.am << 'END'
+ python_PYTHON = a.py
+ nodist_python_PYTHON = b.py
+ nobase_python_PYTHON = x/c.py
+ mydir = ${prefix}
+ my_PYTHON = d.py
+ END
  $ACLOCAL
 -$AUTOMAKE -a
  
 +AUTOMAKE_fails
 +grep '^Makefile\.am:1:.* required file.*py-compile' stderr
 +
 +$AUTOMAKE -a
 +grep '^py_compile *=' Makefile.in
  test -f py-compile
  
+ $AUTOMAKE Makefile2
+ grep "py" Makefile.in Makefile2.in # For debugging.
+ for f in Makefile.in Makefile2.in; do
+   test `grep -c '^py_compile =' $f` -eq 1
+   test `grep -c '^am__py_compile =' $f` -eq 1
+ done
  :