diff options
author | Kevin Smith <git@kismith.co.uk> | 2011-07-09 20:50:55 (GMT) |
---|---|---|
committer | Kevin Smith <git@kismith.co.uk> | 2011-07-09 20:56:48 (GMT) |
commit | 1c2cd11645b33aadee31c37e15f4a24d6ae37587 (patch) | |
tree | 06fc3a2ea87f064fb45b07e59d0a29f1dd2e4e8f /BuildTools | |
parent | 42fd41ae9b0a5e4472805dc34b49587b3b50b092 (diff) | |
download | swift-contrib-1c2cd11645b33aadee31c37e15f4a24d6ae37587.zip swift-contrib-1c2cd11645b33aadee31c37e15f4a24d6ae37587.tar.bz2 |
Allow ccache when compiling from xcode
Diffstat (limited to 'BuildTools')
-rw-r--r-- | BuildTools/SCons/SConstruct | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/BuildTools/SCons/SConstruct b/BuildTools/SCons/SConstruct index d752348..4a4f9ab 100644 --- a/BuildTools/SCons/SConstruct +++ b/BuildTools/SCons/SConstruct @@ -264,6 +264,9 @@ if target in ["iphone-device", "iphone-simulator", "xcode"] : # Set the build flags env["CC"] = "$XCODE_PLATFORM_DEVELOPER_BIN_DIR/gcc" env["CXX"] = "$XCODE_PLATFORM_DEVELOPER_BIN_DIR/g++" + if env.get("ccache", False): + env["CC"] = "ccache " + env["CC"] + env["CXX"] = "ccache " + env["CXX"] env["OBJCCFLAGS"] = ["-fobjc-abi-version=2", "-fobjc-legacy-dispatch"] env["LD"] = env["CC"] env.Append(CCFLAGS = env["XCODE_ARCH_FLAGS"] + ["-fvisibility=hidden"]) |