]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
test: Fix failure in gcc pch suite when using compiler with options
authorJoel Rosdahl <joel@rosdahl.net>
Sat, 27 Jan 2018 14:26:15 +0000 (15:26 +0100)
committerJoel Rosdahl <joel@rosdahl.net>
Sat, 27 Jan 2018 14:26:15 +0000 (15:26 +0100)
Need to remember any extra compiler options in REAL_COMPILER as well.

test.sh

diff --git a/test.sh b/test.sh
index 6fb7ad854bd691037ef558118d26238092581f8d..af569204712dd3fe14189ea3723d65c88ee8b3f2 100755 (executable)
--- a/test.sh
+++ b/test.sh
@@ -3565,7 +3565,11 @@ upgrade
 input_charset
 "
 
-REAL_COMPILER=$(find_compiler $COMPILER)
+compiler_bin=$(echo $COMPILER | awk '{print $1}')
+compiler_args=$(echo $COMPILER | awk '{$1 = ""; print}')
+real_compiler_bin=$(find_compiler $compiler_bin)
+REAL_COMPILER="$real_compiler_bin$compiler_args"
+
 if [ "$REAL_COMPILER" = "$COMPILER" ]; then
     echo "Compiler:         $COMPILER"
 else