[Cmake-commits] CMake branch, next, updated. v3.6.1-1117-gf6773d2
Chuck Atkins
chuck.atkins at kitware.com
Thu Aug 4 15:26:54 EDT 2016
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".
The branch, next has been updated
via f6773d23c4ca2cf59726734aba131f2be36307f0 (commit)
via 388147085e26ec8e8589640f2492cccfe14f3f8b (commit)
from a67e5b8ce377c119914fa8e0983defbbd3daf146 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=f6773d23c4ca2cf59726734aba131f2be36307f0
commit f6773d23c4ca2cf59726734aba131f2be36307f0
Merge: a67e5b8 3881470
Author: Chuck Atkins <chuck.atkins at kitware.com>
AuthorDate: Thu Aug 4 15:26:52 2016 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Thu Aug 4 15:26:52 2016 -0400
Merge topic 'update-cle-version-info' into next
38814708 CrayLinuxEnvironment: Add alternative methods to retrive version info
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=388147085e26ec8e8589640f2492cccfe14f3f8b
commit 388147085e26ec8e8589640f2492cccfe14f3f8b
Author: Chuck Atkins <chuck.atkins at kitware.com>
AuthorDate: Thu Aug 4 14:46:10 2016 -0400
Commit: Chuck Atkins <chuck.atkins at kitware.com>
CommitDate: Thu Aug 4 13:20:37 2016 -0600
CrayLinuxEnvironment: Add alternative methods to retrive version info
diff --git a/Modules/Platform/CrayLinuxEnvironment.cmake b/Modules/Platform/CrayLinuxEnvironment.cmake
index 97771a2..301eb85 100644
--- a/Modules/Platform/CrayLinuxEnvironment.cmake
+++ b/Modules/Platform/CrayLinuxEnvironment.cmake
@@ -8,14 +8,22 @@ if(DEFINED ENV{CRAYOS_VERSION})
set(CMAKE_SYSTEM_VERSION "$ENV{CRAYOS_VERSION}")
elseif(DEFINED ENV{XTOS_VERSION})
set(CMAKE_SYSTEM_VERSION "$ENV{XTOS_VERSION}")
-else()
- message(FATAL_ERROR "Neither the CRAYOS_VERSION or XTOS_VERSION environment variables are defined. This platform file should be used inside the Cray Linux Environment for targeting compute nodes (NIDs)")
+elseif(EXISTS /etc/opt/cray/release/cle-release)
+ file(STRINGS /etc/opt/cray/release/cle-release release REGEX "^RELEASE=.*")
+ string(REGEX REPLACE "^RELEASE=(.*)$" "\\1" CMAKE_SYSTEM_VERSION "${release}")
+ unset(release)
+elseif(EXISTS /etc/opt/cray/release/clerelease)
+ file(READ /etc/opt/cray/release/clerelease CMAKE_SYSTEM_VERSION)
endif()
# Guard against multiple messages
if(NOT __CrayLinuxEnvironment_message)
- set(__CrayLinuxEnvironment_message 1)
- message(STATUS "Cray Linux Environment ${CMAKE_SYSTEM_VERSION}")
+ set(__CrayLinuxEnvironment_message 1 CACHE BOOL "" FORCE)
+ if(NOT CMAKE_SYSTEM_VERSION)
+ message(STATUS "CrayLinuxEnvironment: Unable to determine CLE version. This platform file should only be used from inside the Cray Linux Environment for targeting compute nodes (NIDs).")
+ else()
+ message(STATUS "Cray Linux Environment ${CMAKE_SYSTEM_VERSION}")
+ endif()
endif()
# All cray systems are x86 CPUs and have been for quite some time
-----------------------------------------------------------------------
Summary of changes:
Modules/Platform/CrayLinuxEnvironment.cmake | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list