]> git.ipfire.org Git - thirdparty/autoconf.git/log
thirdparty/autoconf.git
15 years agoFix up AC_INIT vs. " issues, and document it.
Eric Blake [Mon, 19 Jul 2010 22:39:45 +0000 (16:39 -0600)] 
Fix up AC_INIT vs. " issues, and document it.

* 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>
15 years agoRelax AC_INIT requirements for PACKAGE and VERSION strings again.
Ralf Wildenhues [Mon, 19 Jul 2010 21:50:45 +0000 (15:50 -0600)] 
Relax AC_INIT requirements for PACKAGE and VERSION strings again.

* lib/m4sugar/m4sh.m4 (AS_LITERAL_HEREDOC_IF): New macro.
(_AS_LITERAL_HEREDOC_IF, _AS_LITERAL_HEREDOC_IF_YES)
(_AS_LITERAL_HEREDOC_IF_NO): New helper macros.
* lib/autoconf/general.m4 (_AC_INIT_PACKAGE): Use
AS_LITERAL_HEREDOC_IF for PACKAGE and VERSION strings.
* tests/base.at (AC_INIT with unusual version strings): New test.
* tests/m4sh.at (AS@&t@_LITERAL_IF): Extend test.
* NEWS: Update.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoFix testsuite failures from previous patch.
Eric Blake [Mon, 19 Jul 2010 23:31:45 +0000 (17:31 -0600)] 
Fix testsuite failures from previous patch.

* lib/autoconf/c.m4 (_AC_PROG_PREPROC_WORKS_IFELSE): Also remove
conftest.i when preprocessor tests break out of a loop.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAllow inspecting AC_PREPROC_IFELSE output in true branch.
Ralf Wildenhues [Mon, 19 Jul 2010 17:59:19 +0000 (19:59 +0200)] 
Allow inspecting AC_PREPROC_IFELSE output in true branch.

* 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>
15 years agoFix AC_FC_LIBRARY_LDFLAGS detection for BlueGene xlf -qipa.
Ralf Wildenhues [Mon, 19 Jul 2010 17:52:44 +0000 (19:52 +0200)] 
Fix AC_FC_LIBRARY_LDFLAGS detection for BlueGene xlf -qipa.

* lib/autoconf/fortran.m4 (_AC_FC_LIBRARY_LDFLAGS): Ignore
'-link', added spuriously when -qipa is used with the XL
Fortran compilers on BlueGene.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agomanual: compiler flags -D and -L should not be followed by space
Ralf Wildenhues [Sun, 11 Jul 2010 10:12:57 +0000 (12:12 +0200)] 
manual: compiler flags -D and -L should not be followed by space

* 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>
15 years agoFix comment typo in the manual.
Ralf Wildenhues [Sat, 10 Jul 2010 16:38:09 +0000 (18:38 +0200)] 
Fix comment typo in the manual.

* 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>
15 years agoNew Fortran macro AC_FC_LINE_LENGTH.
Ralf Wildenhues [Sat, 10 Jul 2010 16:40:43 +0000 (18:40 +0200)] 
New Fortran macro AC_FC_LINE_LENGTH.

* lib/autoconf/fortran.m4 (AC_FC_LINE_LENGTH): New macro.
* doc/autoconf.texi (Fortran Compiler): Document it.
* tests/fortran.at (AC_FC_LINE_LENGTH): New test.
* NEWS: Update.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFix wording about AC_CONFIG_SUBDIRS warning.
Ralf Wildenhues [Sat, 10 Jul 2010 06:44:07 +0000 (08:44 +0200)] 
Fix wording about AC_CONFIG_SUBDIRS warning.

* 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>
15 years agoFix regression of AC_CHECK_SIZEOF on pointer types.
Eric Blake [Tue, 6 Jul 2010 20:00:44 +0000 (22:00 +0200)] 
Fix regression of AC_CHECK_SIZEOF on pointer types.

* 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>
15 years agoFix regression of AC_CONFIG_SUBDIRS with multiple arguments.
Ralf Wildenhues [Tue, 6 Jul 2010 20:31:33 +0000 (22:31 +0200)] 
Fix regression of AC_CONFIG_SUBDIRS with multiple arguments.

* 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>
15 years agoFix minor copy&paste leftover in m4sh tests.
Stefano Lattarini [Sat, 3 Jul 2010 20:41:03 +0000 (22:41 +0200)] 
Fix minor copy&paste leftover in m4sh tests.

* tests/m4sh.at (AS@&t@_TR_SH and AS@&t@_TR_CPP): Remove
useless variables assignements ($var, $vAr, $VAR).

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFix testsuite to not trigger Solaris sh for bug.
Ralf Wildenhues [Sun, 4 Jul 2010 18:22:29 +0000 (20:22 +0200)] 
Fix testsuite to not trigger Solaris sh for bug.

* tests/torture.at (Torturing config.status)
(Substitute a 2000-byte string)
(Substitute and define special characters)
(Substitute a newline): Quote first argument in for list so
that it does not look like an assignment.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agopost-release administrivia
Eric Blake [Fri, 2 Jul 2010 22:54:35 +0000 (16:54 -0600)] 
post-release administrivia

* maint.mk (NEWS_hash): Define.
* NEWS: Add header line for next release.
* .prev-version: Record previous version.
* cfg.mk (old_NEWS_hash): Auto-update.

15 years agoRelease Version 2.66. v2.66
Eric Blake [Fri, 2 Jul 2010 22:32:08 +0000 (16:32 -0600)] 
Release Version 2.66.

* NEWS: Mention the release.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoPick up some maint.mk improvements from gnulib.
Eric Blake [Fri, 2 Jul 2010 22:31:03 +0000 (16:31 -0600)] 
Pick up some maint.mk improvements from gnulib.

