summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
* fortran: *mingw* → mingw* in previous patchPaul Eggert2021-09-011-1/+1
| | | | * lib/autoconf/fortran.m4 (_AC_FC_LIBRARY_LDFLAGS): Omit a ‘*’.
* fortran.m4: Filter mingw intrinsic librariesKeno Fischer2021-09-011-2/+2
| | | | | | | | * lib/autoconf/fortran.m4 (_AC_FC_LIBRARY_LDFLAGS): Filter out mingw libraries too. Problem and fix reported by Keno Fischer in https://lists.gnu.org/r/autoconf-patches/2021-09/msg00000.html Copyright-paperwork-exempt: Yes
* fix a typoJim Meyering2021-09-011-1/+1
| | | | * doc/autoconf.texi (Integer Overflow): Fix typo: s/many/may/
* Add commentary for Time::HiRes patchesPaul Eggert2021-08-313-0/+16
|
* Fix bug when autom4te updates too quicklyAndreas K. Hüttel2021-08-311-4/+5
| | | | | | Use stat from Time::HiRes (instead of File::stat). Problem reported by Ionen Wolkens <https://bugs.gentoo.org/782985>.
* Port AC_LANG_CALL(C) to C++Paul Eggert2021-08-311-1/+7
| | | | | * lib/autoconf/c.m4 (AC_LANG_CALL(C)): Add an extern "C" if C++. Problem reported by Vincent Lefèvre (sr #110532).
* Modernize discussion of integer overflowPaul Eggert2021-08-311-78/+95
| | | | | | | * doc/autoconf.texi (Integer Overflow, Integer Overflow Basics) (Signed Overflow Examples, Optimization and Wraparound): Modernize discussion to take current compiler and Gnulib technology into account.
* Port test to next m4 versionPaul Eggert2021-08-311-1/+11
| | | | | * tests/tools.at (autom4te cache): Allow m4 to quote 'like this' as well as 'like this'.
* Fortran Cray pointer macro supportMarshall Ward2021-08-163-2/+179
| | | | | | | | | | | | | | | | | | | This patch adds the AC_F77_CRAY_POINTERS and AC_FC_CRAY_POINTERS macros, which test if the Fortran compiler supports Cray pointers. The macros are written such that the tests share a common backend (_AC_FC_CRAY_POINTERS) which works on both F77 and FC compilers. Wrappers are provided to address any future potential compatibility issues. The macros include additional tests for particular flags required by GFortran and PGI compilers. The current set of flags is sparse, but can be extended for other compilers if needed. Documentation and a minimal test of the macro have been included. Two minor variable name typos (@EXEEXT@ as @EEXEXT@) were also fixed in two of the other Fortran tests.
* tests: typo fixEric Blake2021-08-121-1/+1
| | | | | * tests/base.at: Fix typo. Spotted by anonymous in https://savannah.gnu.org/support/?110526
* Autoconf now quotes 'like this' instead of `like this'Paul Eggert2021-07-2048-862/+866
| | | | | | | Autoconf’s diagnostics now follow current GNU coding standards, which say that diagnostics in the C locale should quote 'like this' with plain apostrophes instead of the older GNU style `like this' with grave accent and apostrophe.
* Document unquoted here-documents betterPaul Eggert2021-07-183-40/+38
| | | | | | | | | | | | | | | | | | | Problem reported by Bruno Haible (sr #110518). * doc/autoconf.texi (Generating Sources) (Running the Preprocessor, Running the Compiler) (Running the Linker, Runtime): Briefly mention that the program snippets are expanded as unquoted here-documents. (Here-Documents): Document escaping needed in unquoted here-documents. Remove mention of \" glitch in OpenBSD 2.7 sh; that old system has not been supported for many years. Remove advice that every \ must be quoted, as that sort of quoting (though harmless) is not needed and is rarely done. * lib/autoconf/c.m4 (AC_C_BIGENDIAN, _AC_LANG_OPENMP(Fortran 77)): * lib/autoconf/types.m4 (AC_TYPE_LONG_LONG_INT): Properly quote code snippets. The backslash-newline typos were harmless, and the backslash-$ typo has unspecified behavior as per POSIX though the typo is harmless on all shells I know of. However, Autoconf should follow its own quoting advice.
* doc: fix typo in variable nameEmanuele Giaquinta2021-06-301-1/+1
| | | | | Message-Id: <YJ4Tm3WEkv86L/YV@FSAPPLE2215.fi.f-secure.com> (tiny change)
* _AC_PROG_CXX_STDCXX_EDITION_TRY: fix typo in variable nameEmanuele Giaquinta2021-06-301-2/+2
| | | | | | | The typo causes "ac_prog_cxx_stdcxx" to be always set to "cxx11", regardless of whether the C++ compiler supports C++11. Message-Id: <YJ4TXAeJcvU0oSec@FSAPPLE2215.fi.f-secure.com> (tiny change)
* maint: advertise GNU in READMEEric Blake2021-05-101-1/+20
| | | | | | * README: Add section to attract more people towards the GNU project. Inspired by a suggestion from Jose E. Marchesi <jemarch@gnu.org> on the gnu-prog-discuss mailing list.
* maint: ensure autoconf-latest.* links stay up-to-dateEric Blake2021-05-101-0/+3
| | | | | * cfg.mk (GNUPLOADFLAGS): New. https://lists.gnu.org/archive/html/autoconf/2021-05/msg00006.html
* maint: Add names to THANKSEric Blake2021-05-101-1/+6
| | | | | | * THANKS: Add names that resulted in several recent commits. Also tweak addresses per owner requests. Signed-off-by: Eric Blake <eblake@redhat.com>
* update HACKING fileBen Elliston2021-05-101-2/+2
| | | | | | | Fairly obvious - be gender neutral in who gets thanked. * HACKING: Tweak pronouns. Message-Id: <20151125100819.GA29844@air.net.au> Signed-off-by: Eric Blake <eblake@redhat.com>
* trunk post-release administriviav2.72av2.62aZack Weinberg2021-01-283-2/+20
| | | | | | | | Matching the commits on the release branch: * NEWS: Bring over record of release notes. * .prev-version: Record previous version. * cfg.mk (old_NEWS_hash): Auto-update.
* make fetchZack Weinberg2021-01-2815-33/+45
|
* make update-copyrightZack Weinberg2021-01-2885-118/+147
|
* autoreconf: don’t error out when AM_GNU_GETTEXT is used alone.Zack Weinberg2021-01-041-7/+11
| | | | | | | | | | | | | | | Some projects intentionally don't call AM_GNU_GETTEXT_(REQUIRE_)VERSION because they have all of the gettext infrastructure checked into version control and they want autoreconf to _not_ run autopoint. Therefore, make the “AM_GNU_GETTEXT is used, but not AM_GNU_GETTEXT_(REQUIRE_)VERSION” and “AM_GNU_GETTEXT_(REQUIRE_)VERSION is used, but not AM_GNU_GETTEXT” diagnostics be warnings again, as they were in 2.69. (Technically these diagnostics were always errors, in the sense that they were reported with a call to Autom4te::Channels::error(), but prior to 2.70, error() calls made by autoreconf did not cause autoreconf to exit unsuccessfully, due to an unrelated bug. So people came to depend on these diagnostics not being fatal.)
* doc: Document another portability problem of 'od'.Bruno Haible2020-12-301-2/+21
| | | | | * doc/autoconf.texi (Limitations of Usual Tools): Document that decimal output is not portable.
* doc: modernize grep discussionPaul Eggert2020-12-301-6/+6
|
* autom4te: always update the output file, even if it hasn’t changedZack Weinberg2020-12-292-1/+49
| | | | | | | | | | | | | Automake generates a Makefile rule for regenerating the configure script, that relies on an invocation of ‘autoconf’ always bumping the timestamp on the configure script, even if it hasn’t changed. The patch to make autom4te update the output file atomically (1725c947144d9bebfe7817c2c5f0d53d884b1297) broke this. Fixes several failures in automake’s test suite. * bin/autom4te.in (handle_output): Always call update_file with force=1. * tests/tools.at (autoconf: timestamp changes): New test.
* Restore compatibility with older std-gnu11.m4.Zack Weinberg2020-12-237-400/+1384
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Gnulib’s std-gnu11.m4 backports C11 and C++11 detection to autoconf 2.69. It does this by replacing the definitions of AC_PROC_CC and AC_PROG_CXX and most of their subroutines. In particular, it replaces the definitions of _AC_PROG_CC_C11, _AC_PROG_CC_C99, and _AC_C_STD_TRY, but it does *not* replace the definition of _AC_PROG_CC_C89. Autoconf commit 131d8c69f31dc6fc8dc93abe1096d52d1fe19fd3 changed the calling convention of _AC_C_STD_TRY, and changed the internal definitions of _AC_PROG_CC_C{11,99,89} to match. If std-gnu11.m4 is in use, our _AC_PROG_CC_C89 calls their _AC_C_STD_TRY with the new calling convention, and this produces a syntactically invalid configure script. (This is is fortunate: it could easily have been a runtime malfunction that only manifested with compilers that only implement C89, and then we might not have noticed the problem for years.) Gnulib commit a3b3fc85e3e632374811b27cb2111e50fa177e36 makes std-gnu11.m4 do nothing when used with autoconf >=2.70, but older versions of the file will circulate for years to come, so this patch works around the problem in autoconf. It does this by renaming all of the internal macros involved with C and C++ standard edition detection, *except* _AC_PROG_CC_C89. AC_PROG_CC now calls _AC_PROG_CC_STDC_EDITION, which loops over all supported editions calling _AC_PROG_CC_STDC_EDITION_TRY, which uses the data provided by the existing _AC_C_C${edition}_TEST_PROGRAM macros and a new set of macros called _AC_C_C${edition}_OPTIONS to perform the test for that edition of the standard. Similarly, AC_PROG_CXX calls _AC_PROG_CXX_STDCXX_EDITION, which loops calling _AC_PROG_CXX_STDCXX_EDITION_TRY, which uses data from _AC_CXX_CXX${edition}_TEST_PROGRAM and _AC_CXX_CXX${edition}_OPTIONS. _AC_PROG_CC_C89 is the only macro from the old set that we still define, and its definition is reverted to what std-gnu11.m4 expects it to be. Nothing in Autoconf proper uses it anymore. foreign.at grows a test to verify that the compatibility stub version of _AC_PROG_CC_C89 does its job. Since this is now the third test involving an embedded copy of a third-party macro, I broke them all out of foreign.at to separate files in test/data/. In addition to fixing the breakage, this patch should make it easier to extend C / C++ standard edition detection in the future, by getting rid of the if-else chains in AC_PROG_CC/CXX and by disentangling the lists of command-line options to test from the logic. I also changed the manual to suggest people refer to the variables ‘ac_prog_cc_stdc’ and ‘ac_prog_cxx_stdcxx’ to learn which edition of the C and C++ standards are selected; these are much easier to work with than the ac_cv_prog_cc_cNN cache variables. * lib/autoconf/c.m4 (_AC_C_STD_TRY, _AC_PROG_CC_C99, _AC_PROG_CC_C11) (_AC_CXX_STD_TRY, _AC_PROG_CXX_CXX98, _AC_PROG_CXX_CXX11): Remove macro. (_AC_C_C89_OPTIONS, _AC_C_C99_OPTIONS, _AC_C_C11_OPTIONS) (_AC_PROG_CC_STDC_EDITION, _AC_PROG_CC_STDC_EDITION_TRY) (_AC_CXX_CXX98_OPTIONS, _AC_CXX_CXX11_OPTIONS) (_AC_PROG_CXX_STDCXX_EDITION, _AC_PROG_CXX_STDCXX_EDITION_TRY): New macros. (_AC_PROG_CC_C89): Convert to compatibility stub for std-gnu11.m4. (AC_PROG_CC): Use _AC_PROG_CC_STDC_EDITION. (AC_PROG_CXX): Use _AC_PROG_CXX_STDCXX_EDITION. * tests/data/ax_prog_cc_for_build_v18.m4 * tests/data/ax_prog_cxx_for_build_v3.m4 * tests/data/gnulib_std_gnu11_2020_08_17.m4: New files. * tests/foreign.at (AX_PROG_CC_FOR_BUILD, AX_PROG_CXX_FOR_BUILD): Remove embedded copy of ax_prog_cc_for_build_v18.m4, ax_prog_cxx_for_build_v3.m4 respectively. (gnulib-std-gnu11.m4): New test. * tests/local.mk: Distribute tests/data/*.m4. * doc/autoconf.texi (AC_PROG_CC, AC_PROG_CXX): Document use of ac_prog_cc_stdc / ac_prog_cxx_stdcxx, respectively, to tell which edition of the C / C++ standards are selected, instead of looking through a series of cache variables with awkward definitions.
* Use -fno-builtin, not -Werror, in AC_CHECK_DECLS (#110400)Zack Weinberg2020-12-234-95/+95
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | clang issues only a warning, not an error, when an undeclared identifier that names a built-in function is used: for instance char *(*p)(const char *, int) = strchr; (with no `#include <string.h>`) is an error with most compilers, a warning with clang. This broke the 2.69 implementation of AC_CHECK_DECL. In commit 82ef7805faffa151e724aa76c245ec590d174580, we tried to work around this quirk by using -Werror, but that put us at risk of being tripped up by other warnings. Bug 110400 reports, for instance, that this fragment (which is roughly what you get, after preprocessing, when AC_CHECK_DECL is applied to a function that *is* properly declared) extern void ac_decl (int, char *); int main (void) { (void) ac_decl; ; return 0; } provokes a warning from clang (and thus an error) when -Wextra-semi-stmt has been added to CFLAGS earlier in the configure script. The extra semicolon comes from AC_LANG_PROGRAM, and we can’t get rid of it because we have no way of telling reliably when someone wrote something like AC_LANG_PROGRAM([[#include <stdio.h>]], [[puts("hello world")]]) with no semicolon at the end of the statement; this has been acceptable for decades. Besides, that’s just one warning, who knows what compilers will start complaining about tomorrow? So: change AC_CHECK_DECL to compile its programs with -fno-builtin, instead, when the default compilation mode fails to detect an undeclared strchr. The code is restructured so that we can try other options as well, if we find another compiler with the same quirk but different command-line syntax. (All of this logic is very C-family specific, but it appears to me that AC_CHECK_DECL has never worked with other languages, so we can continue to live with that for now.) Fixes bug 110400; partially reverts 82ef7805faffa151e724aa76c245ec590d174580. * lib/autoconf/general.m4 (_AC_UNDECLARED_WARNING): Rename to _AC_UNDECLARED_BUILTIN. Instead of looking at diagnostic output, loop trying to find a command-line option that makes the compiler error out on undeclared builtins. (_AC_CHECK_DECL_BODY): Don’t AC_REQUIRE anything here. Make shell code language-agnostic, except for the actual test program. Add arguments to the shell function for additional compiler options to use. (AC_CHECK_DECL): AC_REQUIRE _AC_UNDECLARED_BUILTIN here. Supply $ac_{AC_LANG_ABBREV}_undeclared_builtin_options to ac_fn_check_decl. * tests/local.at (AT_CONFIG_CMP): Update list of variables to ignore when comparing C and C++ configure runs. * tests/semantics.at (AC_CHECK_DECLS): Add memcpy and strchr to AC_CHECK_DECLS call for functions that may be known to the compiler. * doc/autoconf.texi (AC_CHECK_DECL, AC_CHECK_DECLS): Remove note about compiler warnings.
* autom4te: correct error message when we can’t create autom4te.cache.Zack Weinberg2020-12-232-7/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While testing something else, I noticed that autom4te may print a nonsensical error message when it fails to create autom4te.cache, because it checks again whether the directory already exists before giving up, and this clobbers errno. Instead of doing (the perl equivalent of) test -d $cache || mkdir $cache || test -d $cache call mkdir unconditionally. If it fails with an errno code other than EEXIST, consider that a hard failure; if it fails with EEXIST, check whether the thing that exists is in fact a directory. (A symlink to a directory qualifies; I wouldn’t be surprised if people are moving autom4te.cache around with symlinks.) Either way, if we fail, report strerror(errno) from the original mkdir failure. Also, print the current working directory as part of the error message; this aids debugging when you’re working with a big hairy nested tree. * bin/autom4te.in: Don’t check whether autom4te.cache exists before attempting to create it. Only stat autom4te.cache if mkdir fails with EEXIST, otherwise fail immediately. Make sure to report the errno code from mkdir, not the subsequent stat (if any). Report the current working directory as part of the error message. * tests/tools.at: Verify that autom4te reports the actual reason when it fails to create autom4te.cache. Verify that failure to create autom4te.cache because that name exists, but isn’t a directory, is detected.
* Merge branch 'branch-2.70' into masterPaul Eggert2020-12-124-15/+22
|\
| * Improve AC_USE_SYSTEM_EXTENSIONS port to HP-UX 11.11Paul Eggert2020-12-111-0/+6
| | | | | | | | | | | | * lib/autoconf/specific.m4 (AC_USE_SYSTEM_EXTENSIONS): Define _HPUX_ALT_XOPEN_SOCKET_API, for HP-UX 11.11. This patch is adapted from Gnulib.
| * Port minor AC_HEADER_MAJOR fixes from GnulibPaul Eggert2020-12-111-4/+4
| | | | | | | | | | * lib/autoconf/headers.m4 (AC_HEADER_MAJOR): Improve m4 quoting.
| * Port minor AC_FUNC_ALLOCA fixes from GnulibPaul Eggert2020-12-111-5/+5
| | | | | | | | | | | | | | * lib/autoconf/functions.m4 (_AC_LIBOBJ_ALLOCA, AC_FUNC_ALLOCA): Use ' not ` in generated comments, as per current GNU coding style. (_AC_LIBOBJ_ALLOCA): Use plain # instead of unnecessary quadrigraph. This patch is adapted from Gnulib.
| * Improve port of AC_C_RESTRICT to Oracle C++Paul Eggert2020-12-111-6/+7
| | | | | | | | | | | | | | | | Problem reported by Christian Biesinger in: https://lists.gnu.org/r/bug-gnulib/2019-12/msg00159.html * lib/autoconf/c.m4 (AC_C_RESTRICT): Port better to Oracle Developer Studio C++ 12.5 or later. This patch is adapted from Gnulib.
| * _AC_PROG_CC_C99: fix typo (#110396)Zack Weinberg2020-12-081-1/+1
| | | | | | | | | | | | | | | | | | _AC_PROG_CC_C99 was using the wrong test program. Fixes #110396, reported anonymously. * lib/autoconf/c.m4 (_AC_PROG_CC_C99): Use the C99 test program, not the C89 test program.
| * maint: add outline for future NEWS (release branch).Zack Weinberg2020-12-081-1/+2
| |
* | _AC_PROG_CC_C99: fix typo (#110396)Zack Weinberg2020-12-081-1/+1
| | | | | | | | | | | | | | | | | | _AC_PROG_CC_C99 was using the wrong test program. Fixes #110396, reported anonymously. * lib/autoconf/c.m4 (_AC_PROG_CC_C99): Use the C99 test program, not the C89 test program.
* | maint: add outline for future NEWSZack Weinberg2020-12-081-0/+4
|/
* maint: post-release administriviaZack Weinberg2020-12-083-2/+5
| | | | | | * NEWS: Add header line for next release. * .prev-version: Record previous version. * cfg.mk (old_NEWS_hash): Auto-update.
* Release 2.70.v2.70Zack Weinberg2020-12-081-1/+1
|
* Remove obsolete instructions from HACKING.Zack Weinberg2020-12-081-4/+1
| | | | | configure CC=g++ is no longer supported, so don’t tell maintainers to test that.
* testsuite: log version of M4 and PerlZack Weinberg2020-12-082-0/+4
| | | | | | | | | | | Jannick reported problems on OSX for which the most plausible explanation is that the system-provided M4 is emitting error messages with different line numbers than we expect, perhaps because Apple froze their copy of GNU M4 to the last GPLv2 release. To test this hypothesis, add $PERL and $M4 to AT_TESTED in our testsuite. * tests/atlocal.in: Also set $M4 from configure. * tests/local.at: Add AT_TESTED([$PERL $M4]).
* lib/autotest/general.m4: typo fixZack Weinberg2020-12-081-1/+1
| | | | | | | | | The absolute-path case in AT_TESTED had a typo in it, causing bizarre error messages and preventing programs identified by absolute path from being logged properly. * lib/autotest/general.m4 (AT_TESTED): Fix typoed shell syntax in handling of programs identified by absolute path.
* Three minor testsuite fixes.Zack Weinberg2020-12-082-9/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. To insulate the test suite from a system-provided config.site file, set the CONFIG_SITE environment variable to a file that is known not to exist. Problem reported by Jannick. 2. AC_PROG_CC, AC_PROG_CXX, AC_PROG_CPP, and AC_PROG_CXXCPP may set cache variables named ‘ac_cv_prog_$tool’ or ‘ac_cv_prog_ac_ct_$tool’, depending on system conditions; _AT_CONFIG_CMP_PRUNE needs to handle both possibilities. Found by testing on FreeBSD 12; I have no idea why it didn’t show up on _any_ of my other test platforms. 3. The ‘AC_PROG_LEX with yywrap’ test needs to be skipped on systems that don’t provide libl.a nor libfl.a. This change needed yet another hook for AT_CHECK_MACRO. Found by testing on Alpine Linux. (Ideally, instead of skipping this test, we would test that this configure script *errors out* on these systems, but that would involve much more invasive changes to AT_CHECK_MACRO, which I don’t want to hold the release for.) * tests/local.at (AT_PREPARE_TESTS): Set CONFIG_SITE to refer to a file that is known not to exist, and export it. (_AT_CONFIG_CMP_PRUNE): Prune all variables matching the ERE ‘ac_cv_prog_(ac_ct_)?(CC|CXX|CPP|CXXCPP)’. (AT_CHECK_MACRO): Add PRETEST-CMDS argument which takes commands to execute immediately after AT_SETUP. * tests/semantics.at (AC_PROG_LEX with yywrap): Using PRETEST-CMDS, skip this test on OSes where neither -ll nor -lfl provides a definition of yywrap.
* autoreconf --install --force: replace install-sh with no timestampZack Weinberg2020-12-082-13/+26
| | | | | | | | | | | | | Old versions of install-sh did not have a timestamp line. Therefore, treat the absence of a timestamp line as indicating a very old file (that --install --force should replace), not as an error. Problem reported by Pascal Terjan. * bin/autoreconf.in (extract_time_stamp): Return 1970-01-01 when no timestamp line is found. * tests/torture.at (Missing auxiliary files (--force)): Test replacement of old install-sh with no timestamp line.
* make fetchZack Weinberg2020-12-071-1/+2
|
* Update documentation of AC_USE_SYSTEM_EXTENSIONS.Zack Weinberg2020-12-072-72/+111
| | | | | | | | | | | | | | | | | | | | | | | The list of macros documented as being defined by AC_USE_SYSTEM_EXTENSIONS had gotten out of sync with the actual list. Update it thoroughly. Also, I introduced an error into the commentary when I merged Julien ÉLIE’s patch to define _NETBSD_SOURCE and _OPENBSD_SOURCE in AC_USE_SYSTEM_EXTENSIONS. _OPENBSD_SOURCE does something on NetBSD and *doesn’t* do anything on OpenBSD. This is corrected. Clean up the code in AC_USE_SYSTEM_EXTENSIONS a bit while I’m in there; we now had a redundant definition of _NETBSD_SOURCE (one unconditional and one conditional on minix/config.h existing). Reorganize the macro to make it easier to catch problems like this in the future. * lib/autoconf/specific.m4 (AC_USE_SYSTEM_EXTENSIONS): Reorganize; remove redundant AC_DEFINE of _NETBSD_SOURCE; add some missing AC_BEFOREs; use _AC_CHECK_HEADER_ONCE for header checks; revise all commentary. * doc/autoconf.texi (AC_USE_SYSTEM_EXTENSIONS): Update.
* Revise documentation of AT_CHECK.Zack Weinberg2020-12-071-42/+58
| | | | Patch originally by Jannick but then about 10x more words added by me.
* Revise documentation of AC_PROG_CC and comments on conformance checks.Zack Weinberg2020-12-072-100/+97
| | | | | | | | | | | | | Makes the documentation of AC_PROG_CC consistent with the documentation of AC_PROG_CXX. Also removes a bunch of redundant text from c.m4 and adds lists of the headers that *can* be used in the conformance tests, so future hackers don’t have to look them up. * doc/autoconf.texi (AC_PROG_CC): Make description consistent with description of AC_PROG_CXX. * lib/autoconf/c.m4: Clean up some outdated or repetitive commentary and add lists of the freestanding headers above the code that needs to avoid using non-freestanding headers.
* Add checks of __STDC__ and __STDC_VERSION__ to C conformance tests.Zack Weinberg2020-12-071-0/+17
| | | | | | | | | | | | | This makes the C conformance tests more consistent with the C++ conformance tests, and should also speed up cycling through the possible options to turn on C99/C11. Tested with gcc, clang, SunPRO C, and AIX xlc. * lib/autoconf/c.m4 (_AC_C_C89_TEST_GLOBALS): Add preprocessor test for __STDC__ being defined (to any value). (_AC_C_C99_TEST_GLOBALS, _AC_C_C11_TEST_GLOBALS): Add preprocessor test of the value of __STDC_VERSION__.
* autom4te: don’t crash when warnings have no stacktraceZack Weinberg2020-12-071-0/+2
| | | | | | | | | | | | | In testing on Darwin (OSX), sometimes warnings reported from M4 code reach autom4te with no stack trace at all, causing the perl script to crash with a “use of uninitialized value” error. The root cause of the problem is not clear to me, but the script certainly shouldn’t crash. Problem found by Jannick <thirdedition@gmx.net>. * bin/autom4te.in: When processing warnings, make sure $stacktrace is defined.