BUG: Fixed construction of CMake_VERSION_DATE to use KWSys DateStamp feature now that cmVersion.cxx is not updated nightly anymore.
This commit is contained in:
parent
d1ad16f438
commit
70adbcee0d
|
@ -349,15 +349,10 @@ SET(CMake_VERSION_PATCH 0)
|
|||
# CVS versions are odd, if this is an odd minor version
|
||||
# then set the CMake_VERSION_DATE variable
|
||||
IF("${CMake_VERSION_MINOR}" MATCHES "[13579]$")
|
||||
# extract the version Date from the cmVersion.cxx file
|
||||
FILE(READ "${CMake_SOURCE_DIR}/Source/cmVersion.cxx"
|
||||
CMAKE_VERSION_FILE_CONTENT)
|
||||
STRING(REGEX MATCH "\\$Date: ([^ ]*) "
|
||||
CMake_VERSION_DATE "${CMAKE_VERSION_FILE_CONTENT}")
|
||||
STRING(REGEX REPLACE "\\$Date: ([^ ]*) " "\\1"
|
||||
CMake_VERSION_DATE "${CMake_VERSION_DATE}")
|
||||
STRING(REPLACE "/" "" CMake_VERSION_DATE
|
||||
"${CMake_VERSION_DATE}")
|
||||
INCLUDE(${CMake_SOURCE_DIR}/Source/kwsys/kwsysDateStamp.cmake)
|
||||
SET(CMake_VERSION_DATE
|
||||
"${KWSYS_DATE_STAMP_YEAR}${KWSYS_DATE_STAMP_MONTH}${KWSYS_DATE_STAMP_DAY}"
|
||||
)
|
||||
ENDIF("${CMake_VERSION_MINOR}" MATCHES "[13579]$")
|
||||
|
||||
SET(CMake_VERSION "${CMake_VERSION_MAJOR}.${CMake_VERSION_MINOR}")
|
||||
|
|
Loading…
Reference in New Issue