* configure.ac (AM_INIT_AUTOMAKE): Require 1.11, and build xz
archives by default now.
* maint.mk (gzip_rsyncable): Avoid non-portable echo.
(VC-tag): Depend on gpg_key_ID.
(PREV_VERSION): Don't parse error as version.
(announcement): Populate email addresses with defaults.
(emit_upload_commands, web-manual): Reflect changes in scripts.
(update-NEWS-hash, emit-commit-log, release-prep): New macros.
* cfg.mk (announcement_Cc_, announcement_mail_headers_): Override
defaults.
* HACKING: Modernize a bit.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoResync upstream files.
Eric Blake [Fri, 2 Jul 2010 21:58:07 +0000 (15:58 -0600)] 
Resync upstream files.

* GNUmakefile: Run 'make fetch'.
* build-aux/announce-gen: Likewise.
* build-aux/config.guess: Likewise.
* build-aux/config.sub: Likewise.
* build-aux/gendocs.sh: Likewise.
* build-aux/git-version-gen: Likewise.
* build-aux/gnupload: Likewise.
* build-aux/texinfo.tex: Likewise.
* build-aux/vc-list-files: Likewise.
* doc/gendocs_template: Likewise.
* doc/gnu-oids.texi: Likewise.
* doc/make-stds.texi: Likewise.
* doc/standards.texi: Likewise.
* lib/Autom4te/Channels.pm: Likewise.
* lib/Autom4te/Configure_ac.pm: Likewise.
* lib/Autom4te/FileUtils.pm: Likewise.
* lib/Autom4te/XFile.pm: Likewise.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoMake AS_TR_SH and AS_TR_CPP similar.
Eric Blake [Fri, 2 Jul 2010 21:35:45 +0000 (15:35 -0600)] 
Make AS_TR_SH and AS_TR_CPP similar.

* lib/m4sugar/m4sh.m4 (_AS_TR_CPP_LITERAL): Avoid underquoting.
(_AS_TR_CPP_INDIR): Handle all polymorphic variables.
* tests/m4sh.at (AS@&t@_TR_SH and AS@&t@_TR_CPP): New test.
* NEWS: Document the fix.
Reported by Bruno Haible.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoReduce startup cost of autotest.
Eric Blake [Fri, 2 Jul 2010 20:03:50 +0000 (14:03 -0600)] 
Reduce startup cost of autotest.

* lib/autotest/general.m4 (_AT_FINISH) <banners>: Rather than
doing a recursive find, limit ourselves to top ChangeLog only.
Reported by Ralf Wildenhues.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoNew macro AC_FC_FIXEDFORM, improved AC_FC_FREEFORM, coverage.
Ralf Wildenhues [Mon, 28 Jun 2010 22:15:25 +0000 (00:15 +0200)] 
New macro AC_FC_FIXEDFORM, improved AC_FC_FREEFORM, coverage.

* 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>
15 years agoOptimize AS_BOX.
Eric Blake [Tue, 2 Mar 2010 00:17:40 +0000 (17:17 -0700)] 
Optimize AS_BOX.

* 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>
15 years agoUse new AS_LITERAL_IF argument when appropriate.
Eric Blake [Sat, 27 Feb 2010 18:43:21 +0000 (11:43 -0700)] 
Use new AS_LITERAL_IF argument when appropriate.

* lib/m4sugar/m4sh.m4 (AS_VAR_SET): Reduce m4 overhead.
(AS_VAR_IF, AS_VAR_TEST_SET): Provide shorter variant for simple
references.
Suggested by Bruno Haible.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAdd tests for AS_BOX.
Eric Blake [Wed, 17 Mar 2010 00:49:07 +0000 (18:49 -0600)] 
Add tests for AS_BOX.

* tests/m4sugar.at (m4@&t@_text_box): New test.
* tests/m4sh.at (AS@&t@_BOX): Likewise.
* lib/m4sugar/m4sugar.m4 (m4_text_box): Support comma.
* doc/autoconf.texi (Text processing Macros) <m4_text_box>:
Document further limitations.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAdd optional argument to AS_LITERAL_IF.
Eric Blake [Wed, 17 Mar 2010 00:12:02 +0000 (18:12 -0600)] 
Add optional argument to AS_LITERAL_IF.

* lib/m4sugar/m4sh.m4 (_AS_LITERAL_IF): Rewrite to generate macro
name, without using m4_cond.
(_AS_LITERAL_IF_, _AS_LITERAL_IF_YES, _AS_LITERAL_IF_NO): New
helpers.
(AS_LITERAL_IF, AS_LITERAL_WORD_IF, _AS_TR_SH, _AS_TR_CPP)
(_AS_VAR_PUSHDEF): Adjust callers.
* lib/autoconf/types.m4 (AC_CHECK_ALIGNOF): Relax restrictions on
invalid bytes, since this allows inline struct layouts.
(_AC_CHECK_ALIGNOF): New helper macro.
* tests/m4sh.at (AS@&t@_LITERAL_IF): Update test.
* doc/autoconf.texi (Polymorphic Variables) <AS_LITERAL_IF>:
Update documentation.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoUse AS_LITERAL_WORD_IF as appropriate.
Eric Blake [Tue, 16 Mar 2010 23:52:12 +0000 (17:52 -0600)] 
Use AS_LITERAL_WORD_IF as appropriate.

