On 04/18/2013 01:15 PM, Mathias De Maré wrote:
Now, I actually have another issue which is partly related.
It seems building for multiple targets with the preprocessor mode and compiler option '-g' doesn't work for us.
The preprocessed file contains the location where the build is executed.
An example:
# 1 "src/foo.cpp"
# 1 "/home/mdemare/testdir/target2//" <--- this is an issue!
# 1 "<built-in>"
# 1 "<command-line>"
# 1 "src/foo.cpp"
int main() {
    return 0;
}
If I build for one target in '/home/mdemare/testdir/target1' and for another target in '/home/mdemare/testdir/target2', this results in a cache miss. Using the direct mode (since there is no preprocessing), this issue does not occur.

I'm not 100% sure, but I think this is something that ccache should change when using 'CCACHE_BASEDIR'.
Apparently, it's possible to use the gcc option '-fno-working-directory'. This gets rid of the issue for the example above.

Greetings,
Mathias
_______________________________________________
ccache mailing list
[email protected]
https://lists.samba.org/mailman/listinfo/ccache

Reply via email to