diff options
author | Brad King <brad.king@kitware.com> | 2021-08-10 13:27:21 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2021-08-10 13:27:29 (GMT) |
commit | 82828401b06b1e04123cea5956fbbfcd604df4b4 (patch) | |
tree | 85458fbf3083bf77ec92f773b2cd8ac81b1b517b | |
parent | 1b3d892ac2b1650f07ae89a80665f1965dbb21be (diff) | |
parent | 7ef5255e1efdcbf48a62a3711b9f75ea69671c6e (diff) | |
download | CMake-82828401b06b1e04123cea5956fbbfcd604df4b4.zip CMake-82828401b06b1e04123cea5956fbbfcd604df4b4.tar.gz CMake-82828401b06b1e04123cea5956fbbfcd604df4b4.tar.bz2 |
Merge topic 'armclang-compiler-deps'
7ef5255e1e armclang: activate compiler dependencies generation
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6433
-rw-r--r-- | Modules/Compiler/ARMClang-C.cmake | 8 | ||||
-rw-r--r-- | Modules/Compiler/ARMClang-CXX.cmake | 8 |
2 files changed, 16 insertions, 0 deletions
diff --git a/Modules/Compiler/ARMClang-C.cmake b/Modules/Compiler/ARMClang-C.cmake index 0a64a8a..01c4cea 100644 --- a/Modules/Compiler/ARMClang-C.cmake +++ b/Modules/Compiler/ARMClang-C.cmake @@ -2,6 +2,14 @@ include(Compiler/Clang-C) include(Compiler/ARMClang) __compiler_armclang(C) +if((NOT DEFINED CMAKE_DEPENDS_USE_COMPILER OR CMAKE_DEPENDS_USE_COMPILER) + AND CMAKE_GENERATOR MATCHES "Makefiles|WMake" + AND CMAKE_DEPFILE_FLAGS_C) + # dependencies are computed by the compiler itself + set(CMAKE_C_DEPFILE_FORMAT gcc) + set(CMAKE_C_DEPENDS_USE_COMPILER TRUE) +endif() + set(CMAKE_C90_STANDARD_COMPILE_OPTION "-std=c90") set(CMAKE_C90_EXTENSION_COMPILE_OPTION "-std=gnu90") set(CMAKE_C90_STANDARD__HAS_FULL_SUPPORT ON) diff --git a/Modules/Compiler/ARMClang-CXX.cmake b/Modules/Compiler/ARMClang-CXX.cmake index 5dfb401..045b783 100644 --- a/Modules/Compiler/ARMClang-CXX.cmake +++ b/Modules/Compiler/ARMClang-CXX.cmake @@ -1,3 +1,11 @@ include(Compiler/Clang-CXX) include(Compiler/ARMClang) __compiler_armclang(CXX) + +if((NOT DEFINED CMAKE_DEPENDS_USE_COMPILER OR CMAKE_DEPENDS_USE_COMPILER) + AND CMAKE_GENERATOR MATCHES "Makefiles|WMake" + AND CMAKE_DEPFILE_FLAGS_CXX) + # dependencies are computed by the compiler itself + set(CMAKE_CXX_DEPFILE_FORMAT gcc) + set(CMAKE_CXX_DEPENDS_USE_COMPILER TRUE) +endif() |