* lib/autoconf/autoheader.m4 (AH_VERBATIM): Use new macro.
* lib/autoconf/general.m4 (AC_REQUIRE_AUX_FILE, AC_CACHE_VAL)
(AS_CACHE_CHECK, AC_DEFINE_TRACE, _AC_LIBOBJ): Likewise.
* lib/autoconf/libs.m4 (AC_CHECK_LIB): Likewise.
* lib/autoconf/status.m4 (AC_CONFIG_SUBDIRS): Likewise.
* lib/m4sugar/m4sh.m4 (AS_UNSET, AS_VAR_COPY, AS_VAR_GET)
(AS_VAR_IF, AS_VAR_SET, AS_VAR_TEST_SET): Likewise.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAdd AS_LITERAL_WORD_IF.
Eric Blake [Tue, 16 Mar 2010 21:51:23 +0000 (15:51 -0600)] 
Add AS_LITERAL_WORD_IF.

* 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>
15 years agoOptimize AC_DEFINE.
Eric Blake [Tue, 16 Mar 2010 21:48:44 +0000 (15:48 -0600)] 
Optimize AC_DEFINE.

* lib/autoconf/general.m4 (_AC_DEFINE_Q): Avoid overhead of
AS_LITERAL_IF.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDescribe a Solaris /bin/sh bug w.r.t. for loops.
Stefano Lattarini [Fri, 2 Jul 2010 16:14:52 +0000 (18:14 +0200)] 
Describe a Solaris /bin/sh bug w.r.t. for loops.

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>
15 years agoDescribe a Solaris /bin/sh bug w.r.t. for loops.
Stefano Lattarini [Fri, 2 Jul 2010 16:14:52 +0000 (18:14 +0200)] 
Describe a Solaris /bin/sh bug w.r.t. for loops.

* 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>
15 years agoImprove VPATH handling in config.status for non-Automake projects.
Ralf Wildenhues [Wed, 23 Jun 2010 17:23:12 +0000 (19:23 +0200)] 
Improve VPATH handling in config.status for non-Automake projects.

* lib/autoconf/status.m4 (_AC_OUTPUT_FILES_PREPARE): Be sure not
to remove references to a subdir of srcdir.  Fix treatment of
multiple colon-separated VPATH entries.
* tests/torture.at (VPATH): New test.
Report by Keith Marshall.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFurther improve docs about nested double-quotes and backquotes.
Ralf Wildenhues [Wed, 23 Jun 2010 17:55:02 +0000 (19:55 +0200)] 
Further improve docs about nested double-quotes and backquotes.

* doc/autoconf.texi (Shellology): Remove anchor for pdksh.
Move quoting bug example to ...
(Shell Substitutions): ... here.  Document which behavior is
specified by Posix.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoCoverage for Fortran compiler macros.
Ralf Wildenhues [Wed, 23 Jun 2010 17:18:14 +0000 (19:18 +0200)] 
Coverage for Fortran compiler macros.

* tests/fortran.at (AC_OPENMP and Fortran 77)
(AC_OPENMP and Fortran): Simplify, using AT_CHECK_CONFIGURE.
(AC_F77_DUMMY_MAIN usage, AC_FC_DUMMY_MAIN usage)
(AC_F77_MAIN usage, AC_FC_MAIN usage, AC_F77_FUNC usage)
(AC_FC_FUNC usage, AC_FC_SRCEXT usage, AC_FC_FREEFORM): New
tests.
* doc/autoconf.texi (Fortran Compiler): Use GNU coding style
on C code snippets.  Add markers for tested examples.
Suggest AC_FC_FREEFORM for source file extensions which the
compiler might not natively support but which are accepted
with help from AC_FC_SRCEXT.  Suggest AC_CONFIG_HEADERS for
setups using one of the AC_*MAIN macros.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoAccept any nonzero exit status upon config.status write failure.
Ralf Wildenhues [Sat, 19 Jun 2010 18:17:09 +0000 (20:17 +0200)] 
Accept any nonzero exit status upon config.status write failure.

* tests/torture.at (AC_CONFIG_FILES, HEADERS, LINKS and COMMANDS):
Normalize nonzero status to 1 for writing to /dev/full, for HP-UX
11.31 cat which exits 2.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFix testsuite failure with Tru64 preprocessor.
Ralf Wildenhues [Sat, 19 Jun 2010 15:49:21 +0000 (17:49 +0200)] 
Fix testsuite failure with Tru64 preprocessor.

* tests/compile.at (Order of user actions and cleanup): Add
incomplete comment to provoke failure with Tru64/OSF 5.1 cc
preprocessor.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFurther clarification on sed -e portability.
Ralf Wildenhues [Tue, 22 Jun 2010 05:29:35 +0000 (07:29 +0200)] 
Further clarification on sed -e portability.

See also http://austingroupbugs.net/view.php?id=262 and
http://austingroupbugs.net/view.php?id=264.

* doc/autoconf.texi (Limitations of Usual Tools) <sed>: Clarify
more about sed -e and Posix limitations.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDocument how to use literal newlines in makefile rules.
Bruno Haible [Fri, 18 Jun 2010 22:49:48 +0000 (00:49 +0200)] 
Document how to use literal newlines in makefile rules.

* doc/autoconf.texi (Newlines in Make Rules): New section.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDocument how to write comments in makefile rules.
Bruno Haible [Fri, 18 Jun 2010 22:06:37 +0000 (00:06 +0200)] 
Document how to write comments in makefile rules.

* doc/autoconf.texi (Comments in Make Rules): Mention a workaround
syntax.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDocument how to propogate variables to submakes.
Ben Pfaff [Tue, 15 Jun 2010 04:10:48 +0000 (21:10 -0700)] 
Document how to propogate variables to submakes.

On bug-gnulib, archived at
     http://permalink.gmane.org/gmane.comp.lib.gnulib.bugs/22132
Ralf Wildenhues taught me a bit about how Automake propagates
variables to submakes.  I thought that it would good to document
this in the Autoconf manual, which currently has no detail at
all.

