diff --git a/CMake/cotire.cmake b/CMake/cotire.cmake index edc948f..48a6bfa 100644 --- a/CMake/cotire.cmake +++ b/CMake/cotire.cmake @@ -3752,7 +3752,7 @@ else() set (COTIRE_UNITY_SOURCE_EXCLUDE_EXTENSIONS "m;mm" CACHE STRING "Ignore sources with the listed file extensions from the generated unity source.") - set (COTIRE_MINIMUM_NUMBER_OF_TARGET_SOURCES "3" CACHE STRING + set (COTIRE_MINIMUM_NUMBER_OF_TARGET_SOURCES "2" CACHE STRING "Minimum number of sources in target required to enable use of precompiled header.") if (NOT DEFINED COTIRE_MAXIMUM_NUMBER_OF_UNITY_INCLUDES_INIT) diff --git a/MANUAL.md b/MANUAL.md index 6b172c9..272b205 100644 --- a/MANUAL.md +++ b/MANUAL.md @@ -324,7 +324,7 @@ directories. A target inherits the property value from its enclosing directory. ### disabling precompiled headers for small targets The cache variable `COTIRE_MINIMUM_NUMBER_OF_TARGET_SOURCES` can be set to the minimum number of -source files required to enable the use of a precompiled header. It defaults to 3. To override the +source files required to enable the use of a precompiled header. It defaults to 2. To override the default, run `cmake` with the following options: $ cmake -D COTIRE_MINIMUM_NUMBER_OF_TARGET_SOURCES=5