-
-
Save oreo639/a43b23916774fe58910bffce6a848190 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/srcpkgs/llvm15/patches/libcxxabi-musl.patch b/srcpkgs/llvm15/patches/libcxxabi-musl.patch | |
new file mode 100644 | |
index 0000000000..2115106691 | |
--- /dev/null | |
+++ b/srcpkgs/llvm15/patches/libcxxabi-musl.patch | |
@@ -0,0 +1,38 @@ | |
+gcc does not support using abi_tag in an extern "C" declaration | |
+https://github.com/gcc-mirror/gcc/blob/cf59c8983ef6590f0d69014f8dc8778b5b7691c6/gcc/cp/tree.cc#L5354-L5359 | |
+diff -rup libcxx/include/__support/musl/xlocale.h.orig libcxx/include/__support/musl/xlocale.h | |
+--- a/libcxx/include/__support/musl/xlocale.h.orig 2022-12-19 14:44:34.049044339 -0800 | |
++++ b/libcxx/include/__support/musl/xlocale.h 2022-12-19 14:45:24.211247988 -0800 | |
+@@ -24,27 +24,27 @@ | |
+ extern "C" { | |
+ #endif | |
+ | |
+-inline _LIBCPP_HIDE_FROM_ABI long long | |
++static inline long long | |
+ strtoll_l(const char *__nptr, char **__endptr, int __base, locale_t) { | |
+ return ::strtoll(__nptr, __endptr, __base); | |
+ } | |
+ | |
+-inline _LIBCPP_HIDE_FROM_ABI unsigned long long | |
++static inline unsigned long long | |
+ strtoull_l(const char *__nptr, char **__endptr, int __base, locale_t) { | |
+ return ::strtoull(__nptr, __endptr, __base); | |
+ } | |
+ | |
+-inline _LIBCPP_HIDE_FROM_ABI long long | |
++static inline long long | |
+ wcstoll_l(const wchar_t *__nptr, wchar_t **__endptr, int __base, locale_t) { | |
+ return ::wcstoll(__nptr, __endptr, __base); | |
+ } | |
+ | |
+-inline _LIBCPP_HIDE_FROM_ABI long long | |
++static inline long long | |
+ wcstoull_l(const wchar_t *__nptr, wchar_t **__endptr, int __base, locale_t) { | |
+ return ::wcstoull(__nptr, __endptr, __base); | |
+ } | |
+ | |
+-inline _LIBCPP_HIDE_FROM_ABI long double | |
++static inline long double | |
+ wcstold_l(const wchar_t *__nptr, wchar_t **__endptr, locale_t) { | |
+ return ::wcstold(__nptr, __endptr); | |
+ } | |
diff --git a/srcpkgs/llvm15/template b/srcpkgs/llvm15/template | |
index 5ed8be1366..44a94c9b54 100644 | |
--- a/srcpkgs/llvm15/template | |
+++ b/srcpkgs/llvm15/template | |
@@ -39,9 +39,8 @@ lib32disabled=yes | |
python_version=3 | |
if [ "$XBPS_TARGET_LIBC" = "musl" ]; then | |
- configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES" | |
- makedepends+=" libexecinfo-devel" | |
- depends+=" libexecinfo-devel" | |
+ configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES | |
+ -DCOMPILER_RT_BUILD_GWP_ASAN=OFF" | |
fi | |
# "operand out of range" assembler failures | |
@@ -122,10 +121,6 @@ post_patch() { | |
esac | |
case "$XBPS_TARGET_MACHINE" in | |
- x86_64-musl) # some sanitizer currently only on x86_64 stuff needs backtrace | |
- vsed -i 's,# Set common link flags.,list(APPEND SANITIZER_COMMON_LINK_LIBS execinfo),' \ | |
- ${wrksrc}/compiler-rt/CMakeLists.txt | |
- ;; | |
arm*-musl|i686-musl) # sanitizer code is broken since it duplicates some libc bits | |
vsed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' \ | |
${wrksrc}/compiler-rt/cmake/config-ix.cmake |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment