From 682f58a0e1d45d691970944117d893bdb523fc3e Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Fri, 11 Nov 2022 21:03:14 +0100 Subject: [PATCH] doc: Add hint about using -fno-pch-timestamp for PCH with Clang --- doc/MANUAL.adoc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/doc/MANUAL.adoc b/doc/MANUAL.adoc index 31651f50d..98ca1f236 100644 --- a/doc/MANUAL.adoc +++ b/doc/MANUAL.adoc @@ -1710,8 +1710,8 @@ directories: == Precompiled headers -Ccache has support for GCC's precompiled headers. However, you have to do some -things to make it work properly: +Ccache has support for precompiled headers with GCC and Clang. However, you have +to do some things to make it work properly: * You must set <> to *pch_defines,time_macros*. The reason is that ccache can't tell whether `+__TIME__+`, `+__DATE__+` or @@ -1734,6 +1734,8 @@ things to make it work properly: compiling. -- + +* If you use Clang, you must compile with `-fno-pch-timestamp`. + 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 "`Preprocessing failed`" (if the non-precompiled -- 2.47.2