ccache options to make the cache relocatable
This MR changes the ccache options to try and make the resulting cache relocatable.
This is building on top of an experiment which I've done with the lb-stack setup where I compile the entire stack in path/stack1/
and then reuse the same ccache for a second build in path/stack2
.
(More details: https://ccache.dev/manual/4.3.html#_compiling_in_different_directories)
Locally this worked, so I'm now trying to make the ccache in the nightlies relocatable, as that would mean one could download the resulting ccache to "jumpstart" a local build.
@clemenci I think that this should be a relatively safe MR, as I don't think this could impact the current ccache behavior where everything is in the same path /workspace/build/
anyway. (Hopefully I won't be proven wrong.)
There is another MR changing the compilation flags for debug builds, lcg-toolchains!71 (closed) such that the cache is also relocatable for those.
cc @rmatev