[PATCH] D37272: [cmake] Stop putting the revision info in LLVM_VERSION_STRING

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 29 14:45:29 PDT 2017


This revision was automatically updated to reflect the committed changes.
Closed by commit rL312043: [cmake] Stop putting the revision info in LLVM_VERSION_STRING (authored by rnk).

Changed prior to commit:
  https://reviews.llvm.org/D37272?vs=113150&id=113163#toc

Repository:
  rL LLVM

https://reviews.llvm.org/D37272

Files:
  llvm/trunk/CMakeLists.txt
  llvm/trunk/docs/CMake.rst
  llvm/trunk/include/llvm/Support/CMakeLists.txt


Index: llvm/trunk/CMakeLists.txt
===================================================================
--- llvm/trunk/CMakeLists.txt
+++ llvm/trunk/CMakeLists.txt
@@ -203,10 +203,6 @@
 option(LLVM_APPEND_VC_REV
   "Embed the version control system revision id in LLVM" ON)
 
-if( LLVM_APPEND_VC_REV )
-  add_version_info_from_vcs(PACKAGE_VERSION)
-endif()
-
 set(PACKAGE_NAME LLVM)
 set(PACKAGE_STRING "${PACKAGE_NAME} ${PACKAGE_VERSION}")
 set(PACKAGE_BUGREPORT "http://llvm.org/bugs/")
Index: llvm/trunk/docs/CMake.rst
===================================================================
--- llvm/trunk/docs/CMake.rst
+++ llvm/trunk/docs/CMake.rst
@@ -248,9 +248,10 @@
 
 **LLVM_APPEND_VC_REV**:BOOL
   Embed version control revision info (svn revision number or Git revision id).
-  This is used among other things in the LLVM version string (stored in the
-  PACKAGE_VERSION macro). For this to work cmake must be invoked before the
-  build. Defaults to ON.
+  The version info is provided by the ``LLVM_REVISION`` macro in
+  ``llvm/include/llvm/Support/VCSRevision.h``. Developers using git who don't
+  need revision info can disable this option to avoid re-linking most binaries
+  after a branch switch. Defaults to ON.
 
 **LLVM_ENABLE_THREADS**:BOOL
   Build with threads support, if available. Defaults to ON.
Index: llvm/trunk/include/llvm/Support/CMakeLists.txt
===================================================================
--- llvm/trunk/include/llvm/Support/CMakeLists.txt
+++ llvm/trunk/include/llvm/Support/CMakeLists.txt
@@ -46,7 +46,7 @@
       RESULT_VARIABLE files_not_equal
       OUTPUT_QUIET
       ERROR_QUIET)
-  # Remove ${version_inc} if it's empty -- toggling LLMV_APPEND_VC_REV
+  # Remove ${version_inc} if it's empty -- toggling LLVM_APPEND_VC_REV
   # from OFF to ON.
   if(NOT files_not_equal)
     file(REMOVE "${version_inc}")


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D37272.113163.patch
Type: text/x-patch
Size: 1868 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170829/f4bb81e4/attachment.bin>


More information about the llvm-commits mailing list