diff options
author | Josh Blum <josh@joshknows.com> | 2010-11-19 11:32:11 -0800 |
---|---|---|
committer | Josh Blum <josh@joshknows.com> | 2010-11-23 09:57:19 -0800 |
commit | ca42ba75a5dd7dff69c6cd802271d54c8309c5f3 (patch) | |
tree | 84140c70175d9144b9b4a0c7d9a4122a40aa5424 /host/config/Version.cmake | |
parent | 87fd34337c76562bb0930734d0a22f142588a63e (diff) | |
download | uhd-ca42ba75a5dd7dff69c6cd802271d54c8309c5f3.tar.gz uhd-ca42ba75a5dd7dff69c6cd802271d54c8309c5f3.tar.bz2 uhd-ca42ba75a5dd7dff69c6cd802271d54c8309c5f3.zip |
uhd: new versioning scheme with API compat number
Diffstat (limited to 'host/config/Version.cmake')
-rw-r--r-- | host/config/Version.cmake | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/host/config/Version.cmake b/host/config/Version.cmake index 9e4b6b306..214002b7b 100644 --- a/host/config/Version.cmake +++ b/host/config/Version.cmake @@ -18,9 +18,9 @@ ######################################################################## # Setup Version Numbers ######################################################################## -SET(UHD_VERSION_MAJOR 0) -SET(UHD_VERSION_MINOR 0) -SET(UHD_VERSION_PATCH 0) +SET(UHD_VERSION_MAJOR 0001) #API compatibility number +SET(UHD_VERSION_MINOR 0) #Timestamp of git commit +SET(UHD_VERSION_PATCH 0) #Short hash of git commit ######################################################################## # Find GIT to get repo information @@ -46,19 +46,12 @@ ELSE(${GIT} STREQUAL "GIT-NOTFOUND") OUTPUT_VARIABLE _git_timestamp OUTPUT_STRIP_TRAILING_WHITESPACE ) - #format the timestamp into YYYY-MM-DD + #format the timestamp into YYYY-MM-DD-HH-MM-SS EXECUTE_PROCESS( - COMMAND ${PYTHON_EXECUTABLE} -c "import time; print time.strftime('%Y%m%d', time.gmtime(${_git_timestamp}))" + COMMAND ${PYTHON_EXECUTABLE} -c "import time; print time.strftime('%Y%m%d%H%M%S', time.gmtime(${_git_timestamp}))" OUTPUT_VARIABLE _git_date OUTPUT_STRIP_TRAILING_WHITESPACE ) - SET(UHD_VERSION_MAJOR ${_git_date}) - - #format the timestamp into HH-MM-SS - EXECUTE_PROCESS( - COMMAND ${PYTHON_EXECUTABLE} -c "import time; print time.strftime('%H%M%S', time.gmtime(${_git_timestamp}))" - OUTPUT_VARIABLE _git_time OUTPUT_STRIP_TRAILING_WHITESPACE - ) - SET(UHD_VERSION_MINOR ${_git_time}) + SET(UHD_VERSION_MINOR ${_git_date}) #grab the git ref id for the current head EXECUTE_PROCESS( |