ruby-changes:53811
From: nobu <ko1@a...>
Date: Tue, 27 Nov 2018 17:39:45 +0900 (JST)
Subject: [ruby-changes:53811] nobu:r66029 (trunk): .travis.yml: avoid bashism
nobu 2018-11-27 17:39:40 +0900 (Tue, 27 Nov 2018) New Revision: 66029 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=66029 Log: .travis.yml: avoid bashism GCC_FLAGS is not an array and CC is finally passed to configure as single string. Pass CC via the environment variable, so it does not need to be quoted anymore. Modified files: trunk/.travis.yml Index: .travis.yml =================================================================== --- .travis.yml (revision 66028) +++ .travis.yml (revision 66029) @@ -336,11 +336,11 @@ before_script: https://github.com/ruby/ruby/blob/trunk/.travis.yml#L336 - "ccache --show-stats" - |- case "$CC" in - gcc*) the_gcc=(ccache $CC ${GCC_FLAGS[@]} -fno-diagnostics-color) ;; - clang*) the_gcc=(ccache $CC ${GCC_FLAGS[@]} -fno-color-diagnostics) ;; + gcc*) CC="ccache $CC${GCC_FLAGS:+ }$GCC_FLAGS -fno-diagnostics-color";; + clang*) CC="ccache $CC${GCC_FLAGS:+ }$GCC_FLAGS -fno-color-diagnostics";; esac - "[ ! -f config.cache ] || [ \"$CC\" = \"`sed -n s/^ac_cv_prog_CC=//p config.cache`\" ] || (set -x; exec rm config.cache)" - - "$SETARCH ../configure -C --disable-install-doc --prefix=/tmp/ruby-prefix --with-gcc=\"${the_gcc[*]}\" $CONFIG_FLAG" + - "$SETARCH ../configure -C --disable-install-doc --prefix=/tmp/ruby-prefix $CONFIG_FLAG" - "cp -pr config.cache config.status .ext/include ../config_1st" - "$SETARCH make reconfig" - "cp -pr config.cache config.status .ext/include ../config_2nd" -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/