summaryrefslogtreecommitdiff
path: root/scripts/launch-cxx.in
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/launch-cxx.in')
-rw-r--r--scripts/launch-cxx.in10
1 files changed, 10 insertions, 0 deletions
diff --git a/scripts/launch-cxx.in b/scripts/launch-cxx.in
new file mode 100644
index 0000000000..23f107ce48
--- /dev/null
+++ b/scripts/launch-cxx.in
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+# Xcode generator doesn't include the compiler as the
+# first argument, Ninja and Makefiles do. Handle both cases.
+if [ "$1" = "${CMAKE_CXX_COMPILER}" ] ; then
+ shift
+fi
+
+export CCACHE_CPP2=true
+exec "${CXX_LAUNCHER}" "${CMAKE_CXX_COMPILER}" "$@" \ No newline at end of file