* doc/autoconf.texi: Describe technique used by Automake to
propagate variables to submakes in more detail.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoBe consistent in doc example.
Peter Johansson [Wed, 23 Jun 2010 01:09:04 +0000 (21:09 -0400)] 
Be consistent in doc example.

* doc/autoconf.texi: (Polymorphic Variables) be consistent in code
example and output

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAdd comments for vim syntax highlighting.
Ralf Wildenhues [Tue, 22 Jun 2010 21:50:33 +0000 (23:50 +0200)] 
Add comments for vim syntax highlighting.

* doc/autoconf.texi: Restore font-lock in some examples using
$$, for vim.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFormatting cleanups for optional arguments.
Ralf Wildenhues [Tue, 22 Jun 2010 21:50:03 +0000 (23:50 +0200)] 
Formatting cleanups for optional arguments.

* doc/autoconf.texi (Configuration Actions, Help Formatting)
(External Software): Use @r{} for brackets denoting optional
arguments, where @ovar is not safe to use.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoClarify nested double-quotes and backquotes shell issues.
Ralf Wildenhues [Tue, 22 Jun 2010 18:05:38 +0000 (20:05 +0200)] 
Clarify nested double-quotes and backquotes shell issues.

* doc/autoconf.texi (Shellology): New anchor for pdksh.
(Shell Substitutions): Link to it for escaped double-quotes
within double-quoted backquotes; add ksh example for unescaped
inner double-quotes problem.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoMention Tru64 5.1 fgrep limitation with emtpy patterns.
Ralf Wildenhues [Tue, 22 Jun 2010 18:27:31 +0000 (20:27 +0200)] 
Mention Tru64 5.1 fgrep limitation with emtpy patterns.

* doc/autoconf.texi (Limitations of Usual Tools): Update.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoOverhaul the manual, esp. the Autotest chapter.
Ralf Wildenhues [Tue, 22 Jun 2010 18:26:33 +0000 (20:26 +0200)] 
Overhaul the manual, esp. the Autotest chapter.

* doc/autoconf.texi (Installation Directory Variables):
Replace some uses of @var with @code.
(Special Shell Variables): Fix misordered paragraph about IFS.
(Writing Testsuites): Include paragraph following AT_TESTED in
the macro definition.
(testsuite Invocation): Failed tests are not rerun.
(testsuite Scripts, Autotest Logs, testsuite Invocation)
(Making testsuite Scripts): Minor edits for consistency and
language.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoDocument sed -e limitation.
Bruno Haible [Fri, 18 Jun 2010 15:05:29 +0000 (09:05 -0600)] 
Document sed -e limitation.

* doc/autoconf.texi (Limitations of Usual Tools): Mention portability
problem of sed -e option with script fragments.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDocument, test, and fix AT_ARG_OPTION, AT_ARG_OPTION_ARG.
Ralf Wildenhues [Thu, 17 Jun 2010 20:44:02 +0000 (22:44 +0200)] 
Document, test, and fix AT_ARG_OPTION, AT_ARG_OPTION_ARG.

* lib/autotest/general.m4 (_AT_ARG_OPTION): Fix translation of
hyphens to underscores when turning option names to variables.
Avoid macro name concatenation garbage with trailing `dnl'.
(AT_ARG_OPTION, AT_ARG_OPTION_ARG): Overhaul macro description.
The OPTIONS are space-separated, not comma-separated.  The
negative form of AT_ARG_OPTION is prefixed with `--no-'.
* tests/autotest.at (AT@&t@_ARG_OPTION, AT@&t@_ARG_OPTION_ARG):
New tests.
* NEWS: Update.
* doc/autoconf.texi (Writing Testsuites): Document AT_ARG_OPTION
and AT_ARG_OPTION_ARG.
(testsuite Invocation): Call the thingies passed to the
testsuite options, not arguments.  Note that the testsuite
author may add further package-specific options.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoAutotest: enable colored test results.
Ralf Wildenhues [Thu, 17 Jun 2010 20:26:30 +0000 (22:26 +0200)] 
Autotest: enable colored test results.

* lib/autotest/general.m4 (HELP_TUNING_BEGIN): New diversion.
(HELP_TUNING, HELP_OTHER, HELP_END): Bump diversion numbers.
(AT_INIT): Accept
--color and --color=never|auto|always.  If desired, colorize
test results and testsuite summary on standard output.
[HELP_TUNING]: Divert content instead to ...
[HELP_TUNING_BEGIN]: ... this diversion, m4_wrapped until the
end, when we know whether AT_COLOR_TESTS has been specified.
(AT_COLOR_TESTS): New macro, set the default for color to auto.
* doc/autoconf.texi (Writing Testsuites): Document it.
(testsuite Invocation): Document --color* options.
* tests/local.at: Call AT_COLOR_TESTS for Autoconf's testsuite.
* tests/autotest.at (color test results): New test, mirroring
color.test from Automake.
* NEWS: Update.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoAvoid texinfo bug with backslashes in macro arguments.
Ralf Wildenhues [Tue, 15 Jun 2010 03:36:19 +0000 (05:36 +0200)] 
Avoid texinfo bug with backslashes in macro arguments.

* doc/autoconf.texi (Text processing Macros)
(Common Shell Constructs): Do not use @dvar with backslashes.

15 years agoMake CONFIG_SITE handling more robust.
Eric Blake [Tue, 8 Jun 2010 12:25:35 +0000 (06:25 -0600)] 
Make CONFIG_SITE handling more robust.

