summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorGregor Jasny <gjasny@googlemail.com>2017-02-19 16:28:49 (GMT)
committerGregor Jasny <gjasny@googlemail.com>2017-02-19 18:27:34 (GMT)
commit717e1f3056b45e79dcb433b1098e8b6fd813d07b (patch)
tree655535217dd51189cc9940ecea95593c919eba00 /Modules
parent0bbd993f618e4ded1d949e64ba778dfab3106262 (diff)
downloadCMake-717e1f3056b45e79dcb433b1098e8b6fd813d07b.zip
CMake-717e1f3056b45e79dcb433b1098e8b6fd813d07b.tar.gz
CMake-717e1f3056b45e79dcb433b1098e8b6fd813d07b.tar.bz2
Use looked up uname path for command execution
Diffstat (limited to 'Modules')
-rw-r--r--Modules/CMakeDetermineSystem.cmake8
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/CMakeDetermineSystem.cmake b/Modules/CMakeDetermineSystem.cmake
index fb1a9ed..f34ec5d 100644
--- a/Modules/CMakeDetermineSystem.cmake
+++ b/Modules/CMakeDetermineSystem.cmake
@@ -35,9 +35,9 @@
if(CMAKE_HOST_UNIX)
find_program(CMAKE_UNAME uname /bin /usr/bin /usr/local/bin )
if(CMAKE_UNAME)
- exec_program(uname ARGS -r OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_VERSION)
+ exec_program(${CMAKE_UNAME} ARGS -r OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_VERSION)
if(CMAKE_HOST_SYSTEM_NAME MATCHES "Linux|CYGWIN.*|Darwin|^GNU$")
- exec_program(uname ARGS -m OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR
+ exec_program(${CMAKE_UNAME} ARGS -m OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR
RETURN_VALUE val)
if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Darwin" AND
CMAKE_HOST_SYSTEM_PROCESSOR STREQUAL "Power Macintosh")
@@ -48,10 +48,10 @@ if(CMAKE_HOST_UNIX)
exec_program(arch ARGS -s OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR
RETURN_VALUE val)
else()
- exec_program(uname ARGS -p OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR
+ exec_program(${CMAKE_UNAME} ARGS -p OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR
RETURN_VALUE val)
if("${val}" GREATER 0)
- exec_program(uname ARGS -m OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR
+ exec_program(${CMAKE_UNAME} ARGS -m OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR
RETURN_VALUE val)
endif()
endif()