From 7fd2b883218d8bc9e6f291fd8c49c9ba38b8c058 Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Sat, 28 Aug 2010 18:04:46 +0200 Subject: [PATCH] Document new support for precompiled headers --- MANUAL.txt | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) diff --git a/MANUAL.txt b/MANUAL.txt index e20c573fb..15a63efe0 100644 --- a/MANUAL.txt +++ b/MANUAL.txt @@ -551,19 +551,24 @@ The drawbacks of using *CCACHE_BASEDIR* are: Precompiled headers ------------------- -ccache has support for GCC's precompiled headers. However, you currently have -to do two things to make it work: - -* You must add the *-fpch-preprocess* option when compiling, as this option - makes it possible for ccache to correctly detect the header file in the - preprocessor output. If you don't do this, either the non-preprocessed - version of the header file will be used (if available) or ccache will fall - back to running the real compiler and increase the statistics counter - ``preprocessor error'' (if the non-preprocessed header file is not - available). +ccache has support for GCC's precompiled headers. However, you have to do some +things to make it work properly: + * You must set *CCACHE_SLOPPINESS* to *time_macros*. The reason is that ccache can't tell whether *\_\_TIME\__* or *\_\_DATE__* is used when using a precompiled header. +* You must either: ++ +-- +** use the *-include* compiler option to include the precompiled header + (i.e., not use *#include* in the source code); or +** add the *-fpch-preprocess* compiler option when compiling. + +If you don't do this, either the non-precompiled version of the header file +will be used (if available) or ccache will fall back to running the real +compiler and increase the statistics counter ``preprocessor error'' (if the +non-precompiled header file is not available). +-- Sharing a cache -- 2.47.3