* lib/autoconf/general.m4 (AC_SITE_LOAD): Avoid leading - and path
search, and check for failure to load.
* tests/base.at (AC_CACHE_CHECK): Enhance test.
* doc/autoconf.texi (Site Defaults): Mention that CONFIG_SITE
works best as an absolute path.
* NEWS: Document the semantic change.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAllow plus signs in AC_ARG_ENABLE and AC_ARG_WITH.
Bruno Haible [Tue, 16 Mar 2010 06:04:40 +0000 (07:04 +0100)] 
Allow plus signs in AC_ARG_ENABLE and AC_ARG_WITH.

* doc/autoconf.texi (External Software): Mention that AC_ARG_WITH
accepts packages with a + sign in it.
(Package Options): Likewise for AC_ARG_ENABLE.
* lib/autoconf/general.m4 (_AC_ENABLE_IF): Also replace '+' with '_'.
* tests/base.at (AC_ARG_ENABLE and AC_ARG_WITH): New test.
* NEWS: Update.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAutotest: simplify logic to compute test group result.
Ralf Wildenhues [Sun, 13 Jun 2010 06:38:09 +0000 (08:38 +0200)] 
Autotest: simplify logic to compute test group result.

* lib/autotest/general.m4 (AT_INIT): Compactify result
computation logic.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoNew Autotest testsuite option --recheck.
Ralf Wildenhues [Mon, 14 Jun 2010 18:31:58 +0000 (20:31 +0200)] 
New Autotest testsuite option --recheck.

* lib/autotest/general.m4 (AT_INIT): New variable $at_recheck.
Escape hyphen in $at_dir early.  Accept command line switch
--recheck.  Set $at_suite_log early, based on --directory
switch; with --recheck, include the list of FAILed and XPASSed
tests from old testsuite.log file in $at_groups.  Document
--recheck in --help output.
* tests/autotest.at (recheck): New test.
* doc/autoconf.texi (testsuite Invocation): Document --recheck.
* NEWS: Update.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoClarify comment about old system.
Karl Berry [Mon, 14 Jun 2010 18:21:08 +0000 (12:21 -0600)] 
Clarify comment about old system.

* lib/autoconf/general.m4 (_AC_INIT_DEFAULTS): Prefer GNU/Linux,
and note that bug has long since been fixed.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoRun libtool test with modern libtool.
Eric Blake [Mon, 7 Jun 2010 16:11:07 +0000 (10:11 -0600)] 
Run libtool test with modern libtool.

* tests/foreign.at (Libtool): Request that libtoolize install
auxiliary files.  Assume libtool 2.x is modern.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoCoverage and doc fixes for AC_LANG_SOURCE and AC_LANG_PROGRAM.
Ralf Wildenhues [Tue, 8 Jun 2010 04:56:43 +0000 (06:56 +0200)] 
Coverage and doc fixes for AC_LANG_SOURCE and AC_LANG_PROGRAM.

* tests/compile.at (AC_LANG_SOURCE, AC_LANG_SOURCE(C++))
(AC_LANG_SOURCE example, AC_LANG_PROGRAM example): New tests.
* doc/autoconf.texi (Generating Sources): Add markers for tested
examples; update quoting, and update AC_INIT usage to also set
optional URL arguments.  Mention that the examples require gcc.
Prompted by report from Brian J. Murrell.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoMake AS_SET_CATFILE polymorphic, and add testsuite coverage.
Ralf Wildenhues [Tue, 8 Jun 2010 04:55:10 +0000 (06:55 +0200)] 
Make AS_SET_CATFILE polymorphic, and add testsuite coverage.

* lib/m4sugar/m4sh.m4 (AS_SET_CATFILE): Use AS_VAR_SET to set
the variable.
* tests/m4sh.at (AS@&t@_SET_CATFILE): New test.
* doc/autoconf.texi (Common Shell Constructs): Document that
AS_SET_CATFILE is polymorphic in its VAR argument now.
* NEWS: Update.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoTestsuite coverage for AC_COPYRIGHT and AT_COPYRIGHT.
Ralf Wildenhues [Tue, 8 Jun 2010 04:51:39 +0000 (06:51 +0200)] 
Testsuite coverage for AC_COPYRIGHT and AT_COPYRIGHT.

* tests/autotest.at (AT@&t@_COPYRIGHT): New test.
* tests/base.at (AC@&t@_COPYRIGHT): Likewise.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoTestsuite coverage for __file__ and __line__.
Ralf Wildenhues [Tue, 8 Jun 2010 04:50:45 +0000 (06:50 +0200)] 
Testsuite coverage for __file__ and __line__.

* tests/m4sugar.at (__file__ and __line__): New test.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoTestsuite coverage for AC_CACHE_VAL and caching semantics.
Ralf Wildenhues [Tue, 8 Jun 2010 04:49:55 +0000 (06:49 +0200)] 
Testsuite coverage for AC_CACHE_VAL and caching semantics.

* tests/base.at (AC_CACHE_CHECK): Extend test.
(AC_CACHE_LOAD): New test.
* tests/torture.at (Configuring subdirectories): Also test
--config-cache with AC_CONFIG_SUBDIRS.
* doc/autoconf.texi (Caching Results): Annotate code snippets
which are tested in the test suite.
(Cache Files): Documented cache variables may be used on the
configure command line to override individual entries in the
cache file.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoClarify OpenBSD sh errexit issue with compound commands.
Ralf Wildenhues [Sun, 6 Jun 2010 09:59:25 +0000 (11:59 +0200)] 
Clarify OpenBSD sh errexit issue with compound commands.

* doc/autoconf.texi (Limitations of Builtins): Only the last
command in a compound list is problematic.
Tested on OpenBSD 4.4.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoProperly quote AC_PREREQ during autoupdate.
Eric Blake [Thu, 25 Feb 2010 23:34:17 +0000 (16:34 -0700)] 
Properly quote AC_PREREQ during autoupdate.

