From: Zack Weinberg Date: Wed, 26 Aug 2020 19:15:34 +0000 (-0400) Subject: Add ‘START_TIME’ and ‘ToD’ to shell variable filter list. X-Git-Tag: v2.69c~28 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f783dd434a077305ea5d1edb0d928f233736aadf;p=thirdparty%2Fautoconf.git Add ‘START_TIME’ and ‘ToD’ to shell variable filter list. NetBSD sh has invented more magic shell variables with values related to the current time: ‘START_TIME’ and ‘ToD’. Like ‘SECONDS’, these can cause spurious testsuite failures and should be filtered out when checking for undesirable changes to the environment. * tests/local.at (_AT_CHECK_ENV, AT_CONFIG_CMP): Add shell variables START_TIME and ToD to filter list. --- diff --git a/tests/local.at b/tests/local.at index 0fe1c343..a875b5e0 100644 --- a/tests/local.at +++ b/tests/local.at @@ -326,7 +326,7 @@ m4_define([AT_CHECK_CONFIGURE], # - AC_SUBST'ed variables # (FIXME: Generate a list of these automatically.) # - _|@|.[*#?$].|argv|ARGC|LINENO|OLDPWD|PIPESTATUS|RANDOM|SECONDS -# |_AST_FEATURES +# |START_TIME|ToD|_AST_FEATURES # Some variables some shells use and change. # `.[*#?$].' catches `$#' etc. which are displayed like this: # | '!'=18186 @@ -377,7 +377,7 @@ if test -f state-env.before && test -f state-env.after; then [GREP|[EF]GREP|SED], [[_@]|.[*#?$].], [argv|ARGC|LINENO|BASH_ARGC|BASH_ARGV|OLDPWD|PIPESTATUS|RANDOM], - [SECONDS|_AST_FEATURES]))=' \ + [SECONDS|START_TIME|ToD|_AST_FEATURES]))=' \ $act_file || test $? -eq 1 || echo failed >&2 ) 2>stderr-$act_file | @@ -408,6 +408,8 @@ fi # - PPID [bash, zsh] # - RANDOM [bash, zsh] # - SECONDS [bash, zsh] +# - START_TIME [NetBSD sh] +# - ToD [NetBSD sh] # - '$' [zsh] # - argv [zsh] # - ARGC [zsh] @@ -437,6 +439,8 @@ do /^PPID=/ d /^RANDOM=/ d /^SECONDS=/ d + /^START_TIME=/ d + /^ToD=/ d /'\'\\\$\''=/ d /^argv=/ d /^ARGC=/ d