summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPetr Hosek <phosek@chromium.org>2019-10-12 01:50:57 +0000
committerPetr Hosek <phosek@chromium.org>2019-10-12 01:50:57 +0000
commitb956c52c878776391430443706d884c124610c41 (patch)
tree6735f157fa87f1fa18a3240a7c09454ff1ce4dcf
parent38529c15312c52f39fc6bf693d2977295385d699 (diff)
[libunwind] Fix issues introduced in r374606
There are few differences in compile flags introduced in r374606 which are causing libcxx-libcxxabi-libunwind-armv8-linux to fail. This change should address all of those, I've compared the generated build file from before r374606 and with this change and the set of flags is the same modulo order. git-svn-id: https://llvm.org/svn/llvm-project/libunwind/trunk@374624 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--CMakeLists.txt4
-rw-r--r--src/CMakeLists.txt4
2 files changed, 6 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 736c533..3639585 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -291,12 +291,12 @@ endif()
add_cxx_compile_flags_if_supported(-fstrict-aliasing)
add_cxx_compile_flags_if_supported(-EHsc)
-add_c_compile_flags_if_supported(-funwind-tables)
+add_compile_flags_if_supported(-funwind-tables)
add_cxx_compile_flags_if_supported(-fno-exceptions)
add_cxx_compile_flags_if_supported(-fno-rtti)
# Ensure that we don't depend on C++ standard library.
-if (LIBCXXABI_HAS_NOSTDINCXX_FLAG)
+if (LIBUNWIND_HAS_NOSTDINCXX_FLAG)
list(APPEND LIBUNWIND_COMPILE_FLAGS -nostdinc++)
# Remove -stdlib flags to prevent them from causing an unused flag warning.
string(REPLACE "-stdlib=libc++" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 0b2a830..ed20ff0 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -117,6 +117,8 @@ if (LIBUNWIND_ENABLE_SHARED)
target_link_libraries(unwind_shared PRIVATE ${LIBUNWIND_LIBRARIES})
set_target_properties(unwind_shared
PROPERTIES
+ CXX_EXTENSIONS
+ OFF
CXX_STANDARD
11
CXX_STANDARD_REQUIRED
@@ -143,6 +145,8 @@ if (LIBUNWIND_ENABLE_STATIC)
target_link_libraries(unwind_static PRIVATE ${LIBUNWIND_LIBRARIES})
set_target_properties(unwind_static
PROPERTIES
+ CXX_EXTENSIONS
+ OFF
CXX_STANDARD
11
CXX_STANDARD_REQUIRED