diff options
author | Brad King <brad.king@kitware.com> | 2019-02-14 15:14:11 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2019-02-14 15:14:47 (GMT) |
commit | 50ba2f019baa3e5487a975cb72059f1fc178f9d0 (patch) | |
tree | e75148951737edb1cc76eb532f1ee8583632b253 /Modules | |
parent | fd74eba1402d66a4d6a1af3442cf219d02f7cbc8 (diff) | |
parent | 6fc33829443ea3ef2dc8cc71c0a98b635bec6179 (diff) | |
download | CMake-50ba2f019baa3e5487a975cb72059f1fc178f9d0.zip CMake-50ba2f019baa3e5487a975cb72059f1fc178f9d0.tar.gz CMake-50ba2f019baa3e5487a975cb72059f1fc178f9d0.tar.bz2 |
Merge topic 'fix-legacy-implicit-includes'
6fc3382944 Update logic for sysroot in detected implicit include directories
2ad14ef4ea cmAlgorithms: Add cmHasPrefix to match existing cmHasSuffix
557b2d6e65 Fix regression in -I/usr/include exclusion logic
017598a444 macOS: Fix addition of <sdk>/usr/include to default implicit include dirs
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2957
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/Platform/Darwin.cmake | 2 | ||||
-rw-r--r-- | Modules/Platform/UnixPaths.cmake | 5 |
2 files changed, 1 insertions, 6 deletions
diff --git a/Modules/Platform/Darwin.cmake b/Modules/Platform/Darwin.cmake index a73ffba..5590433 100644 --- a/Modules/Platform/Darwin.cmake +++ b/Modules/Platform/Darwin.cmake @@ -214,7 +214,7 @@ include(Platform/UnixPaths) if(_CMAKE_OSX_SYSROOT_PATH AND EXISTS ${_CMAKE_OSX_SYSROOT_PATH}/usr/include) list(APPEND CMAKE_SYSTEM_PREFIX_PATH ${_CMAKE_OSX_SYSROOT_PATH}/usr) foreach(lang C CXX) - list(APPEND CMAKE_${lang}_IMPLICIT_INCLUDE_DIRECTORIES ${_CMAKE_OSX_SYSROOT_PATH}/usr/include) + list(APPEND _CMAKE_${lang}_IMPLICIT_INCLUDE_DIRECTORIES_INIT ${_CMAKE_OSX_SYSROOT_PATH}/usr/include) endforeach() endif() list(APPEND CMAKE_SYSTEM_PREFIX_PATH diff --git a/Modules/Platform/UnixPaths.cmake b/Modules/Platform/UnixPaths.cmake index 4ae4514..46c24bb 100644 --- a/Modules/Platform/UnixPaths.cmake +++ b/Modules/Platform/UnixPaths.cmake @@ -63,11 +63,6 @@ list(APPEND CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES /lib /lib32 /lib64 /usr/lib /usr/lib32 /usr/lib64 ) -# Platform-wide directories to avoid adding via -I<dir>. -list(APPEND CMAKE_PLATFORM_IMPLICIT_INCLUDE_DIRECTORIES - /usr/include - ) - # Default per-language values. These may be later replaced after # parsing the implicit directory information from compiler output. set(_CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES_INIT |