diff options
author | Petr Hosek <phosek@chromium.org> | 2019-05-22 21:08:33 +0000 |
---|---|---|
committer | Petr Hosek <phosek@chromium.org> | 2019-05-22 21:08:33 +0000 |
commit | 56f468064aa7c2557f5099cf4f87692866b1787f (patch) | |
tree | 39b8b599c3d7b9ac4418148261f0f7b7ac793e91 /runtimes | |
parent | 64e37aff5f40e23e85c792bc6f500b923a0ed034 (diff) | |
download | llvm-56f468064aa7c2557f5099cf4f87692866b1787f.tar.gz |
[runtimes] Move libunwind, libc++abi and libc++ to lib/$target/c++ and include/c++
This change is a consequence of the discussion in "RFC: Place libs in
Clang-dedicated directories", specifically the suggestion that
libunwind, libc++abi and libc++ shouldn't be using Clang resource
directory. Tools like clangd make this assumption, but this is
currently not true for the LLVM_ENABLE_PER_TARGET_RUNTIME_DIR build.
This change addresses that by moving the output of these libraries to
lib/$target/c++ and include/c++ directories, leaving resource directory
only for compiler-rt runtimes and Clang builtin headers.
Differential Revision: https://reviews.llvm.org/D59168
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@361432 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'runtimes')
-rw-r--r-- | runtimes/CMakeLists.txt | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/runtimes/CMakeLists.txt b/runtimes/CMakeLists.txt index f7ccb550635b..7bbf0cf26a58 100644 --- a/runtimes/CMakeLists.txt +++ b/runtimes/CMakeLists.txt @@ -124,8 +124,8 @@ if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_CURRENT_SOURCE_DIR}) string(REPLACE "-" "_" canon_name ${projName}) string(TOUPPER ${canon_name} canon_name) - if(LLVM_RUNTIMES_LIBDIR_SUFFIX) - set(${canon_name}_LIBDIR_SUFFIX "${LLVM_RUNTIMES_LIBDIR_SUFFIX}" CACHE STRING "" FORCE) + if(LLVM_RUNTIMES_LIBDIR_SUBDIR) + set(${canon_name}_LIBDIR_SUBDIR "${LLVM_RUNTIMES_LIBDIR_SUBDIR}" CACHE STRING "" FORCE) endif() # Setting a variable to let sub-projects detect which other projects @@ -358,6 +358,7 @@ else() # if this is included from LLVM's CMake # Builtins were built separately above CMAKE_ARGS -DCOMPILER_RT_BUILD_BUILTINS=Off -DLLVM_INCLUDE_TESTS=${LLVM_INCLUDE_TESTS} + -DLLVM_BINARY_DIR=${LLVM_BINARY_DIR} -DLLVM_LIBRARY_DIR=${LLVM_LIBRARY_DIR} -DLLVM_DEFAULT_TARGET_TRIPLE=${TARGET_TRIPLE} -DLLVM_ENABLE_PER_TARGET_RUNTIME_DIR=ON @@ -448,6 +449,7 @@ else() # if this is included from LLVM's CMake # Builtins were built separately above CMAKE_ARGS -DCOMPILER_RT_BUILD_BUILTINS=Off -DLLVM_INCLUDE_TESTS=${LLVM_INCLUDE_TESTS} + -DLLVM_BINARY_DIR=${LLVM_BINARY_DIR} -DLLVM_LIBRARY_DIR=${LLVM_LIBRARY_DIR} -DLLVM_DEFAULT_TARGET_TRIPLE=${target} -DLLVM_ENABLE_PER_TARGET_RUNTIME_DIR=ON @@ -519,7 +521,7 @@ else() # if this is included from LLVM's CMake runtime_register_target(${name}+${multilib} ${name} DEPENDS runtimes-${name} CMAKE_ARGS -DLLVM_RUNTIMES_PREFIX=${name}/ - -DLLVM_RUNTIMES_LIBDIR_SUFFIX=/${multilib}) + -DLLVM_RUNTIMES_LIBDIR_SUBDIR=${multilib}) add_dependencies(runtimes runtimes-${name}+${multilib}) add_dependencies(runtimes-configure runtimes-${name}+${multilib}-configure) add_dependencies(install-runtimes install-runtimes-${name}+${multilib}) |