summaryrefslogtreecommitdiff
path: root/libunwind/CMakeLists.txt
diff options
context:
space:
mode:
authorJohn Ericson <John.Ericson@Obsidian.Systems>2022-01-11 03:03:21 +0000
committerJohn Ericson <John.Ericson@Obsidian.Systems>2022-01-11 18:24:50 +0000
commit0a8d15ad55e344419400f037393f2208214e33e0 (patch)
tree7a608f1b3d8fd77a69e985e6b6713ecb8deac081 /libunwind/CMakeLists.txt
parentbf52210e25e2c19203d9e2663d80befb405d385b (diff)
downloadllvm-0a8d15ad55e344419400f037393f2208214e33e0.tar.gz
[libc++][libc++abi][libunwind] Dedup install path var definitions
In D116873 I did this for libunwind prior to defining a new install path variable. But I think the change is good on its own, and libc++{,abi} could also use it. libc++ needed the base header var defined above the conditional part to use it for the prefi+ed headers in the non-target-specific case. For consistency, I therefore put the unconditional ones above for all 3 libs, which is why I touched the libunwind code (seeing that it had the core change already) Reviewed By: phosek, #libunwind, #libc, #libc_abi, ldionne Differential Revision: https://reviews.llvm.org/D116988
Diffstat (limited to 'libunwind/CMakeLists.txt')
-rw-r--r--libunwind/CMakeLists.txt10
1 files changed, 5 insertions, 5 deletions
diff --git a/libunwind/CMakeLists.txt b/libunwind/CMakeLists.txt
index efbd88a27f05..33741aea8f77 100644
--- a/libunwind/CMakeLists.txt
+++ b/libunwind/CMakeLists.txt
@@ -137,6 +137,11 @@ set(CMAKE_MODULE_PATH
"${CMAKE_CURRENT_SOURCE_DIR}/cmake"
${CMAKE_MODULE_PATH})
+set(LIBUNWIND_INSTALL_INCLUDE_DIR include CACHE PATH
+ "Path where built libunwind headers should be installed.")
+set(LIBUNWIND_INSTALL_RUNTIME_DIR bin CACHE PATH
+ "Path where built libunwind runtime libraries should be installed.")
+
if(LLVM_ENABLE_PER_TARGET_RUNTIME_DIR AND NOT APPLE)
set(LIBUNWIND_LIBRARY_DIR ${LLVM_LIBRARY_OUTPUT_INTDIR}/${LLVM_DEFAULT_TARGET_TRIPLE})
set(LIBUNWIND_INSTALL_LIBRARY_DIR lib${LLVM_LIBDIR_SUFFIX}/${LLVM_DEFAULT_TARGET_TRIPLE} CACHE PATH
@@ -155,11 +160,6 @@ else()
"Path where built libunwind libraries should be installed.")
endif()
-set(LIBUNWIND_INSTALL_INCLUDE_DIR include CACHE PATH
- "Path where built libunwind headers should be installed.")
-set(LIBUNWIND_INSTALL_RUNTIME_DIR bin CACHE PATH
- "Path where built libunwind runtime libraries should be installed.")
-
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${LIBUNWIND_LIBRARY_DIR})
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${LIBUNWIND_LIBRARY_DIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${LIBUNWIND_LIBRARY_DIR})