2 # Copyright (C) 2011-2012 Free Software Foundation, Inc.
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; either version 2, or (at your option)
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
14 # You should have received a copy of the GNU General Public License
15 # along with this program. If not, see <http://www.gnu.org/licenses/>.
17 # Check that explicitly-defined warning levels take precedence over
18 # implicit strictness-implied warnings, even when these explicit warning
19 # levels are "catch-all warnings" (such as '-Wall' and '-Wnone').
20 # Since we are at it, also throw in *.am and *.m4 file inclusions.
24 # We want complete control over automake options.
25 AUTOMAKE=$am_original_AUTOMAKE
27 # Files required in gnu and/or gnits strictness.
28 touch README INSTALL NEWS AUTHORS ChangeLog COPYING THANKS
30 cat > configure.ac << END
32 m4_include([am-init-automake.m4])
34 AC_CONFIG_FILES([Makefile])
35 # Other similar tests do not use AC_OUTPUT, so we use it here,
36 # for completeness and for better coverage.
40 cat > Makefile.am <<END
41 include automake-options.am
45 rm -rf autom4te*.cache
46 : > automake-options.am
47 echo 'AM_INIT_AUTOMAKE' > am-init-automake.m4
49 AUTOMAKE_fails -Werror -Wall --foreign
50 grep '^Makefile\.am:.*:=.*not portable' stderr
52 rm -rf autom4te*.cache
53 : > automake-options.am
54 echo 'AM_INIT_AUTOMAKE([-Werror -Wnone gnu])' > am-init-automake.m4
58 rm -rf autom4te*.cache
59 echo 'AUTOMAKE_OPTIONS = -Werror -Wnone gnits' > automake-options.am
60 echo 'AM_INIT_AUTOMAKE' > am-init-automake.m4