diff options
Diffstat (limited to 'mkspecs/features/unix/ccache.prf')
-rw-r--r-- | mkspecs/features/unix/ccache.prf | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/mkspecs/features/unix/ccache.prf b/mkspecs/features/unix/ccache.prf new file mode 100644 index 0000000000..d5739d3eab --- /dev/null +++ b/mkspecs/features/unix/ccache.prf @@ -0,0 +1,19 @@ +macx-xcode: return() + +darwin: load(sdk) + +ccache_prefix = ccache + +precompile_header { + CCACHE_SLOPPINESS += pch_defines time_macros + + ccache_prefix = \ + CCACHE_SLOPPINESS=\"$$join(CCACHE_SLOPPINESS, ',')\$${CCACHE_SLOPPINESS+,\$$CCACHE_SLOPPINESS}\" \ + # Make sure we build sources directly, not from their preprocessed version, + # otherwise precompiled headers will not be used during cache misses. + CCACHE_CPP2=true \ + $$ccache_prefix +} + +for(tool, $$list(QMAKE_CC QMAKE_CXX QMAKE_LINK QMAKE_LINK_SHLIB QMAKE_LINK_C)): \ + $$tool = $$ccache_prefix $$eval($$tool) |