summaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorVladislav Vaintroub <wlad@mariadb.com>2017-09-20 23:58:26 +0000
committerVladislav Vaintroub <wlad@mariadb.com>2017-09-21 08:48:46 +0000
commit0f3735842f584412da6e119927ece5974cbc23f8 (patch)
tree9ee0eb581bbdd4c60be8a893b4c378359ac0653f /cmake
parentf70865bc9e540767d8afc3cc2cbe0e1c92a8c0be (diff)
downloadmariadb-git-0f3735842f584412da6e119927ece5974cbc23f8.tar.gz
MDEV-12583 : Bake the git hash into the binaries.
Added version_source_revision server "variable", for the git revision. Also , mysql -V will show git revision. "make dist" will now pack source_revision.h into the source package.
Diffstat (limited to 'cmake')
-rw-r--r--cmake/make_dist.cmake.in3
1 files changed, 3 insertions, 0 deletions
diff --git a/cmake/make_dist.cmake.in b/cmake/make_dist.cmake.in
index 3cc93d10fb8..6bd71cc7653 100644
--- a/cmake/make_dist.cmake.in
+++ b/cmake/make_dist.cmake.in
@@ -52,6 +52,9 @@ IF(GIT_EXECUTABLE)
ENDIF()
ENDIF()
+CONFIGURE_FILE(${CMAKE_BINARY_DIR}/include/source_revision.h
+ ${PACKAGE_DIR}/include/source_revision.h COPYONLY)
+
IF(NOT GIT_EXECUTABLE)
MESSAGE(STATUS "git not found or source dir is not a repo, use CPack")