[CMake] Using ccache with Xcode generator

Gregor Jasny gjasny at googlemail.com
Mon Feb 1 15:03:05 EST 2016


Hello,

On 01/02/16 04:52, Craig Scott wrote:
> After a bit of experimenting, it seems that getting ccache working with the
> Xcode generator isn't so straightforward. For Ninja and Unix Makefiles, the
> RULE_LAUNCH_COMPILE global property nicely gives us the behaviour we want,
> but this doesn't work for Xcode. Under the constraint that we can't modify
> the build machines (meaning we can't assume ccache symlinks have been set
> up for the clang compiler set), is there a way to coax CMake to use ccache
> with Xcode? I know I could write a wrapper script to explicitly invoke
> ccache, but this seems like something CMake should be able to do without
> having to resort to that. Any suggestions?

I guess you will have to modify the SDK within Xcode to be able to
override the compiler for the SDK.

As far as I remember Bullseye has the same problem to solve:
http://www.bullseye.com/help/tool-xcode.html
Maybe you can have a look there.

Thanks,
Gregor


More information about the CMake mailing list