diff options
author | Brad King <brad.king@kitware.com> | 2021-08-10 13:22:37 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2021-08-10 13:22:52 (GMT) |
commit | 81aef41569bd3887524e680f55a36ccc00631efa (patch) | |
tree | 1e46e3595d5a049e69cf1458d0fa5fafb71d027f /Modules/CMakeFindBinUtils.cmake | |
parent | c949772c44b49e6328a98a7a1cb13338ff8a992b (diff) | |
parent | fc1f733cc7b312cd156b4d2aa6e8190e7def33b9 (diff) | |
download | CMake-81aef41569bd3887524e680f55a36ccc00631efa.zip CMake-81aef41569bd3887524e680f55a36ccc00631efa.tar.gz CMake-81aef41569bd3887524e680f55a36ccc00631efa.tar.bz2 |
Merge topic 'binutils-no-cmake-paths' into release-3.21
fc1f733cc7 BinUtils: Avoid searching CMAKE_PREFIX_PATH
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6434
Diffstat (limited to 'Modules/CMakeFindBinUtils.cmake')
-rw-r--r-- | Modules/CMakeFindBinUtils.cmake | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Modules/CMakeFindBinUtils.cmake b/Modules/CMakeFindBinUtils.cmake index f139ff4..d0beac6 100644 --- a/Modules/CMakeFindBinUtils.cmake +++ b/Modules/CMakeFindBinUtils.cmake @@ -33,7 +33,7 @@ function(__resolve_tool_path CMAKE_TOOL SEARCH_PATH DOCSTRING) if(NOT _CMAKE_USER_TOOL_PATH) # Find CMAKE_TOOL in the SEARCH_PATH directory by user-defined name. - find_program(_CMAKE_TOOL_WITH_PATH NAMES ${${CMAKE_TOOL}} HINTS ${SEARCH_PATH}) + find_program(_CMAKE_TOOL_WITH_PATH NAMES ${${CMAKE_TOOL}} HINTS ${SEARCH_PATH} NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH) if(_CMAKE_TOOL_WITH_PATH) # Overwrite CMAKE_TOOL with full path found in SEARCH_PATH. @@ -202,7 +202,7 @@ foreach(_CMAKE_TOOL IN LISTS _CMAKE_TOOL_VARS) endforeach() list(REMOVE_DUPLICATES _CMAKE_${_CMAKE_TOOL}_FIND_NAMES) - find_program(CMAKE_${_CMAKE_TOOL} NAMES ${_CMAKE_${_CMAKE_TOOL}_FIND_NAMES} HINTS ${_CMAKE_TOOLCHAIN_LOCATION}) + find_program(CMAKE_${_CMAKE_TOOL} NAMES ${_CMAKE_${_CMAKE_TOOL}_FIND_NAMES} HINTS ${_CMAKE_TOOLCHAIN_LOCATION} NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH) unset(_CMAKE_${_CMAKE_TOOL}_FIND_NAMES) endforeach() @@ -212,7 +212,7 @@ endif() if(CMAKE_PLATFORM_HAS_INSTALLNAME) - find_program(CMAKE_INSTALL_NAME_TOOL NAMES ${_CMAKE_TOOLCHAIN_PREFIX}install_name_tool HINTS ${_CMAKE_TOOLCHAIN_LOCATION}) + find_program(CMAKE_INSTALL_NAME_TOOL NAMES ${_CMAKE_TOOLCHAIN_PREFIX}install_name_tool HINTS ${_CMAKE_TOOLCHAIN_LOCATION} NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH) if(NOT CMAKE_INSTALL_NAME_TOOL) message(FATAL_ERROR "Could not find install_name_tool, please check your installation.") |