diff options
author | Brad King <brad.king@kitware.com> | 2016-03-16 13:07:58 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2016-03-16 13:07:58 (GMT) |
commit | 7fff134735d774a27b3d2fb5ddb16f5b9f9bbeb6 (patch) | |
tree | b73025c41f3a010419763909331654d6c403db16 | |
parent | 98f3edcec96b3854126c37e9a44915e77fcd9867 (diff) | |
parent | 6d74e7870b8804a5af0bc395a9fbb45c1b3d26a4 (diff) | |
download | CMake-7fff134735d774a27b3d2fb5ddb16f5b9f9bbeb6.zip CMake-7fff134735d774a27b3d2fb5ddb16f5b9f9bbeb6.tar.gz CMake-7fff134735d774a27b3d2fb5ddb16f5b9f9bbeb6.tar.bz2 |
Merge topic 'ninja-depfile-system-headers'
6d74e787 Ninja: Add dependencies on system-provided header files (#14914)
-rw-r--r-- | Help/release/dev/ninja-depfile-system-headers.rst | 5 | ||||
-rw-r--r-- | Modules/Compiler/GNU.cmake | 2 | ||||
-rw-r--r-- | Modules/Compiler/Intel-C.cmake | 2 | ||||
-rw-r--r-- | Modules/Compiler/Intel-CXX.cmake | 2 | ||||
-rw-r--r-- | Modules/Compiler/QCC.cmake | 2 |
5 files changed, 9 insertions, 4 deletions
diff --git a/Help/release/dev/ninja-depfile-system-headers.rst b/Help/release/dev/ninja-depfile-system-headers.rst new file mode 100644 index 0000000..7033cef --- /dev/null +++ b/Help/release/dev/ninja-depfile-system-headers.rst @@ -0,0 +1,5 @@ +ninja-depfile-system-headers +---------------------------- + +* The :generator:`Ninja` generator now includes system header files in build + dependencies to ensure correct re-builds when system packages are updated. diff --git a/Modules/Compiler/GNU.cmake b/Modules/Compiler/GNU.cmake index d1ca85e..c2d393d 100644 --- a/Modules/Compiler/GNU.cmake +++ b/Modules/Compiler/GNU.cmake @@ -41,7 +41,7 @@ macro(__compiler_gnu lang) # distcc does not transform -o to -MT when invoking the preprocessor # internally, as it ought to. Work around this bug by setting -MT here # even though it isn't strictly necessary. - set(CMAKE_DEPFILE_FLAGS_${lang} "-MMD -MT <OBJECT> -MF <DEPFILE>") + set(CMAKE_DEPFILE_FLAGS_${lang} "-MD -MT <OBJECT> -MF <DEPFILE>") endif() # Initial configuration flags. diff --git a/Modules/Compiler/Intel-C.cmake b/Modules/Compiler/Intel-C.cmake index dfba4b2..77363eb 100644 --- a/Modules/Compiler/Intel-C.cmake +++ b/Modules/Compiler/Intel-C.cmake @@ -6,7 +6,7 @@ set(CMAKE_C_FLAGS_MINSIZEREL_INIT "-Os -DNDEBUG") set(CMAKE_C_FLAGS_RELEASE_INIT "-O3 -DNDEBUG") set(CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-O2 -g -DNDEBUG") -set(CMAKE_DEPFILE_FLAGS_C "-MMD -MT <OBJECT> -MF <DEPFILE>") +set(CMAKE_DEPFILE_FLAGS_C "-MD -MT <OBJECT> -MF <DEPFILE>") set(CMAKE_C_CREATE_PREPROCESSED_SOURCE "<CMAKE_C_COMPILER> <DEFINES> <INCLUDES> <FLAGS> -E <SOURCE> > <PREPROCESSED_SOURCE>") set(CMAKE_C_CREATE_ASSEMBLY_SOURCE "<CMAKE_C_COMPILER> <DEFINES> <INCLUDES> <FLAGS> -S <SOURCE> -o <ASSEMBLY_SOURCE>") diff --git a/Modules/Compiler/Intel-CXX.cmake b/Modules/Compiler/Intel-CXX.cmake index 7947695..02c636c 100644 --- a/Modules/Compiler/Intel-CXX.cmake +++ b/Modules/Compiler/Intel-CXX.cmake @@ -6,7 +6,7 @@ set(CMAKE_CXX_FLAGS_MINSIZEREL_INIT "-Os -DNDEBUG") set(CMAKE_CXX_FLAGS_RELEASE_INIT "-O3 -DNDEBUG") set(CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT "-O2 -g -DNDEBUG") -set(CMAKE_DEPFILE_FLAGS_CXX "-MMD -MT <OBJECT> -MF <DEPFILE>") +set(CMAKE_DEPFILE_FLAGS_CXX "-MD -MT <OBJECT> -MF <DEPFILE>") set(CMAKE_CXX_CREATE_PREPROCESSED_SOURCE "<CMAKE_CXX_COMPILER> <DEFINES> <INCLUDES> <FLAGS> -E <SOURCE> > <PREPROCESSED_SOURCE>") set(CMAKE_CXX_CREATE_ASSEMBLY_SOURCE "<CMAKE_CXX_COMPILER> <DEFINES> <INCLUDES> <FLAGS> -S <SOURCE> -o <ASSEMBLY_SOURCE>") diff --git a/Modules/Compiler/QCC.cmake b/Modules/Compiler/QCC.cmake index 76477e4..f69c7bd 100644 --- a/Modules/Compiler/QCC.cmake +++ b/Modules/Compiler/QCC.cmake @@ -20,5 +20,5 @@ macro(__compiler_qcc lang) set(CMAKE_${lang}_COMPILE_OPTIONS_TARGET "-V") set(CMAKE_INCLUDE_SYSTEM_FLAG_${lang} "-Wp,-isystem,") - set(CMAKE_DEPFILE_FLAGS_${lang} "-Wc,-MMD,<DEPFILE>,-MT,<OBJECT>,-MF,<DEPFILE>") + set(CMAKE_DEPFILE_FLAGS_${lang} "-Wc,-MD,<DEPFILE>,-MT,<OBJECT>,-MF,<DEPFILE>") endmacro() |