CMakeLists.txt

changeset 40
809a75a7113b
parent 37
c82a86ea87be
child 42
9528f8d06962
--- a/CMakeLists.txt	Sat Jun 06 22:03:00 2015 +0300
+++ b/CMakeLists.txt	Sat Jun 06 22:18:30 2015 +0300
@@ -76,6 +76,14 @@
 	)
 endif()
 
+add_custom_target (make_hginfo
+	COMMAND python
+		"${CMAKE_SOURCE_DIR}/updaterevision.py"
+		"${CMAKE_CURRENT_BINARY_DIR}/hginfo.h"
+	WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})
+
+add_dependencies (${PROJECT_NAME} make_hginfo)
+
 # With clang, we need to set -Wno-deprecated since Qt headers seem to use the register keyword
 # which clang doesn't seem to like.
 if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")

mercurial