* doc/autoconf.texi (Writing Testsuites): Document that COMMANDS
is run in a subshell, but RUN-IF-FAIL and RUN-IF-PASS are not.
* tests/autotest.at (AT@&t@_CHECK execution environment): New
test.
* NEWS: Update.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* doc/autoconf.texi: Clarify the meaning of the various variable
indices. Merge variable index `vr' into concept index using
syncodeindex.
(Configuration Actions, Generic Programs, Generic Functions)
(Writing Testsuites): Add index entries for documented shell
variables used during in configure and testsuite scripts.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
(Shell Substitutions, Site Defaults): Fix markup for indexed
entried, using @code and @file as appropriate.
(M4 Macro Index): Clarify which of the indexed macros have m4_
and which have AS_ prefix.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* doc/autoconf.texi (Limitations of Usual Tools) <awk>: Mention
that traditional awk lacks ENVIRON. Add reference to awk manual.
(Particular Programs) <AC_PROG_AWK>: Add reference to awk section.
Reported by Ralf Wildenhues.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (Limitations of Builtins) <test (strings)>:
Mention yet another Solaris issue.
Reported by Stefano Lattarini.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (Shell Substitutions) <${var:=value}>:
Document problem of "" within here-docs.
Reported by Ralf Wildenhues.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (Polymorphic Variables, Shell Substitutions):
Use $var or $t instead.
(Limitations of Usual Tools): Use $dir instead.
(Initialization Macros) <AS_TMPDIR>: Make good on the NEWS
regarding AS_TMPDIR being documented as consuming $tmp.
Suggested by Ralf Wildenhues.
Signed-off-by: Eric Blake <eblake@redhat.com>
* lib/autoconf/general.m4 (AC_CACHE_SAVE): Use `mv -f' to update
the cache file if it is a regular file and not a symlink. Move
first to temporary name in the target directory if not in the
current directory for atomicity across mount points.
* tests/base.at (AC_CACHE_CHECK): Try symlinked cache file.
* doc/autoconf.texi (Cache Files): Leftover temporary cache
files may be deleted by the user.
* NEWS: Update.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* tests/m4sh.at (Null variable substitution): New test.
* doc/autoconf.texi (Shell Substitutions) <${var:-value}>: Mention
that m4sh guarantees support.
(Limitations of Usual Tools) <mktemp>: Use it.
* lib/m4sugar/m4sh.m4 (AS_LINENO_POP, AS_VAR_IF, AS_TMPDIR):
Exploit use of colon for smaller files.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (Conditional constructs) <m4_define_default>:
Document it, since gnulib wants to use it.
* NEWS: Mention this.
Signed-off-by: Eric Blake <eblake@redhat.com>
* lib/autoconf/lang.m4 (AC_LANG_DEFINES_PROVIDED): New macro.
(AC_LANG_SOURCE): Call it.
(AC_LANG_CONFTEST): Add warning if new macro is not called.
* lib/autoconf/c.m4 (_AC_LANG_OPENMP): Add missing AC_LANG_SOURCE.
* lib/autoconf/fortran.m4 (AC_FC_FREEFORM, AC_FC_FIXEDFORM)
(AC_FC_LINE_LENGTH, __AC_FC_NAME_MANGLING): Intentionally bypass
AC_LANG_SOURCE.
* lib/autoconf/programs.m4 (_AC_PROG_LEX_YYTEXT_DECL): Likewise.
* tests/compile.at (AC_COMPILE_IFELSE): New test.
* doc/autoconf.texi (Generating Sources) <AC_LANG_CONFTEST>:
Document new warning.
<AC_LANG_DEFINES_PROVIDED>: Document new macro.
<AC_LANG_SOURCE>: Document use of new macro.
* NEWS: Document the improvement.
Suggested by Bruno Haible.
Signed-off-by: Eric Blake <eblake@redhat.com>
In particular, see http://austingroupbugs.net/view.php?id=221
and http://austingroupbugs.net/view.php?id=255.
* doc/autoconf.texi (Shell Substitutions) <${var+value}>: New
subsection.
<${var=literal}>: Tweak wording. Add mention of an ambiguity
allowed by POSIX.
* tests/torture.at (Substitute and define special characters):
Make test more robust; here, the outer "" is in a here-doc, and
does not violate the quoting rules of thumb just documented.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (Using autoreconf to Update configure
Scripts): List `AUTOM4TE' among the environment variables
honored by autoreconf.
* bin/autoreconf.in ($help): Likewise.
* doc/autoconf.texi (Polymorphic Variables) <AS_VAR_IF>: Make it
clear that user must supply quotes as needed.
* THANKS: Update.
Suggested by Randall Cotton.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (Making testsuite Scripts): atconfig is not
created from an input template.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* doc/autoconf.texi (Writing Testsuites) <AT_BANNER>: Update
description.
* lib/autotest/general.m4 (AT_INIT) <at_fn_banner>: Set banner
to single space, not empty line, once printed. For empty
banners, print a single empty line to separate them from a
previous test group category.
* tests/autotest.at (Banners): Insert another test group; adjust
tests accordingly. Extend test to cover semantic change.
* NEWS: Update.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* doc/autoconf.texi (Fortran Compiler, Language Choice): Add
index entries for AC_FC_DUMMY_MAIN, AC_LANG; reformat entry for
AC_LANG_ASSERT.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* doc/autoconf.texi (Generating Sources): Don't mix gcc '-E' and
'-o -', since the former already implies stdout, while the latter
creates -.exe on cygwin.
* tests/compile.at (AC_LANG_SOURCE example)
(AC_LANG_PROGRAM example): Likewise. Also prevent any config.site
interference.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (File Descriptors): Clarify limitations.
* lib/autotest/general.m4 (AT_CLEANUP): Avoid leaking job control
fifo fd to user tests.
(AT_INIT): Delete comment, now that close is done elsewhere.
Suggested by Ralf Wildenhues.
Signed-off-by: Eric Blake <eblake@redhat.com>
* lib/autoconf/general.m4 (_AC_INIT_LITERAL): Reject a couple more
problematic characters.
* tests/base.at (AC_INIT with unusual version strings): Enhance
test.
* doc/autoconf.texi (Initializing configure) <AC_INIT>: Further
clarifications, and clean up wording about use of m4_esyscmd.
* NEWS: Update previous news entry.
Suggested by Paolo Bonzini.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (Initializing configure): Improve
documentation on argument restrictions.
* NEWS: Tweak information.
* lib/autoconf/general.m4 (_AC_INIT_GENERAL): New macro, that also
rejects literal ".
(_AC_INIT_PACKAGE): Use it to plug hole in last patch.
* tests/base.at (AC_INIT with unusual version strings): Enhance
test.
Signed-off-by: Eric Blake <eblake@redhat.com>
* lib/autoconf/general.m4 (_AC_PREPROC_IFELSE_BODY): Redirect
preprocessor output to conftest.i rather than /dev/null.
(_AC_PREPROC_IFELSE): Remove conftest.i in the postprocessing.
* tests/compile.at (Order of user actions and cleanup): Extend
test in the ACTION-IF-TRUE branch.
* doc/autoconf.texi (Running the Preprocessor): Document new
feature.
* NEWS: Update.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* doc/autoconf.texi (Preset Output Variables): Remove space
between -D and -L flags and their arguments, traditional cpp
implementations like Solaris 10, IRIX 6.5, OSF Tru64 5.1D,
AIX 5.3 do not accept it.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (Generic Compiler Characteristics): Refer
to the right test in the example marker comment.
Spotted by Eric Blake.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* doc/autoconf.texi (Subdirectories): We warn, not error, about
nonexistent config subdirs, but only at configure run time.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* lib/autoconf/types.m4 (AC_CHECK_SIZEOF): Translate `*' to `p'
when checking literal-ness of the type, for pointer types.
* lib/m4sugar/m4sh.m4 (_AS_TR_SH): Also consider `*' as literal.
(_AS_TR_CPP): Likewise.
* tests/semantics.at (AC_CHECK_ALIGNOF struct): When checking
for numeric answer, be sure to not allow variable references.
(AC_CHECK_SIZEOF struct): Likewise. Also, test the
`AC_CHECK_SIZEOF([int *])' example from the manual.
* doc/autoconf.texi (Generic Compiler Characteristics): Add
example marker.
* NEWS: Update.
Reports by Nishio Futoshi and Roberto Bagnara.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* lib/autoconf/status.m4 (AC_CONFIG_SUBDIRS): Do not assume the
argument is a single word.
* tests/torture.at (Deep Package): Extend test to cover this.
(Non-literal AC_CONFIG_SUBDIRS): New test.
* doc/autoconf.texi (Subdirectories): Add example marker.
* NEWS: Update.
Report by Bruno Haible.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* lib/autoconf/fortran.m4 (_AC_FC_DIALECT_YEAR): Fix typo in
comment.
(AC_FC_FREEFORM): Update list of known options for Sun, HP,
Lahey/Fujitsu Fortran compilers. Use M4 quoting consistently.
(AC_FC_FIXEDFORM): New macro.
* tests/fortran.at (AC_FC_DUMMY_MAIN usage, AC_FC_MAIN usage):
Use AC_FC_FIXEDFORM, to avoid testsuite failure with FC=xlf95.
(AC_FC_FREEFORM with AC_FC_SRCEXT, AC_FC_FIXEDFORM)
(AC_FC_FIXEDFORM with AC_FC_SRCEXT): New tests.
* tests/mktests.sh: No need to exclude AC_FC_FREEFORM, it uses
AC_LANG_PUSH/AC_LANG_POP.
* doc/autoconf.texi (Fortran Compiler): Document it.
* NEWS: Update.
Signed-off-by: Eric Blake <eblake@redhat.com>
* lib/m4sugar/m4sh.m4 (AS_BOX): Use less m4 time.
(_AS_BOX_LITERAL): Use fewer forks in the common case.
* doc/autoconf.texi (Common Shell Constructs) <AS_BOX>: Document
the macro.
* NEWS: Mention it.
Signed-off-by: Eric Blake <eblake@redhat.com>
* lib/m4sugar/m4sh.m4 (_AS_LITERAL_IF): Also reject shell quoting
characters as non-literal, and provide way to reject space.
(AS_LITERAL_WORD_IF): New macro.
* doc/autoconf.texi (Polymorphic Variables) <AS_LITERAL_IF>:
Document new macro. Fix example to match reality.
* NEWS: Document change and new macro.
* tests/m4sh.at (AS@&t@_LITERAL_IF): Update test.
Signed-off-by: Eric Blake <eblake@redhat.com>
Fix the commit (forgot to 'git add .').
* doc/autoconf.texi (Limitations of Shell Builtins) <for>:
Document a bug of the 'for' builtin in Solaris /bin/sh, w.r.t.
tokens seeming variable assignment in the list of arguments.
Signed-off-by: Eric Blake <eblake@redhat.com>
* doc/autoconf.texi (Limitations of Shell Builtins) <for>:
Document a bug of the 'for' builtin in Solaris /bin/sh, w.r.t.
tokens seeming variable assignment in the list of arguments.
Signed-off-by: Eric Blake <eblake@redhat.com>