]> Savannah Git Hosting - gnulib.git/commitdiff
test-framework-sh: Don't require bash on Windows and OS/2.
authorBruno Haible <bruno@clisp.org>
Sat, 7 Oct 2017 09:52:45 +0000 (11:52 +0200)
committerBruno Haible <bruno@clisp.org>
Sat, 7 Oct 2017 09:53:13 +0000 (11:53 +0200)
Reported by KO Myung-Hun.

* tests/test-init.sh: Use 'shopt' only when running in bash.

ChangeLog
tests/init.sh

index 470012f4b91e46f3e458effde3db78b241c79cfd..8d18287c7a44d3dba882ab236537c9e433a9dda5 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2017-10-07  Bruno Haible  <bruno@clisp.org>
+
+       test-framework-sh: Don't require bash on Windows and OS/2.
+       Reported by KO Myung-Hun.
+       * tests/test-init.sh: Use 'shopt' only when running in bash.
+
 2017-10-06  KO Myung-Hun  <komh@chollian.net>
 
        wcwidth: check a macro version of wcwidth () as well
index 470605c116631af8d1950d6615f63e53e93d5416..0821c572ae71aef4d5dd9913e8470b7b61c5ab25 100644 (file)
@@ -250,7 +250,7 @@ test -n "$BASH_VERSION" && unalias -a
 # That is part of the shell-selection test above.  Why use aliases rather
 # than functions?  Because support for hyphen-containing aliases is more
 # widespread than that for hyphen-containing function names.
-test -n "$EXEEXT" && shopt -s expand_aliases
+test -n "$EXEEXT" && test -n "$BASH_VERSION" && shopt -s expand_aliases
 
 # Enable glibc's malloc-perturbing option.
 # This is useful for exposing code that depends on the fact that