* lib/autoconf/general.m4 (AC_PREREQ): Follow consistent quoting
style for AC_PREREQ.
* tests/tools.at (autoupdating AC_PREREQ): Update expected
results.
Reported by NightStrike.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDocumentation and tests for the AC_CHECK_DECL change.
Ralf Wildenhues [Tue, 1 Jun 2010 19:54:39 +0000 (21:54 +0200)] 
Documentation and tests for the AC_CHECK_DECL change.

* lib/autoconf/general.m4 (_AC_CHECK_DECL_BODY): Squash trailing
spaces in as_decl_name.
(_AC_CHECK_DECLS): Likewise for the define.
* tests/semantics.at (AC_CHECK_DECLS): Extend test.
* doc/autoconf.texi (Generic Declarations): Update.
* NEWS: Update.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoGeneralize AC_CHECK_DECL for C++: allow optional arguments.
Joern Rennecke [Tue, 1 Jun 2010 18:06:54 +0000 (20:06 +0200)] 
Generalize AC_CHECK_DECL for C++: allow optional arguments.

* general.m4 (_AC_CHECK_DECL_BODY): Process trailing function
argument types as arguments to use for C++.
(_AC_CHECK_DECLS): Filter out trailing function argument types
when generating the HAVE_DECL_* macro.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoDon't expose AC_{COMPILE,LINK}_IFELSE internals in documentation.
Stefano Lattarini [Tue, 25 May 2010 16:58:24 +0000 (18:58 +0200)] 
Don't expose AC_{COMPILE,LINK}_IFELSE internals in documentation.

* doc/autoconf.texi (Runtime) <AC_LINK_IFELSE>: Suggest to use
`conftest$EXEEXT' rather than `conftest$ac_exeext' to acces the
just-linked program file.
(Runtime) <AC_COMPILE_IFELSE>: Suggest to use `conftest.$OBJEXT'
rather than `conftest.$ac_object' to access the just-compiled
object file.  Also, refer to the object file as "just-compiled"
rather than "just-linked".

15 years agoMention another line-counting alternative.
Eric Blake [Thu, 20 May 2010 21:07:03 +0000 (15:07 -0600)] 
Mention another line-counting alternative.

GCS lists sed but not wc as a portable app for Makefile.

* doc/autoconf.texi (Limitations of Usual Tools) <grep>: Mention
how to use sed to count lines.
Suggested by Paolo Bonzini.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDocument the grep workaround.
Eric Blake [Wed, 12 May 2010 14:38:57 +0000 (08:38 -0600)] 
Document the grep workaround.

* doc/autoconf.texi (Limitations of Usual Tools) <grep>: Document
the bug.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoWork around QNX4 grep bug.
Mark Hessling [Wed, 12 May 2010 14:35:00 +0000 (08:35 -0600)] 
Work around QNX4 grep bug.

* lib/autoconf/status.m4 (_AC_OUTPUT_FILES_PREPARE): Count ^
rather than $ to avoid QNX4 grep bug.
* THANKS: Update.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoImprove Erlang documentation.
David Reiss [Tue, 11 May 2010 18:10:36 +0000 (11:10 -0700)] 
Improve Erlang documentation.

* doc/autoconf.texi (Erlang Libraries): Document actual default
values.
* THANKS: Update.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoFix typo in previous patch.
Eric Blake [Tue, 11 May 2010 20:13:32 +0000 (14:13 -0600)] 
Fix typo in previous patch.

* doc/autoconf.texi (File Descriptors): Add end '.
Reported by Ralf Wildenhues.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoMention how to silence program probes.
Eric Blake [Tue, 11 May 2010 14:00:56 +0000 (08:00 -0600)] 
Mention how to silence program probes.

* doc/autoconf.texi (File Descriptors): Document how to silence a
program probe.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoError and warning message formatting cleanups.
Ralf Wildenhues [Sun, 25 Apr 2010 15:02:47 +0000 (17:02 +0200)] 
Error and warning message formatting cleanups.

* doc/autoconf.texi (Autoconf Language, Generic Structures):
Do not capitalize the first word in error messages, do not end
them with a period.
* lib/autoconf/general.m4 (_AC_INIT_PARSE_ARGS, AC_MSG_FAILURE):
Likewise.
* lib/autoconf/status.m4 (_AC_OUTPUT_FILE): Likewise.
* lib/autotest/general.m4 (AT_INIT, at_fn_group_prepare):
Likewise.
* m4/m4.m4 (AC_PROG_GNU_M4): Likewise.
* tests/base.at (AC_TRY_COMMAND): Likewise.
* tests/torture.at (datarootdir workaround): Adjust expected
message.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFix placing of ellipses in English text.
Ralf Wildenhues [Sun, 25 Apr 2010 12:19:13 +0000 (14:19 +0200)] 
Fix placing of ellipses in English text.

* lib/autoconf/general.m4 (_AC_INIT_HELP): Be sure to add a
space before `...' in natural language text.
* lib/autoconf/headers.m4 (_AC_CHECK_HEADER_MONGREL_BODY):
Likewise.
* lib/autoconf/libs.m4 (_AC_PATH_X_XMKMF): Likewise.
* lib/autoconf/programs.m4 (AC_PROG_MAKE_SET): Likewise.
* tests/suite.at: Likewise.
* tests/torture.at (@%:@define header templates): Likewise.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoEnsure autotest tests have an atconfig file, for testsuite -v.
Ralf Wildenhues [Sun, 25 Apr 2010 12:18:19 +0000 (14:18 +0200)] 
Ensure autotest tests have an atconfig file, for testsuite -v.

* tests/autotest.at (AT_CHECK_AT_PREP): Create a default
atconfig file in the directory of the testsuite.
(AT_CHECK_AT_TITLE): Also check that `./micro-suite -v' output
does not contain empty $at_srcdir expansion.
(srcdir propagation): Remove the atconfig file generated by
AT_CHECK_AT_PREP.  Check each suite invocation for $at_srcdir
expansion.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFix autotest testsuite -v output to print test group title.
Ralf Wildenhues [Sun, 25 Apr 2010 12:17:27 +0000 (14:17 +0200)] 
Fix autotest testsuite -v output to print test group title.

