[libunwind] r310327 - [CMake] Allow overriding lib dir suffix independently from LLVM
Petr Hosek via cfe-commits
cfe-commits at lists.llvm.org
Mon Aug 7 17:38:00 PDT 2017
Author: phosek
Date: Mon Aug 7 17:37:59 2017
New Revision: 310327
URL: http://llvm.org/viewvc/llvm-project?rev=310327&view=rev
Log:
[CMake] Allow overriding lib dir suffix independently from LLVM
This matches the options already supported by libc++ and libc++abi.
Differential Revision: https://reviews.llvm.org/D36383
Modified:
libunwind/trunk/CMakeLists.txt
libunwind/trunk/src/CMakeLists.txt
Modified: libunwind/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/libunwind/trunk/CMakeLists.txt?rev=310327&r1=310326&r2=310327&view=diff
==============================================================================
--- libunwind/trunk/CMakeLists.txt (original)
+++ libunwind/trunk/CMakeLists.txt Mon Aug 7 17:37:59 2017
@@ -133,6 +133,8 @@ option(LIBUNWIND_ENABLE_THREADS "Build l
option(LIBUNWIND_USE_COMPILER_RT "Use compiler-rt instead of libgcc" OFF)
option(LIBUNWIND_INCLUDE_DOCS "Build the libunwind documentation." ${LLVM_INCLUDE_DOCS})
+set(LIBUNWIND_LIBDIR_SUFFIX "${LLVM_LIBDIR_SUFFIX}" CACHE STRING
+ "Define suffix of library directory name (32/64)")
set(LIBUNWIND_TARGET_TRIPLE "" CACHE STRING "Target triple for cross compiling.")
set(LIBUNWIND_GCC_TOOLCHAIN "" CACHE PATH "GCC toolchain for cross compiling.")
set(LIBUNWIND_SYSROOT "" CACHE PATH "Sysroot for cross compiling.")
@@ -165,7 +167,7 @@ set(LIBUNWIND_BINARY_DIR ${CMAKE_CURREN
if (LLVM_LIBRARY_OUTPUT_INTDIR)
set(LIBUNWIND_LIBRARY_DIR ${LLVM_LIBRARY_OUTPUT_INTDIR})
else()
- set(LIBUNWIND_LIBRARY_DIR ${CMAKE_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX})
+ set(LIBUNWIND_LIBRARY_DIR ${CMAKE_BINARY_DIR}/lib${LIBUNWIND_LIBDIR_SUFFIX})
endif()
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${LIBUNWIND_LIBRARY_DIR})
Modified: libunwind/trunk/src/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/libunwind/trunk/src/CMakeLists.txt?rev=310327&r1=310326&r2=310327&view=diff
==============================================================================
--- libunwind/trunk/src/CMakeLists.txt (original)
+++ libunwind/trunk/src/CMakeLists.txt Mon Aug 7 17:37:59 2017
@@ -133,6 +133,6 @@ endif()
add_custom_target(unwind DEPENDS ${LIBUNWIND_TARGETS})
install(TARGETS ${LIBUNWIND_TARGETS}
- LIBRARY DESTINATION ${LIBUNWIND_INSTALL_PREFIX}lib${LLVM_LIBDIR_SUFFIX}
- ARCHIVE DESTINATION ${LIBUNWIND_INSTALL_PREFIX}lib${LLVM_LIBDIR_SUFFIX})
+ LIBRARY DESTINATION ${LIBUNWIND_INSTALL_PREFIX}lib${LIBUNWIND_LIBDIR_SUFFIX}
+ ARCHIVE DESTINATION ${LIBUNWIND_INSTALL_PREFIX}lib${LIBUNWIND_LIBDIR_SUFFIX})
More information about the cfe-commits
mailing list