diff options
author | DRC <information@virtualgl.org> | 2015-10-17 18:55:08 -0500 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2015-10-27 14:11:21 +0100 |
commit | 872e5dd859074567c3befbda9225e08710d13669 (patch) | |
tree | 355bf38c9a6a92a7a0ba0ac7332272759ed4d0a5 | |
parent | 2a2e2c3611e660da3f30744cb720bf363a4d3a01 (diff) | |
download | tigervnc-872e5dd859074567c3befbda9225e08710d13669.tar.gz tigervnc-872e5dd859074567c3befbda9225e08710d13669.zip |
Allow BUILD_TIMESTAMP to be set statically
-rw-r--r-- | CMakeLists.txt | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 904809c2..d788b602 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -39,12 +39,9 @@ if(MSVC) message(FATAL_ERROR "TigerVNC cannot be built with Visual Studio. Please use MinGW") endif() -set(BUILD_TIMESTAMP "") -execute_process(COMMAND "date" "+%Y-%m-%d %H:%M" OUTPUT_VARIABLE BUILD_TIMESTAMP) - if(NOT BUILD_TIMESTAMP) set(BUILD_TIMESTAMP "") -else() + execute_process(COMMAND "date" "+%Y-%m-%d %H:%M" OUTPUT_VARIABLE BUILD_TIMESTAMP) string(REGEX REPLACE "\n" "" BUILD_TIMESTAMP ${BUILD_TIMESTAMP}) endif() @@ -57,6 +54,7 @@ endif() message(STATUS "CMAKE_BUILD_TYPE = ${CMAKE_BUILD_TYPE}") message(STATUS "VERSION = ${VERSION}") +message(STATUS "BUILD_TIMESTAMP = ${BUILD_TIMESTAMP}") add_definitions(-DBUILD_TIMESTAMP="${BUILD_TIMESTAMP}") # We want to keep our asserts even in release builds so remove NDEBUG |