Do not pass top_srcdir to configure scripts in testsuite.
[autoconf.git] / tests / torture.at
blob11c619d79d8a5e9d3ef9e05737e0f1087a1aabcc
1 #                                                       -*- Autotest -*-
3 # Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free
4 # Software Foundation, Inc.
6 # This program is free software: you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation, either version 3 of the License, or
9 # (at your option) any later version.
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
20 AT_BANNER([[Testing config.status.]])
23 ## ---------------------------------------- ##
24 ## AC_CONFIG_COMMANDS with empty commands.  ##
25 ## ---------------------------------------- ##
27 AT_CHECK_MACRO([AC_CONFIG_COMMANDS with empty commands],
28 [[AC_CONFIG_COMMANDS([foo], [], [:])
29 ]])
32 ## -------------------------- ##
33 ## Multiple AC_CONFIG_FILES.  ##
34 ## -------------------------- ##
36 AT_SETUP([Multiple AC_CONFIG_FILES])
38 AT_CONFIGURE_AC([[AC_CONFIG_FILES([foo foo])]])
39 AT_CHECK_AUTOCONF([], 1, [], [ignore])
41 AT_CLEANUP
45 ## ------------ ##
46 ## AC_ARG_VAR.  ##
47 ## ------------ ##
49 # AT_CHECK_AC_ARG_VAR(FIRST-VALUE, SECOND-VALUE)
50 # ----------------------------------------------
51 # Check that AC_ARG_VAR caches the latest values, diagnoses
52 # inconsistencies, and arms config.status.
53 m4_define([AT_CHECK_AC_ARG_VAR],
54 [rm -f config.cache
56 # Initial value.
57 m4_ifval([$1],
58          [precious='m4_bpatsubst($1, [[']], ['\\''])'; export precious],
59          [unset precious])
60 AT_CHECK_CONFIGURE([--config-cache -q])
61 AT_CHECK([cat file], [], [`$1'
64 # Testing --recheck: 1. have the environment `forget' about PRECIOUS.
65 unset precious
66 # 2. Rerun config.status to recreate `file'.
67 AT_CHECK([./config.status --recheck], [], [ignore])
68 AT_CHECK([./config.status], [], [ignore])
69 # 3. Check that file contains the old value of PRECIOUS.
70 AT_CHECK([cat file], [], [`$1'
73 # Second value: we should issue an error here: the value
74 # has changed!
75 m4_ifval([$2],
76          [precious='$2'; export precious],
77          [unset precious])
78 AT_CHECK_CONFIGURE([--config-cache], [1], [], [ignore])
80 ])# AT_CHECK_AC_ARG_VAR
83 AT_SETUP([AC_ARG_VAR])
85 # We don't want to run this test if this shell doesn't support
86 # `unset'.
87 AT_CHECK([
88 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
89   exit 0
90 else
91   exit 77
95 AT_DATA([configure.ac],
96 [[AC_INIT
97 AC_ARG_VAR([precious], [this variable costs a lot])
98 echo "precious:$precious"
99 AC_OUTPUT(file)
102 AT_DATA([file.in],
103 [[`@precious@'
106 AT_CHECK_AUTOCONF
108 # Set a precious variable
109 AT_CHECK_AC_ARG_VAR([], [apple of my eye])
111 # Unset a precious variable
112 AT_CHECK_AC_ARG_VAR([apple of my eye], [])
114 # Change a precious variable
115 AT_CHECK_AC_ARG_VAR([apple of my eye], [orange of my eye])
117 # Change a precious variable that contains braces
118 AT_CHECK_AC_ARG_VAR([apple of my {eye}], [orange of my eye])
120 # Change a precious variable that contains all kinds of fun
121 AT_CHECK_AC_ARG_VAR(['p  r      ec"iou$], [orange of my eye])
122 dnl restore font-lock: "
124 AT_CLEANUP
129 ## ---------------------------------------------- ##
130 ## AC_CONFIG_FILES, HEADERS, LINKS and COMMANDS.  ##
131 ## ---------------------------------------------- ##
133 AT_SETUP([[AC_CONFIG_FILES, HEADERS, LINKS and COMMANDS]])
135 AT_DATA([configure.ac],
136 [[AC_INIT
137 rm -f -r header var-header file var-file link var-link command var-command
138 echo 'OK' >input
140 # Be sure to also stress the associated INIT-CMDS.
141 case $what_to_test in
142  header)
143    AC_CONFIG_HEADERS(header:input);;
144  var-header)
145    AC_CONFIG_HEADERS(var-header:$header_in, [], [header_in=input]);;
147  file)
148    AC_CONFIG_FILES(file:input);;
149  var-file)
150    AC_CONFIG_FILES(var-file:$file_in, [], [file_in=input]);;
152  command)
153    AC_CONFIG_COMMANDS(command,
154                       [cp input command]);;
155  var-command)
156    AC_CONFIG_COMMANDS(var-command,
157                       [cp $command_in var-command], [command_in=input]);;
159  link)
160    AC_CONFIG_LINKS(link:input);;
161  var-link)
162    AC_CONFIG_LINKS(var-link:$link_in, [], [link_in=input]);;
163 esac
164 AC_OUTPUT
167 AT_CHECK_AUTOCONF
170 # AT_CHECK_CONFIG_CREATION(THING = (header | link | file | command))
171 # ------------------------------------------------------------------
172 # Check that THING and var-THING (which uses variables in AC_CONFIG_THING)
173 # are properly created, with the right content.
174 # Use `grep OK' instead of a simple `cat' to avoid banners such as in
175 # AC_CONFIG_HEADERS.
176 m4_define([AT_CHECK_CONFIG_CREATION],
177 [AT_CHECK_CONFIGURE([what_to_test=$1])
178 AT_CHECK([ls header var-header file var-file command var-command link var-link 2>/dev/null],
179          [ignore], [$1
181 AT_CHECK([grep OK $1], [], [OK
184 AT_CHECK_CONFIGURE([what_to_test=var-$1 --no-create])
185 # config.status might be stupidly expecting data on stdin, if it's
186 # really broken...
187 AT_CHECK([./config.status var-$1 </dev/null], [], [ignore])
188 AT_CHECK([ls header var-header file var-file command var-command link var-link 2>/dev/null],
189          [ignore], [var-$1
191 AT_CHECK([grep OK var-$1], [], [OK
193 ])# AT_CHECK_CONFIG_CREATION
196 # AT_CHECK_CONFIG_CREATION_NOWRITE(THING = (header | link | file | command))
197 # ------------------------------------------------------------------
198 # Check that THING and var-THING (which uses variables in AC_CONFIG_THING)
199 # are properly created, with the right content.
200 # Use `grep OK' instead of a simple `cat' to avoid banners such as in
201 # AC_CONFIG_HEADERS.
202 m4_define([AT_CHECK_CONFIG_CREATION_NOWRITE],
203 [AT_CHECK_CONFIGURE([what_to_test=$1])
204 AT_CHECK([ls header var-header file var-file command var-command link var-link 2>/dev/null],
205          [ignore], [$1
207 AT_CHECK([grep OK $1], [], [OK
210 AT_CHECK_CONFIGURE([what_to_test=var-$1 --no-create])
211 # config.status might be stupidly expecting data on stdin, if it's
212 # really broken...
213 chmod a-w .
214 AT_CHECK([./config.status var-$1 </dev/null], [1], [ignore], [ignore])
215 chmod u+w .
216 ])# AT_CHECK_CONFIG_CREATION_NOWRITE
219 # Create a file
220 AT_CHECK_CONFIG_CREATION(file)
222 # Create a header
223 AT_CHECK_CONFIG_CREATION(header)
225 # Execute a command
226 AT_CHECK_CONFIG_CREATION(command)
228 # Create a link
229 AT_CHECK_CONFIG_CREATION(link)
231 # Now check for write errors
233 # Create a file
234 AT_CHECK_CONFIG_CREATION_NOWRITE(file)
235 # Create a file with bits from stdin
236 AT_CHECK([echo from-stdin | ./config.status --file=file:-],
237          [0], [ignore])
238 AT_CHECK([grep from-stdin file], [], [from-stdin
240 # Force write error creating a file on stdout
241 AT_CHECK([./config.status --file=-:input </dev/null >/dev/full],
242          [1], [ignore], [ignore])
244 # Create a header
245 AT_CHECK_CONFIG_CREATION_NOWRITE(header)
246 # Create a header on stdout
247 AT_CHECK([./config.status --header=-:input </dev/null],
248          [0], [stdout], [ignore])
249 AT_CHECK([grep OK stdout], [], [OK
251 # Force write error creating a header on stdout
252 AT_CHECK([./config.status --header=-:input </dev/null >/dev/full],
253          [1], [ignore], [ignore])
255 # Execute a command
256 AT_CHECK_CONFIG_CREATION_NOWRITE(command)
258 # Create a link
259 AT_CHECK_CONFIG_CREATION_NOWRITE(link)
261 # Check that no use of `ac_write_fail' escaped into config.status
262 AT_CHECK([grep ac_write_fail config.status], [1])
264 # Check that --file and --header accept funny file names
265 file='file with  funny \ '\'' \'\'' $ & #!*? name'
266 cat >"$file.in" <<'END'
269 # skip if we cannot create such a file
270 AT_CHECK([test -f "$file.in" || exit 77])
271 AT_CHECK([./config.status "--file=$file:$file.in"],
272          [0], [ignore])
273 AT_CHECK([grep OK "$file"], [], [OK
275 AT_CHECK([./config.status "--header=$file:$file.in"],
276          [0], [ignore])
277 AT_CHECK([grep OK "$file"], [], [OK
279 AT_CLEANUP
283 ## ---------------------------------------- ##
284 ## Macro calls in AC_CONFIG_COMMANDS tags.  ##
285 ## ---------------------------------------- ##
287 AT_SETUP([Macro calls in AC_CONFIG_COMMANDS tags])
289 AT_DATA_M4SUGAR([configure.ac],
290 [[AC_INIT
291 AC_CONFIG_COMMANDS([m4_if(1,1,mytag)])
292 AC_OUTPUT
295 AT_CHECK_AUTOCONF
296 AT_CHECK_CONFIGURE
298 AT_CLEANUP
302 ## ------------------- ##
303 ## Missing templates.  ##
304 ## ------------------- ##
306 # Check that config.status detects missing input files
307 AT_SETUP([Missing templates])
309 AT_DATA([configure.ac],
310 [[AC_INIT
311 AC_CONFIG_FILES([nonexistent])
312 AC_OUTPUT
315 AT_CHECK_AUTOCONF
316 AT_CHECK_CONFIGURE([], [1], [],
317 [[config.status: error: cannot find input file: nonexistent.in
319 # Make sure that the output file doesn't exist
320 AT_CHECK([test -f nonexistent], 1)
322 AT_CLEANUP
327 ## ---------------------- ##
328 ## configure invocation.  ##
329 ## ---------------------- ##
331 # Check that `configure' and `config.status' honor their interface.
333 # We run `./configure one=val1 --enable-two=val2 --with-three=val3'
334 # and verify that (i) `configure' correctly receives the arguments,
335 # (ii) correctly passes them to `config.status', which we check by
336 # running `config.status --recheck', and (iii) correctly passes them
337 # to sub-configure scripts.
339 AT_SETUP([configure invocation])
341 mkdir sub
343 AT_DATA([configure.ac],
344 [[AC_INIT
345 AC_CONFIG_SUBDIRS([sub])
346 echo "result=$one$enable_two$with_three"
347 AC_OUTPUT
350 AT_DATA([sub/configure.ac],
351 [[AC_INIT
352 echo "result=$one$enable_two$with_three"
353 AC_OUTPUT
356 echo fake install-sh script >install-sh
358 AT_CHECK_AUTOCONF
359 cd sub
360 AT_CHECK_AUTOCONF
361 cd ..
363 AT_CHECK_CONFIGURE([one=one --enable-two=two --with-three=three |
364                      sed -n -e 's/^result=//p'], 0,
365                    [m4_do([onetwothree
366 ],                        [onetwothree
367 ])])
368 AT_CHECK([./config.status --recheck | sed -n 's/^result=//p'], 0,
369          [onetwothree
372 AT_CHECK_CONFIGURE([one="\"'$ " --enable-two="\" '  $" --with-three="   \"'$"|
373                       sed -n -e 's/^result=//p'], 0,
374                    [m4_do(["'$ " '  $   "'$
375 ],                        ["'$ " '  $   "'$
376 ])])
377 AT_CHECK([./config.status --recheck | sed -n 's/^result=//p'], 0,
378          ["'$ " '  $    "'$
380 dnl restore font-lock: "
382 AT_CLEANUP
386 ## -------------------------------------------- ##
387 ## Check that `#define' templates are honored.  ##
388 ## -------------------------------------------- ##
390 # Use various forms of `#define' templates, and make sure there are no
391 # problems when a symbol is prefix of another.
393 AT_SETUP([@%:@define header templates])
395 AT_DATA([configure.ac],
396 [[AC_INIT
397 AC_CONFIG_HEADERS(config.h:config.hin)
399 # I18n of dummy variables: their French translations.
400 AC_DEFINE(foo, toto)
401 AC_DEFINE(bar, tata)
402 AC_DEFINE(baz, titi)
403 AC_DEFINE(fubar, tutu)
405 # Symbols which are prefixes of another.
406 AC_DEFINE(a, A)
407 AC_DEFINE(aaa, AAA)
408 AC_DEFINE(aa, AA)
410 # backslash-newline combinations
411 AC_DEFINE([multiline], [line1\
412 line2\
413 line3 \
414 line4])
415 AC_DEFINE([multiline_args(ARG1, ARG2)], [ARG2 \
416 ARG1])
417 AC_CONFIG_FILES(defs)
419 # Things included in confdefs.h, but which make no sense in
420 # config.h, nor in $DEFS.
421 cat <<\EOF >>confdefs.h
422 /* Hi Mum! Look, I am doing C++! */
423 #ifdef __cplusplus
424 void exit (int status);
425 #endif
428 # In addition of config.h output a full DEFS
429 AC_OUTPUT_MAKE_DEFS
430 DEFS_SAVED=$DEFS
431 AC_SUBST(DEFS_SAVED)
432 AC_OUTPUT
435 AT_DATA([defs.in],
436 [[@DEFS_SAVED@
439 AT_DATA([config.hin],
440 [[#define foo   0
441 #  define bar bar
442 #  define baz   "Archimedes was sinking in his baz"
443   #  define fubar                               tutu
444 #define a B
445  #define aa BB
446  #  define aaa BBB
447 #undef a
448  #  undef aa
449 #undef aaa
450 #define aaa(a, aa) aa a
451 #define aaab
452 #define aaac(a, aa) aa a
453 #undef multiline
454 #  undef multiline_args
455 /* an ugly one: */
456 #define str(define) \
457 #define
458 #define stringify(arg) str(arg)
461 AT_CHECK_AUTOCONF
462 AT_CHECK_CONFIGURE
464 AT_DATA([expout],
465 [[/* config.h.  Generated from config.hin by configure.  */
466 #define foo toto
467 #  define bar tata
468 #  define baz titi
469   #  define fubar tutu
470 #define a A
471  #define aa AA
472  #  define aaa AAA
473 #define a A
474  #  define aa AA
475 #define aaa AAA
476 #define aaa AAA
477 #define aaab
478 #define aaac(a, aa) aa a
479 #define multiline line1\
480 line2\
481 line3 \
482 line4
483 #  define multiline_args(ARG1, ARG2) ARG2 \
484 ARG1
485 /* an ugly one: */
486 #define str(define) \
487 #define
488 #define stringify(arg) str(arg)
490 AT_CHECK([cat config.h], 0, expout)
492 # Check the value of DEFS.
493 AT_DATA([expout],
494 [[-DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -Dfoo=toto -Dbar=tata -Dbaz=titi -Dfubar=tutu -Da=A -Daaa=AAA -Daa=AA -Dmultiline=line1line2line3\ line4 -Dmultiline_args\(ARG1,\ ARG2\)=ARG2\ ARG1
497 # Because we strip trailing spaces in `testsuite' we can't leave one in
498 # expout, hence nuke the one left by AC_OUTPUT_MAKE_DEFS.
499 AT_CHECK([sed -e 's/ $//' defs], 0, expout)
501 AT_CLEANUP
505 ## ------------------------- ##
506 ## Torturing config.status.  ##
507 ## ------------------------- ##
509 ## Require 100 AC_DEFINE and AC_SUBST and AC_SUBST_FILE with a significantly
510 ## big value.  This is mostly to check that Autoconf produces portable sed
511 ## scripts in config.status.  sed is used to skip the first two lines
512 ## `Generated by...'.
514 # We use m4_for many times.
515 m4_pattern_allow([^m4_for$])
517 AT_SETUP([Torturing config.status])
519 dnl The value used as a big value for AC_DEFINE.
520 dnl Don't use sh active chars here, below it is also used in a sh
521 dnl assignment.
522 m4_define([AT_BIG_VALUE],
523 [This value should be long enough to torture the various limits of sed and other tools used by Autoconf.])
525 m4_define([AT_DESCRIPTION],
526 [Define to a long string if your `Autoconf' works properly.])
529 # AT_DUMMY_VAR(NUMBER)
530 # --------------------
531 # Build a name used for AC_SUBST and AC_DEFINE.  Put ac_ in it
532 # so that the check for user name space invasion does not complain
533 # of the new variables defined.
535 # Note that you should not use the name ac_dummy, because it will be
536 # turned into ac_uummy during the construction of config.status.  Yes,
537 # this is admittedly a bug, but it would be too hard to fix this.
538 # There is really no point in AC_DEFINE a var named ac_d.*.
539 m4_pattern_allow([^m4_bpatsubst$])
540 m4_define([AT_DUMMY_VAR],
541 [ac_Dummy_[]m4_bpatsubst([000$1], [.*\(...\)$], [\1])])
545 AT_DATA([dummy.in],
546 [m4_for([AT_Count], 1, 100, 1,
547 [@AT_DUMMY_VAR(AT_Count)@
548 @[f]AT_Count@
549 ])])
553 while test $i != 101; do
554   echo "content of file $i" > file_$i
555   i=`expr $i + 1`
556 done
559 # ------------ #
560 # configure.ac #
561 # ------------ #
563 m4_pattern_allow([^m4_(define|defun)$])
564 AT_DATA([configure.ac],
565 dnl The following lines transfer AT_DUMMY_VAR, AT_DESCRIPTION, and
566 dnl AT_BIG_VALUE into the configure.ac as AC_DUMMY_VAR etc.
567 [[m4_define([AC_DUMMY_VAR],]
568 m4_dquote(m4_defn([AT_DUMMY_VAR]))[)]]
570 [[m4_define([AC_DESCRIPTION],]
571 m4_dquote(m4_defn([AT_DESCRIPTION]))[)]]
573 [[m4_define([AC_BIG_VALUE],]
574 m4_dquote(m4_defn([AT_BIG_VALUE]))[)]]
576 [[# AC_DEFUBST(NAME)
577 # ----------------
578 # Related VALUE to NAME both with AC_SUBST and AC_DEFINE.  This is
579 # used in the torture tests.
580 m4_defun([AC_DEFUBST],
581 [AC_DUMMY_VAR($1)="AC_BIG_VALUE"
582 AC_DEFINE_UNQUOTED(AC_DUMMY_VAR($1), "$AC_DUMMY_VAR($1) $AC_DUMMY_VAR($1)",
583                    AC_DESCRIPTION)
584 AC_SUBST(AC_DUMMY_VAR($1))
585 AC_SUBST_FILE([f]$1)
586 f$1=file_$1
589 AC_INIT
590 AC_CONFIG_HEADERS(config.h:config.hin)
591 AC_CONFIG_FILES(dummy)
592 m4_for(AC_Count, 1, 100, 1,
593        [AC_DEFUBST(AC_Count)])
594 AC_PROG_AWK
595 AC_OUTPUT
596 ]])# configure.ac
598 AT_CHECK_AUTOCONF
599 AT_CHECK_AUTOHEADER
600 # Check both awk and the result of AC_PROG_AWK
601 for awk_arg in FOO= AWK=awk; do
602   AT_CHECK_CONFIGURE([$awk_arg])
604   # Checking that AC_DEFINE worked properly.
605   AT_DATA([expout],
606 [/* Define to the address where bug reports for this package should be sent. */
607 #define PACKAGE_BUGREPORT ""
609 /* Define to the full name of this package. */
610 #define PACKAGE_NAME ""
612 /* Define to the full name and version of this package. */
613 #define PACKAGE_STRING ""
615 /* Define to the one symbol short name of this package. */
616 #define PACKAGE_TARNAME ""
618 /* Define to the version of this package. */
619 #define PACKAGE_VERSION ""
620 m4_for(AT_Count, 1, 100, 1,
622 /* AT_DESCRIPTION */
623 [#define] AT_DUMMY_VAR(AT_Count) "AT_BIG_VALUE AT_BIG_VALUE"
624 ])])
626   AT_CHECK([sed -n '4,$ p' config.h], 0, expout)
628   # Checking that AC_SUBST worked properly.
629   AT_DATA([expout],
630 [m4_for(AT_Count, 1, 100, 1,
631 [AT_BIG_VALUE
632 content of file AT_Count
633 ])])
635   AT_CHECK([cat dummy], 0, expout)
636 done
638 AT_CLEANUP
641 ## ------------------------------- ##
642 ## Substitute a 2000-byte string.  ##
643 ## ------------------------------- ##
645 # Solaris 9 /usr/ucb/sed that rejects commands longer than 4000 bytes.  HP/UX
646 # sed dumps core around 8 KiB.  However, POSIX says that sed need not
647 # handle lines longer than 2048 bytes (including the trailing newline).
648 # So we'll just test a 2000-byte value, and for awk, we test a line with
649 # almost 1000 words, and one variable with 5 lines of 2000 bytes each:
650 # multi-line values should allow to get around the limitations.
652 AT_SETUP([Substitute a 2000-byte string])
654 AT_DATA([Foo.in], [@foo@
656 AT_DATA([Bar.in], [@bar@
658 AT_DATA([Baz.in], [@baz@
661 AT_DATA([configure.ac],
662 [[AC_INIT
663 AC_SUBST([foo], ]m4_for([n], 1, 100,, ....................)[)
664 AC_SUBST([bar], "]m4_for([n], 1, 100,, @ @ @ @ @ @ @ @ @ @@)[")
665 baz="]m4_for([m], 1, 100,, ... ... ... ... ....)[
667 baz=$baz$baz$baz$baz$baz
668 AC_SUBST([baz])
669 AC_PROG_AWK
670 AC_CONFIG_FILES([Foo Bar Baz])
671 AC_OUTPUT
674 cp "$abs_top_srcdir/build-aux/install-sh" .
676 AT_CHECK_AUTOCONF
677 # Check both awk and the result of AC_PROG_AWK
678 for awk_arg in Foo= AWK=awk; do
679   AT_CHECK_CONFIGURE([$awk_arg])
680   AT_CHECK([cat Foo], 0, m4_for([n], 1, 100,, ....................)
682   AT_CHECK([cat Bar], 0, m4_for([n], 1, 100,, @ @ @ @ @ @ @ @ @ @@)
684   AT_DATA([stdout],
685   [m4_for([n], 1, 5,, m4_for([m], 1, 100,, ... ... ... ... ....)
687   AT_CHECK([cat Baz], 0, [stdout])
688 done
689 AT_CLEANUP
692 ## ------------------------------ ##
693 ## Define to a 2000-byte string.  ##
694 ## ------------------------------ ##
696 AT_SETUP([Define to a 2000-byte string])
698 AT_CONFIGURE_AC(
700 AC_DEFINE([foo], ]m4_for([n], 1, 100,, ....................)[, [desc])
703 AT_CHECK_AUTOCONF
704 AT_CHECK_AUTOHEADER
705 AT_CHECK_CONFIGURE
706 AT_CHECK_DEFINES([@%:@define foo m4_for([n], 1, 100,, ....................)
708 AT_CLEANUP
711 ## ------------------------------------------ ##
712 ## Substitute and define special characters.  ##
713 ## ------------------------------------------ ##
715 # Use characters special to the shell, sed, awk, and M4.
717 AT_SETUP([Substitute and define special characters])
719 AT_DATA([Foo.in], [@foo@
720 @bar@@notsubsted@@baz@ stray @ and more@@@baz@
721 abc@bar@baz@baz
722 abc@bar@@baz@baz
723 abc@bar@@baz@baz@
724 abc@bar @baz@baz
725 abc@bar @baz@baz@
726 abc@bar @baz@@baz@
727 @file@
728          @file@
729 X@file@
730 @file@X
733 AT_DATA([File],
734 [@foo@@bar@
737 AT_DATA([Zardoz.in], [@zardoz@
740 AT_CONFIGURE_AC(
741 [[foo="AS@&t@_ESCAPE([[X*'[]+ ",& &`\($foo \& \\& \\\& \\\\& \ \\ \\\ !]])"
742 bar="@foo@ @baz@"
743 baz=bla
744 ( for i in 0 1 2 3; do
745     for j in 0 1 2 3 4 5 6 7; do
746       for k in 0 1 2 3 4 5 6 7; do
747         case $i$j$k in #(
748         000) ;; #(
749         *) printf \\$i$j$k's' ;; # The 's' works around a Solaris 8 /bin/bash bug.
750         esac
751       done
752     done
753   done
754   printf \\n
755 ) >allowed-chars
756 zardoz=`cat allowed-chars`
757 AC_SUBST([foo])
758 AC_SUBST([bar])
759 AC_SUBST([baz])
760 AC_SUBST([zardoz])
761 file=File
762 AC_SUBST_FILE([file])
763 AC_DEFINE([foo], [[X*'[]+ ",& &`\($foo !]], [Awful value.])
764 AC_DEFINE([bar], [[%!_!# X]], [Value that is used as special delimiter.])
765 AC_PROG_AWK
766 AC_CONFIG_FILES([Foo Zardoz])]])
768 AT_CHECK_AUTOCONF
769 AT_CHECK_AUTOHEADER
770 # Check both awk and the result of AC_PROG_AWK
771 for awk_arg in FOO= AWK=awk; do
772   AT_CHECK_CONFIGURE([$awk_arg])
773   AT_CHECK([cat Foo], 0, [[X*'[]+ ",& &`\($foo \& \\& \\\& \\\\& \ \\ \\\ !
774 @foo@ @baz@@notsubsted@bla stray @ and more@@bla
775 abc@foo@ @baz@baz@baz
776 abc@foo@ @baz@blabaz
777 abc@foo@ @baz@blabaz@
778 abc@bar blabaz
779 abc@bar blabaz@
780 abc@bar blabla
781 @foo@@bar@
782 @foo@@bar@
783 X@file@
784 @file@X
786   AT_CHECK([cmp allowed-chars Zardoz])
787   AT_CHECK_DEFINES([[#define bar %!_!# X
788 #define foo X*'[]+ ",& &`\($foo !
790 done
791 AT_CLEANUP
794 ## ---------------------- ##
795 ## Substitute a newline.  ##
796 ## ---------------------- ##
798 AT_SETUP([Substitute a newline])
800 AT_DATA([Foo.in],
801 [@foo@
802 @bar@
805 AT_DATA([configure.ac],
806 [[AC_INIT
807 foo='one
808 two'
809 bar='%!_!# ''
811 AC_SUBST([foo])
812 AC_SUBST([bar])
813 AC_CONFIG_FILES([Foo])
814 AC_PROG_AWK
815 AC_OUTPUT
818 cp "$abs_top_srcdir/build-aux/install-sh" .
820 echo 'one
822 %!_!# ''
823 x' >expout
825 AT_CHECK_AUTOCONF
826 # Check both awk and the result of AC_PROG_AWK
827 for awk_arg in FOO= AWK=awk; do
828   AT_CHECK_CONFIGURE([$awk_arg])
829   AT_CHECK([cat Foo], 0, [expout])
830 done
831 AT_CLEANUP
834 ## ------------------ ##
835 ## Define a newline.  ##
836 ## ------------------ ##
838 AT_SETUP([Define a newline])
839 AT_CONFIGURE_AC([[AC_DEFINE([foo], [one
840 two], [This spans two lines.])
842 AT_CHECK_AUTOCONF([], [], [], [stderr])
843 dnl Older versions of m4 report error at line 5 (end of macro);
844 dnl newer versions report it at line 4 (start of macro).
845 AT_CHECK([[sed 's/^configure.ac:[45]: //' stderr]], [],
846 [[warning: AC_DEFINE: `one
847 two' is not a valid preprocessor define value
849 AT_CHECK_AUTOHEADER([], [], [], [stderr])
850 AT_CHECK([[sed 's/^configure.ac:[45]: //' stderr]], [],
851 [[warning: AC_DEFINE: `one
852 two' is not a valid preprocessor define value
854 AT_CHECK_CONFIGURE
855 AT_CHECK_DEFINES([[#define foo one
858 AT_CONFIGURE_AC([[AC_DEFINE_UNQUOTED([foo], [one
859 two], [This spans two lines.])
861 AT_CHECK_AUTOCONF([], [], [], [stderr])
862 AT_CHECK([[sed 's/^configure.ac:[45]: //' stderr]], [],
863 [[warning: AC_DEFINE_UNQUOTED: `one
864 two' is not a valid preprocessor define value
866 AT_CHECK_AUTOHEADER([], [], [], [stderr])
867 AT_CHECK([[sed 's/^configure.ac:[45]: //' stderr]], [],
868 [[warning: AC_DEFINE_UNQUOTED: `one
869 two' is not a valid preprocessor define value
871 AT_CHECK_CONFIGURE
872 AT_CHECK_DEFINES([[#define foo one
875 AT_CLEANUP
878 ## ------------------------------------ ##
879 ## AC_SUBST: variable name validation.  ##
880 ## ------------------------------------ ##
882 AT_SETUP([AC_SUBST: variable name validation])
884 AT_CONFIGURE_AC([[AC_SUBST(, [])
885 AC_CONFIG_FILES([Makefile])
887 AT_DATA([Makefile.in], [[
889 mv -f configure.ac configure.tmpl
891 # Invalid names.
892 for var in ['' ab\~ ab\( ab[] ab\' ab\" ab\\\\]; do
893   sed ["s/AC_SUBST(/&[$var]/"] <configure.tmpl >configure.ac
894   AT_CHECK_AUTOCONF([], [1], [], [ignore])
895 done
897 # Valid names.
898 for var in ab a4 'a@@&t@\&t@b'; do
899   sed ["s/AC_SUBST(/&[$var]/"] <configure.tmpl >configure.ac
900   AT_CHECK_AUTOCONF
901   AT_CHECK_AUTOHEADER
902   AT_CHECK_CONFIGURE
903 done
905 AT_CLEANUP
908 ## ------------------------ ##
909 ## datarootdir workaround.  ##
910 ## ------------------------ ##
912 AT_SETUP([datarootdir workaround])
914 AT_DATA([Foo.in],
915 [@datadir@
916 @docdir@
917 @infodir@
918 @localedir@
919 @mandir@
922 AT_DATA([Bar.in],
923 [@mydatadir@
926 AT_DATA([configure.ac],
927 [[AC_INIT
928 d@&t@nl The following line silences the warnings, if uncommented:
929 d@&t@nl AC_DEFUN([AC_DATAROOTDIR_CHECKED])
931 # This substitution is wrong and bogus!  Don't use it in your own code!
932 # Read `info Autoconf "Defining Directories"'!
933 AC_SUBST([mydatadir], [${datadir}/my])
935 AC_CONFIG_FILES([Foo Bar])
936 AC_OUTPUT
939 cp "$abs_top_srcdir/build-aux/install-sh" .
941 AT_CHECK_AUTOCONF
942 AT_CHECK_CONFIGURE([], [], [],
943   [config.status: WARNING:  'Foo.in' seems to ignore the --datarootdir setting
944 config.status: WARNING: Bar contains a reference to the variable `datarootdir'
945 which seems to be undefined.  Please make sure it is defined.
947 AT_CHECK([grep datarootdir Foo], 1, [])
949 rm configure
950 sed '/AC_DEFUN/s/^d@&t@nl //' configure.ac >t
951 mv t configure.ac
953 AT_CHECK_AUTOCONF
954 AT_CHECK_CONFIGURE
956 AT_CLEANUP
959 ## -------- ##
960 ## srcdir.  ##
961 ## -------- ##
963 AT_SETUP([srcdir])
965 rm -f -r at-dir
966 mkdir at-dir
967 : >at-dir/bar.in
968 : >foo.in
970 AT_DATA([configure.ac],
971 [[AC_INIT
973 AC_CONFIG_FILES([foo at-dir/bar])
975 AC_CONFIG_COMMANDS([report],
976 [test -f $srcdir/configure.ac ||
977    AC_MSG_ERROR([cannot find $srcdir/configure.ac])],
978                    [srcdir=$srcdir])
980 AC_OUTPUT
981 rm -f -r foo at-dir/bar
984 AT_CHECK_AUTOCONF
986 # In place.
987 AT_CHECK([./configure], [], [ignore])
989 # Relative name.
990 AT_CHECK([cd at-dir && ../configure], [], [ignore])
992 # Absolute name.
993 at_here=`pwd`
994 AT_CHECK([cd at-dir && "$at_here/configure"], [], [ignore])
996 AT_CLEANUP
999 ## ----------------- ##
1000 ## Signal handling.  ##
1001 ## ----------------- ##
1003 AT_SETUP([Signal handling])
1005 AT_DATA([configure.ac],
1006 [[AC_INIT
1007 kill -2 $$
1008 exit 77
1011 AT_CHECK_AUTOCONF
1012 AT_CHECK_CONFIGURE([], 1, ignore, ignore)
1014 AT_CLEANUP
1017 ## ------------------------------------- ##
1018 ## AC_CONFIG_LINKS and identical files.  ##
1019 ## ------------------------------------- ##
1020 AT_SETUP([AC_CONFIG_LINKS and identical files])
1022 AT_DATA([configure.ac],
1023 [[AC_INIT
1024 AC_CONFIG_LINKS([src/s:src/s])
1025 test "$srcdir" != '.' && AC_CONFIG_LINKS([src/t:src/t])
1026 AC_OUTPUT
1029 mkdir src build
1030 echo file1 > src/s
1031 echo file2 > src/t
1032 AT_CHECK_AUTOCONF
1033 cd build
1034 AT_CHECK([../configure && ../configure], 0, [ignore])
1035 AT_CHECK([cat src/s src/t], 0, [file1
1036 file2
1038 cd ..
1039 AT_CHECK([./configure && ./configure], 0, [ignore], [stderr])
1040 AT_CHECK([grep src/t stderr], 1)
1041 AT_CHECK([cat src/s src/t], 0, [file1
1042 file2
1044 AT_CHECK(["`pwd`"/configure && "`pwd`"/configure], 0, [ignore], [ignore])
1045 AT_CHECK([cat src/s src/t], 0, [file1
1046 file2
1049 AT_CLEANUP
1052 AT_BANNER([autoreconf.])
1054 ## ---------------------------- ##
1055 ## Configuring subdirectories.  ##
1056 ## ---------------------------- ##
1058 # .
1059 # |-- builddir
1060 # |   |-- config.log
1061 # |   |-- config.status
1062 # |   `-- inner
1063 # |       |-- config.log
1064 # |       |-- config.status
1065 # |       `-- innermost
1066 # |           `-- config
1067 # |-- configure
1068 # |-- configure.ac
1069 # |-- inner
1070 # |   |-- configure
1071 # |   |-- configure.ac
1072 # |   `-- innermost
1073 # |       `-- config.in
1074 # `-- install-sh
1076 AT_SETUP([Configuring subdirectories])
1077 AT_KEYWORDS(autoreconf)
1079 # We use aclocal (via autoreconf).
1080 AT_CHECK([aclocal --version || exit 77], [], [stdout], [ignore])
1081 # It should understand configure.ac.
1082 AT_CHECK([[grep '[^0-9]1.[01234][^0-9]' stdout && exit 77]], [1], [ignore])
1084 # Set CONFIG_SITE to a nonexistent file, so that there are
1085 # no worries about nonstandard values for 'prefix'.
1086 CONFIG_SITE=no-such-file
1087 export CONFIG_SITE
1089 # The contents of `inner/', and `inner/innermost/'.
1090 AS_MKDIR_P([inner/innermost])
1092 # We have to use configure.in, not configure.ac, if we still want to
1093 # be compatible with Automake 1.4: aclocal (run by autoreconf) would
1094 # die because it can't find configure.in.
1095 AT_DATA([inner/configure.in],
1096 [[AC_INIT(GNU Inner, 1.0)
1097 AC_CONFIG_SRCDIR([innermost/config.in])
1098 AC_ARG_VAR([INNER], [an inner variable])
1099 AC_SUBST([INNER])
1100 if test "x$INNER" = x; then
1101   INNER=inner
1103 AC_CONFIG_FILES([innermost/config])
1104 AC_OUTPUT
1107 AT_DATA([inner/innermost/config.in],
1108 [INNER=@INNER@
1109 srcdir=@srcdir@
1110 top_srcdir=@top_srcdir@
1111 prefix=@prefix@
1114 # The contents of `.'
1115 AT_DATA([install-sh], [])
1117 # nonexistent is allowed not to exist.
1118 AT_DATA([configure.in],
1119 [[AC_INIT(GNU Outer, 1.0)
1120 AC_ARG_VAR([OUTER], [an outer variable])
1121 if false; then
1122   AC_CONFIG_SUBDIRS([nonexistent])
1124 AC_CONFIG_SUBDIRS([inner])
1125 AC_OUTPUT
1128 # If there are improperly quoted AC_DEFUN installed in share/aclocal,
1129 # they trigger warnings from aclocal 1.8, so ignore stderr.
1130 AT_CHECK([autoreconf], [], [], [ignore])
1131 AT_CHECK([test -f inner/configure])
1133 # Running the outer configure recursively should provide the innermost
1134 # help strings.
1135 chmod a-w inner/innermost inner .
1136 AT_CHECK([{ ./configure --help=recursive; chmod u+w .; } | grep INNER], 0,
1137          [ignore], [stderr],
1138          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1139 chmod u+w . inner inner/innermost
1141 # Running the outer configure should trigger the inner.
1142 AT_CHECK_CONFIGURE
1143 AT_CHECK([cat inner/innermost/config], 0,
1144 [INNER=inner
1145 srcdir=.
1146 top_srcdir=..
1147 prefix=/usr/local
1150 # The same, but from a builddir.
1151 AS_MKDIR_P([builddir])
1152 AT_CHECK([cd builddir && ../configure], 0, [ignore])
1153 AT_CHECK([cat builddir/inner/innermost/config], 0,
1154 [INNER=inner
1155 srcdir=../../../inner/innermost
1156 top_srcdir=../../../inner
1157 prefix=/usr/local
1160 # Make sure precious variables and command line options are properly
1161 # passed, even when there are duplicates.
1162 AT_CHECK([cd builddir && ../configure --prefix /bad --prefix /good INNER=bad INNER=good], 0, [ignore])
1163 AT_CHECK([cat builddir/inner/innermost/config], 0,
1164 [INNER=good
1165 srcdir=../../../inner/innermost
1166 top_srcdir=../../../inner
1167 prefix=/good
1170 # Make sure --prefix is properly quoted
1171 AT_CHECK([cd builddir && ../configure --prefix "/a  b c$ 'd"], 0, [ignore])
1172 AT_CHECK([cat builddir/inner/innermost/config], 0,
1173 [INNER=inner
1174 srcdir=../../../inner/innermost
1175 top_srcdir=../../../inner
1176 prefix=/a  b c$ 'd
1179 # Make sure --silent is properly passed...
1180 AT_CHECK([cd builddir && ../configure --silent], 0, [])
1181 # ...but not stored in config.status.
1182 AT_CHECK([cd builddir && ./config.status --recheck], 0, [stdout])
1183 AT_CHECK([grep 'creating \./config.status' stdout], 0, [ignore])
1185 # Make sure we can run autoreconf on a subdirectory
1186 rm -f configure configure.in
1187 AT_CHECK([autoreconf inner], [], [], [ignore])
1189 # Make sure we can pass a configure.ac name
1190 AT_CHECK([cd inner && autoreconf configure.in], [], [], [ignore])
1191 AT_CHECK([autoreconf inner/configure.in], [], [], [ignore])
1193 AT_CLEANUP
1197 ## -------------- ##
1198 ## Deep Package.  ##
1199 ## -------------- ##
1201 AT_SETUP([Deep Package])
1202 AT_KEYWORDS(autoreconf)
1204 # We use aclocal (via autoreconf).
1205 AT_CHECK([aclocal --version || exit 77], [], [ignore], [ignore])
1207 # The contents of `.'
1208 AT_DATA([install-sh], [])
1209 AT_DATA([configure.in],
1210 [[AC_INIT(GNU Outer, 1.0)
1211 AC_ARG_VAR([OUTER], [an outer variable])
1212 AC_CONFIG_SUBDIRS([inner])
1213 AC_OUTPUT
1216 # The contents of `inner/', and `inner/innermost/'.
1217 AS_MKDIR_P([inner/innermost])
1219 AT_DATA([inner/configure.in],
1220 [[AC_INIT(GNU Inner, 1.0)
1221 AC_ARG_VAR([INNER], [an inner variable])
1222 AC_CONFIG_SUBDIRS(innermost)
1223 AC_OUTPUT
1226 AT_DATA([inner/innermost/configure.in],
1227 [[AC_INIT(GNU Innermost, 1.0)
1228 AC_ARG_VAR([INNERMOST], [an innermost variable])
1229 AC_CONFIG_HEADERS(config.h:config.hin)
1230 AC_DEFINE_UNQUOTED([INNERMOST], [$INNERMOST], [an innermost variable])
1231 AC_OUTPUT
1234 AT_CHECK([autoreconf -Wall -v], [0], [ignore], [ignore])
1235 AT_CHECK([test -f inner/configure])
1236 AT_CHECK([test -f inner/innermost/configure])
1237 AT_CHECK([test -f inner/innermost/config.hin])
1239 # Running the outer configure recursively should provide the innermost
1240 # help strings.
1241 chmod a-w inner/innermost inner
1242 AT_CHECK([{ ./configure --help=recursive; chmod u+w .; } | grep " INNER "],
1243          0, [ignore], [stderr],
1244          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1245 chmod a-w .
1246 AT_CHECK([{ ./configure --help=recursive; chmod u+w .; } | grep " INNERMOST "],
1247          0, [ignore], [stderr],
1248          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1249 chmod a-w .
1250 AT_CHECK([{ /bin/sh ./configure --help=recursive; chmod u+w .; } | grep " INNERMOST "],
1251          0, [ignore], [stderr],
1252          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1253 chmod a-w .
1254 AT_CHECK([PATH=.$PATH_SEPARATOR$PATH; export PATH; { /bin/sh configure --help=recursive; chmod +w .; } | grep " INNERMOST "],
1255          0, [ignore], [stderr],
1256          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1257 chmod a-w .
1258 AT_CHECK([PATH=.$PATH_SEPARATOR$PATH; export PATH; { configure --help=recursive; chmod u+w .; } | grep " INNERMOST "],
1259          0, [ignore], [stderr],
1260          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1261 chmod u+w inner inner/innermost
1263 # Running the outer configure should trigger the inner.
1264 AT_CHECK_CONFIGURE([INNERMOST=tsomrenni])
1265 AT_CHECK([grep INNERMOST inner/innermost/config.h], 0,
1266 [[#define INNERMOST tsomrenni
1269 # The same, but from a builddir.
1270 AS_MKDIR_P([builddir])
1271 chmod a-w builddir inner/innermost inner
1272 AT_CHECK([cd builddir && { ../configure --help=recursive; chmod u+w .; } | grep " INNER "],
1273          0, [ignore], [stderr],
1274          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1275 chmod a-w builddir
1276 AT_CHECK([cd builddir && { ../configure --help=recursive; chmod u+w .; } | grep " INNERMOST "],
1277          0, [ignore], [stderr],
1278          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1279 chmod a-w builddir
1280 AT_CHECK([cd builddir && { /bin/sh ../configure --help=recursive; chmod u+w .; } | grep " INNERMOST "],
1281          0, [ignore], [stderr],
1282          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1283 chmod a-w builddir
1284 # Not all shells search $PATH for scripts.
1285 if (cd builddir && PATH=`pwd`/..$PATH_SEPARATOR$PATH /bin/sh configure --help) >/dev/null 2>&1; then
1286   AT_CHECK([cd builddir && PATH=`pwd`/..$PATH_SEPARATOR$PATH /bin/sh configure --help=recursive | grep " INNERMOST "], 0, [ignore])
1288 AT_CHECK([PATH=`pwd`$PATH_SEPARATOR$PATH; export PATH; cd builddir && { configure --help=recursive; chmod u+w .; } | grep " INNERMOST "],
1289          0, [ignore], [stderr],
1290          [AT_CHECK([grep 'rerun with a POSIX shell' stderr], [], [ignore])])
1291 chmod u+w builddir inner inner/innermost
1292 AT_CHECK([cd builddir && ../configure INNERMOST=build/tsomrenni], 0, [ignore])
1293 AT_CHECK([grep INNERMOST builddir/inner/innermost/config.h], 0,
1294 [[#define INNERMOST build/tsomrenni
1297 AT_CLEANUP
1301 ## -------------------------------- ##
1302 ## Non-Autoconf AC_CONFIG_SUBDIRS.  ##
1303 ## -------------------------------- ##
1305 AT_SETUP([Non-Autoconf AC_CONFIG_SUBDIRS])
1306 AT_KEYWORDS([autoreconf])
1308 # We use aclocal (via autoreconf).
1309 AT_CHECK([aclocal --version || exit 77], [], [ignore], [ignore])
1311 AT_DATA([install-sh], [])
1312 AT_DATA([configure.in],
1313 [[AC_INIT(GNU Outer, 1.0)
1314 AC_CONFIG_SUBDIRS([inner])
1315 AC_OUTPUT
1318 AS_MKDIR_P([inner])
1320 AT_DATA([inner/configure],
1321 [[#! /bin/sh
1322 case "$*" in
1323     *--help*) echo 'No Autoconf here, folks!' ;;
1324     *)        echo got_it >myfile ;;
1325 esac
1326 exit 0
1328 chmod +x inner/configure
1330 AT_CHECK([autoreconf -Wall -v], 0, [ignore], [ignore])
1332 # Running the outer configure recursively should provide the innermost
1333 # help strings.
1334 AT_CHECK([./configure --help=recursive | grep "folks"], 0, [ignore])
1336 # Running the outer configure should trigger the inner.
1337 AT_CHECK([./configure], 0, [ignore])
1338 AT_CHECK([test -f inner/myfile], 0)
1340 AT_CLEANUP
1344 ## ----------------- ##
1345 ## Empty directory.  ##
1346 ## ----------------- ##
1348 AT_SETUP([Empty directory])
1349 AT_KEYWORDS([autoreconf])
1351 # We use aclocal (via autoreconf).
1352 AT_CHECK([aclocal --version || exit 77], [], [ignore], [ignore])
1354 # The test group directory is not necessarily _empty_, but it does not contain
1355 # files meaningful to `autoreconf'.
1357 AT_CHECK([autoreconf -Wall -v], 1, [ignore], [ignore])
1359 AT_CLEANUP
1363 ## ------------------------------ ##
1364 ## Unusual Automake input files.  ##
1365 ## ------------------------------ ##
1367 # This parallels gnumake.test in Automake.
1369 AT_SETUP([Unusual Automake input files])
1370 AT_KEYWORDS([autoreconf])
1372 # We use aclocal and automake via autoreconf.
1373 AT_CHECK([automake --version || exit 77], [], [ignore], [ignore])
1375 AT_DATA([configure.in],
1376 [[AC_INIT(GNU foo, 1.0)
1377 AM_INIT_AUTOMAKE
1378 AC_CONFIG_FILES([HeeHee])
1379 AC_OUTPUT
1382 AT_DATA([HeeHee.am],
1383 [[# Humans do no worse than `GNUmakefile.am'.
1384 AUTOMAKE_OPTIONS = foreign 1.8
1387 AT_CHECK([autoreconf -Wall -v -i], 0, [ignore], [stderr],
1388          [AT_CHECK([grep 'require.*1\.8' stderr && exit 77], [1])])
1389 AT_CHECK([test -f HeeHee.in])
1391 AT_CLEANUP