diff CMakeLists.txt @ 853:82ad6c0c601c

Add Elrood's patch to output LDC and LLVM source revs.
author Christian Kamm <kamm incasoftware de>
date Sun, 14 Dec 2008 16:51:36 +0100
parents 0a31c60a6bc1
children b52d5de7783f
line wrap: on
line diff
--- a/CMakeLists.txt	Sun Dec 14 16:39:27 2008 +0100
+++ b/CMakeLists.txt	Sun Dec 14 16:51:36 2008 +0100
@@ -160,6 +160,17 @@
 
 add_executable(${LDC_EXE} ${LDC_SOURCE_FILES})
 
+# generate revision info
+configure_file(revisions.pl.in revisions.pl)
+add_custom_command(
+	OUTPUT revisions.h
+	COMMAND ${PERL_EXECUTABLE} ${PROJECT_BINARY_DIR}/revisions.pl
+	WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/${DMDFE_PATH}
+)
+add_custom_target(gen_revs_h ALL DEPENDS revisions.h)
+add_dependencies(${LDC_EXE} gen_revs_h)
+#
+
 set(LDC_EXE_NAME ${PROGRAM_PREFIX}${LDC_EXE}${PROGRAM_SUFFIX})
 
 set_target_properties(