summaryrefslogtreecommitdiff
path: root/BUILD
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mariadb.org>2015-12-29 19:37:11 +0400
committerAlexander Barkov <bar@mariadb.org>2015-12-29 19:37:11 +0400
commit2ba7ed77aab05004f0c853a77850e325b78a1892 (patch)
tree943659d76215e16d0d1946c28683c562debeff34 /BUILD
parent63f0669fd6dc430b60ffd5de0bff9854622a1c1a (diff)
parent1bb66ea88c4679d6bd3ad1472d75983e66f679ae (diff)
downloadmariadb-git-2ba7ed77aab05004f0c853a77850e325b78a1892.tar.gz
Merge remote-tracking branch 'origin/10.1' into 10.2
Diffstat (limited to 'BUILD')
-rwxr-xr-xBUILD/SETUP.sh14
1 files changed, 12 insertions, 2 deletions
diff --git a/BUILD/SETUP.sh b/BUILD/SETUP.sh
index 065422459b1..f443c5da680 100755
--- a/BUILD/SETUP.sh
+++ b/BUILD/SETUP.sh
@@ -256,6 +256,10 @@ fi
# (http://samba.org/ccache) is installed, use it.
# We use 'grep' and hope 'grep' will work as expected
# (returns 0 if finds lines)
+
+# As cmake doesn't like CC and CXX with a space, use symlinks from
+# /usr/lib64/ccache if they exits.
+
if test "$USING_GCOV" != "1"
then
# Not using gcov; Safe to use ccache
@@ -264,8 +268,14 @@ fi
if ccache -V > /dev/null 2>&1 && test "$CCACHE_GCOV_VERSION_ENABLED" = "1"
then
- echo "$CC" | grep "ccache" > /dev/null || CC="ccache $CC"
- echo "$CXX" | grep "ccache" > /dev/null || CXX="ccache $CXX"
+ if test -x /usr/lib64/ccache/gcc
+ then
+ CC=/usr/lib64/ccache/gcc
+ fi
+ if test -x /usr/lib64/ccache/g++
+ then
+ CXX=/usr/lib64/ccache/g++
+ fi
fi
# gcov