* lib/autotest/general.m4 (AT_CLEANUP): Actually print test
title in verbose output.  Fixes AUTOCONF-2.57-101-gc102ed8
regression.
* tests/autotest.at (AT_CHECK_AT_TITLE): Amend macro to check
for test title in -v output.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoClarify octal escapes with tr.
Eric Blake [Mon, 26 Apr 2010 15:30:06 +0000 (09:30 -0600)] 
Clarify octal escapes with tr.

* doc/autoconf.texi (Limitations of Usual Tools): Carriage return
is portable in octal, but not newline.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAdd missing ChangeLog entry.
Eric Blake [Thu, 22 Apr 2010 18:01:33 +0000 (12:01 -0600)] 
Add missing ChangeLog entry.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAdd a paragraph to FAQ on Debugging configure scripts.
Joel James Adamson [Thu, 22 Apr 2010 14:53:20 +0000 (10:53 -0400)] 
Add a paragraph to FAQ on Debugging configure scripts.

* doc/autoconf.texi (Debugging): Mention inspecting config.log.
* THANKS: Update.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agomanual: fix minor typo in AC_CONFIG_SUBDIRS example
Mike Frysinger [Wed, 21 Apr 2010 09:20:45 +0000 (05:20 -0400)] 
manual: fix minor typo in AC_CONFIG_SUBDIRS example

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
15 years agoFix m4_cr_all for EBCDIC.
Eric Blake [Mon, 5 Apr 2010 14:06:17 +0000 (08:06 -0600)] 
Fix m4_cr_all for EBCDIC.

* lib/m4sugar/m4sugar.m4 (m4_cr_all): Swap * and $, so that we
don't end up with $* in EBCDIC.
* NEWS: Document the fix.
* THANKS: Update.
Reported by Steve Goetze.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDo not use @acronym in the manual.
Ralf Wildenhues [Sun, 28 Mar 2010 15:55:44 +0000 (17:55 +0200)] 
Do not use @acronym in the manual.

* doc/autoconf.texi: Remove all usage of @acronym.
Suggested by Karl Berry.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoDo not use @sc in the manual.
Ralf Wildenhues [Sun, 28 Mar 2010 15:54:39 +0000 (17:54 +0200)] 
Do not use @sc in the manual.

* doc/autoconf.texi: Remove all usage of @sc in the manual.
Suggested by Karl Berry.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFix wrong comment in testsuite.
Ralf Wildenhues [Fri, 12 Mar 2010 06:02:48 +0000 (07:02 +0100)] 
Fix wrong comment in testsuite.

* tests/m4sugar.at (m4@&t@_warn): Remove copy&pasted comment.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFormatting cleanups in macro comments.
Ralf Wildenhues [Fri, 12 Mar 2010 05:58:46 +0000 (06:58 +0100)] 
Formatting cleanups in macro comments.

For a list of candidate unaligned underlines, use this script:

for f in `git ls-files`; do
  awk '{ len[NR] = length($0) }
       /----*/ && len[NR-1] != 0 {
         if (len[NR-1] != len[NR])
           print FILENAME ":" NR ":" $0
       }' $f
done

* lib/autoconf/c.m4, lib/autoconf/erlang.m4,
lib/autoconf/fortran.m4, lib/autoconf/functions.m4,
lib/autoconf/general.m4, lib/autoconf/lang.m4,
lib/autoconf/programs.m4, lib/autoconf/specific.m4,
lib/autoconf/status.m4, lib/autoconf/types.m4,
lib/autotest/general.m4, lib/autotest/specific.m4,
lib/m4sugar/m4sh.m4, lib/m4sugar/m4sugar.m4,
tests/autotest.at, tests/local.at, tests/m4sh.at,
tests/semantics.at, tests/tools.at, tests/torture.at: Fix macro
comment format.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agomanual: index strings containing colon in non-info outputs.
Ralf Wildenhues [Fri, 5 Mar 2010 23:09:52 +0000 (00:09 +0100)] 
manual: index strings containing colon in non-info outputs.

* doc/autoconf.texi (Quadrigraphs, Shell Substitutions): Produce
index entries for concepts containing a colon in output formats
other than info.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoUpdate copyright years for files generated by mktests.sh.
Ralf Wildenhues [Fri, 5 Mar 2010 23:08:58 +0000 (00:08 +0100)] 
Update copyright years for files generated by mktests.sh.

* tests/mktests.sh: Update copyright years for generated files.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoDocument AC_LANG_CONFTEST semantic change.
Eric Blake [Tue, 2 Mar 2010 22:46:34 +0000 (15:46 -0700)] 
Document AC_LANG_CONFTEST semantic change.

* doc/autoconf.texi (Generating Sources) <AC_LANG_CONFTEST>:
Enhance documentation, to show that semantic change in 2.63b was
intentional.
* THANKS: Update.
Reported by Brian J. Murrell, analyzed by Ralf Wildenhues.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoAutoconf Macro Archive URL has changed.
Peter Johansson [Thu, 4 Mar 2010 04:13:22 +0000 (23:13 -0500)] 
Autoconf Macro Archive URL has changed.

