mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-09-25 04:09:36 +03:00
CMakeDetermineSystem: Do not try to lookup 'uname' in CMAKE_SYSROOT
We find `uname` before the toolchain file has been included, so the user has not yet been able to set `CMAKE_FIND_ROOT_PATH_MODE_PROGRAM`. If `CMAKE_SYSROOT` is passed via the command line, avoid searching in it.
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
|
||||
# find out on which system cmake runs
|
||||
if(CMAKE_HOST_UNIX)
|
||||
find_program(CMAKE_UNAME NAMES uname PATHS /bin /usr/bin /usr/local/bin)
|
||||
find_program(CMAKE_UNAME NAMES uname PATHS /bin /usr/bin /usr/local/bin NO_CMAKE_FIND_ROOT_PATH)
|
||||
if(CMAKE_UNAME)
|
||||
if(CMAKE_HOST_SYSTEM_NAME STREQUAL "AIX")
|
||||
execute_process(COMMAND ${CMAKE_UNAME} -v
|
||||
|
||||
Reference in New Issue
Block a user