Skip to content

Commit

Permalink
[CMake] Support symlinks even with LLVM_INSTALL_TOOLCHAIN_ONLY
Browse files Browse the repository at this point in the history
When LLVM_INSTALL_TOOLCHAIN_ONLY is used and LLVM_TOOLCHAIN_TOOLS
contains a tool which is a symlink, it would be ignored. This already
worked before but got broken in r282510.

Differential Revision: https://reviews.llvm.org/D25067

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282844 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
petrhosek committed Sep 30, 2016
1 parent d203a8f commit 156ae09
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cmake/modules/AddLLVM.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -1264,11 +1264,11 @@ function(add_llvm_tool_symlink name dest)
set_target_properties(${target_name} PROPERTIES FOLDER Tools)

# Make sure both the link and target are toolchain tools
if (NOT ${name} IN_LIST LLVM_TOOLCHAIN_TOOLS OR NOT ${dest} IN_LIST LLVM_TOOLCHAIN_TOOLS)
return()
if (${name} IN_LIST LLVM_TOOLCHAIN_TOOLS AND ${dest} IN_LIST LLVM_TOOLCHAIN_TOOLS)
set(TOOL_IS_TOOLCHAIN ON)
endif()

if (NOT LLVM_INSTALL_TOOLCHAIN_ONLY AND LLVM_BUILD_TOOLS )
if ((TOOL_IS_TOOLCHAIN OR NOT LLVM_INSTALL_TOOLCHAIN_ONLY) AND LLVM_BUILD_TOOLS)
llvm_install_symlink(${name} ${dest})
endif()
endif()
Expand Down

0 comments on commit 156ae09

Please sign in to comment.