* doc/autoconf.texi (Introduction, Coding Style, Defining
Directories): The Autoconf Macro Archive is officially `GNU'.
Update URL.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoFix shell code in AS_TR_SH documentation.
Eric Blake [Tue, 2 Mar 2010 22:39:58 +0000 (15:39 -0700)] 
Fix shell code in AS_TR_SH documentation.

* doc/autoconf.texi (Common Shell Constructs) <AS_TR_SH>: Fix
example to expand to valid shell code.
Reported by Ralf Wildenhues.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoImprove documentation on AC_{COMPILE,LINK}_IFELSE.
Eric Blake [Tue, 2 Mar 2010 21:00:24 +0000 (14:00 -0700)] 
Improve documentation on AC_{COMPILE,LINK}_IFELSE.

* doc/autoconf.texi (Running the Compiler): Mention that the
object file is available after a successful compile.
(Running the Linker): Likewise for the linker output.
Suggested by Paolo Bonzini.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoFix typo in docs.
Eric Blake [Tue, 2 Mar 2010 19:15:56 +0000 (12:15 -0700)] 
Fix typo in docs.

* doc/autoconf.texi (Conditional constructs) <m4_ifblank>: Fix
typo.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoFix AS_ERROR for FreeBSD sh.
Ralf Wildenhues [Tue, 2 Mar 2010 19:19:32 +0000 (20:19 +0100)] 
Fix AS_ERROR for FreeBSD sh.

* lib/m4sugar/m4sh.m4 (_AS_ERROR_PREPARE): Rewrite as_fn_error
to take additional first argument STATUS instead of transporting
$? across shell function entry, which does not work with FreeBSD
sh.  Shift all other arguments by one, adjust.
(AS_ERROR): Pass EXIT-STATUS, defaulting to $?, to as_fn_error.
Report by Václav Haisman.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFix `autom4te cache creation' testsuite failure on FreeBSD.
Ralf Wildenhues [Tue, 2 Mar 2010 06:50:19 +0000 (07:50 +0100)] 
Fix `autom4te cache creation' testsuite failure on FreeBSD.

* tests/tools.at (autom4te cache creation): Normalize exit
status of failed redirection to 1, may be 2 with FreeBSD sh.
* THANKS: Update.
Report by Václav Haisman.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoFix Autotest tracing of shell pipelines for FreeBSD sh.
Ralf Wildenhues [Tue, 2 Mar 2010 06:48:42 +0000 (07:48 +0100)] 
Fix Autotest tracing of shell pipelines for FreeBSD sh.

* lib/autotest/general.m4 (_AT_DECIDE_TRACEABLE): Do not trace
commands that contain [^|]|[^|], a likely shell pipeline.
* tests/local.at (_AT_CHECK_ENV): Turn off tracing for egrep |
grep pipeline.
* doc/autoconf.texi (File Descriptors): Document limitation.
* tests/autotest.at (Trace output): New test.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoUpdate file flow diagram to mention Automake.
Eric Blake [Thu, 25 Feb 2010 22:49:12 +0000 (15:49 -0700)] 
Update file flow diagram to mention Automake.

* doc/autoconf.texi (Making configure Scripts): Avoid confusion
with listing Makefile.in twice on one line.  Add a diagram showing
how automake fits into the picture.
Reported by santilín.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoOptimize AC_REPLACE_FUNCS.
Eric Blake [Wed, 9 Sep 2009 14:32:46 +0000 (08:32 -0600)] 
Optimize AC_REPLACE_FUNCS.

* lib/autoconf/functions.m4 (_AC_REPLACE_FUNC): New helper macro.
(AC_REPLACE_FUNCS): Use it to reduce forks when checking for
replacements, by using literal rather than shell variable.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDocument how to safely override CFLAGS default.
Eric Blake [Thu, 25 Feb 2010 21:56:34 +0000 (14:56 -0700)] 
Document how to safely override CFLAGS default.

* doc/autoconf.texi (C Compiler) <AC_PROG_CC>: Document a way to
change the default CFLAGS.
(C++ Compiler) <AC_PROG_CXX>: Likewise, for CXXFLAGS.
Reported by Monty Taylor; wording suggested by Paolo Bonzini.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoDocument that Autoconf relies on IFS.
Eric Blake [Thu, 25 Feb 2010 21:06:38 +0000 (14:06 -0700)] 
Document that Autoconf relies on IFS.

* doc/autoconf.texi (Special Shell Variables) <IFS>: Add details
about use of IFS within configure script.
* THANKS: Update.
Reported by Arkadiusz Miskiewicz.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoRecommend latest m4 release.
Eric Blake [Thu, 25 Feb 2010 21:17:31 +0000 (14:17 -0700)] 
Recommend latest m4 release.

* README: Bump recommendation to m4 1.4.14 (minimum remains
1.4.6).
* doc/autoconf.texi (Introduction): Likewise.
* m4/m4.m4 (AC_PROG_GNU_M4): Likewise.

Signed-off-by: Eric Blake <eblake@redhat.com>
15 years agoFix testsuite failures due to setting of $U.
Ralf Wildenhues [Tue, 23 Feb 2010 05:53:09 +0000 (06:53 +0100)] 
Fix testsuite failures due to setting of $U.

* tests/local.at (_AT_CHECK_ENV): Ignore setting of $U.

Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15 years agoAvoid uninitialized use of $U.
Eric Blake [Tue, 9 Feb 2010 13:22:59 +0000 (06:22 -0700)] 
Avoid uninitialized use of $U.

Automake sets up $U in AM_C_PROTOTYPES, but we can't assume that
automake is always in use.

* lib/autoconf/general.m4 (_AC_LIBOBJS_NORMALIZE): Ensure $U is
set if automake did not define it.
* THANKS: Update.
Reported by Heiko Schlichting, via Julien Élie.

Signed-off-by: Eric Blake <ebb9@byu.net>