Commit Graph

677 Commits

Author SHA1 Message Date
Zack Weinberg
f7693b83f2
Revise documentation for AC_PROG_LEX.
- Better explanation of the additional tests performed by this macro,
   once the tool has been located.

 - Update advice re using Flex to generate a bundled lex.yy.c.

 - Remove text describing a bug in Automake that has long since been
   corrected.
2020-07-16 14:48:09 -04:00
Paul Eggert
29ede6b96f AC_PROG_LEX no longer sets LEXLIB for yywrap
Suggested by Zack Weinberg in:
https://lists.gnu.org/r/autoconf-patches/2020-07/msg00016.html
* lib/autoconf/programs.m4 (_AC_PROG_LEX_YYTEXT_DECL):
Define yywrap too.
2020-07-16 10:48:09 -07:00
Paul Eggert
d45c2e2f5b Revert mistaken patch for Bison
Problem reported by Bruno Haible in:
https://savannah.gnu.org/support/?110266
* lib/autoconf/programs.m4 (AC_PROG_YACC):
Go back to using bison -y instead of bison -o y.tab.c.
2020-07-15 13:30:56 -07:00
Nick Alcock
60e1c17ee0
NEWS: don’t describe Automake 1.13 as “upcoming.”
Automake 1.13 was released eight years ago.  The current version is
1.16.2.
2020-07-14 13:23:00 -04:00
Zack Weinberg
a1acd8e66b
Formally obsolete AC_CONFIG_HEADER (#105403)
This macro was replaced by AC_CONFIG_HEADERS many years ago (before
the beginning of the VCS history) and isn’t even documented, but we
never got around to making autoupdate notice it.  Problem reported
*in 2006* by jensseidel@users.sf.net.

There was one use of AC_CONFIG_HEADER in our source tree, which is
converted.  Also, to avoid confusing people reading old NEWS or TODO
entries, all mentions of AC_CONFIG_HEADER therein are also replaced
with AC_CONFIG_HEADERS.

* lib/autoconf/status.m4 (AC_CONFIG_HEADER): Make an AU_ALIAS for
  AC_CONFIG_HEADERS.
2020-07-12 11:59:14 -04:00
Zack Weinberg
d5cb54d02d
Add AC_PROG_EGREP to AU_DEFUN for AC_HEADER_STDC (#110215)
AC_HEADER_STDC used to use AC_EGREP_CPP, and therefore had the side
effect of AC_REQUIRE([AC_PROG_EGREP]).  In 2.70 AC_HEADER_STDC is an
AU_DEFUN and, before this change, the replacement didn’t invoke
AC_PROG_EGREP, which broke configure scripts that assumed $EGREP would
be set.  Problem reported by Ross Burton.

* lib/autoconf/headers.m4 (AU::AC_HEADER_STDC): Also invoke AC_PROG_EGREP.
2020-07-12 11:26:47 -04:00
Zack Weinberg
83798d2971
NEWS: add notes about known breakage due to pickier macros.
These are all cases where the offending configure script or
third-party macro was always incorrect, but autoconf 2.69 let you get
away with it.
2020-07-10 14:16:18 -04:00
Zack Weinberg
5016cdc03a
NEWS: mention that AS_INIT no longer embeds full paths to source files.
(Change made in c6daae41276a49b52a9d5e2f70c95651364ed619.)

Also reorder some of the NEWS entries more logically.
2020-07-09 13:59:05 -04:00
Zack Weinberg
0a0a337886 Consistently expand macros in whitespace-separated lists.
Several of the most commonly used Autoconf macros (starting with
AC_CHECK_FUNCS and AC_CHECK_HEADERS) take a whitespace-separated list
of symbols as their primary argument.  It would abstractly be best if
this list were _not_ subject to M4 macro expansion, in case there’s a
collision between a M4 macro name and something to be looked for.
However, we have historically not been careful about this, and there’s
been reports of configure scripts using ‘dnl’ to write comments inside
the list.  The AS_LITERAL_IF optimizations added to AC_CHECK_FUNCS and
AC_CHECK_HEADERS since 2.69 broke some of those scripts with bizarre
shell syntax errors.

Also, the macro expansion behavior is not consistent among all of the
macros that take whitespace-separated lists, nor is it consistent
between autoconf and autoheader.

Address this by introducing a new m4sugar macro, currently called
‘m4_validate_w’ (I’m open to suggestions for better names).  Here’s
its documentation comment:

| m4_validate_w(STRING): Expands into m4_normalize(m4_expand([STRING])),
| but if that is not the same as just m4_normalize([STRING]),
| issue a warning.

The text of the warning is

| configure.ac:N: warning: whitespace-separated-list contains macros;
| configure.ac:N: in a future version of Autoconf they will not be expanded

If the unexpanded form of the string contains the token ‘dnl’ then
there’s an additional line:

| configure.ac:N: note: ‘dnl’ is a macro

All of the public macros that take a whitespace-separated list of
symbols are changed to pass that argument through m4_validate_w before
doing anything else with it, and the test suite is updated to verify
consistent behavior for every last one of them.

This addresses Savannah issues #110210 and #110211, and the harmless
but annoying autoheader behavior described at
https://lists.gnu.org/archive/html/bug-autoconf/2018-02/msg00005.html .

In order to avoid expanding relatively expensive m4sugar macros
multiple times per top-level macro invocation, several of the affected
Autoconf macros are restructured along the same lines as I did for
AC_REPLACE_FUNCS in the previous patch.

* lib/m4sugar/m4sugar.m4 (m4_validate_w): New macro.
* lib/autoconf/functions.m4 (AC_CHECK_FUNCS, AC_CHECK_FUNCS_ONCE)
  (AC_REPLACE_FUNCS)
* lib/autoconf/general.m4 (AC_CONFIG_MACRO_DIRS, AC_CHECK_FILES)
* lib/autoconf/headers.m4 (AC_CHECK_HEADERS, AC_CHECK_HEADERS_ONCE)
* lib/autoconf/status.m4 (AC_CONFIG_SUBDIRS): Pass $1 through
  m4_validate_w before use.

* lib/autoconf/headers.m4 (AC_CHECK_HEADERS): Refactor with helpers
  _AC_CHECK_HEADERS_ONE_U, _AC_CHECK_HEADERS_ONE_S, _AC_CHECK_HEADERS_ONE_C.
  (AC_CHECK_HEADERS_ONCE): Eliminate _AC_CHECK_HEADERS_ONCE.
  (AC_CHECK_INCLUDES_DEFAULT): Don’t use _AC_CHECK_HEADERS_ONCE.

* lib/autoconf/functions.m4 (AC_CHECK_FUNCS): Refactor with helpers
  _AC_CHECK_FUNCS_ONE_U, _AC_CHECK_FUNCS_ONE_S, _AC_CHECK_FUNCS_ONE_C.

* lib/autoconf/status.m4 (_AC_CONFIG_SUBDIRS): No need to use m4_normalize.

* tests/semantics.at: Add tests for expansion of M4 macros in
  whitespace-separated list arguments to all of the above.
2020-06-29 23:17:15 -07:00
Zack Weinberg
8a09003664
Define $as_echo and $as_echo_n for backward compatibility.
Commit 2b59b6f8a7 removed the internal
shell variables $as_echo and $as_echo_n.  It turns out that these are
used by several widely-used third-party m4 files (notably both
gnulib-common.m4 from gnulib, and ax_pthread.m4 from the Autoconf
macro archive) as well as any number of existing configure.ac’s.

Restore these shell variables, unconditionally defining them to use
printf.  Issue -Wobsolete warnings if they are used, recommending the
use of AS_ECHO and AS_ECHO_N respectively.  Add a test which checks
both that they do work and that they trigger warnings.
2020-03-13 14:50:50 -04:00
Jim Meyering
d78a7dd95f maint: make update-copyright 2020-01-01 11:45:50 -08:00
Daniel Colascione
f0aa3cc07a fix quoting 2018-03-19 20:19:46 -07:00
Paul Eggert
d3dcd5895d Prefer HTTPS to FTP and HTTP 2017-09-16 17:48:51 -07:00
Jim Meyering
60460b91d0 maint: update copyright dates for 2017
* all files: Run "make update-copyright".
* doc/autoconf.texi: Update manually.
2017-01-01 05:18:32 -08:00
Daniel Elstner
78ad1b0b2c autoheader: check templates of all config headers
* bin/autoheader.in: When checking for missing templates, take
all config headers into account, not just the one generated by
autoheader.  This makes it possible to use AC_DEFINE() for
secondary headers without duplicating the template into the
first header.
* tests/tools.at: Add a check for autoheader with multiple
config headers.
* NEWS: Document the new behavior.
Message-Id: <1482336946.31331.2.camel@gmail.com>
Signed-off-by: Eric Blake <eblake@redhat.com>
2016-12-21 10:31:54 -06:00
Eric Blake
501ccbbfdb AC_CHECK_HEADERS_ONCE: honor current AC_LANG
Previously, AC_CHECK_HEADERS_ONCE collected a list of header names
to check, but ran the checks using the AC_LANG that was active
during the first encounter of the macro.  In practice, this is
usually the C language, and we haven't had actual reports of projects
attempting to use AC_CHECK_HEADERS_ONCE across multiple languages,
rather this was discovered by code inspection.

With this patch, the code now tracks a separate per-language list of
names to check.  Note, however, that it is only possible to check for
a given header name in one language; attempting to add a name again
under AC_CHECK_HEADERS_ONCE while a different language is active is a
no-op (this still makes sense because the side-effect of defining
the CPP macro HAVE_HEADER does not include a language prefix).

* lib/autoconf/headers.m4 (_AC_CHECK_HEADER_ONCE)
(_AC_HEADERS_EXPANSION):
* NEWS: Mention it.

Signed-off-by: Eric Blake <eblake@redhat.com>
2016-12-21 08:32:29 -06:00
Eric Blake
4523f7c32b AC_CHECK_FUNCS_ONCE: honor current AC_LANG
Previously, AC_CHECK_FUNCS_ONCE collected a list of function names
to check, but ran the checks using the AC_LANG that was active
during the first encounter of the macro.  In practice, this is
usually the C language, and we haven't had actual reports of projects
attempting to use AC_CHECK_FUNCS_ONCE across multiple languages,
rather this was discovered by code inspection.

With this patch, the code now tracks a separate per-language list of
names to check.  Note, however, that it is only possible to check for
a given function name in one language; attempting to add a name again
under AC_CHECK_FUNCS_ONCE while a different language is active is a
no-op (this still makes sense because the side-effect of defining
the CPP macro HAVE_FUNC does not include a language prefix).

* lib/autoconf/functions.m4 (_AC_CHECK_FUNC_ONCE)
(_AC_FUNCS_EXPANSION):
* NEWS: Mention it.

Signed-off-by: Eric Blake <eblake@redhat.com>
2016-12-20 13:34:20 -06:00
Paul Eggert
9021c82280 AC_USE_SYSTEM_EXTENSIONS: port to more ISO C TSes
* doc/autoconf.texi (C and Posix Variants): Rename from "Posix
Variants", and document updated behavior.
* lib/autoconf/specific.m4 (AC_USE_SYSTEM_EXTENSIONS): Also define
__STDC_WANT_IEC_60559_ATTRIBS_EXT__,
__STDC_WANT_IEC_60559_DFP_EXT__,
__STDC_WANT_IEC_60559_TYPES_EXT__, and
__STDC_WANT_MATH_SPEC_FUNCS__.  From a suggestion by Joseph Myers in:
http://lists.gnu.org/archive/html/autoconf-patches/2016-09/msg00011.html
2016-09-15 10:10:14 -07:00
Paul Eggert
4f08ddfe35 AC_USE_SYSTEM_EXTENSIONS: port to recent ISO C
* lib/autoconf/specific.m4 (AC_USE_SYSTEM_EXTENSIONS):
Also define __STDC_WANT_IEC_60559_BFP_EXT__,
__STDC_WANT_IEC_60559_FUNCS_EXT__, and __STDC_WANT_LIB_EXT2__.
* NEWS, doc/autoconf.texi (Posix Variants):
Document this.  Also, document other changes in this area
that were not properly documented before.
2016-09-13 18:28:47 -07:00
Paul Eggert
04be2b7a29 Move config.* man pages to its source tree
Suggested by Ben Elliston in:
https://lists.gnu.org/archive/html/autoconf-patches/2015-11/msg00000.html
* man/config.guess.x, man/config.sub.x: Remove.
* NEWS: Mention this.
* man/local.mk (dist_man_MANS): Remove them.
($(mansrcdir)/config.guess.1, $(mansrcdir)/config.sub.1): Remove rules.
2016-02-06 17:17:50 -08:00
Paul Eggert
bbfa63cd4a maint: make update-copyright 2016-02-06 17:17:49 -08:00
Noah Misch
82ef7805fa AC_CHECK_DECL, AC_CHECK_DECLS: port to the Clang compiler
* lib/autoconf/general.m4 (_AC_UNDECLARED_WARNING): New macro.
(_AC_CHECK_DECL_BODY): Call it once per language; treat warnings as
errors when its verdict indicates that.
* tests/semantics.at (AC_CHECK_DECLS): Add a macro call that relies on
the new semantics.  Avoid -Wmissing-variable-declarations warnings.
* doc/autoconf.texi (Generic Declarations): Document the implications.
* NEWS: Mention this change.
2015-05-13 21:11:47 -04:00
Paul Eggert
7b13e39a11 maint: bump copyright to 2015
* all files: Run 'make update-copyright'.
2015-01-02 13:03:39 -08:00
Paul Eggert
f6156ba050 autoconf: modernize AC_C_VARARRAYS for C11
* lib/autoconf/c.m4 (AC_C_VARARRAYS): Define __STDC_NO_VLA__ if
VLAs are not supported, as this is what C11 does.  The old macro
HAVE_C_VARARRAYS is still defined if they are supported, but is
now obsolescent.  Also, check for VLA bug in GCC 3.4.3.
* doc/autoconf.texi (C Compiler), NEWS: Document the above.
2014-08-07 17:17:25 -07:00
Eric Blake
a610501ded maint: bump copyright to 2014
Done via 'make update-copyright', since all files are effectively
modified and distributed this year via public version control.

* all files: Update copyright year.
2014-01-01 16:27:53 -07:00
Zack Weinberg
f181785d0e Expose the checks done by AC_INCLUDES_DEFAULT as a public macro.
* lib/autoconf/headers.m4 (_AC_INCLUDES_DEFAULT_REQUIREMENTS):
   Rename to AC_CHECK_INCLUDES_DEFAULT.  All callers changed.
   (AC_HEADER_STDC, AC_UNISTD_H): Use AC_CHECK_INCLUDES_DEFAULT instead
   of previous kludge.

 * doc/autoconf.texi, NEWS: Document AC_CHECK_INCLUDES_DEFAULT.
2013-09-21 20:02:47 -04:00
Zack Weinberg
86c213d0e3 Modernize AC_INCLUDES_DEFAULT and friends.
* lib/autoconf/headers.m4 (_AC_INCLUDES_DEFAULT_REQUIREMENTS):
   Include stddef.h, stdlib.h, and string.h unconditionally.
   Don't include memory.h at all.
   Don't use AC_HEADER_STDC.
   Don't check for stddef.h, stdlib.h, string.h, or memory.h.
   For compatibility, unconditionally define STDC_HEADERS,
   HAVE_STDLIB_H, and HAVE_STRING_H.
   (AN_HEADER list): Remove C89 headers, and memory.h from list.
   (AC_HEADER_STDC, AC_UNISTD_H): AU_DEFUN to trigger
   _AC_INCLUDES_DEFAULT_REQUIREMENTS if it hasn't already happened,
   and do nothing else.
   (AC_HEADER_TIME): AU_DEFUN, and define TIME_WITH_SYS_TIME unconditionally
   as long as sys/time.h is present.
   (AC_USG, AC_MEMORY_H): Assume existence of string.h.
 * lib/autoconf/functions.m4 (_AC_FUNC_MALLOC_IF, _AC_FUNC_REALLOC_IF):
   Don't use AC_HEADER_STDC. Assume stdlib.h exists.
   (AC_FUNC_MKTIME): Don't use AC_HEADER_TIME.  Assume time.h exists.
   (AC_FUNC_ALLOCA): Assume stdlib.h exists.
   (_AC_LIBOBJ_FNMATCH): Assume wchar.h and wctype.h exist.
   (_AC_LIBOBJ_GETLOADAVG): Assume locale.h exists.
   (AC_FUNC_MMAP): Assume stdlib.h exists.
 * tests/tools.at: Use AC_WORDS_BIGENDIAN instead of AC_STDC_HEADERS in
   autoupdate test.

 * NEWS, doc/autoconf.texi: Document changes. Remove obsolete advice.
2013-09-21 19:38:09 -04:00
Zack Weinberg
11f520c61d AC_CHECK_HEADER/AC_CHECK_HEADERS: complete transition to compile tests.
* lib/autoconf/headers.m4 (AC_CHECK_HEADER): Use _AC_CHECK_HEADER_COMPILE
  by default.  Continue to use _AC_CHECK_HEADER_PREPROC if fourth arg is '-'.
  (_AC_CHECK_HEADER_PREPROC): Issue a deprecation warning.
  (_AC_CHECK_HEADER_MONGREL, _AC_CHECK_HEADER_MONGREL_BODY): Remove.

* tests/c.at, tests/semantics.at: Update uses of AC_CHECK_HEADER(S).
* doc/autoconf.texi, NEWS: Document change.
2013-09-21 19:01:40 -04:00
Eric Blake
a197431414 AC_INIT: add --runstatedir option to configure
http://lwn.net/Articles/436012/ documents that many distros
are now preferring to use /run rather than /var/run for
storage of pid files and other per-process temporary files
that must not be cleaned out during arbitrary TMPDIR sweeps.
As such, the GNU Coding Standards were recently changed to
recommend a new configure option to make it easy to choose
this directory at configure time.  This patch adds support
for the option to all configure scripts built by autoconf.

* general.m4 (_AC_INIT_PARSE_ARGS): Add new directory option.
(_AC_INIT_HELP): Document it.
* doc/autoconf.texi (Installation Directory Variables): Document
new option.
(Site Defaults): Mention typical use within a distro.
* NEWS: Mention the addition.

Signed-off-by: Eric Blake <eblake@redhat.com>
2013-09-14 06:28:34 -06:00
Akim Demaille
42761668c0 AC_PROG_YACC: don't force Bison to warn against its own features
When invoked with -y/--yacc, Bison warns when its extensions over
POSIX Yacc are used.  Yet many packages requiring GNU Bison use
Autoconf/Automake's Yacc support, which passes -y to Bison.  It
turns out that passing '-o y.tab.c' has exactly the desired
effect: generating not only y.tab.c but also y.tab.h with -d and
y.output with -v.  See:
http://lists.gnu.org/archive/html/bison-patches/2013-02/msg00100.html
* lib/autoconf/programs.m4 (AC_PROG_YACC): Use bison -o y.tab.c.
* NEWS, doc/autoconf.texi: Document this change.
2013-03-19 11:19:40 -07:00
Paul Eggert
9e33646cac AC_USE_SYSTEM_EXTENSIONS: port to HP-UX, MINUX 3, OS X.
* NEWS: Mention this.
* lib/autoconf/specific.m4 (AC_USE_SYSTEM_EXTENSIONS):
Define _NETBSD_HOST on MINUX, for MINUX 3.
Define _DARWIN_C_SOURCE, for OS X.
On HP-UX, define _XOPEN_SOURCE.
2013-02-06 22:47:17 -08:00
Gary V. Vaughan
c3d301efd6 m4sugar: fix AS_VAR_GET regression.
AS_VAR_GET expands AS_ECHO inside en evaled single quoted string,
which causes the single quotes in "printf '%s\n'" to expose the
%s\n to the shell which expands "\n" to simply "n" before passing
it to printf.
* lib/m4sugar/m4sh.m4 (AS_ECHO): Use double quotes around the
format string.
* doc/autoconf.texi (Limitations of Shell Builtins): Show double
quotes to match AS_ECHO expansion.
* NEWS: Likewise.
2013-01-29 19:25:14 +07:00
Gary V. Vaughan
2b59b6f8a7 m4sugar: factor away _AS_ECHO_PREPARE.
"printf '%s\n' ..." has been a fine replacement for plain "echo"
for at least 5 years (probably more like 10), even with most
museum-piece shells.
* lib/m4sugar/m4sh.m4 (_AS_ECHO_PREPARE): Remove.
(_AS_SHELL_SANITIZE): Keep as_nl setting originally from
_AS_ECHO_PREPARE here where it more properly belongs.
(AS_ECHO, AS_ECHO_N): Use printf unconditionally.
* doc/autoconf.texi (Limitations of Shell Builtins): Document
preference for 'printf' over working around 'echo' bugs.
* NEWS: Updated.
Reported by Jim Meyering.
2013-01-29 16:47:48 +07:00
Paul Eggert
bea5177adc AC_PROG_CXX: document change
* NEWS: Document recent change to AC_PROG_CXX.
2013-01-28 23:32:05 -08:00
Eric Blake
fbaee459bf maint: bump copyright to 2013
Done via 'make update-copyright', since all files are effectively
modified and distributed this year via public version control.

* all files: Update copyright year.
2013-01-03 14:58:52 -07:00
Paul Eggert
ca8b864f43 AC_C__GENERIC: New macro.
* NEWS, doc/autoconf.texi (C Compiler): Document it.
* lib/autoconf/c.m4 (AC_C__GENERIC): Implement it.
2012-12-27 14:35:16 -08:00
Paolo Bonzini
851ef51796 autotest: enable usage of EXEEXT in AT_TESTED
Together with Linux's binfmt-misc feature, Wine can be used to test
cross-compiled programs as if they were native.  However, the shell
will not perform the "magic" addition of the .exe extension after a
program name when searching for an executable.  These simple patches
let the user work around this by specifying $EXEEXT in the AT_CHECK
and AT_TESTED argument.  (More care is needed because of carriage
returns, but this is beyond the scope of this series).

* tests/autotest.at (AT_INIT): Expand contents of $at_tested.
(AT_TESTED): Quote each program that is passed to the function.
* lib/autotest/general.m4 (C unit tests): Add AT_TESTED invocation
and keyword.
* doc/autoconf.texi (Writing testsuites): Document usage of variables
in AT_TESTED.
* NEWS: Document change.

Signed-off-by: Paolo Bonzini <bonzini@gnu.org>
2012-12-22 15:34:50 +01:00
Paolo Bonzini
d902536845 autotest: add a simple test suite that runs a C program
* tests/autotest.at (C unit tests): New testcase.
* NEWS: Document change.

Signed-off-by: Paolo Bonzini <bonzini@gnu.org>
2012-12-22 15:34:50 +01:00
Paolo Bonzini
42b4918d16 autotest: define AT_DATA_UNQUOTED
* lib/autotest/general.m4 (AT_DATA_UNQUOTED): New macro, paralleling
AT_DATA but not quoting the contents.
* doc/autoconf.texi (Writing Testsuites): Document it.
* tests/autotest.at (AT_DATA_UNQUOTED): Test it.

Signed-off-by: Paolo Bonzini <bonzini@gnu.org>
2012-12-07 14:25:08 +01:00
Stefano Lattarini
d73770f879 AC_CONFIG_MACRO_DIRS: new macro, mostly for aclocal
Similar to AC_CONFIG_MACRO_DIR, but accepts more than one argument.
This will allow projects to use several m4 macro local dirs.  This is
especially important for projects that are used as nested subpackages
of larger projects.

See also:
<http://lists.gnu.org/archive/html/autoconf/2011-12/msg00037.html>
<http://lists.gnu.org/archive/html/automake-patches/2012-07/msg00010.html>

* lib/autoconf/general.m4 (AC_CONFIG_MACRO_DIRS): New.  Expands to the
empty anyway, since it is only meant to be traced by tools like aclocal
and autoreconf.
(AC_CONFIG_MACRO_DIR): Updated comments.
* doc/autoconf.texi (@node "Input"): Document AC_CONFIG_MACRO_DIRS as
preferred over AC_CONFIG_MACRO_DIR.
* NEWS: Update.

Suggested-by: Eric Blake <eblake@redhat.com>
Helped-by: Nick Bowler <nbowler@elliptictech.com>
Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
Signed-off-by: Eric Blake <eblake@redhat.com>
2012-11-09 15:45:44 -07:00
Paul Eggert
18c140b50b AC_PROG_CC: define via AC_DEFUN_ONCE
Suggested by Adrian Bunk in
http://lists.gnu.org/archive/html/autoconf-patches/2012-09/msg00034.html
* NEWS:
* doc/autoconf.texi (C Compiler): Document it
* lib/autoconf/c.m4 (AC_PROG_CC): Implement it.
2012-10-16 13:41:34 -07:00
Paul Eggert
27eb3aef3e AC_PROG_CC_C89, AC_PROG_CC_C99: now obsolete; defer to AC_PROG_CC
* NEWS:
* doc/autoconf.texi (C Compiler, Running the Preprocessor)
(Limitations of Usual Tools, Present But Cannot Be Compiled)
(Obsolete Macros):
Document the changes described below.
* lib/autoconf/c.m4 (_AC_PROG_CC_FORCE_VERSION): Remove.
(AC_PROG_CC_C89, AC_PROG_CC_C99, AC_PROG_CC_STDC):
Just do AC_PROG_CC, but mark as obsolete.  This replaces my recent
ill-advised attempt to let AC_PROG_CC_C89 and AC_PROG_CC_C99 downgrade
the version of C supported.
* doc/autoconf.texi (Limitations of Usual Tools, Volatile Objects):
Document C11 more accurately.  In some cases this involves removing
some details about 'volatile', alas, since C11 changed this stuff.
Again.
2012-09-21 19:28:20 -07:00
Stefano Lattarini
6e7c2223e6 autoreconf: assume --force-missing automake option is supported
According to Automake's NEWS file, it is since at least Automake 1.8,
and in autoreconf we are already assuming aclocal >= 1.8 anyway.

* bin/autoreconf.in (parse_args): Simplify a little by just assuming
the automake option '--force-missing' is supported.
($automake_supports_force_missing): Delete, no longer needed.
* NEWS: Update.

Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
2012-09-21 21:42:19 +02:00
Stefano Lattarini
bc7e12e78e autoreconf: drop support for old (< 1.8) aclocal versions
The minimal automake and aclocal version required by the "most"
conservative important real world-projects (like Gnulib and Libvirt)
is 1.9 anyway (which is the version installed on old but still
supported installations of stable Distros like RHEL 5), so this
change should be safe and justified by now.

* bin/autoreconf.in (parse_args): Simplify by just assuming the aclocal
options '--force' and '--no-force' are supported and works correctly.
($aclocal_supports_force): Delete, no longer needed.
(run_aclocal): Heavily simplify by assuming that aclocal properly creates
'aclocal.m4' as lazily as possible.
* NEWS: Update.

Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
2012-09-21 21:42:15 +02:00
Paul Eggert
8e796471bf AC_PROG_CC_STDC: fold into AC_PROG_CC, removing C11 macro
* NEWS:
* doc/autoconf.texi (C Compiler): Document the following.
* lib/autoconf/c.m4 (AC_PROG_CC): Check for the latest C version
supported, not just C89.
(_AC_C_STD_TRY): Keep track of the options we add to bring
the C compiler up to standard, so that we can undo it if the
user later requests some other C standard.
(_AC_PROG_CC_FORCE_VERSION): New macro.
(AC_PROG_CC_C89, AC_PROG_CC_C99): Use it.  These macros now
have a documented side effect of changing the C version requested.
(AC_PROG_CC_C11): Remove.  It wasn't useful.
(AC_PROG_CC_STDC): Now an obsolescent alias for AC_PROG_CC.
(AC_C_PROTOTYPES): Allow any standard C version, not just c89.
Don't chatter, since we don't actually run any checking code.
* lib/autoconf/types.m4 (AC_TYPE_LONG_LONG_INT)
(AC_TYPE_UNSIGNED_LONG_LONG_INT): Treat C11 like C99.
* TODO: Remove the TODO item corresponding to the above.
2012-09-20 14:33:32 -07:00
Paul Eggert
787acdfaa7 AC_FUNC_VFORK: check for Solaris 2.4 signal-handling bug
* NEWS:
* doc/autoconf.texi (Particular Functions): Document this.
* lib/autoconf/functions.m4 (_AC_FUNC_VFORK): Check for the bug.
2012-09-16 16:42:20 -07:00
Paul Eggert
db36f6df60 AC_PROG_CC_C11: new macro, which AC_PROG_CC_STDC now defaults to
* NEWS:
* doc/autoconf.texi (C Compiler): Document this.
(Gnulib, Function Portability, Particular Functions)
(Header Portability, Particular Headers, Defining Symbols)
(Printing Messages, Limitations of Usual Tools)
(Preprocessor Arithmetic, Volatile Objects, Exiting Portably):
Modernize wording for C11.
* lib/autoconf/c.m4 (_AC_C_C99_TEST_HEADER, _AC_C_C99_TEST_BODY):
New macros, taken from _AC_PROG_CC_C99.  These are so that we can
also include the C99 tests in the C11 test program.
(_AC_PROG_CC_C99): Use them.
(_AC_PROG_CC_C11, AC_PROG_CC_C11): New macros.
(AC_PROG_CC_STDC): Prefer C11 to C99 or C89.
2012-08-23 12:46:20 -07:00
Stefano Lattarini
560f16b52d general: deprecate 'configure.in' as autoconf input
It has been years since that has been deprecated in the documentation,
in favour of 'configure.ac':

  Previous versions of Autoconf promoted the name configure.in, which
  is somewhat ambiguous (the tool needed to process this file is not
  described by its extension), and introduces a slight confusion with
  config.h.in and so on (for which '.in' means "to be processed by
  configure"). Using configure.ac is now preferred.

It's now time to start giving runtime warning about the use of
'configure.in', so that support for it can be removed in future
versions of autoconf/automake.

* lib/Autom4te/Configure_ac.pm: Issue a warning in the 'obsolete'
category if 'configure.in' is detected.  Since this module is synced
from Automake, this change is to be backported there (and will be
soon).
* doc/autoconf.texi: Update.
* tests/tools.at: Adjust to avoid spurious failures.

Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
2012-05-23 00:13:01 +02:00
Eric Blake
2d4eb95932 maint: post-release administrivia
* NEWS: Add header line for next release.
* .prev-version: Record previous version.
* cfg.mk (old_NEWS_hash): Auto-update.
2012-04-24 21:06:32 -06:00
Eric Blake
771017a433 Release Version 2.69.
* NEWS: Mention the release.

Signed-off-by: Eric Blake <eblake@redhat.com>
2012-04-24 21:04:26 -06:00