[libcxx-commits] [PATCH] D150252: [libunwind][CMake] Add cached compile and link flags to libunwind
Maciej Grzywacz via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Wed May 10 00:38:07 PDT 2023
mgrzywac created this revision.
mgrzywac added a reviewer: libunwind.
mgrzywac added projects: libunwind, LLVM.
Herald added a subscriber: ekilmer.
Herald added a project: All.
mgrzywac requested review of this revision.
Herald added subscribers: libcxx-commits, llvm-commits.
Herald added 1 blocking reviewer(s): libunwind.
Add flags allowing to use compile flags and libraries provided in cache with libunwind.
Similar flags are already present in libc++ and libc++abi CMakeLists files.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D150252
Files:
libunwind/CMakeLists.txt
Index: libunwind/CMakeLists.txt
===================================================================
--- libunwind/CMakeLists.txt
+++ libunwind/CMakeLists.txt
@@ -143,6 +143,10 @@
set(LIBUNWIND_CXX_FLAGS "")
set(LIBUNWIND_COMPILE_FLAGS "")
set(LIBUNWIND_LINK_FLAGS "")
+set(LIBUNWIND_ADDITIONAL_COMPILE_FLAGS "" CACHE STRING
+ "Additional Compile only flags which can be provided in cache")
+set(LIBUNWIND_ADDITIONAL_LIBRARIES "" CACHE STRING
+ "Additional libraries libunwind is linked to which can be provided in cache")
# Include macros for adding and removing libunwind flags.
include(HandleLibunwindFlags)
@@ -151,6 +155,10 @@
# Setup Compiler Flags
#===============================================================================
+# Configure target flags
+add_compile_flags("${LIBUNWIND_ADDITIONAL_COMPILE_FLAGS}")
+add_library_flags("${LIBUNWIND_ADDITIONAL_LIBRARIES}")
+
# Configure compiler.
include(config-ix)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D150252.520922.patch
Type: text/x-patch
Size: 941 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20230510/972196dc/attachment-0001.bin>
More information about the libcxx-commits
mailing list