diff options
author | Stefano Lattarini <stefano.lattarini@gmail.com> | 2012-06-14 23:27:42 +0200 |
---|---|---|
committer | Stefano Lattarini <stefano.lattarini@gmail.com> | 2012-06-14 23:37:31 +0200 |
commit | 9cb6dc889b95c90f443e7ec30b3541d33ca97ef3 (patch) | |
tree | 2fc51bdf41c8b6e6e1e5a0d4854c6784405d6e03 /t/dir-named-obj-is-bad.sh | |
parent | 911a6e9fc85ce67a867178bd7daf8ce8c461135c (diff) | |
download | automake-9cb6dc889b95c90f443e7ec30b3541d33ca97ef3.tar.gz |
tests: minor reorganization of few tests
* t/subdir3.sh: Rename ...
* t/sourcefile-in-subdir.sh: ... like this.
* t/subdir4.sh: Rename ...
* t/depcomp-implicit-auxdir.sh: ... like this.
* t/subdir6.sh: Rename ...
* t/confh-subdir-clean.sh: ... like this.
* t/subdir7.sh: Renamed ...
* t/dir-named-obj-is-bad.sh: ... like this, and enhance.
* t/srcsub.sh, t/srcsub2.sh: Unify ...
* t/src-acsubst.sh: ... as this test.
* t/list-of-tests.mk: Adjust.
Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
Diffstat (limited to 't/dir-named-obj-is-bad.sh')
-rwxr-xr-x | t/dir-named-obj-is-bad.sh | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/t/dir-named-obj-is-bad.sh b/t/dir-named-obj-is-bad.sh new file mode 100755 index 000000000..e422f1928 --- /dev/null +++ b/t/dir-named-obj-is-bad.sh @@ -0,0 +1,61 @@ +#! /bin/sh +# Copyright (C) 2002-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/>. + +# Naming a subdirectory 'obj/' is a bad idea. Automake should say so. + +. ./defs || Exit 1 + +mkdir obj + +cat >>configure.ac << 'END' +AC_CONFIG_FILES([obj/Makefile]) +AC_OUTPUT +END + +: > obj/Makefile.am +echo 'SUBDIRS = obj' > Makefile.am + +$ACLOCAL + +AUTOMAKE_fails +grep "^Makefile\.am:1:.*'obj'.*BSD make" stderr + +cat >Makefile.am <<'END' +SUBDIRS = @STH@ +FOO = obj +DIST_SUBDIRS = $(FOO) +END + +AUTOMAKE_fails +grep "^Makefile\\.am:2:.*'obj'.*BSD make" stderr + +rm -rf autom4te*.cache + +cat >configure.ac << 'END' +AC_INIT([x], [1.0]) +AC_CONFIG_AUX_DIR([obj]) +AM_INIT_AUTOMAKE +AC_CONFIG_FILES([Makefile]) +END + +rm -f obj/Makefile.am +: > Makefile.am + +$ACLOCAL +AUTOMAKE_fails -a +grep "^configure\.ac:2:.*'obj'.*BSD make" stderr + +: |