unwind-force-pthread-dl
authorLLVM Packaging Team <pkg-llvm-team@lists.alioth.debian.org>
Sun, 1 Jan 2023 14:46:39 +0000 (14:46 +0000)
committerSylvestre Ledru <sylvestre@debian.org>
Sun, 1 Jan 2023 14:46:39 +0000 (14:46 +0000)
===================================================================

Gbp-Pq: Name unwind-force-pthread-dl.diff

libunwind/CMakeLists.txt

index 5a06805f05f182a34f8d5f7223fe00d45deaba62..2b82ccd65fd3b94aeb18ef90bbe703bc529a30f1 100644 (file)
@@ -309,14 +309,17 @@ if (MSVC)
   add_definitions(-D_CRT_SECURE_NO_WARNINGS)
 endif()
 
-if (C_SUPPORTS_COMMENT_LIB_PRAGMA)
-  if (LIBUNWIND_HAS_DL_LIB)
+list(APPEND LIBUNWIND_LINK_FLAGS "-ldl")
+list(APPEND LIBUNWIND_LINK_FLAGS "-lpthread")
+
+#if (C_SUPPORTS_COMMENT_LIB_PRAGMA)
+#  if (LIBUNWIND_HAS_DL_LIB)
     add_definitions(-D_LIBUNWIND_LINK_DL_LIB)
-  endif()
-  if (LIBUNWIND_HAS_PTHREAD_LIB)
+#  endif()
+#  if (LIBUNWIND_HAS_PTHREAD_LIB)
     add_definitions(-D_LIBUNWIND_LINK_PTHREAD_LIB)
-  endif()
-endif()
+#  endif()
+#endif()
 
 #===============================================================================
 # Setup Source Code