aboutsummaryrefslogtreecommitdiffstats
path: root/host/cmake
diff options
context:
space:
mode:
authorAndrej Rode <andrej.rode@ettus.com>2017-02-27 10:14:27 -0800
committerMartin Braun <martin.braun@ettus.com>2018-03-07 16:21:51 -0800
commit4aca39fdca5ca160d2294f16877db1fdc60cc6b5 (patch)
tree4fee3402a5cf675c8ea02b2115659667da03d07a /host/cmake
parent3645139e7d51d92f4bfe4148eefad2c22b40147a (diff)
downloaduhd-4aca39fdca5ca160d2294f16877db1fdc60cc6b5.tar.gz
uhd-4aca39fdca5ca160d2294f16877db1fdc60cc6b5.tar.bz2
uhd-4aca39fdca5ca160d2294f16877db1fdc60cc6b5.zip
cmake: add manual override option to UHD_VERSION
Diffstat (limited to 'host/cmake')
-rw-r--r--host/cmake/Modules/UHDVersion.cmake4
1 files changed, 3 insertions, 1 deletions
diff --git a/host/cmake/Modules/UHDVersion.cmake b/host/cmake/Modules/UHDVersion.cmake
index a15d03ddf..a4ad23188 100644
--- a/host/cmake/Modules/UHDVersion.cmake
+++ b/host/cmake/Modules/UHDVersion.cmake
@@ -125,7 +125,9 @@ ENDIF()
########################################################################
-IF(TRIM_UHD_VERSION STREQUAL "True")
+IF(DEFINED UHD_VERSION)
+ SET(UHD_VERSION "${UHD_VERSION}" CACHE STRING "Set UHD_VERSION to a custom value")
+ELSEIF(TRIM_UHD_VERSION STREQUAL "True")
SET(UHD_VERSION "${UHD_VERSION_MAJOR}.${UHD_VERSION_API}.${UHD_VERSION_ABI}.${UHD_VERSION_PATCH}-${UHD_GIT_HASH}")
ELSE()
SET(UHD_VERSION "${UHD_VERSION_MAJOR}.${UHD_VERSION_API}.${UHD_VERSION_ABI}.${UHD_VERSION_PATCH}-${UHD_GIT_COUNT}-${UHD_GIT_HASH}")