From 0b977787374349328a21af0deade30d534cf3978 Mon Sep 17 00:00:00 2001 From: davidovski Date: Wed, 18 May 2022 23:40:38 +0100 Subject: fixed gcc loader/linker errors --- repo/devel/llvm/libcxxabi-dl.patch | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 repo/devel/llvm/libcxxabi-dl.patch (limited to 'repo/devel/llvm/libcxxabi-dl.patch') diff --git a/repo/devel/llvm/libcxxabi-dl.patch b/repo/devel/llvm/libcxxabi-dl.patch new file mode 100644 index 0000000..3a15f9d --- /dev/null +++ b/repo/devel/llvm/libcxxabi-dl.patch @@ -0,0 +1,25 @@ +Also link to -ldl to prevent undefined references. + +--- a/libcxxabi/src/CMakeLists.txt ++++ b/libcxxabi/src/CMakeLists.txt +@@ -73,6 +73,7 @@ + endif() + + add_library_flags_if(LIBCXXABI_HAS_C_LIB c) ++ add_library_flags_if(LIBCXXABI_HAS_C_LIB dl) + endif() + + if (LIBCXXABI_USE_LLVM_UNWINDER) +--- a/libcxx/CMakeLists.txt ++++ b/libcxx/CMakeLists.txt +@@ -745,6 +745,10 @@ + target_link_libraries(${target} PRIVATE m) + endif() + ++ if (LIBCXX_HAS_C_LIB) ++ target_link_libraries(${target} PRIVATE dl) ++ endif() ++ + if (LIBCXX_HAS_RT_LIB) + target_link_libraries(${target} PRIVATE rt) + endif() -- cgit v1.2.1