summaryrefslogtreecommitdiff
path: root/build-aux/config.sub
diff options
context:
space:
mode:
authorZack Weinberg <zackw@panix.com>2020-11-09 15:15:23 -0500
committerZack Weinberg <zackw@panix.com>2020-11-09 15:15:23 -0500
commit3b411849a0f97d6531d6a671ba5d7bc50e268df1 (patch)
tree350f84cbf72a9255028df4fbad8e565ae090a847 /build-aux/config.sub
parentd1a65dc04301a11b7fe33708489a9ab470cfe55f (diff)
downloadautoconf-3b411849a0f97d6531d6a671ba5d7bc50e268df1.tar.gz
m4sh: Require shell to support $(...) command substitution.
As of the 2020-11-07 update, config.sub and config.guess unconditionally use $(...) command substitution; see <https://lists.gnu.org/archive/html/config-patches/2020-11/msg00011.html>. Therefore, add this to the set of required shell features, searched for by _AS_DETECT_BETTER_SHELL. On a system where /bin/sh doesn’t support $(...), $CONFIG_SHELL will be set to one that does (and the primary configure script will be re-executed using that shell). AC_CANONICAL_* use $CONFIG_SHELL to execute config.guess/sub, so they will keep working. This also means that configure scripts and third-party macros that use $(...) will quietly start working correctly on such ancient systems. The test code is simple, but sufficient to weed out Solaris 10’s /bin/sh, which doesn’t support $(...) but *does* support shell functions. I’m not going to touch any of the existing uses of `...` command substitution in Autoconf proper for now, but it might make sense to bulk upgrade them early in the 2.71 release cycle; if nothing else, it would remove a major obstacle to running shellcheck over our scripts. * lib/m4sugar/m4sh.m4 (_AS_MODERN_CMDSUBST_WORKS): New macro. (AS_INIT, AS_SHELL_SANITIZE): Call _AS_DETECT_REQUIRED for _AS_MODERN_CMDSUBST_WORKS. * NEWS: Mention the requirement for $(...).
Diffstat (limited to 'build-aux/config.sub')
0 files changed, 0 insertions, 0 deletions