Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix that LLVM currently rebuilds unnecessarily when git HEAD changes.
This removes the file dependency between LLVM and the git HEAD file,
which currently causes that we rebuild LLVM/Cling/Dictionaries
once someone does anything meaningful in git.
  • Loading branch information
Teemperor committed Jul 26, 2017
commit 3bd83cecd05cd3e41a24cf2b21a499ddccaaea61
7 changes: 7 additions & 0 deletions interpreter/llvm/src/include/llvm/Support/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,13 @@ set(version_inc "${CMAKE_CURRENT_BINARY_DIR}/VCSRevision.h")

set(get_svn_script "${LLVM_CMAKE_PATH}/GenerateVersionFromCVS.cmake")

# Ugly hack to prevent rebuilding LLVM whenever the git HEAD timestamp
# changes. This is properly solved by setting LLVM_APPEND_VC_REV to OFF
# but this only really works once this review is included in our LLVM
# version: https://reviews.llvm.org/D35377
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't we backport it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's multiple commits that refactored this thing, D35377 is only the one that actually makes it fully work as intended (we don't even have the setting variable he's using in our CMake code yet), and backporting bigger pieces of CMake code isn't a lot of fun.

It's also just until the next LLVM upgrade where the other commit fixes this properly and we can drop this hack.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds reasonable to me, thanks for explaining.

# Once our LLVM version includes this review, this code can be removed
# as we properly set LLVM_APPEND_VC_REV in interpreter/CMakeLists.txt.
set(llvm_vc)
if(DEFINED llvm_vc)
# Create custom target to generate the VC revision include.
add_custom_command(OUTPUT "${version_inc}"
Expand Down