Update documentation of AC_USE_SYSTEM_EXTENSIONS.
commit4e310e78cbb0f85ec68a7356e9ed4dcb327ad046
authorZack Weinberg <zackw@panix.com>
Mon, 7 Dec 2020 22:17:40 +0000 (7 17:17 -0500)
committerZack Weinberg <zackw@panix.com>
Mon, 7 Dec 2020 22:17:40 +0000 (7 17:17 -0500)
tree06e3e9601d43b3e00afb354fb96fad2fc216fc56
parent5ab70f1769d21e48a9a4220d0b747b9da958e4d6
Update documentation of AC_USE_SYSTEM_EXTENSIONS.

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.
doc/autoconf.texi
lib/autoconf/specific.m4