[libunwind] r355142 - [CMake][libunwind] Define add_target_flags which is missing
Petr Hosek via cfe-commits
cfe-commits at lists.llvm.org
Thu Feb 28 13:38:59 PST 2019
Author: phosek
Date: Thu Feb 28 13:38:59 2019
New Revision: 355142
URL: http://llvm.org/viewvc/llvm-project?rev=355142&view=rev
Log:
[CMake][libunwind] Define add_target_flags which is missing
It's use was introduced in r353084 but its definition is missing.
Differential Revision: https://reviews.llvm.org/D58745
Modified:
libunwind/trunk/CMakeLists.txt
Modified: libunwind/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/libunwind/trunk/CMakeLists.txt?rev=355142&r1=355141&r2=355142&view=diff
==============================================================================
--- libunwind/trunk/CMakeLists.txt (original)
+++ libunwind/trunk/CMakeLists.txt Thu Feb 28 13:38:59 2019
@@ -214,12 +214,18 @@ macro(unwind_append_if list condition va
endif()
endmacro()
-macro(add_target_flags_if condition var)
+macro(add_target_flags)
+ foreach(value ${ARGN})
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${value}")
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${value}")
+ list(APPEND LIBUNWIND_COMPILE_FLAGS ${value})
+ list(APPEND LIBUNWIND_LINK_FLAGS ${value})
+ endforeach()
+endmacro()
+
+macro(add_target_flags_if condition)
if (${condition})
- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${var}")
- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${var}")
- list(APPEND LIBUNWIND_COMPILE_FLAGS ${var})
- list(APPEND LIBUNWIND_LINK_FLAGS ${var})
+ add_target_flags(${ARGN})
endif()
endmacro()
More information about the cfe-commits
mailing list