]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Export (if possible) svn info in compat mode
authormaier <maier@0785d39b-7218-0410-832d-ea1e28bc413d>
Wed, 6 Mar 2013 10:04:49 +0000 (10:04 +0000)
committermaier <maier@0785d39b-7218-0410-832d-ea1e28bc413d>
Wed, 6 Mar 2013 10:04:49 +0000 (10:04 +0000)
git-svn-id: https://svn.dealii.org/branches/branch_cmake@28745 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/cmake/config/CMakeLists.txt

index 8233cac8dcae5a9adf1efd4e6213217dc3d113c9..14577be01f3505ab47848ef951cd9e9d127edde8 100644 (file)
@@ -210,9 +210,19 @@ IF(DEAL_II_COMPONENT_COMPAT_FILES)
     COMPONENT compat_files
     )
 
-  INSTALL(FILES
-    DESTINATION ${CMAKE_INSTALL_PREFIX}
-    COMPONENT compat_files
-    )
+  #
+  # Export some information about the current svn revision:
+  #
+  FIND_PACKAGE(Subversion REQUIRED)
+  IF(SUBVERSION_FOUND AND EXISTS ${CMAKE_SOURCE_DIR}/.svn)
+    SUBVERSION_WC_INFO(${CMAKE_SOURCE_DIR} _svn)
+    FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/SVN.info "${_svn_WC_INFO}")
+    INSTALL(FILES
+      ${CMAKE_CURRENT_BINARY_DIR}/SVN.info
+      DESTINATION common
+      COMPONENT compat_files
+      )
+  ENDIF()
+
 ENDIF()
 

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.