* [PR PATCH] remove llvm12
@ 2024-07-10 3:07 Calandracas606
2024-07-10 3:10 ` [PR REVIEW] " Calandracas606
` (14 more replies)
0 siblings, 15 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-10 3:07 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1417 bytes --]
There is a new pull request by Calandracas606 against master on the void-packages repository
https://github.com/Calandracas606/void-packages remove-llvm12
https://github.com/void-linux/void-packages/pull/51186
remove llvm12
- **mozjs102: build with llvm18**
- **ghdl: update to 4.1.0.**
- **llvm12: remove package**
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, x86_64
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64-musl
- i686
- aarch64 (cross)
- aarch64-musl (cross)
- armv7l (cross)
- armv7l-musl (cross)
- armv6l (cross)
- armv6l-musl (cross)
A patch file from https://github.com/void-linux/void-packages/pull/51186.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-remove-llvm12-51186.patch --]
[-- Type: text/x-diff, Size: 52750 bytes --]
From 099c010f8c7ade292346730d1e64e8cc874996e0 Mon Sep 17 00:00:00 2001
From: Daniel Martinez <danielmartinez@cock.li>
Date: Tue, 9 Jul 2024 22:03:32 -0400
Subject: [PATCH 1/3] mozjs102: build with llvm18
---
srcpkgs/mozjs102/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/mozjs102/template b/srcpkgs/mozjs102/template
index 04050f47c1fe34..1b8d6293130728 100644
--- a/srcpkgs/mozjs102/template
+++ b/srcpkgs/mozjs102/template
@@ -1,7 +1,7 @@
# Template file for 'mozjs102'
pkgname=mozjs102
version=102.15.1
-revision=1
+revision=2
build_wrksrc=js/src
build_style=gnu-configure
build_helper=rust
@@ -11,7 +11,7 @@ configure_args="--disable-jemalloc --disable-strip --disable-tests \
--enable-shared-js --enable-system-ffi --with-intl-api --with-system-icu \
--with-system-nspr --with-system-zlib --enable-hardening --enable-release"
hostmakedepends="make pkg-config python3 python3-setuptools python3-six perl m4
- rust cargo llvm12 clang python3-looseversion"
+ rust cargo llvm18 clang18 python3-looseversion"
makedepends="icu-devel libffi-devel nspr-devel python3-devel readline-devel
zlib-devel rust-std"
checkdepends="python3"
From 97e13b7fab3de7abfe3c05e05ef535b4b375eadf Mon Sep 17 00:00:00 2001
From: Daniel Martinez <danielmartinez@cock.li>
Date: Tue, 9 Jul 2024 22:14:13 -0400
Subject: [PATCH 2/3] ghdl: update to 4.1.0.
---
srcpkgs/ghdl/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/ghdl/template b/srcpkgs/ghdl/template
index 0e2d82c2d42fd9..3bf5686364505f 100644
--- a/srcpkgs/ghdl/template
+++ b/srcpkgs/ghdl/template
@@ -6,8 +6,8 @@
#
pkgname=ghdl
reverts="20181129_1"
-version=3.0.0
-revision=2
+version=4.1.0
+revision=1
build_style=configure
configure_args="--prefix=/usr --srcdir=.. --disable-werror"
makedepends="zlib-devel"
@@ -17,7 +17,7 @@ license="GPL-2.0-or-later"
homepage="https://github.com/ghdl/ghdl"
changelog="https://raw.githubusercontent.com/ghdl/ghdl/master/NEWS.md"
distfiles="https://github.com/ghdl/ghdl/archive/v${version}.tar.gz"
-checksum=c1ed4d2095df80131260a48c55bb53409ce8d4c38bba42618ca040115faf08b9
+checksum=0aab531b45a6613b0918f3ac6ec717b8acfad051d1abb1c39eb7490590c7a324
nocross=yes
# testsuite is big and long
make_check=extended
@@ -39,7 +39,7 @@ case "$XBPS_TARGET_MACHINE" in
esac
if [ "$build_option_llvm" ]; then
- makedepends+=" llvm12"
+ makedepends+=" llvm18-devel"
fi
do_configure() {
From 16a752acee5967e1975eb82278615cc2cd19f5a5 Mon Sep 17 00:00:00 2001
From: Daniel Martinez <danielmartinez@cock.li>
Date: Tue, 9 Jul 2024 22:18:51 -0400
Subject: [PATCH 3/3] llvm12: remove package
---
common/shlibs | 2 -
srcpkgs/libllvm12 | 1 -
.../llvm12/files/llvm-Config-llvm-config.h | 9 -
...clang-001-fix-unwind-chain-inclusion.patch | 44 -----
.../patches/clang-002-add-musl-triples.patch | 110 ------------
.../clang-003-ppc64-dynamic-linker-path.patch | 13 --
.../patches/clang-004-ppc64-musl-elfv2.patch | 48 ------
.../compiler-rt-aarch64-ucontext.patch | 11 --
.../compiler-rt-sanitizer-glibc-2.36.patch | 59 -------
.../compiler-rt-sanitizer-ppc64-musl.patch | 35 ----
.../llvm12/patches/compiler-rt-size_t.patch | 10 --
.../patches/compiler-rt-xray-ppc64-musl.patch | 62 -------
srcpkgs/llvm12/patches/libcxx-musl.patch | 26 ---
srcpkgs/llvm12/patches/libcxx-ppc.patch | 22 ---
.../llvm12/patches/libcxx-ssp-nonshared.patch | 11 --
srcpkgs/llvm12/patches/libcxxabi-dl.patch | 25 ---
srcpkgs/llvm12/patches/libunwind-ppc32.patch | 63 -------
srcpkgs/llvm12/patches/lldb-musl.patch | 31 ----
srcpkgs/llvm12/patches/llvm-001-musl.patch | 57 -------
.../patches/llvm-002-musl-ppc64-elfv2.patch | 30 ----
.../patches/llvm-003-ppc-secureplt.patch | 11 --
.../patches/llvm-004-override-opt.patch | 18 --
.../llvm12/patches/llvm-005-ppc-bigpic.patch | 36 ----
.../patches/llvm-006-aarch64-mf_exec.patch | 25 ---
srcpkgs/llvm12/patches/llvm-gcc13.patch | 28 ---
.../llvm12/patches/ppc32-compiler-rt.patch | 21 ---
srcpkgs/llvm12/template | 161 ------------------
srcpkgs/llvm12/update | 3 -
srcpkgs/removed-packages/template | 6 +-
29 files changed, 4 insertions(+), 974 deletions(-)
delete mode 120000 srcpkgs/libllvm12
delete mode 100644 srcpkgs/llvm12/files/llvm-Config-llvm-config.h
delete mode 100644 srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-size_t.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ppc.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxxabi-dl.patch
delete mode 100644 srcpkgs/llvm12/patches/libunwind-ppc32.patch
delete mode 100644 srcpkgs/llvm12/patches/lldb-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-001-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-004-override-opt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-gcc13.patch
delete mode 100644 srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
delete mode 100644 srcpkgs/llvm12/template
delete mode 100644 srcpkgs/llvm12/update
diff --git a/common/shlibs b/common/shlibs
index a61fee85bfe1d3..6d71d094df6fd1 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -985,8 +985,6 @@ libclang.so.15 libclang15-15.0.7_4
libclang-cpp.so.18.1 libclang-cpp18-18.1.8_1
libclang-cpp.so.17 libclang-cpp17-17.0.6_1
libclang-cpp.so.15 libclang-cpp15-15.0.7_4
-libLLVM-11.so libllvm11-11.0.0_1
-libLLVM-12.so libllvm12-12.0.0_1
libLLVM-15.so libllvm15-15.0.7_4
libLLVM-17.so libllvm17-17.0.6_1
libLLVM.so.18.1 libllvm18-18.1.8_1
diff --git a/srcpkgs/libllvm12 b/srcpkgs/libllvm12
deleted file mode 120000
index cd60fd7a981bdd..00000000000000
--- a/srcpkgs/libllvm12
+++ /dev/null
@@ -1 +0,0 @@
-llvm12
\ No newline at end of file
diff --git a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h b/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
deleted file mode 100644
index 2fa08c9be69621..00000000000000
--- a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
+++ /dev/null
@@ -1,9 +0,0 @@
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 32
-#include "llvm-config-32.h"
-#elif __WORDSIZE == 64
-#include "llvm-config-64.h"
-#else
-#error "Unknown word size"
-#endif
diff --git a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
deleted file mode 100644
index e4eaa7783e7a6c..00000000000000
--- a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 352974169f0d2b5da3d5321f588f5e3b5941330e Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:14:57 +0200
-Subject: [PATCH 2/7] fix unwind chain inclusion
-
----
- lib/Headers/unwind.h | 9 +++++----
- 1 file changed, 5 insertions(+), 4 deletions(-)
-
-diff --git a/lib/Headers/unwind.h b/lib/Headers/unwind.h
-index 303d792..44e10cc 100644
---- a/clang/lib/Headers/unwind.h
-+++ b/clang/lib/Headers/unwind.h
-@@ -9,9 +9,6 @@
-
- /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/
-
--#ifndef __CLANG_UNWIND_H
--#define __CLANG_UNWIND_H
--
- #if defined(__APPLE__) && __has_include_next(<unwind.h>)
- /* Darwin (from 11.x on) provide an unwind.h. If that's available,
- * use it. libunwind wraps some of its definitions in #ifdef _GNU_SOURCE,
-@@ -39,6 +36,9 @@
- # endif
- #else
-
-+#ifndef __CLANG_UNWIND_H
-+#define __CLANG_UNWIND_H
-+
- #include <stdint.h>
-
- #ifdef __cplusplus
-@@ -322,6 +322,7 @@ _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *);
- }
- #endif
-
-+#endif /* __CLANG_UNWIND_H */
-+
- #endif
-
--#endif /* __CLANG_UNWIND_H */
---
-2.5.1
diff --git a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch b/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
deleted file mode 100644
index 25688d40dbc275..00000000000000
--- a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
+++ /dev/null
@@ -1,110 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Gnu.cpp
-+++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2086,7 +2086,8 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
- "armv7hl-redhat-linux-gnueabi",
- "armv6hl-suse-linux-gnueabi",
-- "armv7hl-suse-linux-gnueabi"};
-+ "armv7hl-suse-linux-gnueabi",
-+ "armv7l-linux-gnueabihf"};
- static const char *const ARMebLibDirs[] = {"/lib"};
- static const char *const ARMebTriples[] = {"armeb-linux-gnueabi",
- "armeb-linux-androideabi"};
-@@ -2153,8 +2154,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- "powerpc64-suse-linux", "powerpc-montavista-linuxspe"};
- static const char *const PPCLELibDirs[] = {"/lib32", "/lib"};
- static const char *const PPCLETriples[] = {"powerpcle-linux-gnu",
-- "powerpcle-unknown-linux-gnu",
-- "powerpcle-linux-musl"};
-+ "powerpcle-unknown-linux-gnu"};
-
- static const char *const PPC64LibDirs[] = {"/lib64", "/lib"};
- static const char *const PPC64Triples[] = {
-@@ -2235,6 +2235,87 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- return;
- }
-
-+ if (TargetTriple.isMusl()) {
-+ static const char *const AArch64MuslTriples[] = {"aarch64-linux-musl"};
-+ static const char *const ARMHFMuslTriples[] = {
-+ "arm-linux-musleabihf", "armv7l-linux-musleabihf"
-+ };
-+ static const char *const ARMMuslTriples[] = {"arm-linux-musleabi"};
-+ static const char *const X86_64MuslTriples[] = {"x86_64-linux-musl"};
-+ static const char *const X86MuslTriples[] = {"i686-linux-musl"};
-+ static const char *const MIPSMuslTriples[] = {
-+ "mips-linux-musl", "mipsel-linux-musl",
-+ "mipsel-linux-muslhf", "mips-linux-muslhf"
-+ };
-+ static const char *const PPCMuslTriples[] = {"powerpc-linux-musl"};
-+ static const char *const PPCLEMuslTriples[] = {"powerpcle-linux-musl"};
-+ static const char *const PPC64MuslTriples[] = {"powerpc64-linux-musl"};
-+ static const char *const PPC64LEMuslTriples[] = {"powerpc64le-linux-musl"};
-+
-+ switch (TargetTriple.getArch()) {
-+ case llvm::Triple::aarch64:
-+ LibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ TripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ BiarchLibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ BiarchTripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ break;
-+ case llvm::Triple::arm:
-+ LibDirs.append(begin(ARMLibDirs), end(ARMLibDirs));
-+ if (TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
-+ TripleAliases.append(begin(ARMHFMuslTriples), end(ARMHFMuslTriples));
-+ } else {
-+ TripleAliases.append(begin(ARMMuslTriples), end(ARMMuslTriples));
-+ }
-+ break;
-+ case llvm::Triple::x86_64:
-+ LibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ TripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ BiarchLibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ BiarchTripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ break;
-+ case llvm::Triple::x86:
-+ LibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ TripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ BiarchLibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ BiarchTripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ break;
-+ case llvm::Triple::mips:
-+ LibDirs.append(begin(MIPSLibDirs), end(MIPSLibDirs));
-+ TripleAliases.append(begin(MIPSMuslTriples), end(MIPSMuslTriples));
-+ break;
-+ case llvm::Triple::ppc:
-+ LibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ TripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ BiarchTripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ break;
-+ case llvm::Triple::ppcle:
-+ LibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ TripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ BiarchTripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64:
-+ LibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ TripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ BiarchLibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ BiarchTripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64le:
-+ LibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ TripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ BiarchLibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ BiarchTripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ break;
-+ default:
-+ break;
-+ }
-+ TripleAliases.push_back(TargetTriple.str());
-+ if (TargetTriple.str() != BiarchTriple.str())
-+ BiarchTripleAliases.push_back(BiarchTriple.str());
-+ return;
-+ }
-+
- // Android targets should not use GNU/Linux tools or libraries.
- if (TargetTriple.isAndroid()) {
- static const char *const AArch64AndroidTriples[] = {
diff --git a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
deleted file mode 100644
index 4ad6412d1e6c63..00000000000000
--- a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Linux.cpp
-+++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -504,10 +504,6 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
- Loader = "ld.so.1";
- break;
- case llvm::Triple::ppc64:
-- LibDir = "lib64";
-- Loader =
-- (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
-- break;
- case llvm::Triple::ppc64le:
- LibDir = "lib64";
- Loader =
diff --git a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
deleted file mode 100644
index 21fc8003c5f1a8..00000000000000
--- a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
+++ /dev/null
@@ -1,48 +0,0 @@
---- a/clang/lib/Basic/Targets/PPC.h
-+++ b/clang/lib/Basic/Targets/PPC.h
-@@ -415,11 +415,10 @@ public:
- LongDoubleFormat = &llvm::APFloat::IEEEdouble();
- } else if ((Triple.getArch() == llvm::Triple::ppc64le)) {
- DataLayout = "e-m:e-i64:64-n32:64";
-- ABI = "elfv2";
- } else {
- DataLayout = "E-m:e-i64:64-n32:64";
-- ABI = "elfv1";
- }
-+ ABI = "elfv2";
-
- if (Triple.isOSFreeBSD() || Triple.isOSOpenBSD() || Triple.isMusl()) {
- LongDoubleWidth = LongDoubleAlign = 64;
---- a/clang/lib/CodeGen/TargetInfo.cpp
-+++ b/clang/lib/CodeGen/TargetInfo.cpp
-@@ -10927,9 +10927,9 @@ const TargetCodeGenInfo &CodeGenModule::getTargetCodeGenInfo() {
- return SetCGInfo(new AIXTargetCodeGenInfo(Types, /*Is64Bit*/ true));
-
- if (Triple.isOSBinFormatELF()) {
-- PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv1;
-- if (getTarget().getABI() == "elfv2")
-- Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ if (getTarget().getABI() == "elfv1")
-+ Kind = PPC64_SVR4_ABIInfo::ELFv1;
- bool IsSoftFloat = CodeGenOpts.FloatABI == "soft";
-
- return SetCGInfo(
---- a/clang/lib/Driver/ToolChains/Clang.cpp
-+++ b/clang/lib/Driver/ToolChains/Clang.cpp
-@@ -1920,14 +1920,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
- const llvm::Triple &T = getToolChain().getTriple();
- if (T.isOSBinFormatELF()) {
- switch (getToolChain().getArch()) {
-- case llvm::Triple::ppc64: {
-- if ((T.isOSFreeBSD() && T.getOSMajorVersion() >= 13) ||
-- T.isOSOpenBSD() || T.isMusl())
-- ABIName = "elfv2";
-- else
-- ABIName = "elfv1";
-- break;
-- }
-+ case llvm::Triple::ppc64:
- case llvm::Triple::ppc64le:
- ABIName = "elfv2";
- break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch b/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
deleted file mode 100644
index 893c059d7b8def..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp.orig
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -1799,7 +1799,7 @@
-
- static bool Aarch64GetESR(ucontext_t *ucontext, u64 *esr) {
- static const u32 kEsrMagic = 0x45535201;
-- u8 *aux = ucontext->uc_mcontext.__reserved;
-+ u8 *aux = reinterpret_cast<u8 *>(ucontext->uc_mcontext.__reserved);
- while (true) {
- _aarch64_ctx *ctx = (_aarch64_ctx *)aux;
- if (ctx->size == 0) break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
deleted file mode 100644
index e5f24dab893547..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From 9cf13067cb5088626ba7ee1ec4c42ec59c7995a0 Mon Sep 17 00:00:00 2001
-From: Fangrui Song <i@maskray.me>
-Date: Mon, 11 Jul 2022 12:53:34 -0700
-Subject: [PATCH] [sanitizer] Remove #include <linux/fs.h> to resolve
- fsconfig_command/mount_attr conflict with glibc 2.36
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-It is generally not a good idea to mix usage of glibc headers and Linux UAPI
-headers (https://sourceware.org/glibc/wiki/Synchronizing_Headers). In glibc
-since 7eae6a91e9b1670330c9f15730082c91c0b1d570 (milestone: 2.36), sys/mount.h
-defines `fsconfig_command` which conflicts with linux/mount.h:
-
- .../usr/include/linux/mount.h:95:6: error: redeclaration of ‘enum fsconfig_command’
-
-Remove #include <linux/fs.h> which pulls in linux/mount.h. Expand its 4 macros manually.
-Android sys/mount.h doesn't define BLKBSZGET and it still needs linux/fs.h.
-In the long term we should move Linux specific definitions to sanitizer_platform_limits_linux.cpp
-but this commit is easy to cherry pick into older compiler-rt releases.
-
-Fix https://github.com/llvm/llvm-project/issues/56421
-
-Reviewed By: #sanitizers, vitalybuka, zatrazz
-
-Differential Revision: https://reviews.llvm.org/D129471
----
- .../sanitizer_platform_limits_posix.cpp | 10 ++++++----
- 1 file changed, 6 insertions(+), 4 deletions(-)
-
-diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-index 4bd425435d56d..3a94b260686f1 100644
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -73,7 +73,9 @@
- #include <sys/vt.h>
- #include <linux/cdrom.h>
- #include <linux/fd.h>
-+#if SANITIZER_ANDROID
- #include <linux/fs.h>
-+#endif
- #include <linux/hdreg.h>
- #include <linux/input.h>
- #include <linux/ioctl.h>
-@@ -876,10 +878,10 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr);
- unsigned IOCTL_EVIOCGPROP = IOCTL_NOT_PRESENT;
- unsigned IOCTL_EVIOCSKEYCODE_V2 = IOCTL_NOT_PRESENT;
- #endif
-- unsigned IOCTL_FS_IOC_GETFLAGS = FS_IOC_GETFLAGS;
-- unsigned IOCTL_FS_IOC_GETVERSION = FS_IOC_GETVERSION;
-- unsigned IOCTL_FS_IOC_SETFLAGS = FS_IOC_SETFLAGS;
-- unsigned IOCTL_FS_IOC_SETVERSION = FS_IOC_SETVERSION;
-+ unsigned IOCTL_FS_IOC_GETFLAGS = _IOR('f', 1, long);
-+ unsigned IOCTL_FS_IOC_GETVERSION = _IOR('v', 1, long);
-+ unsigned IOCTL_FS_IOC_SETFLAGS = _IOW('f', 2, long);
-+ unsigned IOCTL_FS_IOC_SETVERSION = _IOW('v', 2, long);
- unsigned IOCTL_GIO_CMAP = GIO_CMAP;
- unsigned IOCTL_GIO_FONT = GIO_FONT;
- unsigned IOCTL_GIO_UNIMAP = GIO_UNIMAP;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
deleted file mode 100644
index 35f16d24f340c6..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
+++ /dev/null
@@ -1,35 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -74,6 +74,10 @@
- #include <sys/utsname.h>
- #endif
-
-+#if SANITIZER_LINUX && defined(__powerpc__)
-+#include <asm/ptrace.h>
-+#endif
-+
- #if SANITIZER_LINUX && !SANITIZER_ANDROID
- #include <sys/personality.h>
- #endif
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -92,7 +92,7 @@
- # include <utime.h>
- # include <sys/ptrace.h>
- #if defined(__mips64) || defined(__aarch64__) || defined(__arm__) || \
-- SANITIZER_RISCV64
-+ defined(__powerpc__) || SANITIZER_RISCV64
- # include <asm/ptrace.h>
- # ifdef __arm__
- typedef struct user_fpregs elf_fpregset_t;
---- a/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-@@ -31,7 +31,7 @@
- #include <sys/types.h> // for pid_t
- #include <sys/uio.h> // for iovec
- #include <elf.h> // for NT_PRSTATUS
--#if (defined(__aarch64__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
-+#if (defined(__aarch64__) || defined(__powerpc__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
- // GLIBC 2.20+ sys/user does not include asm/ptrace.h
- # include <asm/ptrace.h>
- #endif
diff --git a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch b/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
deleted file mode 100644
index 2c63063a5e9e3f..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp.orig
-+++ b/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp
-@@ -25,6 +25,7 @@
- }
-
- #include <cassert>
-+#include <cstddef>
- #include <cstdint>
- #include <dlfcn.h> // for dlsym()
-
diff --git a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
deleted file mode 100644
index d0b61c80c897f4..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
+++ /dev/null
@@ -1,62 +0,0 @@
---- a/compiler-rt/lib/xray/xray_powerpc64.inc
-+++ b/compiler-rt/lib/xray/xray_powerpc64.inc
-@@ -12,7 +12,13 @@
-
- #include <cstdint>
- #include <mutex>
-+#ifdef __GLIBC__
- #include <sys/platform/ppc.h>
-+#else
-+#include <cctype>
-+#include <cstring>
-+#include <cstdlib>
-+#endif
-
- #include "xray_defs.h"
-
-@@ -20,13 +26,45 @@ namespace __xray {
-
- ALWAYS_INLINE uint64_t readTSC(uint8_t &CPU) XRAY_NEVER_INSTRUMENT {
- CPU = 0;
-+#ifdef __GLIBC__
- return __ppc_get_timebase();
-+#else
-+ return __builtin_ppc_get_timebase();
-+#endif
- }
-
- inline uint64_t getTSCFrequency() XRAY_NEVER_INSTRUMENT {
- static std::mutex M;
- std::lock_guard<std::mutex> Guard(M);
-+#ifdef __GLIBC__
- return __ppc_get_timebase_freq();
-+#else
-+ /* FIXME: a less dirty implementation? */
-+ static uint64_t base;
-+ if (!base) {
-+ FILE *f = fopen("/proc/cpuinfo", "rb");
-+ if (f) {
-+ ssize_t nr;
-+ /* virtually always big enough to hold the line */
-+ char buf[512];
-+ while (fgets(buf, sizeof(buf), f)) {
-+ char *ret = strstr(buf, "timebase");
-+ if (!ret) {
-+ continue;
-+ }
-+ ret += sizeof("timebase") - 1;
-+ ret = strchr(ret, ':');
-+ if (!ret) {
-+ continue;
-+ }
-+ base = strtoul(ret + 1, nullptr, 10);
-+ break;
-+ }
-+ fclose(f);
-+ }
-+ }
-+ return base;
-+#endif
- }
-
- inline bool probeRequiredCPUFeatures() XRAY_NEVER_INSTRUMENT {
diff --git a/srcpkgs/llvm12/patches/libcxx-musl.patch b/srcpkgs/llvm12/patches/libcxx-musl.patch
deleted file mode 100644
index bbd31ffc2cb1f4..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-musl.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/libcxx/include/locale
-+++ b/libcxx/include/locale
-@@ -742,7 +742,11 @@ __num_get_signed_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ long long __ll = strtoll(__a, &__p2, __base);
-+#else
- long long __ll = strtoll_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
-@@ -782,7 +786,11 @@ __num_get_unsigned_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ unsigned long long __ll = strtoull(__a, &__p2, __base);
-+#else
- unsigned long long __ll = strtoull_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
diff --git a/srcpkgs/llvm12/patches/libcxx-ppc.patch b/srcpkgs/llvm12/patches/libcxx-ppc.patch
deleted file mode 100644
index 7a92f8004e1cf8..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ppc.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-This ensures `is_iec559` is defined correctly under all long double ABIs,
-including musl and its 64-bit long double. Also, `__ppc__` or `__ppc64__`
-is not defined on gcc.
-
---- a/libcxx/include/limits
-+++ b/libcxx/include/limits
-@@ -426,8 +426,14 @@ protected:
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nansl("");}
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __LDBL_DENORM_MIN__;}
-
--#if (defined(__ppc__) || defined(__ppc64__))
-+#if defined(__powerpc__) || defined(__powerpc64__)
-+#if (__LDBL_MAX_EXP__ > __DBL_MAX_EXP__) || (__LDBL_MANT_DIG__ == __DBL_MANT_DIG__)
-+ /* IEEE 754 quadruple or double precision */
-+ static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
-+#else
-+ /* 128-bit IBM double-double */
- static _LIBCPP_CONSTEXPR const bool is_iec559 = false;
-+#endif
- #else
- static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
- #endif
diff --git a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch b/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
deleted file mode 100644
index 70292beb2fcdbd..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/libcxx/CMakeLists.txt
-+++ b/libcxx/CMakeLists.txt
-@@ -769,6 +769,8 @@ function(cxx_link_system_libraries target)
- target_link_libraries(${target} PRIVATE atomic)
- endif()
-
-+#ssp target_link_libraries(${target} PRIVATE ssp_nonshared)
-+
- if (MINGW)
- target_link_libraries(${target} PRIVATE "${MINGW_LIBRARIES}")
- endif()
diff --git a/srcpkgs/llvm12/patches/libcxxabi-dl.patch b/srcpkgs/llvm12/patches/libcxxabi-dl.patch
deleted file mode 100644
index 3a15f9db8c981e..00000000000000
--- a/srcpkgs/llvm12/patches/libcxxabi-dl.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-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()
diff --git a/srcpkgs/llvm12/patches/libunwind-ppc32.patch b/srcpkgs/llvm12/patches/libunwind-ppc32.patch
deleted file mode 100644
index 74aa7576ecf9df..00000000000000
--- a/srcpkgs/llvm12/patches/libunwind-ppc32.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-This fixes build at least with gcc9 which does not define `__ppc__`.
-
---- a/libunwind/include/__libunwind_config.h
-+++ b/libunwind/include/__libunwind_config.h
-@@ -49,7 +49,7 @@
- # define _LIBUNWIND_CONTEXT_SIZE 167
- # define _LIBUNWIND_CURSOR_SIZE 179
- # define _LIBUNWIND_HIGHEST_DWARF_REGISTER _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC64
--# elif defined(__ppc__)
-+# elif defined(__powerpc__)
- # define _LIBUNWIND_TARGET_PPC 1
- # define _LIBUNWIND_CONTEXT_SIZE 117
- # define _LIBUNWIND_CURSOR_SIZE 124
---- a/libunwind/src/UnwindRegistersRestore.S
-+++ b/libunwind/src/UnwindRegistersRestore.S
-@@ -392,7 +392,7 @@ Lnovec:
- PPC64_LR(3)
- bctr
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- DEFINE_LIBUNWIND_FUNCTION(_ZN9libunwind13Registers_ppc6jumptoEv)
- //
---- a/libunwind/src/UnwindRegistersSave.S
-+++ b/libunwind/src/UnwindRegistersSave.S
-@@ -554,7 +554,7 @@ DEFINE_LIBUNWIND_FUNCTION(__unw_getcontext)
- blr
-
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- //
- // extern int unw_getcontext(unw_context_t* thread_state)
---- a/libunwind/src/config.h
-+++ b/libunwind/src/config.h
-@@ -95,12 +95,12 @@
- #define _LIBUNWIND_BUILD_SJLJ_APIS
- #endif
-
--#if defined(__i386__) || defined(__x86_64__) || defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__)
-+#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc__) || defined(__powerpc64__)
- #define _LIBUNWIND_SUPPORT_FRAME_APIS
- #endif
-
- #if defined(__i386__) || defined(__x86_64__) || \
-- defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__) || \
-+ defined(__powerpc__) || defined(__powerpc64__) || \
- (!defined(__APPLE__) && defined(__arm__)) || \
- (defined(__arm64__) || defined(__aarch64__)) || \
- defined(__mips__)
---- a/libunwind/src/libunwind.cpp
-+++ b/libunwind/src/libunwind.cpp
-@@ -42,7 +42,7 @@ _LIBUNWIND_HIDDEN int __unw_init_local(unw_cursor_t *cursor,
- # define REGISTER_KIND Registers_x86_64
- #elif defined(__powerpc64__)
- # define REGISTER_KIND Registers_ppc64
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
- # define REGISTER_KIND Registers_ppc
- #elif defined(__aarch64__)
- # define REGISTER_KIND Registers_arm64
diff --git a/srcpkgs/llvm12/patches/lldb-musl.patch b/srcpkgs/llvm12/patches/lldb-musl.patch
deleted file mode 100644
index 601c0d138523e8..00000000000000
--- a/srcpkgs/llvm12/patches/lldb-musl.patch
+++ /dev/null
@@ -1,31 +0,0 @@
---- a/lldb/source/Plugins/Process/Linux/Procfs.h
-+++ b/lldb/source/Plugins/Process/Linux/Procfs.h
-@@ -10,21 +10,12 @@
- // sys/procfs.h on Android/Linux for all supported architectures.
-
- #include <sys/ptrace.h>
-+#include <asm/ptrace.h>
-
--#ifdef __ANDROID__
--#if defined(__arm64__) || defined(__aarch64__)
--typedef unsigned long elf_greg_t;
--typedef elf_greg_t
-- elf_gregset_t[(sizeof(struct user_pt_regs) / sizeof(elf_greg_t))];
--typedef struct user_fpsimd_state elf_fpregset_t;
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#elif defined(__mips__)
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#endif
--#else // __ANDROID__
-+#if !defined(__GLIBC__) && defined(__powerpc__)
-+#define pt_regs musl_pt_regs
-+#include <sys/procfs.h>
-+#undef pt_regs
-+#else
- #include <sys/procfs.h>
--#endif // __ANDROID__
-+#endif
diff --git a/srcpkgs/llvm12/patches/llvm-001-musl.patch b/srcpkgs/llvm12/patches/llvm-001-musl.patch
deleted file mode 100644
index f2a3f8d62813e3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-001-musl.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From faca3fbd15d0c3108493c3c54cd93138e049ac43 Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:03:02 +0200
-Subject: [PATCH 3/3] musl
-
----
- include/llvm/Analysis/TargetLibraryInfo.h | 9 +++++++++
- lib/Support/DynamicLibrary.cpp | 2 +-
- lib/Support/Unix/Signals.inc | 6 +++---
- utils/unittest/googletest/src/gtest.cc | 1 +
- 5 files changed, 17 insertions(+), 6 deletions(-)
-
-diff --git a/include/llvm/Analysis/TargetLibraryInfo.h b/include/llvm/Analysis/TargetLibraryInfo.h
-index 34a8a1e3..1214ece5 100644
---- a/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-+++ b/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-@@ -18,6 +18,15 @@
- #include "llvm/IR/PassManager.h"
- #include "llvm/Pass.h"
-
-+#undef fopen64
-+#undef fseeko64
-+#undef fstat64
-+#undef fstatvfs64
-+#undef ftello64
-+#undef lstat64
-+#undef stat64
-+#undef tmpfile64
-+
- namespace llvm {
- template <typename T> class ArrayRef;
- class Triple;
-diff --git a/lib/Support/Unix/DynamicLibrary.inc b/lib/Support/Unix/DynamicLibrary.inc
-index a2a37996..2f86c470 100644
---- a/llvm/lib/Support/Unix/DynamicLibrary.inc
-+++ b/llvm/lib/Support/Unix/DynamicLibrary.inc
-@@ -102,7 +102,7 @@ static void *DoSearch(const char* SymbolName) {
-
- // This macro returns the address of a well-known, explicit symbol
- #define EXPLICIT_SYMBOL(SYM) \
-- if (!strcmp(SymbolName, #SYM)) return &SYM
-+ if (!strcmp(SymbolName, #SYM)) return (void *)&SYM
-
- // Under glibc we have a weird situation. The stderr/out/in symbols are both
- // macros and global variables because of standards requirements. So, we
-diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
-index d882ab2e..f1fb12d0 100644
---- a/llvm/utils/unittest/googletest/src/gtest.cc
-+++ b/llvm/utils/unittest/googletest/src/gtest.cc
-@@ -128,6 +128,7 @@
-
- #if GTEST_CAN_STREAM_RESULTS_
- # include <arpa/inet.h> // NOLINT
-+# include <sys/socket.h> // NOLINT
- # include <netdb.h> // NOLINT
- # include <sys/socket.h> // NOLINT
- # include <sys/types.h> // NOLINT
diff --git a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
deleted file mode 100644
index 0071d964bd371f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-This patches LLVM to use ELFv2 on ppc64 unconditionally unless overridden. We
-need this because unlike most distros we use ELFv2 for both glibc and musl
-on big endian ppc64.
-
-diff --git a/lib/Target/PowerPC/PPCTargetMachine.cpp b/lib/Target/PowerPC/PPCTargetMachine.cpp
-index 0634833e..b7cbc2e7 100644
---- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-@@ -222,9 +222,8 @@ static PPCTargetMachine::PPCABI computeTargetABI(const Triple &TT,
-
- switch (TT.getArch()) {
- case Triple::ppc64le:
-- return PPCTargetMachine::PPC_ABI_ELFv2;
- case Triple::ppc64:
-- return PPCTargetMachine::PPC_ABI_ELFv1;
-+ return PPCTargetMachine::PPC_ABI_ELFv2;
- default:
- return PPCTargetMachine::PPC_ABI_UNKNOWN;
- }
-diff --git a/test/CodeGen/PowerPC/ppc64-elf-abi.ll b/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-index 8b1cf6b5..296a2afa 100644
---- a/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-+++ b/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-@@ -1,4 +1,5 @@
--; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv1
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-musl < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
diff --git a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch b/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
deleted file mode 100644
index b5d15974375d49..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-@@ -165,7 +165,7 @@ void PPCSubtarget::initSubtargetFeatures(StringRef CPU, StringRef FS) {
-
- if ((TargetTriple.isOSFreeBSD() && TargetTriple.getOSMajorVersion() >= 13) ||
- TargetTriple.isOSNetBSD() || TargetTriple.isOSOpenBSD() ||
-- TargetTriple.isMusl())
-+ isTargetLinux())
- SecurePlt = true;
-
- if (HasSPE && IsPPC64)
diff --git a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch b/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
deleted file mode 100644
index 51d0e4b31b32c3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-This allows us to override the optimization level as not all platforms can
-deal with -O3.
-
---- a/llvm/CMakeLists.txt
-+++ b/llvm/CMakeLists.txt
-@@ -918,6 +918,12 @@ if( MINGW AND NOT "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang" )
- llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "-O2")
- endif()
-
-+set(VOID_CXX_OPT_FLAGS "" CACHE STRING "Optimization level to use")
-+
-+if (NOT VOID_CXX_OPT_FLAGS STREQUAL "")
-+ llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "${VOID_CXX_OPT_FLAGS}")
-+endif()
-+
- # Put this before tblgen. Else we have a circular dependence.
- add_subdirectory(lib/Demangle)
- add_subdirectory(lib/Support)
diff --git a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
deleted file mode 100644
index d332687b9d9295..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From f3dbdd49c06bfafc1d6138094cf42889c14d38b6 Mon Sep 17 00:00:00 2001
-From: Samuel Holland <samuel@sholland.org>
-Date: Sun, 3 Nov 2019 10:57:27 -0600
-Subject: [PATCH] [LLVM][PowerPC] Assume BigPIC if no PIC level is specified
-
----
- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp | 2 +-
- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/lib/Target/PowerPC/PPCAsmPrinter.cpp b/lib/Target/PowerPC/PPCAsmPrinter.cpp
-index cce21f32..87ca5f9b 100644
---- a/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-@@ -520,7 +520,7 @@ void PPCAsmPrinter::EmitTlsCall(const MachineInstr *MI,
-
- // Add 32768 offset to the symbol so we follow up the latest GOT/PLT ABI.
- if (Kind == MCSymbolRefExpr::VK_PLT && Subtarget->isSecurePlt() &&
-- M->getPICLevel() == PICLevel::BigPIC)
-+ M->getPICLevel() != PICLevel::SmallPIC)
- TlsRef = MCBinaryExpr::createAdd(
- TlsRef, MCConstantExpr::create(32768, OutContext), OutContext);
- const MachineOperand &MO = MI->getOperand(2);
-diff --git a/lib/Target/PowerPC/PPCMCInstLower.cpp b/lib/Target/PowerPC/PPCMCInstLower.cpp
-index 5cc180d7..a5b02565 100644
---- a/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-@@ -117,7 +117,7 @@ static MCOperand GetSymbolRef(const MachineOperand &MO, const MCSymbol *Symbol,
- const MCExpr *Expr = MCSymbolRefExpr::create(Symbol, RefKind, Ctx);
- // If -msecure-plt -fPIC, add 32768 to symbol.
- if (Subtarget->isSecurePlt() && TM.isPositionIndependent() &&
-- M->getPICLevel() == PICLevel::BigPIC &&
-+ M->getPICLevel() != PICLevel::SmallPIC &&
- MO.getTargetFlags() == PPCII::MO_PLT)
- Expr =
- MCBinaryExpr::createAdd(Expr, MCConstantExpr::create(32768, Ctx), Ctx);
diff --git a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch b/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
deleted file mode 100644
index a00abd2166651f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Fix failures in AllocationTests/MappedMemoryTest.* on aarch64:
-
- Failing Tests (8):
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.AllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.DuplicateNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.EnabledWrite/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.MultipleAllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.SuccessiveNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.UnalignedNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroSizeNear/3
-
-Upstream-Issue: https://bugs.llvm.org/show_bug.cgi?id=14278#c10
-
---- a/llvm/lib/Support/Unix/Memory.inc
-+++ b/llvm/lib/Support/Unix/Memory.inc
-@@ -58,7 +58,7 @@ static int getPosixProtectionFlags(unsigned Flags) {
- return PROT_READ | PROT_WRITE | PROT_EXEC;
- case llvm::sys::Memory::MF_EXEC:
- #if (defined(__FreeBSD__) || defined(__POWERPC__) || defined (__ppc__) || \
-- defined(_POWER) || defined(_ARCH_PPC))
-+ defined(_POWER) || defined(_ARCH_PPC) || (defined(__linux__) && defined(__aarch64__)))
- // On PowerPC, having an executable page that has no read permission
- // can have unintended consequences. The function InvalidateInstruction-
- // Cache uses instructions dcbf and icbi, both of which are treated by
diff --git a/srcpkgs/llvm12/patches/llvm-gcc13.patch b/srcpkgs/llvm12/patches/llvm-gcc13.patch
deleted file mode 100644
index 6895221b73bb75..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-gcc13.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From ff1681ddb303223973653f7f5f3f3435b48a1983 Mon Sep 17 00:00:00 2001
-From: Sergei Trofimovich <slyich@gmail.com>
-Date: Mon, 23 May 2022 08:03:23 +0100
-Subject: [PATCH] [Support] Add missing <cstdint> header to Signals.h
-
-Without the change llvm build fails on this week's gcc-13 snapshot as:
-
- [ 0%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o
- In file included from llvm/lib/Support/Signals.cpp:14:
- llvm/include/llvm/Support/Signals.h:119:8: error: variable or field 'CleanupOnSignal' declared void
- 119 | void CleanupOnSignal(uintptr_t Context);
- | ^~~~~~~~~~~~~~~
----
- llvm/include/llvm/Support/Signals.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/llvm/include/llvm/Support/Signals.h b/llvm/include/llvm/Support/Signals.h
-index 44f5a750ff5cb0..937e0572d4a725 100644
---- a/llvm/include/llvm/Support/Signals.h
-+++ b/llvm/include/llvm/Support/Signals.h
-@@ -14,6 +14,7 @@
- #ifndef LLVM_SUPPORT_SIGNALS_H
- #define LLVM_SUPPORT_SIGNALS_H
-
-+#include <cstdint>
- #include <string>
-
- namespace llvm {
diff --git a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch b/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
deleted file mode 100644
index 8e0a9a779d1bf8..00000000000000
--- a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-commit ba4ede595ff9599232f5dd2b4384c243137b53fc
-Author: Daniel Kolesa <daniel@octaforge.org>
-Date: Tue Jun 22 23:40:54 2021 +0200
-
- enable compiler-rt support for ppc32
-
-diff --git a/compiler-rt/cmake/base-config-ix.cmake b/compiler-rt/cmake/base-config-ix.cmake
-index 1edab43..5c0c8a2 100644
---- a/compiler-rt/cmake/base-config-ix.cmake
-+++ b/compiler-rt/cmake/base-config-ix.cmake
-@@ -182,9 +182,7 @@ macro(test_targets)
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc64le")
- test_target_arch(powerpc64le "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc")
-- if(CMAKE_SYSTEM_NAME MATCHES "AIX")
-- test_target_arch(powerpc "" "-m32")
-- endif()
-+ test_target_arch(powerpc "" "-m32")
- test_target_arch(powerpc64 "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "s390x")
- test_target_arch(s390x "" "")
diff --git a/srcpkgs/llvm12/template b/srcpkgs/llvm12/template
deleted file mode 100644
index 86e86bb96c63f1..00000000000000
--- a/srcpkgs/llvm12/template
+++ /dev/null
@@ -1,161 +0,0 @@
-# Template file for 'llvm12'
-pkgname=llvm12
-version=12.0.1
-revision=4
-build_wrksrc=llvm
-build_style=cmake
-configure_args="
- -DCMAKE_BUILD_TYPE=Release -Wno-dev
- -DENABLE_LINKER_BUILD_ID=YES
- -DLLDB_USE_SYSTEM_SIX=YES
- -DLIBCXX_CXX_ABI=libcxxabi
- -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=YES
- -DLIBCXXABI_USE_LLVM_UNWINDER=YES
- -DLIBCXXABI_ENABLE_STATIC_UNWINDER=YES
- -DLIBOMP_ENABLE_SHARED=YES
- -DLIBOMP_INSTALL_ALIASES=NO
- -DLLVM_INCLUDE_DOCS=YES
- -DLLVM_BUILD_DOCS=YES
- -DLLVM_ENABLE_SPHINX=YES
- -DSPHINX_WARNINGS_AS_ERRORS=NO
- -DLLVM_INSTALL_UTILS=YES
- -DLLVM_BUILD_LLVM_DYLIB=YES
- -DLLVM_LINK_LLVM_DYLIB=YES
- -DLLVM_ENABLE_RTTI=YES
- -DLLVM_ENABLE_FFI=YES
- -DLLVM_BINUTILS_INCDIR=/usr/include"
-hostmakedepends="perl python3 zlib-devel libffi-devel swig python3-Sphinx
- python3-recommonmark python3-sphinx-automodapi"
-makedepends="python3-devel zlib-devel elfutils-devel libffi-devel libedit-devel
- libxml2-devel binutils-devel"
-depends="libllvm12>=${version}_${revision}"
-short_desc="Low Level Virtual Machine"
-maintainer="Orphaned <orphan@voidlinux.org>"
-license="Apache-2.0"
-homepage="https://www.llvm.org"
-distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-project-${version}.src.tar.xz"
-checksum=129cb25cd13677aad951ce5c2deb0fe4afc1e9d98950f53b51bdcfb5a73afa0e
-lib32disabled=yes
-python_version=3
-
-if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
- configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
- makedepends+=" libexecinfo-devel"
- depends+=" libexecinfo-devel"
-fi
-
-# "operand out of range" assembler failures
-case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*) configure_args+=" -DCLANG_ENABLE_CLANGD=OFF" ;;
-esac
-
-post_patch() {
- # update config.guess for better platform detection
- cp $XBPS_COMMONDIR/environment/configure/automake/config.guess \
- ${wrksrc}/llvm/cmake
-
- # fix linker failures on some archs
- vsed -i 's,check_library_exists(gcc_s .*,set(LIBCXXABI_HAS_GCC_S_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
- vsed -i 's,check_library_exists(gcc .*,set(LIBCXXABI_HAS_GCC_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
-
- # need libssp_nonshared on some musl platforms (because of nodefaultlibs)
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*-musl|i686-musl|mips*-musl)
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libunwind/src/CMakeLists.txt
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libcxxabi/src/CMakeLists.txt
- vsed -i 's,#ssp,,' ${wrksrc}/libcxx/CMakeLists.txt
- ;;
- 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
- ;;
- esac
-}
-
-pre_configure() {
- local triplet
-
- # Vastly reduce size of debugging symbols:
- CFLAGS=${CFLAGS/ -g/ -g1}
- CXXFLAGS=${CXXFLAGS/ -g/ -g1}
-
- # since gcc9, the build likes to blow up for ppc32 apparently because
- # of clang being too large for a 24-bit relative call to the PLT, so
- # optimize for size instead
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- mips*-musl|ppc*) configure_args+=" -DVOID_CXX_OPT_FLAGS=-Os" ;;
- esac
-
- if [ "$CROSS_BUILD" ]; then
- msg_normal "Building host tblgen\n"
- mkdir -p build/HOST
- cd build/HOST
- CC="$BUILD_CC" CXX="$BUILD_CXX" CFLAGS="$BUILD_CFLAGS" \
- CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
- cmake ../.. -DCMAKE_BUILD_TYPE=Release
- make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
- [ "$_lldb_enable" = "yes" ] && make ${makejobs} -C tools/lldb/utils/TableGen
- configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/clang-tblgen"
- cd ../..
- fi
-
- case "$XBPS_TARGET_MACHINE" in
- i686*) _arch="X86";;
- x86_64*) _arch="X86";;
- armv5*) _arch="Armv5te";;
- armv6*) _arch="Armv6";;
- armv7*) _arch="Armv7";;
- aarch64*) _arch="AArch64";;
- mips*) _arch="Mips";;
- ppc*) _arch="PowerPC";;
- riscv64*) _arch="RISCV64";;
- esac
-
- triplet=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}
-
- configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
- configure_args+=" -DLLVM_HOST_TRIPLE=${triplet}"
- configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${triplet}"
-}
-
-do_install() {
- cd build
- cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
-
- # Required for multilib.
- if [ "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
- for _header in llvm-config; do
- mv ${DESTDIR}/usr/include/llvm/Config/${_header}{,-64}.h
- vinstall ${FILESDIR}/llvm-Config-${_header}.h 644 \
- usr/include/llvm/Config ${_header}.h
- done
- fi
-
- # Remove llvm-config-host in cross builds.
- if [ "$CROSS_BUILD" ]; then
- rm -f ${DESTDIR}/usr/bin/llvm-config-host
- fi
-}
-
-libllvm12_package() {
- short_desc+=" - runtime library"
- pkg_install() {
- vmove "usr/lib/libLLVM-*.so*"
- }
-}
diff --git a/srcpkgs/llvm12/update b/srcpkgs/llvm12/update
deleted file mode 100644
index e95cf26b3586b7..00000000000000
--- a/srcpkgs/llvm12/update
+++ /dev/null
@@ -1,3 +0,0 @@
-site="https://github.com/llvm/llvm-project/releases"
-pattern="llvmorg-\K(\d+.){2}\d+(-rc\d+)?"
-ignore="*-rc*"
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index 1e2e65f7e82340..8adebce925c861 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,7 +1,7 @@
# Template file for 'removed-packages'
pkgname=removed-packages
-version=0.1.20240625
-revision=2
+version=0.1.20240709
+revision=1
build_style=meta
short_desc="Uninstalls packages removed from repository"
maintainer="Piotr Wójcik <chocimier@tlen.pl>"
@@ -370,6 +370,7 @@ replaces="
libgroff<=1.22.4_3
libgtkhtml<=4.10.0_1
libkscreen<=5.27.11_3
+ libllvm12<=12.0.1_4
libllvm10<=10.0.0_8
libllvm11<=11.0.0_2
libllvm6.0<=6.0.1_8
@@ -429,6 +430,7 @@ replaces="
livewallpaper<=0.5.0_2
lld-devel<=15.0.7_3
lldb-devel<=15.0.7_3
+ llvm12<=12.0.1_4
llvm10<=10.0.0_8
llvm11<=11.0.0_2
llvm3.9<=3.9.1_5
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR REVIEW] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
@ 2024-07-10 3:10 ` Calandracas606
2024-07-10 3:12 ` Calandracas606
` (13 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-10 3:10 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 234 bytes --]
New review comment by Calandracas606 on void-packages repository
https://github.com/void-linux/void-packages/pull/51186#discussion_r1671553261
Comment:
tested with with the llvm build option enabled, although this isn't the default
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR REVIEW] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
2024-07-10 3:10 ` [PR REVIEW] " Calandracas606
@ 2024-07-10 3:12 ` Calandracas606
2024-07-10 4:17 ` Calandracas606
` (12 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-10 3:12 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 326 bytes --]
New review comment by Calandracas606 on void-packages repository
https://github.com/void-linux/void-packages/pull/51186#discussion_r1671554473
Comment:
For packages which only use llvm in hostmakedepends, and only because they want to use clang as the compiler, should we still use `llvm18 clang18` instead of `llvm clang`?
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
2024-07-10 3:10 ` [PR REVIEW] " Calandracas606
2024-07-10 3:12 ` Calandracas606
@ 2024-07-10 4:17 ` Calandracas606
2024-07-29 8:40 ` tranzystorekk
` (11 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-10 4:17 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 214 bytes --]
New comment by Calandracas606 on void-packages repository
https://github.com/void-linux/void-packages/pull/51186#issuecomment-2219516190
Comment:
CI errors are timeouts in the tests, I'm not getting them locally
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (2 preceding siblings ...)
2024-07-10 4:17 ` Calandracas606
@ 2024-07-29 8:40 ` tranzystorekk
2024-07-29 12:00 ` [PR PATCH] [Updated] " Calandracas606
` (10 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: tranzystorekk @ 2024-07-29 8:40 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 230 bytes --]
New comment by tranzystorekk on void-packages repository
https://github.com/void-linux/void-packages/pull/51186#issuecomment-2255343561
Comment:
Maybe we should do the llvm18 transitions first, in separate PRs, just to be safe?
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (3 preceding siblings ...)
2024-07-29 8:40 ` tranzystorekk
@ 2024-07-29 12:00 ` Calandracas606
2024-07-29 12:01 ` Calandracas606
` (9 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-29 12:00 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1422 bytes --]
There is an updated pull request by Calandracas606 against master on the void-packages repository
https://github.com/Calandracas606/void-packages remove-llvm12
https://github.com/void-linux/void-packages/pull/51186
remove llvm12
- **mozjs102: build with llvm18**
- **ghdl: update to 4.1.0.**
- **llvm12: remove package**
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, x86_64
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64-musl
- i686
- aarch64 (cross)
- aarch64-musl (cross)
- armv7l (cross)
- armv7l-musl (cross)
- armv6l (cross)
- armv6l-musl (cross)
A patch file from https://github.com/void-linux/void-packages/pull/51186.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-remove-llvm12-51186.patch --]
[-- Type: text/x-diff, Size: 50344 bytes --]
From 1b5f2d6d97c4f24d485a1654b23b70d21cde8e79 Mon Sep 17 00:00:00 2001
From: Daniel Martinez <danielmartinez@cock.li>
Date: Tue, 9 Jul 2024 22:18:51 -0400
Subject: [PATCH] llvm12: remove package
---
common/shlibs | 2 +
srcpkgs/libllvm12 | 1 -
.../llvm12/files/llvm-Config-llvm-config.h | 9 -
...clang-001-fix-unwind-chain-inclusion.patch | 44 -----
.../patches/clang-002-add-musl-triples.patch | 110 ------------
.../clang-003-ppc64-dynamic-linker-path.patch | 13 --
.../patches/clang-004-ppc64-musl-elfv2.patch | 48 ------
.../compiler-rt-aarch64-ucontext.patch | 11 --
.../compiler-rt-sanitizer-glibc-2.36.patch | 59 -------
.../compiler-rt-sanitizer-ppc64-musl.patch | 35 ----
.../llvm12/patches/compiler-rt-size_t.patch | 10 --
.../patches/compiler-rt-xray-ppc64-musl.patch | 62 -------
srcpkgs/llvm12/patches/libcxx-musl.patch | 26 ---
srcpkgs/llvm12/patches/libcxx-ppc.patch | 22 ---
.../llvm12/patches/libcxx-ssp-nonshared.patch | 11 --
srcpkgs/llvm12/patches/libcxxabi-dl.patch | 25 ---
srcpkgs/llvm12/patches/libunwind-ppc32.patch | 63 -------
srcpkgs/llvm12/patches/lldb-musl.patch | 31 ----
srcpkgs/llvm12/patches/llvm-001-musl.patch | 57 -------
.../patches/llvm-002-musl-ppc64-elfv2.patch | 30 ----
.../patches/llvm-003-ppc-secureplt.patch | 11 --
.../patches/llvm-004-override-opt.patch | 18 --
.../llvm12/patches/llvm-005-ppc-bigpic.patch | 36 ----
.../patches/llvm-006-aarch64-mf_exec.patch | 25 ---
srcpkgs/llvm12/patches/llvm-gcc13.patch | 28 ---
.../llvm12/patches/ppc32-compiler-rt.patch | 21 ---
srcpkgs/llvm12/template | 161 ------------------
srcpkgs/llvm12/update | 3 -
srcpkgs/removed-packages/template | 7 +-
29 files changed, 8 insertions(+), 971 deletions(-)
delete mode 120000 srcpkgs/libllvm12
delete mode 100644 srcpkgs/llvm12/files/llvm-Config-llvm-config.h
delete mode 100644 srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-size_t.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ppc.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxxabi-dl.patch
delete mode 100644 srcpkgs/llvm12/patches/libunwind-ppc32.patch
delete mode 100644 srcpkgs/llvm12/patches/lldb-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-001-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-004-override-opt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-gcc13.patch
delete mode 100644 srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
delete mode 100644 srcpkgs/llvm12/template
delete mode 100644 srcpkgs/llvm12/update
diff --git a/common/shlibs b/common/shlibs
index 5cfafa2be55b75..c3f08c44b7ba48 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -994,6 +994,8 @@ libclang-cpp.so.18.1 libclang-cpp18-18.1.8_1
libclang-cpp.so.17 libclang-cpp17-17.0.6_1
libLLVM-11.so libllvm11-11.0.0_1
libLLVM-12.so libllvm12-12.0.0_1
+libclang-cpp.so.15 libclang-cpp15-15.0.7_4
+libLLVM-15.so libllvm15-15.0.7_4
libLLVM-17.so libllvm17-17.0.6_1
libLLVM.so.18.1 libllvm18-18.1.8_1
libLLVMSPIRVLib.so.18.1 SPIRV-LLVM-Translator-18.1.2_1
diff --git a/srcpkgs/libllvm12 b/srcpkgs/libllvm12
deleted file mode 120000
index cd60fd7a981bdd..00000000000000
--- a/srcpkgs/libllvm12
+++ /dev/null
@@ -1 +0,0 @@
-llvm12
\ No newline at end of file
diff --git a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h b/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
deleted file mode 100644
index 2fa08c9be69621..00000000000000
--- a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
+++ /dev/null
@@ -1,9 +0,0 @@
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 32
-#include "llvm-config-32.h"
-#elif __WORDSIZE == 64
-#include "llvm-config-64.h"
-#else
-#error "Unknown word size"
-#endif
diff --git a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
deleted file mode 100644
index e4eaa7783e7a6c..00000000000000
--- a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 352974169f0d2b5da3d5321f588f5e3b5941330e Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:14:57 +0200
-Subject: [PATCH 2/7] fix unwind chain inclusion
-
----
- lib/Headers/unwind.h | 9 +++++----
- 1 file changed, 5 insertions(+), 4 deletions(-)
-
-diff --git a/lib/Headers/unwind.h b/lib/Headers/unwind.h
-index 303d792..44e10cc 100644
---- a/clang/lib/Headers/unwind.h
-+++ b/clang/lib/Headers/unwind.h
-@@ -9,9 +9,6 @@
-
- /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/
-
--#ifndef __CLANG_UNWIND_H
--#define __CLANG_UNWIND_H
--
- #if defined(__APPLE__) && __has_include_next(<unwind.h>)
- /* Darwin (from 11.x on) provide an unwind.h. If that's available,
- * use it. libunwind wraps some of its definitions in #ifdef _GNU_SOURCE,
-@@ -39,6 +36,9 @@
- # endif
- #else
-
-+#ifndef __CLANG_UNWIND_H
-+#define __CLANG_UNWIND_H
-+
- #include <stdint.h>
-
- #ifdef __cplusplus
-@@ -322,6 +322,7 @@ _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *);
- }
- #endif
-
-+#endif /* __CLANG_UNWIND_H */
-+
- #endif
-
--#endif /* __CLANG_UNWIND_H */
---
-2.5.1
diff --git a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch b/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
deleted file mode 100644
index 25688d40dbc275..00000000000000
--- a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
+++ /dev/null
@@ -1,110 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Gnu.cpp
-+++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2086,7 +2086,8 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
- "armv7hl-redhat-linux-gnueabi",
- "armv6hl-suse-linux-gnueabi",
-- "armv7hl-suse-linux-gnueabi"};
-+ "armv7hl-suse-linux-gnueabi",
-+ "armv7l-linux-gnueabihf"};
- static const char *const ARMebLibDirs[] = {"/lib"};
- static const char *const ARMebTriples[] = {"armeb-linux-gnueabi",
- "armeb-linux-androideabi"};
-@@ -2153,8 +2154,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- "powerpc64-suse-linux", "powerpc-montavista-linuxspe"};
- static const char *const PPCLELibDirs[] = {"/lib32", "/lib"};
- static const char *const PPCLETriples[] = {"powerpcle-linux-gnu",
-- "powerpcle-unknown-linux-gnu",
-- "powerpcle-linux-musl"};
-+ "powerpcle-unknown-linux-gnu"};
-
- static const char *const PPC64LibDirs[] = {"/lib64", "/lib"};
- static const char *const PPC64Triples[] = {
-@@ -2235,6 +2235,87 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- return;
- }
-
-+ if (TargetTriple.isMusl()) {
-+ static const char *const AArch64MuslTriples[] = {"aarch64-linux-musl"};
-+ static const char *const ARMHFMuslTriples[] = {
-+ "arm-linux-musleabihf", "armv7l-linux-musleabihf"
-+ };
-+ static const char *const ARMMuslTriples[] = {"arm-linux-musleabi"};
-+ static const char *const X86_64MuslTriples[] = {"x86_64-linux-musl"};
-+ static const char *const X86MuslTriples[] = {"i686-linux-musl"};
-+ static const char *const MIPSMuslTriples[] = {
-+ "mips-linux-musl", "mipsel-linux-musl",
-+ "mipsel-linux-muslhf", "mips-linux-muslhf"
-+ };
-+ static const char *const PPCMuslTriples[] = {"powerpc-linux-musl"};
-+ static const char *const PPCLEMuslTriples[] = {"powerpcle-linux-musl"};
-+ static const char *const PPC64MuslTriples[] = {"powerpc64-linux-musl"};
-+ static const char *const PPC64LEMuslTriples[] = {"powerpc64le-linux-musl"};
-+
-+ switch (TargetTriple.getArch()) {
-+ case llvm::Triple::aarch64:
-+ LibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ TripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ BiarchLibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ BiarchTripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ break;
-+ case llvm::Triple::arm:
-+ LibDirs.append(begin(ARMLibDirs), end(ARMLibDirs));
-+ if (TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
-+ TripleAliases.append(begin(ARMHFMuslTriples), end(ARMHFMuslTriples));
-+ } else {
-+ TripleAliases.append(begin(ARMMuslTriples), end(ARMMuslTriples));
-+ }
-+ break;
-+ case llvm::Triple::x86_64:
-+ LibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ TripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ BiarchLibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ BiarchTripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ break;
-+ case llvm::Triple::x86:
-+ LibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ TripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ BiarchLibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ BiarchTripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ break;
-+ case llvm::Triple::mips:
-+ LibDirs.append(begin(MIPSLibDirs), end(MIPSLibDirs));
-+ TripleAliases.append(begin(MIPSMuslTriples), end(MIPSMuslTriples));
-+ break;
-+ case llvm::Triple::ppc:
-+ LibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ TripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ BiarchTripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ break;
-+ case llvm::Triple::ppcle:
-+ LibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ TripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ BiarchTripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64:
-+ LibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ TripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ BiarchLibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ BiarchTripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64le:
-+ LibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ TripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ BiarchLibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ BiarchTripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ break;
-+ default:
-+ break;
-+ }
-+ TripleAliases.push_back(TargetTriple.str());
-+ if (TargetTriple.str() != BiarchTriple.str())
-+ BiarchTripleAliases.push_back(BiarchTriple.str());
-+ return;
-+ }
-+
- // Android targets should not use GNU/Linux tools or libraries.
- if (TargetTriple.isAndroid()) {
- static const char *const AArch64AndroidTriples[] = {
diff --git a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
deleted file mode 100644
index 4ad6412d1e6c63..00000000000000
--- a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Linux.cpp
-+++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -504,10 +504,6 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
- Loader = "ld.so.1";
- break;
- case llvm::Triple::ppc64:
-- LibDir = "lib64";
-- Loader =
-- (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
-- break;
- case llvm::Triple::ppc64le:
- LibDir = "lib64";
- Loader =
diff --git a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
deleted file mode 100644
index 21fc8003c5f1a8..00000000000000
--- a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
+++ /dev/null
@@ -1,48 +0,0 @@
---- a/clang/lib/Basic/Targets/PPC.h
-+++ b/clang/lib/Basic/Targets/PPC.h
-@@ -415,11 +415,10 @@ public:
- LongDoubleFormat = &llvm::APFloat::IEEEdouble();
- } else if ((Triple.getArch() == llvm::Triple::ppc64le)) {
- DataLayout = "e-m:e-i64:64-n32:64";
-- ABI = "elfv2";
- } else {
- DataLayout = "E-m:e-i64:64-n32:64";
-- ABI = "elfv1";
- }
-+ ABI = "elfv2";
-
- if (Triple.isOSFreeBSD() || Triple.isOSOpenBSD() || Triple.isMusl()) {
- LongDoubleWidth = LongDoubleAlign = 64;
---- a/clang/lib/CodeGen/TargetInfo.cpp
-+++ b/clang/lib/CodeGen/TargetInfo.cpp
-@@ -10927,9 +10927,9 @@ const TargetCodeGenInfo &CodeGenModule::getTargetCodeGenInfo() {
- return SetCGInfo(new AIXTargetCodeGenInfo(Types, /*Is64Bit*/ true));
-
- if (Triple.isOSBinFormatELF()) {
-- PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv1;
-- if (getTarget().getABI() == "elfv2")
-- Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ if (getTarget().getABI() == "elfv1")
-+ Kind = PPC64_SVR4_ABIInfo::ELFv1;
- bool IsSoftFloat = CodeGenOpts.FloatABI == "soft";
-
- return SetCGInfo(
---- a/clang/lib/Driver/ToolChains/Clang.cpp
-+++ b/clang/lib/Driver/ToolChains/Clang.cpp
-@@ -1920,14 +1920,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
- const llvm::Triple &T = getToolChain().getTriple();
- if (T.isOSBinFormatELF()) {
- switch (getToolChain().getArch()) {
-- case llvm::Triple::ppc64: {
-- if ((T.isOSFreeBSD() && T.getOSMajorVersion() >= 13) ||
-- T.isOSOpenBSD() || T.isMusl())
-- ABIName = "elfv2";
-- else
-- ABIName = "elfv1";
-- break;
-- }
-+ case llvm::Triple::ppc64:
- case llvm::Triple::ppc64le:
- ABIName = "elfv2";
- break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch b/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
deleted file mode 100644
index 893c059d7b8def..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp.orig
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -1799,7 +1799,7 @@
-
- static bool Aarch64GetESR(ucontext_t *ucontext, u64 *esr) {
- static const u32 kEsrMagic = 0x45535201;
-- u8 *aux = ucontext->uc_mcontext.__reserved;
-+ u8 *aux = reinterpret_cast<u8 *>(ucontext->uc_mcontext.__reserved);
- while (true) {
- _aarch64_ctx *ctx = (_aarch64_ctx *)aux;
- if (ctx->size == 0) break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
deleted file mode 100644
index e5f24dab893547..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From 9cf13067cb5088626ba7ee1ec4c42ec59c7995a0 Mon Sep 17 00:00:00 2001
-From: Fangrui Song <i@maskray.me>
-Date: Mon, 11 Jul 2022 12:53:34 -0700
-Subject: [PATCH] [sanitizer] Remove #include <linux/fs.h> to resolve
- fsconfig_command/mount_attr conflict with glibc 2.36
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-It is generally not a good idea to mix usage of glibc headers and Linux UAPI
-headers (https://sourceware.org/glibc/wiki/Synchronizing_Headers). In glibc
-since 7eae6a91e9b1670330c9f15730082c91c0b1d570 (milestone: 2.36), sys/mount.h
-defines `fsconfig_command` which conflicts with linux/mount.h:
-
- .../usr/include/linux/mount.h:95:6: error: redeclaration of ‘enum fsconfig_command’
-
-Remove #include <linux/fs.h> which pulls in linux/mount.h. Expand its 4 macros manually.
-Android sys/mount.h doesn't define BLKBSZGET and it still needs linux/fs.h.
-In the long term we should move Linux specific definitions to sanitizer_platform_limits_linux.cpp
-but this commit is easy to cherry pick into older compiler-rt releases.
-
-Fix https://github.com/llvm/llvm-project/issues/56421
-
-Reviewed By: #sanitizers, vitalybuka, zatrazz
-
-Differential Revision: https://reviews.llvm.org/D129471
----
- .../sanitizer_platform_limits_posix.cpp | 10 ++++++----
- 1 file changed, 6 insertions(+), 4 deletions(-)
-
-diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-index 4bd425435d56d..3a94b260686f1 100644
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -73,7 +73,9 @@
- #include <sys/vt.h>
- #include <linux/cdrom.h>
- #include <linux/fd.h>
-+#if SANITIZER_ANDROID
- #include <linux/fs.h>
-+#endif
- #include <linux/hdreg.h>
- #include <linux/input.h>
- #include <linux/ioctl.h>
-@@ -876,10 +878,10 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr);
- unsigned IOCTL_EVIOCGPROP = IOCTL_NOT_PRESENT;
- unsigned IOCTL_EVIOCSKEYCODE_V2 = IOCTL_NOT_PRESENT;
- #endif
-- unsigned IOCTL_FS_IOC_GETFLAGS = FS_IOC_GETFLAGS;
-- unsigned IOCTL_FS_IOC_GETVERSION = FS_IOC_GETVERSION;
-- unsigned IOCTL_FS_IOC_SETFLAGS = FS_IOC_SETFLAGS;
-- unsigned IOCTL_FS_IOC_SETVERSION = FS_IOC_SETVERSION;
-+ unsigned IOCTL_FS_IOC_GETFLAGS = _IOR('f', 1, long);
-+ unsigned IOCTL_FS_IOC_GETVERSION = _IOR('v', 1, long);
-+ unsigned IOCTL_FS_IOC_SETFLAGS = _IOW('f', 2, long);
-+ unsigned IOCTL_FS_IOC_SETVERSION = _IOW('v', 2, long);
- unsigned IOCTL_GIO_CMAP = GIO_CMAP;
- unsigned IOCTL_GIO_FONT = GIO_FONT;
- unsigned IOCTL_GIO_UNIMAP = GIO_UNIMAP;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
deleted file mode 100644
index 35f16d24f340c6..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
+++ /dev/null
@@ -1,35 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -74,6 +74,10 @@
- #include <sys/utsname.h>
- #endif
-
-+#if SANITIZER_LINUX && defined(__powerpc__)
-+#include <asm/ptrace.h>
-+#endif
-+
- #if SANITIZER_LINUX && !SANITIZER_ANDROID
- #include <sys/personality.h>
- #endif
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -92,7 +92,7 @@
- # include <utime.h>
- # include <sys/ptrace.h>
- #if defined(__mips64) || defined(__aarch64__) || defined(__arm__) || \
-- SANITIZER_RISCV64
-+ defined(__powerpc__) || SANITIZER_RISCV64
- # include <asm/ptrace.h>
- # ifdef __arm__
- typedef struct user_fpregs elf_fpregset_t;
---- a/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-@@ -31,7 +31,7 @@
- #include <sys/types.h> // for pid_t
- #include <sys/uio.h> // for iovec
- #include <elf.h> // for NT_PRSTATUS
--#if (defined(__aarch64__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
-+#if (defined(__aarch64__) || defined(__powerpc__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
- // GLIBC 2.20+ sys/user does not include asm/ptrace.h
- # include <asm/ptrace.h>
- #endif
diff --git a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch b/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
deleted file mode 100644
index 2c63063a5e9e3f..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp.orig
-+++ b/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp
-@@ -25,6 +25,7 @@
- }
-
- #include <cassert>
-+#include <cstddef>
- #include <cstdint>
- #include <dlfcn.h> // for dlsym()
-
diff --git a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
deleted file mode 100644
index d0b61c80c897f4..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
+++ /dev/null
@@ -1,62 +0,0 @@
---- a/compiler-rt/lib/xray/xray_powerpc64.inc
-+++ b/compiler-rt/lib/xray/xray_powerpc64.inc
-@@ -12,7 +12,13 @@
-
- #include <cstdint>
- #include <mutex>
-+#ifdef __GLIBC__
- #include <sys/platform/ppc.h>
-+#else
-+#include <cctype>
-+#include <cstring>
-+#include <cstdlib>
-+#endif
-
- #include "xray_defs.h"
-
-@@ -20,13 +26,45 @@ namespace __xray {
-
- ALWAYS_INLINE uint64_t readTSC(uint8_t &CPU) XRAY_NEVER_INSTRUMENT {
- CPU = 0;
-+#ifdef __GLIBC__
- return __ppc_get_timebase();
-+#else
-+ return __builtin_ppc_get_timebase();
-+#endif
- }
-
- inline uint64_t getTSCFrequency() XRAY_NEVER_INSTRUMENT {
- static std::mutex M;
- std::lock_guard<std::mutex> Guard(M);
-+#ifdef __GLIBC__
- return __ppc_get_timebase_freq();
-+#else
-+ /* FIXME: a less dirty implementation? */
-+ static uint64_t base;
-+ if (!base) {
-+ FILE *f = fopen("/proc/cpuinfo", "rb");
-+ if (f) {
-+ ssize_t nr;
-+ /* virtually always big enough to hold the line */
-+ char buf[512];
-+ while (fgets(buf, sizeof(buf), f)) {
-+ char *ret = strstr(buf, "timebase");
-+ if (!ret) {
-+ continue;
-+ }
-+ ret += sizeof("timebase") - 1;
-+ ret = strchr(ret, ':');
-+ if (!ret) {
-+ continue;
-+ }
-+ base = strtoul(ret + 1, nullptr, 10);
-+ break;
-+ }
-+ fclose(f);
-+ }
-+ }
-+ return base;
-+#endif
- }
-
- inline bool probeRequiredCPUFeatures() XRAY_NEVER_INSTRUMENT {
diff --git a/srcpkgs/llvm12/patches/libcxx-musl.patch b/srcpkgs/llvm12/patches/libcxx-musl.patch
deleted file mode 100644
index bbd31ffc2cb1f4..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-musl.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/libcxx/include/locale
-+++ b/libcxx/include/locale
-@@ -742,7 +742,11 @@ __num_get_signed_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ long long __ll = strtoll(__a, &__p2, __base);
-+#else
- long long __ll = strtoll_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
-@@ -782,7 +786,11 @@ __num_get_unsigned_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ unsigned long long __ll = strtoull(__a, &__p2, __base);
-+#else
- unsigned long long __ll = strtoull_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
diff --git a/srcpkgs/llvm12/patches/libcxx-ppc.patch b/srcpkgs/llvm12/patches/libcxx-ppc.patch
deleted file mode 100644
index 7a92f8004e1cf8..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ppc.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-This ensures `is_iec559` is defined correctly under all long double ABIs,
-including musl and its 64-bit long double. Also, `__ppc__` or `__ppc64__`
-is not defined on gcc.
-
---- a/libcxx/include/limits
-+++ b/libcxx/include/limits
-@@ -426,8 +426,14 @@ protected:
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nansl("");}
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __LDBL_DENORM_MIN__;}
-
--#if (defined(__ppc__) || defined(__ppc64__))
-+#if defined(__powerpc__) || defined(__powerpc64__)
-+#if (__LDBL_MAX_EXP__ > __DBL_MAX_EXP__) || (__LDBL_MANT_DIG__ == __DBL_MANT_DIG__)
-+ /* IEEE 754 quadruple or double precision */
-+ static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
-+#else
-+ /* 128-bit IBM double-double */
- static _LIBCPP_CONSTEXPR const bool is_iec559 = false;
-+#endif
- #else
- static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
- #endif
diff --git a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch b/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
deleted file mode 100644
index 70292beb2fcdbd..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/libcxx/CMakeLists.txt
-+++ b/libcxx/CMakeLists.txt
-@@ -769,6 +769,8 @@ function(cxx_link_system_libraries target)
- target_link_libraries(${target} PRIVATE atomic)
- endif()
-
-+#ssp target_link_libraries(${target} PRIVATE ssp_nonshared)
-+
- if (MINGW)
- target_link_libraries(${target} PRIVATE "${MINGW_LIBRARIES}")
- endif()
diff --git a/srcpkgs/llvm12/patches/libcxxabi-dl.patch b/srcpkgs/llvm12/patches/libcxxabi-dl.patch
deleted file mode 100644
index 3a15f9db8c981e..00000000000000
--- a/srcpkgs/llvm12/patches/libcxxabi-dl.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-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()
diff --git a/srcpkgs/llvm12/patches/libunwind-ppc32.patch b/srcpkgs/llvm12/patches/libunwind-ppc32.patch
deleted file mode 100644
index 74aa7576ecf9df..00000000000000
--- a/srcpkgs/llvm12/patches/libunwind-ppc32.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-This fixes build at least with gcc9 which does not define `__ppc__`.
-
---- a/libunwind/include/__libunwind_config.h
-+++ b/libunwind/include/__libunwind_config.h
-@@ -49,7 +49,7 @@
- # define _LIBUNWIND_CONTEXT_SIZE 167
- # define _LIBUNWIND_CURSOR_SIZE 179
- # define _LIBUNWIND_HIGHEST_DWARF_REGISTER _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC64
--# elif defined(__ppc__)
-+# elif defined(__powerpc__)
- # define _LIBUNWIND_TARGET_PPC 1
- # define _LIBUNWIND_CONTEXT_SIZE 117
- # define _LIBUNWIND_CURSOR_SIZE 124
---- a/libunwind/src/UnwindRegistersRestore.S
-+++ b/libunwind/src/UnwindRegistersRestore.S
-@@ -392,7 +392,7 @@ Lnovec:
- PPC64_LR(3)
- bctr
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- DEFINE_LIBUNWIND_FUNCTION(_ZN9libunwind13Registers_ppc6jumptoEv)
- //
---- a/libunwind/src/UnwindRegistersSave.S
-+++ b/libunwind/src/UnwindRegistersSave.S
-@@ -554,7 +554,7 @@ DEFINE_LIBUNWIND_FUNCTION(__unw_getcontext)
- blr
-
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- //
- // extern int unw_getcontext(unw_context_t* thread_state)
---- a/libunwind/src/config.h
-+++ b/libunwind/src/config.h
-@@ -95,12 +95,12 @@
- #define _LIBUNWIND_BUILD_SJLJ_APIS
- #endif
-
--#if defined(__i386__) || defined(__x86_64__) || defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__)
-+#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc__) || defined(__powerpc64__)
- #define _LIBUNWIND_SUPPORT_FRAME_APIS
- #endif
-
- #if defined(__i386__) || defined(__x86_64__) || \
-- defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__) || \
-+ defined(__powerpc__) || defined(__powerpc64__) || \
- (!defined(__APPLE__) && defined(__arm__)) || \
- (defined(__arm64__) || defined(__aarch64__)) || \
- defined(__mips__)
---- a/libunwind/src/libunwind.cpp
-+++ b/libunwind/src/libunwind.cpp
-@@ -42,7 +42,7 @@ _LIBUNWIND_HIDDEN int __unw_init_local(unw_cursor_t *cursor,
- # define REGISTER_KIND Registers_x86_64
- #elif defined(__powerpc64__)
- # define REGISTER_KIND Registers_ppc64
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
- # define REGISTER_KIND Registers_ppc
- #elif defined(__aarch64__)
- # define REGISTER_KIND Registers_arm64
diff --git a/srcpkgs/llvm12/patches/lldb-musl.patch b/srcpkgs/llvm12/patches/lldb-musl.patch
deleted file mode 100644
index 601c0d138523e8..00000000000000
--- a/srcpkgs/llvm12/patches/lldb-musl.patch
+++ /dev/null
@@ -1,31 +0,0 @@
---- a/lldb/source/Plugins/Process/Linux/Procfs.h
-+++ b/lldb/source/Plugins/Process/Linux/Procfs.h
-@@ -10,21 +10,12 @@
- // sys/procfs.h on Android/Linux for all supported architectures.
-
- #include <sys/ptrace.h>
-+#include <asm/ptrace.h>
-
--#ifdef __ANDROID__
--#if defined(__arm64__) || defined(__aarch64__)
--typedef unsigned long elf_greg_t;
--typedef elf_greg_t
-- elf_gregset_t[(sizeof(struct user_pt_regs) / sizeof(elf_greg_t))];
--typedef struct user_fpsimd_state elf_fpregset_t;
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#elif defined(__mips__)
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#endif
--#else // __ANDROID__
-+#if !defined(__GLIBC__) && defined(__powerpc__)
-+#define pt_regs musl_pt_regs
-+#include <sys/procfs.h>
-+#undef pt_regs
-+#else
- #include <sys/procfs.h>
--#endif // __ANDROID__
-+#endif
diff --git a/srcpkgs/llvm12/patches/llvm-001-musl.patch b/srcpkgs/llvm12/patches/llvm-001-musl.patch
deleted file mode 100644
index f2a3f8d62813e3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-001-musl.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From faca3fbd15d0c3108493c3c54cd93138e049ac43 Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:03:02 +0200
-Subject: [PATCH 3/3] musl
-
----
- include/llvm/Analysis/TargetLibraryInfo.h | 9 +++++++++
- lib/Support/DynamicLibrary.cpp | 2 +-
- lib/Support/Unix/Signals.inc | 6 +++---
- utils/unittest/googletest/src/gtest.cc | 1 +
- 5 files changed, 17 insertions(+), 6 deletions(-)
-
-diff --git a/include/llvm/Analysis/TargetLibraryInfo.h b/include/llvm/Analysis/TargetLibraryInfo.h
-index 34a8a1e3..1214ece5 100644
---- a/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-+++ b/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-@@ -18,6 +18,15 @@
- #include "llvm/IR/PassManager.h"
- #include "llvm/Pass.h"
-
-+#undef fopen64
-+#undef fseeko64
-+#undef fstat64
-+#undef fstatvfs64
-+#undef ftello64
-+#undef lstat64
-+#undef stat64
-+#undef tmpfile64
-+
- namespace llvm {
- template <typename T> class ArrayRef;
- class Triple;
-diff --git a/lib/Support/Unix/DynamicLibrary.inc b/lib/Support/Unix/DynamicLibrary.inc
-index a2a37996..2f86c470 100644
---- a/llvm/lib/Support/Unix/DynamicLibrary.inc
-+++ b/llvm/lib/Support/Unix/DynamicLibrary.inc
-@@ -102,7 +102,7 @@ static void *DoSearch(const char* SymbolName) {
-
- // This macro returns the address of a well-known, explicit symbol
- #define EXPLICIT_SYMBOL(SYM) \
-- if (!strcmp(SymbolName, #SYM)) return &SYM
-+ if (!strcmp(SymbolName, #SYM)) return (void *)&SYM
-
- // Under glibc we have a weird situation. The stderr/out/in symbols are both
- // macros and global variables because of standards requirements. So, we
-diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
-index d882ab2e..f1fb12d0 100644
---- a/llvm/utils/unittest/googletest/src/gtest.cc
-+++ b/llvm/utils/unittest/googletest/src/gtest.cc
-@@ -128,6 +128,7 @@
-
- #if GTEST_CAN_STREAM_RESULTS_
- # include <arpa/inet.h> // NOLINT
-+# include <sys/socket.h> // NOLINT
- # include <netdb.h> // NOLINT
- # include <sys/socket.h> // NOLINT
- # include <sys/types.h> // NOLINT
diff --git a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
deleted file mode 100644
index 0071d964bd371f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-This patches LLVM to use ELFv2 on ppc64 unconditionally unless overridden. We
-need this because unlike most distros we use ELFv2 for both glibc and musl
-on big endian ppc64.
-
-diff --git a/lib/Target/PowerPC/PPCTargetMachine.cpp b/lib/Target/PowerPC/PPCTargetMachine.cpp
-index 0634833e..b7cbc2e7 100644
---- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-@@ -222,9 +222,8 @@ static PPCTargetMachine::PPCABI computeTargetABI(const Triple &TT,
-
- switch (TT.getArch()) {
- case Triple::ppc64le:
-- return PPCTargetMachine::PPC_ABI_ELFv2;
- case Triple::ppc64:
-- return PPCTargetMachine::PPC_ABI_ELFv1;
-+ return PPCTargetMachine::PPC_ABI_ELFv2;
- default:
- return PPCTargetMachine::PPC_ABI_UNKNOWN;
- }
-diff --git a/test/CodeGen/PowerPC/ppc64-elf-abi.ll b/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-index 8b1cf6b5..296a2afa 100644
---- a/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-+++ b/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-@@ -1,4 +1,5 @@
--; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv1
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-musl < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
diff --git a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch b/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
deleted file mode 100644
index b5d15974375d49..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-@@ -165,7 +165,7 @@ void PPCSubtarget::initSubtargetFeatures(StringRef CPU, StringRef FS) {
-
- if ((TargetTriple.isOSFreeBSD() && TargetTriple.getOSMajorVersion() >= 13) ||
- TargetTriple.isOSNetBSD() || TargetTriple.isOSOpenBSD() ||
-- TargetTriple.isMusl())
-+ isTargetLinux())
- SecurePlt = true;
-
- if (HasSPE && IsPPC64)
diff --git a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch b/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
deleted file mode 100644
index 51d0e4b31b32c3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-This allows us to override the optimization level as not all platforms can
-deal with -O3.
-
---- a/llvm/CMakeLists.txt
-+++ b/llvm/CMakeLists.txt
-@@ -918,6 +918,12 @@ if( MINGW AND NOT "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang" )
- llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "-O2")
- endif()
-
-+set(VOID_CXX_OPT_FLAGS "" CACHE STRING "Optimization level to use")
-+
-+if (NOT VOID_CXX_OPT_FLAGS STREQUAL "")
-+ llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "${VOID_CXX_OPT_FLAGS}")
-+endif()
-+
- # Put this before tblgen. Else we have a circular dependence.
- add_subdirectory(lib/Demangle)
- add_subdirectory(lib/Support)
diff --git a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
deleted file mode 100644
index d332687b9d9295..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From f3dbdd49c06bfafc1d6138094cf42889c14d38b6 Mon Sep 17 00:00:00 2001
-From: Samuel Holland <samuel@sholland.org>
-Date: Sun, 3 Nov 2019 10:57:27 -0600
-Subject: [PATCH] [LLVM][PowerPC] Assume BigPIC if no PIC level is specified
-
----
- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp | 2 +-
- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/lib/Target/PowerPC/PPCAsmPrinter.cpp b/lib/Target/PowerPC/PPCAsmPrinter.cpp
-index cce21f32..87ca5f9b 100644
---- a/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-@@ -520,7 +520,7 @@ void PPCAsmPrinter::EmitTlsCall(const MachineInstr *MI,
-
- // Add 32768 offset to the symbol so we follow up the latest GOT/PLT ABI.
- if (Kind == MCSymbolRefExpr::VK_PLT && Subtarget->isSecurePlt() &&
-- M->getPICLevel() == PICLevel::BigPIC)
-+ M->getPICLevel() != PICLevel::SmallPIC)
- TlsRef = MCBinaryExpr::createAdd(
- TlsRef, MCConstantExpr::create(32768, OutContext), OutContext);
- const MachineOperand &MO = MI->getOperand(2);
-diff --git a/lib/Target/PowerPC/PPCMCInstLower.cpp b/lib/Target/PowerPC/PPCMCInstLower.cpp
-index 5cc180d7..a5b02565 100644
---- a/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-@@ -117,7 +117,7 @@ static MCOperand GetSymbolRef(const MachineOperand &MO, const MCSymbol *Symbol,
- const MCExpr *Expr = MCSymbolRefExpr::create(Symbol, RefKind, Ctx);
- // If -msecure-plt -fPIC, add 32768 to symbol.
- if (Subtarget->isSecurePlt() && TM.isPositionIndependent() &&
-- M->getPICLevel() == PICLevel::BigPIC &&
-+ M->getPICLevel() != PICLevel::SmallPIC &&
- MO.getTargetFlags() == PPCII::MO_PLT)
- Expr =
- MCBinaryExpr::createAdd(Expr, MCConstantExpr::create(32768, Ctx), Ctx);
diff --git a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch b/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
deleted file mode 100644
index a00abd2166651f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Fix failures in AllocationTests/MappedMemoryTest.* on aarch64:
-
- Failing Tests (8):
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.AllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.DuplicateNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.EnabledWrite/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.MultipleAllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.SuccessiveNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.UnalignedNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroSizeNear/3
-
-Upstream-Issue: https://bugs.llvm.org/show_bug.cgi?id=14278#c10
-
---- a/llvm/lib/Support/Unix/Memory.inc
-+++ b/llvm/lib/Support/Unix/Memory.inc
-@@ -58,7 +58,7 @@ static int getPosixProtectionFlags(unsigned Flags) {
- return PROT_READ | PROT_WRITE | PROT_EXEC;
- case llvm::sys::Memory::MF_EXEC:
- #if (defined(__FreeBSD__) || defined(__POWERPC__) || defined (__ppc__) || \
-- defined(_POWER) || defined(_ARCH_PPC))
-+ defined(_POWER) || defined(_ARCH_PPC) || (defined(__linux__) && defined(__aarch64__)))
- // On PowerPC, having an executable page that has no read permission
- // can have unintended consequences. The function InvalidateInstruction-
- // Cache uses instructions dcbf and icbi, both of which are treated by
diff --git a/srcpkgs/llvm12/patches/llvm-gcc13.patch b/srcpkgs/llvm12/patches/llvm-gcc13.patch
deleted file mode 100644
index 6895221b73bb75..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-gcc13.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From ff1681ddb303223973653f7f5f3f3435b48a1983 Mon Sep 17 00:00:00 2001
-From: Sergei Trofimovich <slyich@gmail.com>
-Date: Mon, 23 May 2022 08:03:23 +0100
-Subject: [PATCH] [Support] Add missing <cstdint> header to Signals.h
-
-Without the change llvm build fails on this week's gcc-13 snapshot as:
-
- [ 0%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o
- In file included from llvm/lib/Support/Signals.cpp:14:
- llvm/include/llvm/Support/Signals.h:119:8: error: variable or field 'CleanupOnSignal' declared void
- 119 | void CleanupOnSignal(uintptr_t Context);
- | ^~~~~~~~~~~~~~~
----
- llvm/include/llvm/Support/Signals.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/llvm/include/llvm/Support/Signals.h b/llvm/include/llvm/Support/Signals.h
-index 44f5a750ff5cb0..937e0572d4a725 100644
---- a/llvm/include/llvm/Support/Signals.h
-+++ b/llvm/include/llvm/Support/Signals.h
-@@ -14,6 +14,7 @@
- #ifndef LLVM_SUPPORT_SIGNALS_H
- #define LLVM_SUPPORT_SIGNALS_H
-
-+#include <cstdint>
- #include <string>
-
- namespace llvm {
diff --git a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch b/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
deleted file mode 100644
index 8e0a9a779d1bf8..00000000000000
--- a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-commit ba4ede595ff9599232f5dd2b4384c243137b53fc
-Author: Daniel Kolesa <daniel@octaforge.org>
-Date: Tue Jun 22 23:40:54 2021 +0200
-
- enable compiler-rt support for ppc32
-
-diff --git a/compiler-rt/cmake/base-config-ix.cmake b/compiler-rt/cmake/base-config-ix.cmake
-index 1edab43..5c0c8a2 100644
---- a/compiler-rt/cmake/base-config-ix.cmake
-+++ b/compiler-rt/cmake/base-config-ix.cmake
-@@ -182,9 +182,7 @@ macro(test_targets)
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc64le")
- test_target_arch(powerpc64le "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc")
-- if(CMAKE_SYSTEM_NAME MATCHES "AIX")
-- test_target_arch(powerpc "" "-m32")
-- endif()
-+ test_target_arch(powerpc "" "-m32")
- test_target_arch(powerpc64 "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "s390x")
- test_target_arch(s390x "" "")
diff --git a/srcpkgs/llvm12/template b/srcpkgs/llvm12/template
deleted file mode 100644
index 86e86bb96c63f1..00000000000000
--- a/srcpkgs/llvm12/template
+++ /dev/null
@@ -1,161 +0,0 @@
-# Template file for 'llvm12'
-pkgname=llvm12
-version=12.0.1
-revision=4
-build_wrksrc=llvm
-build_style=cmake
-configure_args="
- -DCMAKE_BUILD_TYPE=Release -Wno-dev
- -DENABLE_LINKER_BUILD_ID=YES
- -DLLDB_USE_SYSTEM_SIX=YES
- -DLIBCXX_CXX_ABI=libcxxabi
- -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=YES
- -DLIBCXXABI_USE_LLVM_UNWINDER=YES
- -DLIBCXXABI_ENABLE_STATIC_UNWINDER=YES
- -DLIBOMP_ENABLE_SHARED=YES
- -DLIBOMP_INSTALL_ALIASES=NO
- -DLLVM_INCLUDE_DOCS=YES
- -DLLVM_BUILD_DOCS=YES
- -DLLVM_ENABLE_SPHINX=YES
- -DSPHINX_WARNINGS_AS_ERRORS=NO
- -DLLVM_INSTALL_UTILS=YES
- -DLLVM_BUILD_LLVM_DYLIB=YES
- -DLLVM_LINK_LLVM_DYLIB=YES
- -DLLVM_ENABLE_RTTI=YES
- -DLLVM_ENABLE_FFI=YES
- -DLLVM_BINUTILS_INCDIR=/usr/include"
-hostmakedepends="perl python3 zlib-devel libffi-devel swig python3-Sphinx
- python3-recommonmark python3-sphinx-automodapi"
-makedepends="python3-devel zlib-devel elfutils-devel libffi-devel libedit-devel
- libxml2-devel binutils-devel"
-depends="libllvm12>=${version}_${revision}"
-short_desc="Low Level Virtual Machine"
-maintainer="Orphaned <orphan@voidlinux.org>"
-license="Apache-2.0"
-homepage="https://www.llvm.org"
-distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-project-${version}.src.tar.xz"
-checksum=129cb25cd13677aad951ce5c2deb0fe4afc1e9d98950f53b51bdcfb5a73afa0e
-lib32disabled=yes
-python_version=3
-
-if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
- configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
- makedepends+=" libexecinfo-devel"
- depends+=" libexecinfo-devel"
-fi
-
-# "operand out of range" assembler failures
-case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*) configure_args+=" -DCLANG_ENABLE_CLANGD=OFF" ;;
-esac
-
-post_patch() {
- # update config.guess for better platform detection
- cp $XBPS_COMMONDIR/environment/configure/automake/config.guess \
- ${wrksrc}/llvm/cmake
-
- # fix linker failures on some archs
- vsed -i 's,check_library_exists(gcc_s .*,set(LIBCXXABI_HAS_GCC_S_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
- vsed -i 's,check_library_exists(gcc .*,set(LIBCXXABI_HAS_GCC_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
-
- # need libssp_nonshared on some musl platforms (because of nodefaultlibs)
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*-musl|i686-musl|mips*-musl)
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libunwind/src/CMakeLists.txt
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libcxxabi/src/CMakeLists.txt
- vsed -i 's,#ssp,,' ${wrksrc}/libcxx/CMakeLists.txt
- ;;
- 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
- ;;
- esac
-}
-
-pre_configure() {
- local triplet
-
- # Vastly reduce size of debugging symbols:
- CFLAGS=${CFLAGS/ -g/ -g1}
- CXXFLAGS=${CXXFLAGS/ -g/ -g1}
-
- # since gcc9, the build likes to blow up for ppc32 apparently because
- # of clang being too large for a 24-bit relative call to the PLT, so
- # optimize for size instead
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- mips*-musl|ppc*) configure_args+=" -DVOID_CXX_OPT_FLAGS=-Os" ;;
- esac
-
- if [ "$CROSS_BUILD" ]; then
- msg_normal "Building host tblgen\n"
- mkdir -p build/HOST
- cd build/HOST
- CC="$BUILD_CC" CXX="$BUILD_CXX" CFLAGS="$BUILD_CFLAGS" \
- CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
- cmake ../.. -DCMAKE_BUILD_TYPE=Release
- make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
- [ "$_lldb_enable" = "yes" ] && make ${makejobs} -C tools/lldb/utils/TableGen
- configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/clang-tblgen"
- cd ../..
- fi
-
- case "$XBPS_TARGET_MACHINE" in
- i686*) _arch="X86";;
- x86_64*) _arch="X86";;
- armv5*) _arch="Armv5te";;
- armv6*) _arch="Armv6";;
- armv7*) _arch="Armv7";;
- aarch64*) _arch="AArch64";;
- mips*) _arch="Mips";;
- ppc*) _arch="PowerPC";;
- riscv64*) _arch="RISCV64";;
- esac
-
- triplet=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}
-
- configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
- configure_args+=" -DLLVM_HOST_TRIPLE=${triplet}"
- configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${triplet}"
-}
-
-do_install() {
- cd build
- cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
-
- # Required for multilib.
- if [ "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
- for _header in llvm-config; do
- mv ${DESTDIR}/usr/include/llvm/Config/${_header}{,-64}.h
- vinstall ${FILESDIR}/llvm-Config-${_header}.h 644 \
- usr/include/llvm/Config ${_header}.h
- done
- fi
-
- # Remove llvm-config-host in cross builds.
- if [ "$CROSS_BUILD" ]; then
- rm -f ${DESTDIR}/usr/bin/llvm-config-host
- fi
-}
-
-libllvm12_package() {
- short_desc+=" - runtime library"
- pkg_install() {
- vmove "usr/lib/libLLVM-*.so*"
- }
-}
diff --git a/srcpkgs/llvm12/update b/srcpkgs/llvm12/update
deleted file mode 100644
index e95cf26b3586b7..00000000000000
--- a/srcpkgs/llvm12/update
+++ /dev/null
@@ -1,3 +0,0 @@
-site="https://github.com/llvm/llvm-project/releases"
-pattern="llvmorg-\K(\d+.){2}\d+(-rc\d+)?"
-ignore="*-rc*"
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index e729b51bfc267d..d59bdf00432c32 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
# Template file for 'removed-packages'
pkgname=removed-packages
-version=0.1.20240727
+version=0.1.20240729
revision=1
build_style=meta
short_desc="Uninstalls packages removed from repository"
@@ -376,6 +376,7 @@ replaces="
libgroff<=1.22.4_3
libgtkhtml<=4.10.0_1
libkscreen<=5.27.11_3
+ libllvm12<=12.0.1_4
libllvm10<=10.0.0_8
libllvm11<=11.0.0_2
libllvm15<=15.0.7_4
@@ -438,8 +439,12 @@ replaces="
lld15-devel<=15.0.7_4
lld15<=15.0.7_4
lldb-devel<=15.0.7_3
+<<<<<<< HEAD
lldb15-devel<=15.0.7_4
lldb15<=15.0.7_4
+=======
+ llvm12<=12.0.1_4
+>>>>>>> 16a752acee5 (llvm12: remove package)
llvm10<=10.0.0_8
llvm11<=11.0.0_2
llvm15<=15.0.7_4
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (4 preceding siblings ...)
2024-07-29 12:00 ` [PR PATCH] [Updated] " Calandracas606
@ 2024-07-29 12:01 ` Calandracas606
2024-07-30 19:41 ` [PR REVIEW] " classabbyamp
` (8 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-29 12:01 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 205 bytes --]
New comment by Calandracas606 on void-packages repository
https://github.com/void-linux/void-packages/pull/51186#issuecomment-2255746007
Comment:
https://github.com/void-linux/void-packages/pull/51526
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR REVIEW] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (6 preceding siblings ...)
2024-07-30 19:41 ` [PR REVIEW] " classabbyamp
@ 2024-07-30 19:41 ` classabbyamp
2024-07-30 20:38 ` [PR PATCH] [Updated] " Calandracas606
` (6 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: classabbyamp @ 2024-07-30 19:41 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 167 bytes --]
New review comment by classabbyamp on void-packages repository
https://github.com/void-linux/void-packages/pull/51186#discussion_r1697486289
Comment:
merge conflict
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR REVIEW] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (5 preceding siblings ...)
2024-07-29 12:01 ` Calandracas606
@ 2024-07-30 19:41 ` classabbyamp
2024-07-30 19:41 ` classabbyamp
` (7 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: classabbyamp @ 2024-07-30 19:41 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 166 bytes --]
New review comment by classabbyamp on void-packages repository
https://github.com/void-linux/void-packages/pull/51186#discussion_r1697486547
Comment:
llvm15 stuff?
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (7 preceding siblings ...)
2024-07-30 19:41 ` classabbyamp
@ 2024-07-30 20:38 ` Calandracas606
2024-07-30 20:39 ` Calandracas606
` (5 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-30 20:38 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1422 bytes --]
There is an updated pull request by Calandracas606 against master on the void-packages repository
https://github.com/Calandracas606/void-packages remove-llvm12
https://github.com/void-linux/void-packages/pull/51186
remove llvm12
- **mozjs102: build with llvm18**
- **ghdl: update to 4.1.0.**
- **llvm12: remove package**
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, x86_64
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64-musl
- i686
- aarch64 (cross)
- aarch64-musl (cross)
- armv7l (cross)
- armv7l-musl (cross)
- armv6l (cross)
- armv6l-musl (cross)
A patch file from https://github.com/void-linux/void-packages/pull/51186.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-remove-llvm12-51186.patch --]
[-- Type: text/x-diff, Size: 50344 bytes --]
From dd0bcea4d992471276e1a09538ea1bbba27f70c3 Mon Sep 17 00:00:00 2001
From: Daniel Martinez <danielmartinez@cock.li>
Date: Tue, 9 Jul 2024 22:18:51 -0400
Subject: [PATCH] llvm12: remove package
---
common/shlibs | 2 +
srcpkgs/libllvm12 | 1 -
.../llvm12/files/llvm-Config-llvm-config.h | 9 -
...clang-001-fix-unwind-chain-inclusion.patch | 44 -----
.../patches/clang-002-add-musl-triples.patch | 110 ------------
.../clang-003-ppc64-dynamic-linker-path.patch | 13 --
.../patches/clang-004-ppc64-musl-elfv2.patch | 48 ------
.../compiler-rt-aarch64-ucontext.patch | 11 --
.../compiler-rt-sanitizer-glibc-2.36.patch | 59 -------
.../compiler-rt-sanitizer-ppc64-musl.patch | 35 ----
.../llvm12/patches/compiler-rt-size_t.patch | 10 --
.../patches/compiler-rt-xray-ppc64-musl.patch | 62 -------
srcpkgs/llvm12/patches/libcxx-musl.patch | 26 ---
srcpkgs/llvm12/patches/libcxx-ppc.patch | 22 ---
.../llvm12/patches/libcxx-ssp-nonshared.patch | 11 --
srcpkgs/llvm12/patches/libcxxabi-dl.patch | 25 ---
srcpkgs/llvm12/patches/libunwind-ppc32.patch | 63 -------
srcpkgs/llvm12/patches/lldb-musl.patch | 31 ----
srcpkgs/llvm12/patches/llvm-001-musl.patch | 57 -------
.../patches/llvm-002-musl-ppc64-elfv2.patch | 30 ----
.../patches/llvm-003-ppc-secureplt.patch | 11 --
.../patches/llvm-004-override-opt.patch | 18 --
.../llvm12/patches/llvm-005-ppc-bigpic.patch | 36 ----
.../patches/llvm-006-aarch64-mf_exec.patch | 25 ---
srcpkgs/llvm12/patches/llvm-gcc13.patch | 28 ---
.../llvm12/patches/ppc32-compiler-rt.patch | 21 ---
srcpkgs/llvm12/template | 161 ------------------
srcpkgs/llvm12/update | 3 -
srcpkgs/removed-packages/template | 7 +-
29 files changed, 8 insertions(+), 971 deletions(-)
delete mode 120000 srcpkgs/libllvm12
delete mode 100644 srcpkgs/llvm12/files/llvm-Config-llvm-config.h
delete mode 100644 srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-size_t.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ppc.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxxabi-dl.patch
delete mode 100644 srcpkgs/llvm12/patches/libunwind-ppc32.patch
delete mode 100644 srcpkgs/llvm12/patches/lldb-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-001-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-004-override-opt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-gcc13.patch
delete mode 100644 srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
delete mode 100644 srcpkgs/llvm12/template
delete mode 100644 srcpkgs/llvm12/update
diff --git a/common/shlibs b/common/shlibs
index 5cfafa2be55b75..c3f08c44b7ba48 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -994,6 +994,8 @@ libclang-cpp.so.18.1 libclang-cpp18-18.1.8_1
libclang-cpp.so.17 libclang-cpp17-17.0.6_1
libLLVM-11.so libllvm11-11.0.0_1
libLLVM-12.so libllvm12-12.0.0_1
+libclang-cpp.so.15 libclang-cpp15-15.0.7_4
+libLLVM-15.so libllvm15-15.0.7_4
libLLVM-17.so libllvm17-17.0.6_1
libLLVM.so.18.1 libllvm18-18.1.8_1
libLLVMSPIRVLib.so.18.1 SPIRV-LLVM-Translator-18.1.2_1
diff --git a/srcpkgs/libllvm12 b/srcpkgs/libllvm12
deleted file mode 120000
index cd60fd7a981bdd..00000000000000
--- a/srcpkgs/libllvm12
+++ /dev/null
@@ -1 +0,0 @@
-llvm12
\ No newline at end of file
diff --git a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h b/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
deleted file mode 100644
index 2fa08c9be69621..00000000000000
--- a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
+++ /dev/null
@@ -1,9 +0,0 @@
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 32
-#include "llvm-config-32.h"
-#elif __WORDSIZE == 64
-#include "llvm-config-64.h"
-#else
-#error "Unknown word size"
-#endif
diff --git a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
deleted file mode 100644
index e4eaa7783e7a6c..00000000000000
--- a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 352974169f0d2b5da3d5321f588f5e3b5941330e Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:14:57 +0200
-Subject: [PATCH 2/7] fix unwind chain inclusion
-
----
- lib/Headers/unwind.h | 9 +++++----
- 1 file changed, 5 insertions(+), 4 deletions(-)
-
-diff --git a/lib/Headers/unwind.h b/lib/Headers/unwind.h
-index 303d792..44e10cc 100644
---- a/clang/lib/Headers/unwind.h
-+++ b/clang/lib/Headers/unwind.h
-@@ -9,9 +9,6 @@
-
- /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/
-
--#ifndef __CLANG_UNWIND_H
--#define __CLANG_UNWIND_H
--
- #if defined(__APPLE__) && __has_include_next(<unwind.h>)
- /* Darwin (from 11.x on) provide an unwind.h. If that's available,
- * use it. libunwind wraps some of its definitions in #ifdef _GNU_SOURCE,
-@@ -39,6 +36,9 @@
- # endif
- #else
-
-+#ifndef __CLANG_UNWIND_H
-+#define __CLANG_UNWIND_H
-+
- #include <stdint.h>
-
- #ifdef __cplusplus
-@@ -322,6 +322,7 @@ _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *);
- }
- #endif
-
-+#endif /* __CLANG_UNWIND_H */
-+
- #endif
-
--#endif /* __CLANG_UNWIND_H */
---
-2.5.1
diff --git a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch b/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
deleted file mode 100644
index 25688d40dbc275..00000000000000
--- a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
+++ /dev/null
@@ -1,110 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Gnu.cpp
-+++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2086,7 +2086,8 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
- "armv7hl-redhat-linux-gnueabi",
- "armv6hl-suse-linux-gnueabi",
-- "armv7hl-suse-linux-gnueabi"};
-+ "armv7hl-suse-linux-gnueabi",
-+ "armv7l-linux-gnueabihf"};
- static const char *const ARMebLibDirs[] = {"/lib"};
- static const char *const ARMebTriples[] = {"armeb-linux-gnueabi",
- "armeb-linux-androideabi"};
-@@ -2153,8 +2154,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- "powerpc64-suse-linux", "powerpc-montavista-linuxspe"};
- static const char *const PPCLELibDirs[] = {"/lib32", "/lib"};
- static const char *const PPCLETriples[] = {"powerpcle-linux-gnu",
-- "powerpcle-unknown-linux-gnu",
-- "powerpcle-linux-musl"};
-+ "powerpcle-unknown-linux-gnu"};
-
- static const char *const PPC64LibDirs[] = {"/lib64", "/lib"};
- static const char *const PPC64Triples[] = {
-@@ -2235,6 +2235,87 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- return;
- }
-
-+ if (TargetTriple.isMusl()) {
-+ static const char *const AArch64MuslTriples[] = {"aarch64-linux-musl"};
-+ static const char *const ARMHFMuslTriples[] = {
-+ "arm-linux-musleabihf", "armv7l-linux-musleabihf"
-+ };
-+ static const char *const ARMMuslTriples[] = {"arm-linux-musleabi"};
-+ static const char *const X86_64MuslTriples[] = {"x86_64-linux-musl"};
-+ static const char *const X86MuslTriples[] = {"i686-linux-musl"};
-+ static const char *const MIPSMuslTriples[] = {
-+ "mips-linux-musl", "mipsel-linux-musl",
-+ "mipsel-linux-muslhf", "mips-linux-muslhf"
-+ };
-+ static const char *const PPCMuslTriples[] = {"powerpc-linux-musl"};
-+ static const char *const PPCLEMuslTriples[] = {"powerpcle-linux-musl"};
-+ static const char *const PPC64MuslTriples[] = {"powerpc64-linux-musl"};
-+ static const char *const PPC64LEMuslTriples[] = {"powerpc64le-linux-musl"};
-+
-+ switch (TargetTriple.getArch()) {
-+ case llvm::Triple::aarch64:
-+ LibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ TripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ BiarchLibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ BiarchTripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ break;
-+ case llvm::Triple::arm:
-+ LibDirs.append(begin(ARMLibDirs), end(ARMLibDirs));
-+ if (TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
-+ TripleAliases.append(begin(ARMHFMuslTriples), end(ARMHFMuslTriples));
-+ } else {
-+ TripleAliases.append(begin(ARMMuslTriples), end(ARMMuslTriples));
-+ }
-+ break;
-+ case llvm::Triple::x86_64:
-+ LibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ TripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ BiarchLibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ BiarchTripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ break;
-+ case llvm::Triple::x86:
-+ LibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ TripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ BiarchLibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ BiarchTripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ break;
-+ case llvm::Triple::mips:
-+ LibDirs.append(begin(MIPSLibDirs), end(MIPSLibDirs));
-+ TripleAliases.append(begin(MIPSMuslTriples), end(MIPSMuslTriples));
-+ break;
-+ case llvm::Triple::ppc:
-+ LibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ TripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ BiarchTripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ break;
-+ case llvm::Triple::ppcle:
-+ LibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ TripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ BiarchTripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64:
-+ LibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ TripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ BiarchLibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ BiarchTripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64le:
-+ LibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ TripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ BiarchLibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ BiarchTripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ break;
-+ default:
-+ break;
-+ }
-+ TripleAliases.push_back(TargetTriple.str());
-+ if (TargetTriple.str() != BiarchTriple.str())
-+ BiarchTripleAliases.push_back(BiarchTriple.str());
-+ return;
-+ }
-+
- // Android targets should not use GNU/Linux tools or libraries.
- if (TargetTriple.isAndroid()) {
- static const char *const AArch64AndroidTriples[] = {
diff --git a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
deleted file mode 100644
index 4ad6412d1e6c63..00000000000000
--- a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Linux.cpp
-+++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -504,10 +504,6 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
- Loader = "ld.so.1";
- break;
- case llvm::Triple::ppc64:
-- LibDir = "lib64";
-- Loader =
-- (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
-- break;
- case llvm::Triple::ppc64le:
- LibDir = "lib64";
- Loader =
diff --git a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
deleted file mode 100644
index 21fc8003c5f1a8..00000000000000
--- a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
+++ /dev/null
@@ -1,48 +0,0 @@
---- a/clang/lib/Basic/Targets/PPC.h
-+++ b/clang/lib/Basic/Targets/PPC.h
-@@ -415,11 +415,10 @@ public:
- LongDoubleFormat = &llvm::APFloat::IEEEdouble();
- } else if ((Triple.getArch() == llvm::Triple::ppc64le)) {
- DataLayout = "e-m:e-i64:64-n32:64";
-- ABI = "elfv2";
- } else {
- DataLayout = "E-m:e-i64:64-n32:64";
-- ABI = "elfv1";
- }
-+ ABI = "elfv2";
-
- if (Triple.isOSFreeBSD() || Triple.isOSOpenBSD() || Triple.isMusl()) {
- LongDoubleWidth = LongDoubleAlign = 64;
---- a/clang/lib/CodeGen/TargetInfo.cpp
-+++ b/clang/lib/CodeGen/TargetInfo.cpp
-@@ -10927,9 +10927,9 @@ const TargetCodeGenInfo &CodeGenModule::getTargetCodeGenInfo() {
- return SetCGInfo(new AIXTargetCodeGenInfo(Types, /*Is64Bit*/ true));
-
- if (Triple.isOSBinFormatELF()) {
-- PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv1;
-- if (getTarget().getABI() == "elfv2")
-- Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ if (getTarget().getABI() == "elfv1")
-+ Kind = PPC64_SVR4_ABIInfo::ELFv1;
- bool IsSoftFloat = CodeGenOpts.FloatABI == "soft";
-
- return SetCGInfo(
---- a/clang/lib/Driver/ToolChains/Clang.cpp
-+++ b/clang/lib/Driver/ToolChains/Clang.cpp
-@@ -1920,14 +1920,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
- const llvm::Triple &T = getToolChain().getTriple();
- if (T.isOSBinFormatELF()) {
- switch (getToolChain().getArch()) {
-- case llvm::Triple::ppc64: {
-- if ((T.isOSFreeBSD() && T.getOSMajorVersion() >= 13) ||
-- T.isOSOpenBSD() || T.isMusl())
-- ABIName = "elfv2";
-- else
-- ABIName = "elfv1";
-- break;
-- }
-+ case llvm::Triple::ppc64:
- case llvm::Triple::ppc64le:
- ABIName = "elfv2";
- break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch b/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
deleted file mode 100644
index 893c059d7b8def..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp.orig
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -1799,7 +1799,7 @@
-
- static bool Aarch64GetESR(ucontext_t *ucontext, u64 *esr) {
- static const u32 kEsrMagic = 0x45535201;
-- u8 *aux = ucontext->uc_mcontext.__reserved;
-+ u8 *aux = reinterpret_cast<u8 *>(ucontext->uc_mcontext.__reserved);
- while (true) {
- _aarch64_ctx *ctx = (_aarch64_ctx *)aux;
- if (ctx->size == 0) break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
deleted file mode 100644
index e5f24dab893547..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From 9cf13067cb5088626ba7ee1ec4c42ec59c7995a0 Mon Sep 17 00:00:00 2001
-From: Fangrui Song <i@maskray.me>
-Date: Mon, 11 Jul 2022 12:53:34 -0700
-Subject: [PATCH] [sanitizer] Remove #include <linux/fs.h> to resolve
- fsconfig_command/mount_attr conflict with glibc 2.36
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-It is generally not a good idea to mix usage of glibc headers and Linux UAPI
-headers (https://sourceware.org/glibc/wiki/Synchronizing_Headers). In glibc
-since 7eae6a91e9b1670330c9f15730082c91c0b1d570 (milestone: 2.36), sys/mount.h
-defines `fsconfig_command` which conflicts with linux/mount.h:
-
- .../usr/include/linux/mount.h:95:6: error: redeclaration of ‘enum fsconfig_command’
-
-Remove #include <linux/fs.h> which pulls in linux/mount.h. Expand its 4 macros manually.
-Android sys/mount.h doesn't define BLKBSZGET and it still needs linux/fs.h.
-In the long term we should move Linux specific definitions to sanitizer_platform_limits_linux.cpp
-but this commit is easy to cherry pick into older compiler-rt releases.
-
-Fix https://github.com/llvm/llvm-project/issues/56421
-
-Reviewed By: #sanitizers, vitalybuka, zatrazz
-
-Differential Revision: https://reviews.llvm.org/D129471
----
- .../sanitizer_platform_limits_posix.cpp | 10 ++++++----
- 1 file changed, 6 insertions(+), 4 deletions(-)
-
-diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-index 4bd425435d56d..3a94b260686f1 100644
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -73,7 +73,9 @@
- #include <sys/vt.h>
- #include <linux/cdrom.h>
- #include <linux/fd.h>
-+#if SANITIZER_ANDROID
- #include <linux/fs.h>
-+#endif
- #include <linux/hdreg.h>
- #include <linux/input.h>
- #include <linux/ioctl.h>
-@@ -876,10 +878,10 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr);
- unsigned IOCTL_EVIOCGPROP = IOCTL_NOT_PRESENT;
- unsigned IOCTL_EVIOCSKEYCODE_V2 = IOCTL_NOT_PRESENT;
- #endif
-- unsigned IOCTL_FS_IOC_GETFLAGS = FS_IOC_GETFLAGS;
-- unsigned IOCTL_FS_IOC_GETVERSION = FS_IOC_GETVERSION;
-- unsigned IOCTL_FS_IOC_SETFLAGS = FS_IOC_SETFLAGS;
-- unsigned IOCTL_FS_IOC_SETVERSION = FS_IOC_SETVERSION;
-+ unsigned IOCTL_FS_IOC_GETFLAGS = _IOR('f', 1, long);
-+ unsigned IOCTL_FS_IOC_GETVERSION = _IOR('v', 1, long);
-+ unsigned IOCTL_FS_IOC_SETFLAGS = _IOW('f', 2, long);
-+ unsigned IOCTL_FS_IOC_SETVERSION = _IOW('v', 2, long);
- unsigned IOCTL_GIO_CMAP = GIO_CMAP;
- unsigned IOCTL_GIO_FONT = GIO_FONT;
- unsigned IOCTL_GIO_UNIMAP = GIO_UNIMAP;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
deleted file mode 100644
index 35f16d24f340c6..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
+++ /dev/null
@@ -1,35 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -74,6 +74,10 @@
- #include <sys/utsname.h>
- #endif
-
-+#if SANITIZER_LINUX && defined(__powerpc__)
-+#include <asm/ptrace.h>
-+#endif
-+
- #if SANITIZER_LINUX && !SANITIZER_ANDROID
- #include <sys/personality.h>
- #endif
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -92,7 +92,7 @@
- # include <utime.h>
- # include <sys/ptrace.h>
- #if defined(__mips64) || defined(__aarch64__) || defined(__arm__) || \
-- SANITIZER_RISCV64
-+ defined(__powerpc__) || SANITIZER_RISCV64
- # include <asm/ptrace.h>
- # ifdef __arm__
- typedef struct user_fpregs elf_fpregset_t;
---- a/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-@@ -31,7 +31,7 @@
- #include <sys/types.h> // for pid_t
- #include <sys/uio.h> // for iovec
- #include <elf.h> // for NT_PRSTATUS
--#if (defined(__aarch64__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
-+#if (defined(__aarch64__) || defined(__powerpc__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
- // GLIBC 2.20+ sys/user does not include asm/ptrace.h
- # include <asm/ptrace.h>
- #endif
diff --git a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch b/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
deleted file mode 100644
index 2c63063a5e9e3f..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp.orig
-+++ b/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp
-@@ -25,6 +25,7 @@
- }
-
- #include <cassert>
-+#include <cstddef>
- #include <cstdint>
- #include <dlfcn.h> // for dlsym()
-
diff --git a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
deleted file mode 100644
index d0b61c80c897f4..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
+++ /dev/null
@@ -1,62 +0,0 @@
---- a/compiler-rt/lib/xray/xray_powerpc64.inc
-+++ b/compiler-rt/lib/xray/xray_powerpc64.inc
-@@ -12,7 +12,13 @@
-
- #include <cstdint>
- #include <mutex>
-+#ifdef __GLIBC__
- #include <sys/platform/ppc.h>
-+#else
-+#include <cctype>
-+#include <cstring>
-+#include <cstdlib>
-+#endif
-
- #include "xray_defs.h"
-
-@@ -20,13 +26,45 @@ namespace __xray {
-
- ALWAYS_INLINE uint64_t readTSC(uint8_t &CPU) XRAY_NEVER_INSTRUMENT {
- CPU = 0;
-+#ifdef __GLIBC__
- return __ppc_get_timebase();
-+#else
-+ return __builtin_ppc_get_timebase();
-+#endif
- }
-
- inline uint64_t getTSCFrequency() XRAY_NEVER_INSTRUMENT {
- static std::mutex M;
- std::lock_guard<std::mutex> Guard(M);
-+#ifdef __GLIBC__
- return __ppc_get_timebase_freq();
-+#else
-+ /* FIXME: a less dirty implementation? */
-+ static uint64_t base;
-+ if (!base) {
-+ FILE *f = fopen("/proc/cpuinfo", "rb");
-+ if (f) {
-+ ssize_t nr;
-+ /* virtually always big enough to hold the line */
-+ char buf[512];
-+ while (fgets(buf, sizeof(buf), f)) {
-+ char *ret = strstr(buf, "timebase");
-+ if (!ret) {
-+ continue;
-+ }
-+ ret += sizeof("timebase") - 1;
-+ ret = strchr(ret, ':');
-+ if (!ret) {
-+ continue;
-+ }
-+ base = strtoul(ret + 1, nullptr, 10);
-+ break;
-+ }
-+ fclose(f);
-+ }
-+ }
-+ return base;
-+#endif
- }
-
- inline bool probeRequiredCPUFeatures() XRAY_NEVER_INSTRUMENT {
diff --git a/srcpkgs/llvm12/patches/libcxx-musl.patch b/srcpkgs/llvm12/patches/libcxx-musl.patch
deleted file mode 100644
index bbd31ffc2cb1f4..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-musl.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/libcxx/include/locale
-+++ b/libcxx/include/locale
-@@ -742,7 +742,11 @@ __num_get_signed_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ long long __ll = strtoll(__a, &__p2, __base);
-+#else
- long long __ll = strtoll_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
-@@ -782,7 +786,11 @@ __num_get_unsigned_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ unsigned long long __ll = strtoull(__a, &__p2, __base);
-+#else
- unsigned long long __ll = strtoull_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
diff --git a/srcpkgs/llvm12/patches/libcxx-ppc.patch b/srcpkgs/llvm12/patches/libcxx-ppc.patch
deleted file mode 100644
index 7a92f8004e1cf8..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ppc.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-This ensures `is_iec559` is defined correctly under all long double ABIs,
-including musl and its 64-bit long double. Also, `__ppc__` or `__ppc64__`
-is not defined on gcc.
-
---- a/libcxx/include/limits
-+++ b/libcxx/include/limits
-@@ -426,8 +426,14 @@ protected:
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nansl("");}
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __LDBL_DENORM_MIN__;}
-
--#if (defined(__ppc__) || defined(__ppc64__))
-+#if defined(__powerpc__) || defined(__powerpc64__)
-+#if (__LDBL_MAX_EXP__ > __DBL_MAX_EXP__) || (__LDBL_MANT_DIG__ == __DBL_MANT_DIG__)
-+ /* IEEE 754 quadruple or double precision */
-+ static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
-+#else
-+ /* 128-bit IBM double-double */
- static _LIBCPP_CONSTEXPR const bool is_iec559 = false;
-+#endif
- #else
- static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
- #endif
diff --git a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch b/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
deleted file mode 100644
index 70292beb2fcdbd..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/libcxx/CMakeLists.txt
-+++ b/libcxx/CMakeLists.txt
-@@ -769,6 +769,8 @@ function(cxx_link_system_libraries target)
- target_link_libraries(${target} PRIVATE atomic)
- endif()
-
-+#ssp target_link_libraries(${target} PRIVATE ssp_nonshared)
-+
- if (MINGW)
- target_link_libraries(${target} PRIVATE "${MINGW_LIBRARIES}")
- endif()
diff --git a/srcpkgs/llvm12/patches/libcxxabi-dl.patch b/srcpkgs/llvm12/patches/libcxxabi-dl.patch
deleted file mode 100644
index 3a15f9db8c981e..00000000000000
--- a/srcpkgs/llvm12/patches/libcxxabi-dl.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-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()
diff --git a/srcpkgs/llvm12/patches/libunwind-ppc32.patch b/srcpkgs/llvm12/patches/libunwind-ppc32.patch
deleted file mode 100644
index 74aa7576ecf9df..00000000000000
--- a/srcpkgs/llvm12/patches/libunwind-ppc32.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-This fixes build at least with gcc9 which does not define `__ppc__`.
-
---- a/libunwind/include/__libunwind_config.h
-+++ b/libunwind/include/__libunwind_config.h
-@@ -49,7 +49,7 @@
- # define _LIBUNWIND_CONTEXT_SIZE 167
- # define _LIBUNWIND_CURSOR_SIZE 179
- # define _LIBUNWIND_HIGHEST_DWARF_REGISTER _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC64
--# elif defined(__ppc__)
-+# elif defined(__powerpc__)
- # define _LIBUNWIND_TARGET_PPC 1
- # define _LIBUNWIND_CONTEXT_SIZE 117
- # define _LIBUNWIND_CURSOR_SIZE 124
---- a/libunwind/src/UnwindRegistersRestore.S
-+++ b/libunwind/src/UnwindRegistersRestore.S
-@@ -392,7 +392,7 @@ Lnovec:
- PPC64_LR(3)
- bctr
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- DEFINE_LIBUNWIND_FUNCTION(_ZN9libunwind13Registers_ppc6jumptoEv)
- //
---- a/libunwind/src/UnwindRegistersSave.S
-+++ b/libunwind/src/UnwindRegistersSave.S
-@@ -554,7 +554,7 @@ DEFINE_LIBUNWIND_FUNCTION(__unw_getcontext)
- blr
-
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- //
- // extern int unw_getcontext(unw_context_t* thread_state)
---- a/libunwind/src/config.h
-+++ b/libunwind/src/config.h
-@@ -95,12 +95,12 @@
- #define _LIBUNWIND_BUILD_SJLJ_APIS
- #endif
-
--#if defined(__i386__) || defined(__x86_64__) || defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__)
-+#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc__) || defined(__powerpc64__)
- #define _LIBUNWIND_SUPPORT_FRAME_APIS
- #endif
-
- #if defined(__i386__) || defined(__x86_64__) || \
-- defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__) || \
-+ defined(__powerpc__) || defined(__powerpc64__) || \
- (!defined(__APPLE__) && defined(__arm__)) || \
- (defined(__arm64__) || defined(__aarch64__)) || \
- defined(__mips__)
---- a/libunwind/src/libunwind.cpp
-+++ b/libunwind/src/libunwind.cpp
-@@ -42,7 +42,7 @@ _LIBUNWIND_HIDDEN int __unw_init_local(unw_cursor_t *cursor,
- # define REGISTER_KIND Registers_x86_64
- #elif defined(__powerpc64__)
- # define REGISTER_KIND Registers_ppc64
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
- # define REGISTER_KIND Registers_ppc
- #elif defined(__aarch64__)
- # define REGISTER_KIND Registers_arm64
diff --git a/srcpkgs/llvm12/patches/lldb-musl.patch b/srcpkgs/llvm12/patches/lldb-musl.patch
deleted file mode 100644
index 601c0d138523e8..00000000000000
--- a/srcpkgs/llvm12/patches/lldb-musl.patch
+++ /dev/null
@@ -1,31 +0,0 @@
---- a/lldb/source/Plugins/Process/Linux/Procfs.h
-+++ b/lldb/source/Plugins/Process/Linux/Procfs.h
-@@ -10,21 +10,12 @@
- // sys/procfs.h on Android/Linux for all supported architectures.
-
- #include <sys/ptrace.h>
-+#include <asm/ptrace.h>
-
--#ifdef __ANDROID__
--#if defined(__arm64__) || defined(__aarch64__)
--typedef unsigned long elf_greg_t;
--typedef elf_greg_t
-- elf_gregset_t[(sizeof(struct user_pt_regs) / sizeof(elf_greg_t))];
--typedef struct user_fpsimd_state elf_fpregset_t;
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#elif defined(__mips__)
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#endif
--#else // __ANDROID__
-+#if !defined(__GLIBC__) && defined(__powerpc__)
-+#define pt_regs musl_pt_regs
-+#include <sys/procfs.h>
-+#undef pt_regs
-+#else
- #include <sys/procfs.h>
--#endif // __ANDROID__
-+#endif
diff --git a/srcpkgs/llvm12/patches/llvm-001-musl.patch b/srcpkgs/llvm12/patches/llvm-001-musl.patch
deleted file mode 100644
index f2a3f8d62813e3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-001-musl.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From faca3fbd15d0c3108493c3c54cd93138e049ac43 Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:03:02 +0200
-Subject: [PATCH 3/3] musl
-
----
- include/llvm/Analysis/TargetLibraryInfo.h | 9 +++++++++
- lib/Support/DynamicLibrary.cpp | 2 +-
- lib/Support/Unix/Signals.inc | 6 +++---
- utils/unittest/googletest/src/gtest.cc | 1 +
- 5 files changed, 17 insertions(+), 6 deletions(-)
-
-diff --git a/include/llvm/Analysis/TargetLibraryInfo.h b/include/llvm/Analysis/TargetLibraryInfo.h
-index 34a8a1e3..1214ece5 100644
---- a/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-+++ b/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-@@ -18,6 +18,15 @@
- #include "llvm/IR/PassManager.h"
- #include "llvm/Pass.h"
-
-+#undef fopen64
-+#undef fseeko64
-+#undef fstat64
-+#undef fstatvfs64
-+#undef ftello64
-+#undef lstat64
-+#undef stat64
-+#undef tmpfile64
-+
- namespace llvm {
- template <typename T> class ArrayRef;
- class Triple;
-diff --git a/lib/Support/Unix/DynamicLibrary.inc b/lib/Support/Unix/DynamicLibrary.inc
-index a2a37996..2f86c470 100644
---- a/llvm/lib/Support/Unix/DynamicLibrary.inc
-+++ b/llvm/lib/Support/Unix/DynamicLibrary.inc
-@@ -102,7 +102,7 @@ static void *DoSearch(const char* SymbolName) {
-
- // This macro returns the address of a well-known, explicit symbol
- #define EXPLICIT_SYMBOL(SYM) \
-- if (!strcmp(SymbolName, #SYM)) return &SYM
-+ if (!strcmp(SymbolName, #SYM)) return (void *)&SYM
-
- // Under glibc we have a weird situation. The stderr/out/in symbols are both
- // macros and global variables because of standards requirements. So, we
-diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
-index d882ab2e..f1fb12d0 100644
---- a/llvm/utils/unittest/googletest/src/gtest.cc
-+++ b/llvm/utils/unittest/googletest/src/gtest.cc
-@@ -128,6 +128,7 @@
-
- #if GTEST_CAN_STREAM_RESULTS_
- # include <arpa/inet.h> // NOLINT
-+# include <sys/socket.h> // NOLINT
- # include <netdb.h> // NOLINT
- # include <sys/socket.h> // NOLINT
- # include <sys/types.h> // NOLINT
diff --git a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
deleted file mode 100644
index 0071d964bd371f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-This patches LLVM to use ELFv2 on ppc64 unconditionally unless overridden. We
-need this because unlike most distros we use ELFv2 for both glibc and musl
-on big endian ppc64.
-
-diff --git a/lib/Target/PowerPC/PPCTargetMachine.cpp b/lib/Target/PowerPC/PPCTargetMachine.cpp
-index 0634833e..b7cbc2e7 100644
---- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-@@ -222,9 +222,8 @@ static PPCTargetMachine::PPCABI computeTargetABI(const Triple &TT,
-
- switch (TT.getArch()) {
- case Triple::ppc64le:
-- return PPCTargetMachine::PPC_ABI_ELFv2;
- case Triple::ppc64:
-- return PPCTargetMachine::PPC_ABI_ELFv1;
-+ return PPCTargetMachine::PPC_ABI_ELFv2;
- default:
- return PPCTargetMachine::PPC_ABI_UNKNOWN;
- }
-diff --git a/test/CodeGen/PowerPC/ppc64-elf-abi.ll b/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-index 8b1cf6b5..296a2afa 100644
---- a/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-+++ b/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-@@ -1,4 +1,5 @@
--; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv1
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-musl < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
diff --git a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch b/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
deleted file mode 100644
index b5d15974375d49..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-@@ -165,7 +165,7 @@ void PPCSubtarget::initSubtargetFeatures(StringRef CPU, StringRef FS) {
-
- if ((TargetTriple.isOSFreeBSD() && TargetTriple.getOSMajorVersion() >= 13) ||
- TargetTriple.isOSNetBSD() || TargetTriple.isOSOpenBSD() ||
-- TargetTriple.isMusl())
-+ isTargetLinux())
- SecurePlt = true;
-
- if (HasSPE && IsPPC64)
diff --git a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch b/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
deleted file mode 100644
index 51d0e4b31b32c3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-This allows us to override the optimization level as not all platforms can
-deal with -O3.
-
---- a/llvm/CMakeLists.txt
-+++ b/llvm/CMakeLists.txt
-@@ -918,6 +918,12 @@ if( MINGW AND NOT "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang" )
- llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "-O2")
- endif()
-
-+set(VOID_CXX_OPT_FLAGS "" CACHE STRING "Optimization level to use")
-+
-+if (NOT VOID_CXX_OPT_FLAGS STREQUAL "")
-+ llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "${VOID_CXX_OPT_FLAGS}")
-+endif()
-+
- # Put this before tblgen. Else we have a circular dependence.
- add_subdirectory(lib/Demangle)
- add_subdirectory(lib/Support)
diff --git a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
deleted file mode 100644
index d332687b9d9295..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From f3dbdd49c06bfafc1d6138094cf42889c14d38b6 Mon Sep 17 00:00:00 2001
-From: Samuel Holland <samuel@sholland.org>
-Date: Sun, 3 Nov 2019 10:57:27 -0600
-Subject: [PATCH] [LLVM][PowerPC] Assume BigPIC if no PIC level is specified
-
----
- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp | 2 +-
- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/lib/Target/PowerPC/PPCAsmPrinter.cpp b/lib/Target/PowerPC/PPCAsmPrinter.cpp
-index cce21f32..87ca5f9b 100644
---- a/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-@@ -520,7 +520,7 @@ void PPCAsmPrinter::EmitTlsCall(const MachineInstr *MI,
-
- // Add 32768 offset to the symbol so we follow up the latest GOT/PLT ABI.
- if (Kind == MCSymbolRefExpr::VK_PLT && Subtarget->isSecurePlt() &&
-- M->getPICLevel() == PICLevel::BigPIC)
-+ M->getPICLevel() != PICLevel::SmallPIC)
- TlsRef = MCBinaryExpr::createAdd(
- TlsRef, MCConstantExpr::create(32768, OutContext), OutContext);
- const MachineOperand &MO = MI->getOperand(2);
-diff --git a/lib/Target/PowerPC/PPCMCInstLower.cpp b/lib/Target/PowerPC/PPCMCInstLower.cpp
-index 5cc180d7..a5b02565 100644
---- a/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-@@ -117,7 +117,7 @@ static MCOperand GetSymbolRef(const MachineOperand &MO, const MCSymbol *Symbol,
- const MCExpr *Expr = MCSymbolRefExpr::create(Symbol, RefKind, Ctx);
- // If -msecure-plt -fPIC, add 32768 to symbol.
- if (Subtarget->isSecurePlt() && TM.isPositionIndependent() &&
-- M->getPICLevel() == PICLevel::BigPIC &&
-+ M->getPICLevel() != PICLevel::SmallPIC &&
- MO.getTargetFlags() == PPCII::MO_PLT)
- Expr =
- MCBinaryExpr::createAdd(Expr, MCConstantExpr::create(32768, Ctx), Ctx);
diff --git a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch b/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
deleted file mode 100644
index a00abd2166651f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Fix failures in AllocationTests/MappedMemoryTest.* on aarch64:
-
- Failing Tests (8):
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.AllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.DuplicateNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.EnabledWrite/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.MultipleAllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.SuccessiveNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.UnalignedNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroSizeNear/3
-
-Upstream-Issue: https://bugs.llvm.org/show_bug.cgi?id=14278#c10
-
---- a/llvm/lib/Support/Unix/Memory.inc
-+++ b/llvm/lib/Support/Unix/Memory.inc
-@@ -58,7 +58,7 @@ static int getPosixProtectionFlags(unsigned Flags) {
- return PROT_READ | PROT_WRITE | PROT_EXEC;
- case llvm::sys::Memory::MF_EXEC:
- #if (defined(__FreeBSD__) || defined(__POWERPC__) || defined (__ppc__) || \
-- defined(_POWER) || defined(_ARCH_PPC))
-+ defined(_POWER) || defined(_ARCH_PPC) || (defined(__linux__) && defined(__aarch64__)))
- // On PowerPC, having an executable page that has no read permission
- // can have unintended consequences. The function InvalidateInstruction-
- // Cache uses instructions dcbf and icbi, both of which are treated by
diff --git a/srcpkgs/llvm12/patches/llvm-gcc13.patch b/srcpkgs/llvm12/patches/llvm-gcc13.patch
deleted file mode 100644
index 6895221b73bb75..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-gcc13.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From ff1681ddb303223973653f7f5f3f3435b48a1983 Mon Sep 17 00:00:00 2001
-From: Sergei Trofimovich <slyich@gmail.com>
-Date: Mon, 23 May 2022 08:03:23 +0100
-Subject: [PATCH] [Support] Add missing <cstdint> header to Signals.h
-
-Without the change llvm build fails on this week's gcc-13 snapshot as:
-
- [ 0%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o
- In file included from llvm/lib/Support/Signals.cpp:14:
- llvm/include/llvm/Support/Signals.h:119:8: error: variable or field 'CleanupOnSignal' declared void
- 119 | void CleanupOnSignal(uintptr_t Context);
- | ^~~~~~~~~~~~~~~
----
- llvm/include/llvm/Support/Signals.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/llvm/include/llvm/Support/Signals.h b/llvm/include/llvm/Support/Signals.h
-index 44f5a750ff5cb0..937e0572d4a725 100644
---- a/llvm/include/llvm/Support/Signals.h
-+++ b/llvm/include/llvm/Support/Signals.h
-@@ -14,6 +14,7 @@
- #ifndef LLVM_SUPPORT_SIGNALS_H
- #define LLVM_SUPPORT_SIGNALS_H
-
-+#include <cstdint>
- #include <string>
-
- namespace llvm {
diff --git a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch b/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
deleted file mode 100644
index 8e0a9a779d1bf8..00000000000000
--- a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-commit ba4ede595ff9599232f5dd2b4384c243137b53fc
-Author: Daniel Kolesa <daniel@octaforge.org>
-Date: Tue Jun 22 23:40:54 2021 +0200
-
- enable compiler-rt support for ppc32
-
-diff --git a/compiler-rt/cmake/base-config-ix.cmake b/compiler-rt/cmake/base-config-ix.cmake
-index 1edab43..5c0c8a2 100644
---- a/compiler-rt/cmake/base-config-ix.cmake
-+++ b/compiler-rt/cmake/base-config-ix.cmake
-@@ -182,9 +182,7 @@ macro(test_targets)
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc64le")
- test_target_arch(powerpc64le "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc")
-- if(CMAKE_SYSTEM_NAME MATCHES "AIX")
-- test_target_arch(powerpc "" "-m32")
-- endif()
-+ test_target_arch(powerpc "" "-m32")
- test_target_arch(powerpc64 "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "s390x")
- test_target_arch(s390x "" "")
diff --git a/srcpkgs/llvm12/template b/srcpkgs/llvm12/template
deleted file mode 100644
index 86e86bb96c63f1..00000000000000
--- a/srcpkgs/llvm12/template
+++ /dev/null
@@ -1,161 +0,0 @@
-# Template file for 'llvm12'
-pkgname=llvm12
-version=12.0.1
-revision=4
-build_wrksrc=llvm
-build_style=cmake
-configure_args="
- -DCMAKE_BUILD_TYPE=Release -Wno-dev
- -DENABLE_LINKER_BUILD_ID=YES
- -DLLDB_USE_SYSTEM_SIX=YES
- -DLIBCXX_CXX_ABI=libcxxabi
- -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=YES
- -DLIBCXXABI_USE_LLVM_UNWINDER=YES
- -DLIBCXXABI_ENABLE_STATIC_UNWINDER=YES
- -DLIBOMP_ENABLE_SHARED=YES
- -DLIBOMP_INSTALL_ALIASES=NO
- -DLLVM_INCLUDE_DOCS=YES
- -DLLVM_BUILD_DOCS=YES
- -DLLVM_ENABLE_SPHINX=YES
- -DSPHINX_WARNINGS_AS_ERRORS=NO
- -DLLVM_INSTALL_UTILS=YES
- -DLLVM_BUILD_LLVM_DYLIB=YES
- -DLLVM_LINK_LLVM_DYLIB=YES
- -DLLVM_ENABLE_RTTI=YES
- -DLLVM_ENABLE_FFI=YES
- -DLLVM_BINUTILS_INCDIR=/usr/include"
-hostmakedepends="perl python3 zlib-devel libffi-devel swig python3-Sphinx
- python3-recommonmark python3-sphinx-automodapi"
-makedepends="python3-devel zlib-devel elfutils-devel libffi-devel libedit-devel
- libxml2-devel binutils-devel"
-depends="libllvm12>=${version}_${revision}"
-short_desc="Low Level Virtual Machine"
-maintainer="Orphaned <orphan@voidlinux.org>"
-license="Apache-2.0"
-homepage="https://www.llvm.org"
-distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-project-${version}.src.tar.xz"
-checksum=129cb25cd13677aad951ce5c2deb0fe4afc1e9d98950f53b51bdcfb5a73afa0e
-lib32disabled=yes
-python_version=3
-
-if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
- configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
- makedepends+=" libexecinfo-devel"
- depends+=" libexecinfo-devel"
-fi
-
-# "operand out of range" assembler failures
-case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*) configure_args+=" -DCLANG_ENABLE_CLANGD=OFF" ;;
-esac
-
-post_patch() {
- # update config.guess for better platform detection
- cp $XBPS_COMMONDIR/environment/configure/automake/config.guess \
- ${wrksrc}/llvm/cmake
-
- # fix linker failures on some archs
- vsed -i 's,check_library_exists(gcc_s .*,set(LIBCXXABI_HAS_GCC_S_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
- vsed -i 's,check_library_exists(gcc .*,set(LIBCXXABI_HAS_GCC_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
-
- # need libssp_nonshared on some musl platforms (because of nodefaultlibs)
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*-musl|i686-musl|mips*-musl)
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libunwind/src/CMakeLists.txt
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libcxxabi/src/CMakeLists.txt
- vsed -i 's,#ssp,,' ${wrksrc}/libcxx/CMakeLists.txt
- ;;
- 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
- ;;
- esac
-}
-
-pre_configure() {
- local triplet
-
- # Vastly reduce size of debugging symbols:
- CFLAGS=${CFLAGS/ -g/ -g1}
- CXXFLAGS=${CXXFLAGS/ -g/ -g1}
-
- # since gcc9, the build likes to blow up for ppc32 apparently because
- # of clang being too large for a 24-bit relative call to the PLT, so
- # optimize for size instead
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- mips*-musl|ppc*) configure_args+=" -DVOID_CXX_OPT_FLAGS=-Os" ;;
- esac
-
- if [ "$CROSS_BUILD" ]; then
- msg_normal "Building host tblgen\n"
- mkdir -p build/HOST
- cd build/HOST
- CC="$BUILD_CC" CXX="$BUILD_CXX" CFLAGS="$BUILD_CFLAGS" \
- CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
- cmake ../.. -DCMAKE_BUILD_TYPE=Release
- make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
- [ "$_lldb_enable" = "yes" ] && make ${makejobs} -C tools/lldb/utils/TableGen
- configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/clang-tblgen"
- cd ../..
- fi
-
- case "$XBPS_TARGET_MACHINE" in
- i686*) _arch="X86";;
- x86_64*) _arch="X86";;
- armv5*) _arch="Armv5te";;
- armv6*) _arch="Armv6";;
- armv7*) _arch="Armv7";;
- aarch64*) _arch="AArch64";;
- mips*) _arch="Mips";;
- ppc*) _arch="PowerPC";;
- riscv64*) _arch="RISCV64";;
- esac
-
- triplet=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}
-
- configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
- configure_args+=" -DLLVM_HOST_TRIPLE=${triplet}"
- configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${triplet}"
-}
-
-do_install() {
- cd build
- cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
-
- # Required for multilib.
- if [ "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
- for _header in llvm-config; do
- mv ${DESTDIR}/usr/include/llvm/Config/${_header}{,-64}.h
- vinstall ${FILESDIR}/llvm-Config-${_header}.h 644 \
- usr/include/llvm/Config ${_header}.h
- done
- fi
-
- # Remove llvm-config-host in cross builds.
- if [ "$CROSS_BUILD" ]; then
- rm -f ${DESTDIR}/usr/bin/llvm-config-host
- fi
-}
-
-libllvm12_package() {
- short_desc+=" - runtime library"
- pkg_install() {
- vmove "usr/lib/libLLVM-*.so*"
- }
-}
diff --git a/srcpkgs/llvm12/update b/srcpkgs/llvm12/update
deleted file mode 100644
index e95cf26b3586b7..00000000000000
--- a/srcpkgs/llvm12/update
+++ /dev/null
@@ -1,3 +0,0 @@
-site="https://github.com/llvm/llvm-project/releases"
-pattern="llvmorg-\K(\d+.){2}\d+(-rc\d+)?"
-ignore="*-rc*"
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index e729b51bfc267d..d59bdf00432c32 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
# Template file for 'removed-packages'
pkgname=removed-packages
-version=0.1.20240727
+version=0.1.20240729
revision=1
build_style=meta
short_desc="Uninstalls packages removed from repository"
@@ -376,6 +376,7 @@ replaces="
libgroff<=1.22.4_3
libgtkhtml<=4.10.0_1
libkscreen<=5.27.11_3
+ libllvm12<=12.0.1_4
libllvm10<=10.0.0_8
libllvm11<=11.0.0_2
libllvm15<=15.0.7_4
@@ -438,8 +439,12 @@ replaces="
lld15-devel<=15.0.7_4
lld15<=15.0.7_4
lldb-devel<=15.0.7_3
+<<<<<<< HEAD
lldb15-devel<=15.0.7_4
lldb15<=15.0.7_4
+=======
+ llvm12<=12.0.1_4
+>>>>>>> 16a752acee5 (llvm12: remove package)
llvm10<=10.0.0_8
llvm11<=11.0.0_2
llvm15<=15.0.7_4
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (8 preceding siblings ...)
2024-07-30 20:38 ` [PR PATCH] [Updated] " Calandracas606
@ 2024-07-30 20:39 ` Calandracas606
2024-07-30 20:42 ` [PR REVIEW] " Calandracas606
` (4 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-30 20:39 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1422 bytes --]
There is an updated pull request by Calandracas606 against master on the void-packages repository
https://github.com/Calandracas606/void-packages remove-llvm12
https://github.com/void-linux/void-packages/pull/51186
remove llvm12
- **mozjs102: build with llvm18**
- **ghdl: update to 4.1.0.**
- **llvm12: remove package**
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, x86_64
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64-musl
- i686
- aarch64 (cross)
- aarch64-musl (cross)
- armv7l (cross)
- armv7l-musl (cross)
- armv6l (cross)
- armv6l-musl (cross)
A patch file from https://github.com/void-linux/void-packages/pull/51186.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-remove-llvm12-51186.patch --]
[-- Type: text/x-diff, Size: 50232 bytes --]
From e793e7eba50fe12423a9615fead3f77693088302 Mon Sep 17 00:00:00 2001
From: Daniel Martinez <danielmartinez@cock.li>
Date: Tue, 9 Jul 2024 22:18:51 -0400
Subject: [PATCH] llvm12: remove package
---
common/shlibs | 2 +
srcpkgs/libllvm12 | 1 -
.../llvm12/files/llvm-Config-llvm-config.h | 9 -
...clang-001-fix-unwind-chain-inclusion.patch | 44 -----
.../patches/clang-002-add-musl-triples.patch | 110 ------------
.../clang-003-ppc64-dynamic-linker-path.patch | 13 --
.../patches/clang-004-ppc64-musl-elfv2.patch | 48 ------
.../compiler-rt-aarch64-ucontext.patch | 11 --
.../compiler-rt-sanitizer-glibc-2.36.patch | 59 -------
.../compiler-rt-sanitizer-ppc64-musl.patch | 35 ----
.../llvm12/patches/compiler-rt-size_t.patch | 10 --
.../patches/compiler-rt-xray-ppc64-musl.patch | 62 -------
srcpkgs/llvm12/patches/libcxx-musl.patch | 26 ---
srcpkgs/llvm12/patches/libcxx-ppc.patch | 22 ---
.../llvm12/patches/libcxx-ssp-nonshared.patch | 11 --
srcpkgs/llvm12/patches/libcxxabi-dl.patch | 25 ---
srcpkgs/llvm12/patches/libunwind-ppc32.patch | 63 -------
srcpkgs/llvm12/patches/lldb-musl.patch | 31 ----
srcpkgs/llvm12/patches/llvm-001-musl.patch | 57 -------
.../patches/llvm-002-musl-ppc64-elfv2.patch | 30 ----
.../patches/llvm-003-ppc-secureplt.patch | 11 --
.../patches/llvm-004-override-opt.patch | 18 --
.../llvm12/patches/llvm-005-ppc-bigpic.patch | 36 ----
.../patches/llvm-006-aarch64-mf_exec.patch | 25 ---
srcpkgs/llvm12/patches/llvm-gcc13.patch | 28 ---
.../llvm12/patches/ppc32-compiler-rt.patch | 21 ---
srcpkgs/llvm12/template | 161 ------------------
srcpkgs/llvm12/update | 3 -
srcpkgs/removed-packages/template | 4 +-
29 files changed, 5 insertions(+), 971 deletions(-)
delete mode 120000 srcpkgs/libllvm12
delete mode 100644 srcpkgs/llvm12/files/llvm-Config-llvm-config.h
delete mode 100644 srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-size_t.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ppc.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxxabi-dl.patch
delete mode 100644 srcpkgs/llvm12/patches/libunwind-ppc32.patch
delete mode 100644 srcpkgs/llvm12/patches/lldb-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-001-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-004-override-opt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-gcc13.patch
delete mode 100644 srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
delete mode 100644 srcpkgs/llvm12/template
delete mode 100644 srcpkgs/llvm12/update
diff --git a/common/shlibs b/common/shlibs
index 5cfafa2be55b75..c3f08c44b7ba48 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -994,6 +994,8 @@ libclang-cpp.so.18.1 libclang-cpp18-18.1.8_1
libclang-cpp.so.17 libclang-cpp17-17.0.6_1
libLLVM-11.so libllvm11-11.0.0_1
libLLVM-12.so libllvm12-12.0.0_1
+libclang-cpp.so.15 libclang-cpp15-15.0.7_4
+libLLVM-15.so libllvm15-15.0.7_4
libLLVM-17.so libllvm17-17.0.6_1
libLLVM.so.18.1 libllvm18-18.1.8_1
libLLVMSPIRVLib.so.18.1 SPIRV-LLVM-Translator-18.1.2_1
diff --git a/srcpkgs/libllvm12 b/srcpkgs/libllvm12
deleted file mode 120000
index cd60fd7a981bdd..00000000000000
--- a/srcpkgs/libllvm12
+++ /dev/null
@@ -1 +0,0 @@
-llvm12
\ No newline at end of file
diff --git a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h b/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
deleted file mode 100644
index 2fa08c9be69621..00000000000000
--- a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
+++ /dev/null
@@ -1,9 +0,0 @@
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 32
-#include "llvm-config-32.h"
-#elif __WORDSIZE == 64
-#include "llvm-config-64.h"
-#else
-#error "Unknown word size"
-#endif
diff --git a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
deleted file mode 100644
index e4eaa7783e7a6c..00000000000000
--- a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 352974169f0d2b5da3d5321f588f5e3b5941330e Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:14:57 +0200
-Subject: [PATCH 2/7] fix unwind chain inclusion
-
----
- lib/Headers/unwind.h | 9 +++++----
- 1 file changed, 5 insertions(+), 4 deletions(-)
-
-diff --git a/lib/Headers/unwind.h b/lib/Headers/unwind.h
-index 303d792..44e10cc 100644
---- a/clang/lib/Headers/unwind.h
-+++ b/clang/lib/Headers/unwind.h
-@@ -9,9 +9,6 @@
-
- /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/
-
--#ifndef __CLANG_UNWIND_H
--#define __CLANG_UNWIND_H
--
- #if defined(__APPLE__) && __has_include_next(<unwind.h>)
- /* Darwin (from 11.x on) provide an unwind.h. If that's available,
- * use it. libunwind wraps some of its definitions in #ifdef _GNU_SOURCE,
-@@ -39,6 +36,9 @@
- # endif
- #else
-
-+#ifndef __CLANG_UNWIND_H
-+#define __CLANG_UNWIND_H
-+
- #include <stdint.h>
-
- #ifdef __cplusplus
-@@ -322,6 +322,7 @@ _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *);
- }
- #endif
-
-+#endif /* __CLANG_UNWIND_H */
-+
- #endif
-
--#endif /* __CLANG_UNWIND_H */
---
-2.5.1
diff --git a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch b/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
deleted file mode 100644
index 25688d40dbc275..00000000000000
--- a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
+++ /dev/null
@@ -1,110 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Gnu.cpp
-+++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2086,7 +2086,8 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
- "armv7hl-redhat-linux-gnueabi",
- "armv6hl-suse-linux-gnueabi",
-- "armv7hl-suse-linux-gnueabi"};
-+ "armv7hl-suse-linux-gnueabi",
-+ "armv7l-linux-gnueabihf"};
- static const char *const ARMebLibDirs[] = {"/lib"};
- static const char *const ARMebTriples[] = {"armeb-linux-gnueabi",
- "armeb-linux-androideabi"};
-@@ -2153,8 +2154,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- "powerpc64-suse-linux", "powerpc-montavista-linuxspe"};
- static const char *const PPCLELibDirs[] = {"/lib32", "/lib"};
- static const char *const PPCLETriples[] = {"powerpcle-linux-gnu",
-- "powerpcle-unknown-linux-gnu",
-- "powerpcle-linux-musl"};
-+ "powerpcle-unknown-linux-gnu"};
-
- static const char *const PPC64LibDirs[] = {"/lib64", "/lib"};
- static const char *const PPC64Triples[] = {
-@@ -2235,6 +2235,87 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- return;
- }
-
-+ if (TargetTriple.isMusl()) {
-+ static const char *const AArch64MuslTriples[] = {"aarch64-linux-musl"};
-+ static const char *const ARMHFMuslTriples[] = {
-+ "arm-linux-musleabihf", "armv7l-linux-musleabihf"
-+ };
-+ static const char *const ARMMuslTriples[] = {"arm-linux-musleabi"};
-+ static const char *const X86_64MuslTriples[] = {"x86_64-linux-musl"};
-+ static const char *const X86MuslTriples[] = {"i686-linux-musl"};
-+ static const char *const MIPSMuslTriples[] = {
-+ "mips-linux-musl", "mipsel-linux-musl",
-+ "mipsel-linux-muslhf", "mips-linux-muslhf"
-+ };
-+ static const char *const PPCMuslTriples[] = {"powerpc-linux-musl"};
-+ static const char *const PPCLEMuslTriples[] = {"powerpcle-linux-musl"};
-+ static const char *const PPC64MuslTriples[] = {"powerpc64-linux-musl"};
-+ static const char *const PPC64LEMuslTriples[] = {"powerpc64le-linux-musl"};
-+
-+ switch (TargetTriple.getArch()) {
-+ case llvm::Triple::aarch64:
-+ LibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ TripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ BiarchLibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ BiarchTripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ break;
-+ case llvm::Triple::arm:
-+ LibDirs.append(begin(ARMLibDirs), end(ARMLibDirs));
-+ if (TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
-+ TripleAliases.append(begin(ARMHFMuslTriples), end(ARMHFMuslTriples));
-+ } else {
-+ TripleAliases.append(begin(ARMMuslTriples), end(ARMMuslTriples));
-+ }
-+ break;
-+ case llvm::Triple::x86_64:
-+ LibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ TripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ BiarchLibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ BiarchTripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ break;
-+ case llvm::Triple::x86:
-+ LibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ TripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ BiarchLibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ BiarchTripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ break;
-+ case llvm::Triple::mips:
-+ LibDirs.append(begin(MIPSLibDirs), end(MIPSLibDirs));
-+ TripleAliases.append(begin(MIPSMuslTriples), end(MIPSMuslTriples));
-+ break;
-+ case llvm::Triple::ppc:
-+ LibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ TripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ BiarchTripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ break;
-+ case llvm::Triple::ppcle:
-+ LibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ TripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ BiarchTripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64:
-+ LibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ TripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ BiarchLibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ BiarchTripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64le:
-+ LibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ TripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ BiarchLibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ BiarchTripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ break;
-+ default:
-+ break;
-+ }
-+ TripleAliases.push_back(TargetTriple.str());
-+ if (TargetTriple.str() != BiarchTriple.str())
-+ BiarchTripleAliases.push_back(BiarchTriple.str());
-+ return;
-+ }
-+
- // Android targets should not use GNU/Linux tools or libraries.
- if (TargetTriple.isAndroid()) {
- static const char *const AArch64AndroidTriples[] = {
diff --git a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
deleted file mode 100644
index 4ad6412d1e6c63..00000000000000
--- a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Linux.cpp
-+++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -504,10 +504,6 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
- Loader = "ld.so.1";
- break;
- case llvm::Triple::ppc64:
-- LibDir = "lib64";
-- Loader =
-- (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
-- break;
- case llvm::Triple::ppc64le:
- LibDir = "lib64";
- Loader =
diff --git a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
deleted file mode 100644
index 21fc8003c5f1a8..00000000000000
--- a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
+++ /dev/null
@@ -1,48 +0,0 @@
---- a/clang/lib/Basic/Targets/PPC.h
-+++ b/clang/lib/Basic/Targets/PPC.h
-@@ -415,11 +415,10 @@ public:
- LongDoubleFormat = &llvm::APFloat::IEEEdouble();
- } else if ((Triple.getArch() == llvm::Triple::ppc64le)) {
- DataLayout = "e-m:e-i64:64-n32:64";
-- ABI = "elfv2";
- } else {
- DataLayout = "E-m:e-i64:64-n32:64";
-- ABI = "elfv1";
- }
-+ ABI = "elfv2";
-
- if (Triple.isOSFreeBSD() || Triple.isOSOpenBSD() || Triple.isMusl()) {
- LongDoubleWidth = LongDoubleAlign = 64;
---- a/clang/lib/CodeGen/TargetInfo.cpp
-+++ b/clang/lib/CodeGen/TargetInfo.cpp
-@@ -10927,9 +10927,9 @@ const TargetCodeGenInfo &CodeGenModule::getTargetCodeGenInfo() {
- return SetCGInfo(new AIXTargetCodeGenInfo(Types, /*Is64Bit*/ true));
-
- if (Triple.isOSBinFormatELF()) {
-- PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv1;
-- if (getTarget().getABI() == "elfv2")
-- Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ if (getTarget().getABI() == "elfv1")
-+ Kind = PPC64_SVR4_ABIInfo::ELFv1;
- bool IsSoftFloat = CodeGenOpts.FloatABI == "soft";
-
- return SetCGInfo(
---- a/clang/lib/Driver/ToolChains/Clang.cpp
-+++ b/clang/lib/Driver/ToolChains/Clang.cpp
-@@ -1920,14 +1920,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
- const llvm::Triple &T = getToolChain().getTriple();
- if (T.isOSBinFormatELF()) {
- switch (getToolChain().getArch()) {
-- case llvm::Triple::ppc64: {
-- if ((T.isOSFreeBSD() && T.getOSMajorVersion() >= 13) ||
-- T.isOSOpenBSD() || T.isMusl())
-- ABIName = "elfv2";
-- else
-- ABIName = "elfv1";
-- break;
-- }
-+ case llvm::Triple::ppc64:
- case llvm::Triple::ppc64le:
- ABIName = "elfv2";
- break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch b/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
deleted file mode 100644
index 893c059d7b8def..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp.orig
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -1799,7 +1799,7 @@
-
- static bool Aarch64GetESR(ucontext_t *ucontext, u64 *esr) {
- static const u32 kEsrMagic = 0x45535201;
-- u8 *aux = ucontext->uc_mcontext.__reserved;
-+ u8 *aux = reinterpret_cast<u8 *>(ucontext->uc_mcontext.__reserved);
- while (true) {
- _aarch64_ctx *ctx = (_aarch64_ctx *)aux;
- if (ctx->size == 0) break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
deleted file mode 100644
index e5f24dab893547..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From 9cf13067cb5088626ba7ee1ec4c42ec59c7995a0 Mon Sep 17 00:00:00 2001
-From: Fangrui Song <i@maskray.me>
-Date: Mon, 11 Jul 2022 12:53:34 -0700
-Subject: [PATCH] [sanitizer] Remove #include <linux/fs.h> to resolve
- fsconfig_command/mount_attr conflict with glibc 2.36
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-It is generally not a good idea to mix usage of glibc headers and Linux UAPI
-headers (https://sourceware.org/glibc/wiki/Synchronizing_Headers). In glibc
-since 7eae6a91e9b1670330c9f15730082c91c0b1d570 (milestone: 2.36), sys/mount.h
-defines `fsconfig_command` which conflicts with linux/mount.h:
-
- .../usr/include/linux/mount.h:95:6: error: redeclaration of ‘enum fsconfig_command’
-
-Remove #include <linux/fs.h> which pulls in linux/mount.h. Expand its 4 macros manually.
-Android sys/mount.h doesn't define BLKBSZGET and it still needs linux/fs.h.
-In the long term we should move Linux specific definitions to sanitizer_platform_limits_linux.cpp
-but this commit is easy to cherry pick into older compiler-rt releases.
-
-Fix https://github.com/llvm/llvm-project/issues/56421
-
-Reviewed By: #sanitizers, vitalybuka, zatrazz
-
-Differential Revision: https://reviews.llvm.org/D129471
----
- .../sanitizer_platform_limits_posix.cpp | 10 ++++++----
- 1 file changed, 6 insertions(+), 4 deletions(-)
-
-diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-index 4bd425435d56d..3a94b260686f1 100644
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -73,7 +73,9 @@
- #include <sys/vt.h>
- #include <linux/cdrom.h>
- #include <linux/fd.h>
-+#if SANITIZER_ANDROID
- #include <linux/fs.h>
-+#endif
- #include <linux/hdreg.h>
- #include <linux/input.h>
- #include <linux/ioctl.h>
-@@ -876,10 +878,10 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr);
- unsigned IOCTL_EVIOCGPROP = IOCTL_NOT_PRESENT;
- unsigned IOCTL_EVIOCSKEYCODE_V2 = IOCTL_NOT_PRESENT;
- #endif
-- unsigned IOCTL_FS_IOC_GETFLAGS = FS_IOC_GETFLAGS;
-- unsigned IOCTL_FS_IOC_GETVERSION = FS_IOC_GETVERSION;
-- unsigned IOCTL_FS_IOC_SETFLAGS = FS_IOC_SETFLAGS;
-- unsigned IOCTL_FS_IOC_SETVERSION = FS_IOC_SETVERSION;
-+ unsigned IOCTL_FS_IOC_GETFLAGS = _IOR('f', 1, long);
-+ unsigned IOCTL_FS_IOC_GETVERSION = _IOR('v', 1, long);
-+ unsigned IOCTL_FS_IOC_SETFLAGS = _IOW('f', 2, long);
-+ unsigned IOCTL_FS_IOC_SETVERSION = _IOW('v', 2, long);
- unsigned IOCTL_GIO_CMAP = GIO_CMAP;
- unsigned IOCTL_GIO_FONT = GIO_FONT;
- unsigned IOCTL_GIO_UNIMAP = GIO_UNIMAP;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
deleted file mode 100644
index 35f16d24f340c6..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
+++ /dev/null
@@ -1,35 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -74,6 +74,10 @@
- #include <sys/utsname.h>
- #endif
-
-+#if SANITIZER_LINUX && defined(__powerpc__)
-+#include <asm/ptrace.h>
-+#endif
-+
- #if SANITIZER_LINUX && !SANITIZER_ANDROID
- #include <sys/personality.h>
- #endif
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -92,7 +92,7 @@
- # include <utime.h>
- # include <sys/ptrace.h>
- #if defined(__mips64) || defined(__aarch64__) || defined(__arm__) || \
-- SANITIZER_RISCV64
-+ defined(__powerpc__) || SANITIZER_RISCV64
- # include <asm/ptrace.h>
- # ifdef __arm__
- typedef struct user_fpregs elf_fpregset_t;
---- a/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-@@ -31,7 +31,7 @@
- #include <sys/types.h> // for pid_t
- #include <sys/uio.h> // for iovec
- #include <elf.h> // for NT_PRSTATUS
--#if (defined(__aarch64__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
-+#if (defined(__aarch64__) || defined(__powerpc__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
- // GLIBC 2.20+ sys/user does not include asm/ptrace.h
- # include <asm/ptrace.h>
- #endif
diff --git a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch b/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
deleted file mode 100644
index 2c63063a5e9e3f..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp.orig
-+++ b/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp
-@@ -25,6 +25,7 @@
- }
-
- #include <cassert>
-+#include <cstddef>
- #include <cstdint>
- #include <dlfcn.h> // for dlsym()
-
diff --git a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
deleted file mode 100644
index d0b61c80c897f4..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
+++ /dev/null
@@ -1,62 +0,0 @@
---- a/compiler-rt/lib/xray/xray_powerpc64.inc
-+++ b/compiler-rt/lib/xray/xray_powerpc64.inc
-@@ -12,7 +12,13 @@
-
- #include <cstdint>
- #include <mutex>
-+#ifdef __GLIBC__
- #include <sys/platform/ppc.h>
-+#else
-+#include <cctype>
-+#include <cstring>
-+#include <cstdlib>
-+#endif
-
- #include "xray_defs.h"
-
-@@ -20,13 +26,45 @@ namespace __xray {
-
- ALWAYS_INLINE uint64_t readTSC(uint8_t &CPU) XRAY_NEVER_INSTRUMENT {
- CPU = 0;
-+#ifdef __GLIBC__
- return __ppc_get_timebase();
-+#else
-+ return __builtin_ppc_get_timebase();
-+#endif
- }
-
- inline uint64_t getTSCFrequency() XRAY_NEVER_INSTRUMENT {
- static std::mutex M;
- std::lock_guard<std::mutex> Guard(M);
-+#ifdef __GLIBC__
- return __ppc_get_timebase_freq();
-+#else
-+ /* FIXME: a less dirty implementation? */
-+ static uint64_t base;
-+ if (!base) {
-+ FILE *f = fopen("/proc/cpuinfo", "rb");
-+ if (f) {
-+ ssize_t nr;
-+ /* virtually always big enough to hold the line */
-+ char buf[512];
-+ while (fgets(buf, sizeof(buf), f)) {
-+ char *ret = strstr(buf, "timebase");
-+ if (!ret) {
-+ continue;
-+ }
-+ ret += sizeof("timebase") - 1;
-+ ret = strchr(ret, ':');
-+ if (!ret) {
-+ continue;
-+ }
-+ base = strtoul(ret + 1, nullptr, 10);
-+ break;
-+ }
-+ fclose(f);
-+ }
-+ }
-+ return base;
-+#endif
- }
-
- inline bool probeRequiredCPUFeatures() XRAY_NEVER_INSTRUMENT {
diff --git a/srcpkgs/llvm12/patches/libcxx-musl.patch b/srcpkgs/llvm12/patches/libcxx-musl.patch
deleted file mode 100644
index bbd31ffc2cb1f4..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-musl.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/libcxx/include/locale
-+++ b/libcxx/include/locale
-@@ -742,7 +742,11 @@ __num_get_signed_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ long long __ll = strtoll(__a, &__p2, __base);
-+#else
- long long __ll = strtoll_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
-@@ -782,7 +786,11 @@ __num_get_unsigned_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ unsigned long long __ll = strtoull(__a, &__p2, __base);
-+#else
- unsigned long long __ll = strtoull_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
diff --git a/srcpkgs/llvm12/patches/libcxx-ppc.patch b/srcpkgs/llvm12/patches/libcxx-ppc.patch
deleted file mode 100644
index 7a92f8004e1cf8..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ppc.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-This ensures `is_iec559` is defined correctly under all long double ABIs,
-including musl and its 64-bit long double. Also, `__ppc__` or `__ppc64__`
-is not defined on gcc.
-
---- a/libcxx/include/limits
-+++ b/libcxx/include/limits
-@@ -426,8 +426,14 @@ protected:
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nansl("");}
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __LDBL_DENORM_MIN__;}
-
--#if (defined(__ppc__) || defined(__ppc64__))
-+#if defined(__powerpc__) || defined(__powerpc64__)
-+#if (__LDBL_MAX_EXP__ > __DBL_MAX_EXP__) || (__LDBL_MANT_DIG__ == __DBL_MANT_DIG__)
-+ /* IEEE 754 quadruple or double precision */
-+ static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
-+#else
-+ /* 128-bit IBM double-double */
- static _LIBCPP_CONSTEXPR const bool is_iec559 = false;
-+#endif
- #else
- static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
- #endif
diff --git a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch b/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
deleted file mode 100644
index 70292beb2fcdbd..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/libcxx/CMakeLists.txt
-+++ b/libcxx/CMakeLists.txt
-@@ -769,6 +769,8 @@ function(cxx_link_system_libraries target)
- target_link_libraries(${target} PRIVATE atomic)
- endif()
-
-+#ssp target_link_libraries(${target} PRIVATE ssp_nonshared)
-+
- if (MINGW)
- target_link_libraries(${target} PRIVATE "${MINGW_LIBRARIES}")
- endif()
diff --git a/srcpkgs/llvm12/patches/libcxxabi-dl.patch b/srcpkgs/llvm12/patches/libcxxabi-dl.patch
deleted file mode 100644
index 3a15f9db8c981e..00000000000000
--- a/srcpkgs/llvm12/patches/libcxxabi-dl.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-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()
diff --git a/srcpkgs/llvm12/patches/libunwind-ppc32.patch b/srcpkgs/llvm12/patches/libunwind-ppc32.patch
deleted file mode 100644
index 74aa7576ecf9df..00000000000000
--- a/srcpkgs/llvm12/patches/libunwind-ppc32.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-This fixes build at least with gcc9 which does not define `__ppc__`.
-
---- a/libunwind/include/__libunwind_config.h
-+++ b/libunwind/include/__libunwind_config.h
-@@ -49,7 +49,7 @@
- # define _LIBUNWIND_CONTEXT_SIZE 167
- # define _LIBUNWIND_CURSOR_SIZE 179
- # define _LIBUNWIND_HIGHEST_DWARF_REGISTER _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC64
--# elif defined(__ppc__)
-+# elif defined(__powerpc__)
- # define _LIBUNWIND_TARGET_PPC 1
- # define _LIBUNWIND_CONTEXT_SIZE 117
- # define _LIBUNWIND_CURSOR_SIZE 124
---- a/libunwind/src/UnwindRegistersRestore.S
-+++ b/libunwind/src/UnwindRegistersRestore.S
-@@ -392,7 +392,7 @@ Lnovec:
- PPC64_LR(3)
- bctr
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- DEFINE_LIBUNWIND_FUNCTION(_ZN9libunwind13Registers_ppc6jumptoEv)
- //
---- a/libunwind/src/UnwindRegistersSave.S
-+++ b/libunwind/src/UnwindRegistersSave.S
-@@ -554,7 +554,7 @@ DEFINE_LIBUNWIND_FUNCTION(__unw_getcontext)
- blr
-
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- //
- // extern int unw_getcontext(unw_context_t* thread_state)
---- a/libunwind/src/config.h
-+++ b/libunwind/src/config.h
-@@ -95,12 +95,12 @@
- #define _LIBUNWIND_BUILD_SJLJ_APIS
- #endif
-
--#if defined(__i386__) || defined(__x86_64__) || defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__)
-+#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc__) || defined(__powerpc64__)
- #define _LIBUNWIND_SUPPORT_FRAME_APIS
- #endif
-
- #if defined(__i386__) || defined(__x86_64__) || \
-- defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__) || \
-+ defined(__powerpc__) || defined(__powerpc64__) || \
- (!defined(__APPLE__) && defined(__arm__)) || \
- (defined(__arm64__) || defined(__aarch64__)) || \
- defined(__mips__)
---- a/libunwind/src/libunwind.cpp
-+++ b/libunwind/src/libunwind.cpp
-@@ -42,7 +42,7 @@ _LIBUNWIND_HIDDEN int __unw_init_local(unw_cursor_t *cursor,
- # define REGISTER_KIND Registers_x86_64
- #elif defined(__powerpc64__)
- # define REGISTER_KIND Registers_ppc64
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
- # define REGISTER_KIND Registers_ppc
- #elif defined(__aarch64__)
- # define REGISTER_KIND Registers_arm64
diff --git a/srcpkgs/llvm12/patches/lldb-musl.patch b/srcpkgs/llvm12/patches/lldb-musl.patch
deleted file mode 100644
index 601c0d138523e8..00000000000000
--- a/srcpkgs/llvm12/patches/lldb-musl.patch
+++ /dev/null
@@ -1,31 +0,0 @@
---- a/lldb/source/Plugins/Process/Linux/Procfs.h
-+++ b/lldb/source/Plugins/Process/Linux/Procfs.h
-@@ -10,21 +10,12 @@
- // sys/procfs.h on Android/Linux for all supported architectures.
-
- #include <sys/ptrace.h>
-+#include <asm/ptrace.h>
-
--#ifdef __ANDROID__
--#if defined(__arm64__) || defined(__aarch64__)
--typedef unsigned long elf_greg_t;
--typedef elf_greg_t
-- elf_gregset_t[(sizeof(struct user_pt_regs) / sizeof(elf_greg_t))];
--typedef struct user_fpsimd_state elf_fpregset_t;
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#elif defined(__mips__)
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#endif
--#else // __ANDROID__
-+#if !defined(__GLIBC__) && defined(__powerpc__)
-+#define pt_regs musl_pt_regs
-+#include <sys/procfs.h>
-+#undef pt_regs
-+#else
- #include <sys/procfs.h>
--#endif // __ANDROID__
-+#endif
diff --git a/srcpkgs/llvm12/patches/llvm-001-musl.patch b/srcpkgs/llvm12/patches/llvm-001-musl.patch
deleted file mode 100644
index f2a3f8d62813e3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-001-musl.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From faca3fbd15d0c3108493c3c54cd93138e049ac43 Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:03:02 +0200
-Subject: [PATCH 3/3] musl
-
----
- include/llvm/Analysis/TargetLibraryInfo.h | 9 +++++++++
- lib/Support/DynamicLibrary.cpp | 2 +-
- lib/Support/Unix/Signals.inc | 6 +++---
- utils/unittest/googletest/src/gtest.cc | 1 +
- 5 files changed, 17 insertions(+), 6 deletions(-)
-
-diff --git a/include/llvm/Analysis/TargetLibraryInfo.h b/include/llvm/Analysis/TargetLibraryInfo.h
-index 34a8a1e3..1214ece5 100644
---- a/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-+++ b/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-@@ -18,6 +18,15 @@
- #include "llvm/IR/PassManager.h"
- #include "llvm/Pass.h"
-
-+#undef fopen64
-+#undef fseeko64
-+#undef fstat64
-+#undef fstatvfs64
-+#undef ftello64
-+#undef lstat64
-+#undef stat64
-+#undef tmpfile64
-+
- namespace llvm {
- template <typename T> class ArrayRef;
- class Triple;
-diff --git a/lib/Support/Unix/DynamicLibrary.inc b/lib/Support/Unix/DynamicLibrary.inc
-index a2a37996..2f86c470 100644
---- a/llvm/lib/Support/Unix/DynamicLibrary.inc
-+++ b/llvm/lib/Support/Unix/DynamicLibrary.inc
-@@ -102,7 +102,7 @@ static void *DoSearch(const char* SymbolName) {
-
- // This macro returns the address of a well-known, explicit symbol
- #define EXPLICIT_SYMBOL(SYM) \
-- if (!strcmp(SymbolName, #SYM)) return &SYM
-+ if (!strcmp(SymbolName, #SYM)) return (void *)&SYM
-
- // Under glibc we have a weird situation. The stderr/out/in symbols are both
- // macros and global variables because of standards requirements. So, we
-diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
-index d882ab2e..f1fb12d0 100644
---- a/llvm/utils/unittest/googletest/src/gtest.cc
-+++ b/llvm/utils/unittest/googletest/src/gtest.cc
-@@ -128,6 +128,7 @@
-
- #if GTEST_CAN_STREAM_RESULTS_
- # include <arpa/inet.h> // NOLINT
-+# include <sys/socket.h> // NOLINT
- # include <netdb.h> // NOLINT
- # include <sys/socket.h> // NOLINT
- # include <sys/types.h> // NOLINT
diff --git a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
deleted file mode 100644
index 0071d964bd371f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-This patches LLVM to use ELFv2 on ppc64 unconditionally unless overridden. We
-need this because unlike most distros we use ELFv2 for both glibc and musl
-on big endian ppc64.
-
-diff --git a/lib/Target/PowerPC/PPCTargetMachine.cpp b/lib/Target/PowerPC/PPCTargetMachine.cpp
-index 0634833e..b7cbc2e7 100644
---- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-@@ -222,9 +222,8 @@ static PPCTargetMachine::PPCABI computeTargetABI(const Triple &TT,
-
- switch (TT.getArch()) {
- case Triple::ppc64le:
-- return PPCTargetMachine::PPC_ABI_ELFv2;
- case Triple::ppc64:
-- return PPCTargetMachine::PPC_ABI_ELFv1;
-+ return PPCTargetMachine::PPC_ABI_ELFv2;
- default:
- return PPCTargetMachine::PPC_ABI_UNKNOWN;
- }
-diff --git a/test/CodeGen/PowerPC/ppc64-elf-abi.ll b/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-index 8b1cf6b5..296a2afa 100644
---- a/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-+++ b/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-@@ -1,4 +1,5 @@
--; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv1
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-musl < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
diff --git a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch b/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
deleted file mode 100644
index b5d15974375d49..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-@@ -165,7 +165,7 @@ void PPCSubtarget::initSubtargetFeatures(StringRef CPU, StringRef FS) {
-
- if ((TargetTriple.isOSFreeBSD() && TargetTriple.getOSMajorVersion() >= 13) ||
- TargetTriple.isOSNetBSD() || TargetTriple.isOSOpenBSD() ||
-- TargetTriple.isMusl())
-+ isTargetLinux())
- SecurePlt = true;
-
- if (HasSPE && IsPPC64)
diff --git a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch b/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
deleted file mode 100644
index 51d0e4b31b32c3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-This allows us to override the optimization level as not all platforms can
-deal with -O3.
-
---- a/llvm/CMakeLists.txt
-+++ b/llvm/CMakeLists.txt
-@@ -918,6 +918,12 @@ if( MINGW AND NOT "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang" )
- llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "-O2")
- endif()
-
-+set(VOID_CXX_OPT_FLAGS "" CACHE STRING "Optimization level to use")
-+
-+if (NOT VOID_CXX_OPT_FLAGS STREQUAL "")
-+ llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "${VOID_CXX_OPT_FLAGS}")
-+endif()
-+
- # Put this before tblgen. Else we have a circular dependence.
- add_subdirectory(lib/Demangle)
- add_subdirectory(lib/Support)
diff --git a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
deleted file mode 100644
index d332687b9d9295..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From f3dbdd49c06bfafc1d6138094cf42889c14d38b6 Mon Sep 17 00:00:00 2001
-From: Samuel Holland <samuel@sholland.org>
-Date: Sun, 3 Nov 2019 10:57:27 -0600
-Subject: [PATCH] [LLVM][PowerPC] Assume BigPIC if no PIC level is specified
-
----
- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp | 2 +-
- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/lib/Target/PowerPC/PPCAsmPrinter.cpp b/lib/Target/PowerPC/PPCAsmPrinter.cpp
-index cce21f32..87ca5f9b 100644
---- a/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-@@ -520,7 +520,7 @@ void PPCAsmPrinter::EmitTlsCall(const MachineInstr *MI,
-
- // Add 32768 offset to the symbol so we follow up the latest GOT/PLT ABI.
- if (Kind == MCSymbolRefExpr::VK_PLT && Subtarget->isSecurePlt() &&
-- M->getPICLevel() == PICLevel::BigPIC)
-+ M->getPICLevel() != PICLevel::SmallPIC)
- TlsRef = MCBinaryExpr::createAdd(
- TlsRef, MCConstantExpr::create(32768, OutContext), OutContext);
- const MachineOperand &MO = MI->getOperand(2);
-diff --git a/lib/Target/PowerPC/PPCMCInstLower.cpp b/lib/Target/PowerPC/PPCMCInstLower.cpp
-index 5cc180d7..a5b02565 100644
---- a/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-@@ -117,7 +117,7 @@ static MCOperand GetSymbolRef(const MachineOperand &MO, const MCSymbol *Symbol,
- const MCExpr *Expr = MCSymbolRefExpr::create(Symbol, RefKind, Ctx);
- // If -msecure-plt -fPIC, add 32768 to symbol.
- if (Subtarget->isSecurePlt() && TM.isPositionIndependent() &&
-- M->getPICLevel() == PICLevel::BigPIC &&
-+ M->getPICLevel() != PICLevel::SmallPIC &&
- MO.getTargetFlags() == PPCII::MO_PLT)
- Expr =
- MCBinaryExpr::createAdd(Expr, MCConstantExpr::create(32768, Ctx), Ctx);
diff --git a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch b/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
deleted file mode 100644
index a00abd2166651f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Fix failures in AllocationTests/MappedMemoryTest.* on aarch64:
-
- Failing Tests (8):
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.AllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.DuplicateNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.EnabledWrite/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.MultipleAllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.SuccessiveNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.UnalignedNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroSizeNear/3
-
-Upstream-Issue: https://bugs.llvm.org/show_bug.cgi?id=14278#c10
-
---- a/llvm/lib/Support/Unix/Memory.inc
-+++ b/llvm/lib/Support/Unix/Memory.inc
-@@ -58,7 +58,7 @@ static int getPosixProtectionFlags(unsigned Flags) {
- return PROT_READ | PROT_WRITE | PROT_EXEC;
- case llvm::sys::Memory::MF_EXEC:
- #if (defined(__FreeBSD__) || defined(__POWERPC__) || defined (__ppc__) || \
-- defined(_POWER) || defined(_ARCH_PPC))
-+ defined(_POWER) || defined(_ARCH_PPC) || (defined(__linux__) && defined(__aarch64__)))
- // On PowerPC, having an executable page that has no read permission
- // can have unintended consequences. The function InvalidateInstruction-
- // Cache uses instructions dcbf and icbi, both of which are treated by
diff --git a/srcpkgs/llvm12/patches/llvm-gcc13.patch b/srcpkgs/llvm12/patches/llvm-gcc13.patch
deleted file mode 100644
index 6895221b73bb75..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-gcc13.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From ff1681ddb303223973653f7f5f3f3435b48a1983 Mon Sep 17 00:00:00 2001
-From: Sergei Trofimovich <slyich@gmail.com>
-Date: Mon, 23 May 2022 08:03:23 +0100
-Subject: [PATCH] [Support] Add missing <cstdint> header to Signals.h
-
-Without the change llvm build fails on this week's gcc-13 snapshot as:
-
- [ 0%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o
- In file included from llvm/lib/Support/Signals.cpp:14:
- llvm/include/llvm/Support/Signals.h:119:8: error: variable or field 'CleanupOnSignal' declared void
- 119 | void CleanupOnSignal(uintptr_t Context);
- | ^~~~~~~~~~~~~~~
----
- llvm/include/llvm/Support/Signals.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/llvm/include/llvm/Support/Signals.h b/llvm/include/llvm/Support/Signals.h
-index 44f5a750ff5cb0..937e0572d4a725 100644
---- a/llvm/include/llvm/Support/Signals.h
-+++ b/llvm/include/llvm/Support/Signals.h
-@@ -14,6 +14,7 @@
- #ifndef LLVM_SUPPORT_SIGNALS_H
- #define LLVM_SUPPORT_SIGNALS_H
-
-+#include <cstdint>
- #include <string>
-
- namespace llvm {
diff --git a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch b/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
deleted file mode 100644
index 8e0a9a779d1bf8..00000000000000
--- a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-commit ba4ede595ff9599232f5dd2b4384c243137b53fc
-Author: Daniel Kolesa <daniel@octaforge.org>
-Date: Tue Jun 22 23:40:54 2021 +0200
-
- enable compiler-rt support for ppc32
-
-diff --git a/compiler-rt/cmake/base-config-ix.cmake b/compiler-rt/cmake/base-config-ix.cmake
-index 1edab43..5c0c8a2 100644
---- a/compiler-rt/cmake/base-config-ix.cmake
-+++ b/compiler-rt/cmake/base-config-ix.cmake
-@@ -182,9 +182,7 @@ macro(test_targets)
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc64le")
- test_target_arch(powerpc64le "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc")
-- if(CMAKE_SYSTEM_NAME MATCHES "AIX")
-- test_target_arch(powerpc "" "-m32")
-- endif()
-+ test_target_arch(powerpc "" "-m32")
- test_target_arch(powerpc64 "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "s390x")
- test_target_arch(s390x "" "")
diff --git a/srcpkgs/llvm12/template b/srcpkgs/llvm12/template
deleted file mode 100644
index 86e86bb96c63f1..00000000000000
--- a/srcpkgs/llvm12/template
+++ /dev/null
@@ -1,161 +0,0 @@
-# Template file for 'llvm12'
-pkgname=llvm12
-version=12.0.1
-revision=4
-build_wrksrc=llvm
-build_style=cmake
-configure_args="
- -DCMAKE_BUILD_TYPE=Release -Wno-dev
- -DENABLE_LINKER_BUILD_ID=YES
- -DLLDB_USE_SYSTEM_SIX=YES
- -DLIBCXX_CXX_ABI=libcxxabi
- -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=YES
- -DLIBCXXABI_USE_LLVM_UNWINDER=YES
- -DLIBCXXABI_ENABLE_STATIC_UNWINDER=YES
- -DLIBOMP_ENABLE_SHARED=YES
- -DLIBOMP_INSTALL_ALIASES=NO
- -DLLVM_INCLUDE_DOCS=YES
- -DLLVM_BUILD_DOCS=YES
- -DLLVM_ENABLE_SPHINX=YES
- -DSPHINX_WARNINGS_AS_ERRORS=NO
- -DLLVM_INSTALL_UTILS=YES
- -DLLVM_BUILD_LLVM_DYLIB=YES
- -DLLVM_LINK_LLVM_DYLIB=YES
- -DLLVM_ENABLE_RTTI=YES
- -DLLVM_ENABLE_FFI=YES
- -DLLVM_BINUTILS_INCDIR=/usr/include"
-hostmakedepends="perl python3 zlib-devel libffi-devel swig python3-Sphinx
- python3-recommonmark python3-sphinx-automodapi"
-makedepends="python3-devel zlib-devel elfutils-devel libffi-devel libedit-devel
- libxml2-devel binutils-devel"
-depends="libllvm12>=${version}_${revision}"
-short_desc="Low Level Virtual Machine"
-maintainer="Orphaned <orphan@voidlinux.org>"
-license="Apache-2.0"
-homepage="https://www.llvm.org"
-distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-project-${version}.src.tar.xz"
-checksum=129cb25cd13677aad951ce5c2deb0fe4afc1e9d98950f53b51bdcfb5a73afa0e
-lib32disabled=yes
-python_version=3
-
-if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
- configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
- makedepends+=" libexecinfo-devel"
- depends+=" libexecinfo-devel"
-fi
-
-# "operand out of range" assembler failures
-case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*) configure_args+=" -DCLANG_ENABLE_CLANGD=OFF" ;;
-esac
-
-post_patch() {
- # update config.guess for better platform detection
- cp $XBPS_COMMONDIR/environment/configure/automake/config.guess \
- ${wrksrc}/llvm/cmake
-
- # fix linker failures on some archs
- vsed -i 's,check_library_exists(gcc_s .*,set(LIBCXXABI_HAS_GCC_S_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
- vsed -i 's,check_library_exists(gcc .*,set(LIBCXXABI_HAS_GCC_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
-
- # need libssp_nonshared on some musl platforms (because of nodefaultlibs)
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*-musl|i686-musl|mips*-musl)
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libunwind/src/CMakeLists.txt
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libcxxabi/src/CMakeLists.txt
- vsed -i 's,#ssp,,' ${wrksrc}/libcxx/CMakeLists.txt
- ;;
- 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
- ;;
- esac
-}
-
-pre_configure() {
- local triplet
-
- # Vastly reduce size of debugging symbols:
- CFLAGS=${CFLAGS/ -g/ -g1}
- CXXFLAGS=${CXXFLAGS/ -g/ -g1}
-
- # since gcc9, the build likes to blow up for ppc32 apparently because
- # of clang being too large for a 24-bit relative call to the PLT, so
- # optimize for size instead
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- mips*-musl|ppc*) configure_args+=" -DVOID_CXX_OPT_FLAGS=-Os" ;;
- esac
-
- if [ "$CROSS_BUILD" ]; then
- msg_normal "Building host tblgen\n"
- mkdir -p build/HOST
- cd build/HOST
- CC="$BUILD_CC" CXX="$BUILD_CXX" CFLAGS="$BUILD_CFLAGS" \
- CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
- cmake ../.. -DCMAKE_BUILD_TYPE=Release
- make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
- [ "$_lldb_enable" = "yes" ] && make ${makejobs} -C tools/lldb/utils/TableGen
- configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/clang-tblgen"
- cd ../..
- fi
-
- case "$XBPS_TARGET_MACHINE" in
- i686*) _arch="X86";;
- x86_64*) _arch="X86";;
- armv5*) _arch="Armv5te";;
- armv6*) _arch="Armv6";;
- armv7*) _arch="Armv7";;
- aarch64*) _arch="AArch64";;
- mips*) _arch="Mips";;
- ppc*) _arch="PowerPC";;
- riscv64*) _arch="RISCV64";;
- esac
-
- triplet=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}
-
- configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
- configure_args+=" -DLLVM_HOST_TRIPLE=${triplet}"
- configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${triplet}"
-}
-
-do_install() {
- cd build
- cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
-
- # Required for multilib.
- if [ "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
- for _header in llvm-config; do
- mv ${DESTDIR}/usr/include/llvm/Config/${_header}{,-64}.h
- vinstall ${FILESDIR}/llvm-Config-${_header}.h 644 \
- usr/include/llvm/Config ${_header}.h
- done
- fi
-
- # Remove llvm-config-host in cross builds.
- if [ "$CROSS_BUILD" ]; then
- rm -f ${DESTDIR}/usr/bin/llvm-config-host
- fi
-}
-
-libllvm12_package() {
- short_desc+=" - runtime library"
- pkg_install() {
- vmove "usr/lib/libLLVM-*.so*"
- }
-}
diff --git a/srcpkgs/llvm12/update b/srcpkgs/llvm12/update
deleted file mode 100644
index e95cf26b3586b7..00000000000000
--- a/srcpkgs/llvm12/update
+++ /dev/null
@@ -1,3 +0,0 @@
-site="https://github.com/llvm/llvm-project/releases"
-pattern="llvmorg-\K(\d+.){2}\d+(-rc\d+)?"
-ignore="*-rc*"
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index e729b51bfc267d..e2bf28e8cb2db3 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
# Template file for 'removed-packages'
pkgname=removed-packages
-version=0.1.20240727
+version=0.1.20240729
revision=1
build_style=meta
short_desc="Uninstalls packages removed from repository"
@@ -376,6 +376,7 @@ replaces="
libgroff<=1.22.4_3
libgtkhtml<=4.10.0_1
libkscreen<=5.27.11_3
+ libllvm12<=12.0.1_4
libllvm10<=10.0.0_8
libllvm11<=11.0.0_2
libllvm15<=15.0.7_4
@@ -440,6 +441,7 @@ replaces="
lldb-devel<=15.0.7_3
lldb15-devel<=15.0.7_4
lldb15<=15.0.7_4
+ llvm12<=12.0.1_4
llvm10<=10.0.0_8
llvm11<=11.0.0_2
llvm15<=15.0.7_4
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR REVIEW] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (9 preceding siblings ...)
2024-07-30 20:39 ` Calandracas606
@ 2024-07-30 20:42 ` Calandracas606
2024-07-31 17:43 ` [PR PATCH] [Updated] " Calandracas606
` (3 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-30 20:42 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 196 bytes --]
New review comment by Calandracas606 on void-packages repository
https://github.com/void-linux/void-packages/pull/51186#discussion_r1697560212
Comment:
leftover bits from a failed rebase. fixed
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (10 preceding siblings ...)
2024-07-30 20:42 ` [PR REVIEW] " Calandracas606
@ 2024-07-31 17:43 ` Calandracas606
2024-07-31 17:44 ` Calandracas606
` (2 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-31 17:43 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1422 bytes --]
There is an updated pull request by Calandracas606 against master on the void-packages repository
https://github.com/Calandracas606/void-packages remove-llvm12
https://github.com/void-linux/void-packages/pull/51186
remove llvm12
- **mozjs102: build with llvm18**
- **ghdl: update to 4.1.0.**
- **llvm12: remove package**
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, x86_64
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64-musl
- i686
- aarch64 (cross)
- aarch64-musl (cross)
- armv7l (cross)
- armv7l-musl (cross)
- armv6l (cross)
- armv6l-musl (cross)
A patch file from https://github.com/void-linux/void-packages/pull/51186.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-remove-llvm12-51186.patch --]
[-- Type: text/x-diff, Size: 49669 bytes --]
From 148b5458b86fa22f4ccdc44ce3e1bd1595405f6d Mon Sep 17 00:00:00 2001
From: Daniel Martinez <danielmartinez@cock.li>
Date: Tue, 9 Jul 2024 22:18:51 -0400
Subject: [PATCH] llvm12: remove package
---
srcpkgs/libllvm12 | 1 -
.../llvm12/files/llvm-Config-llvm-config.h | 9 -
...clang-001-fix-unwind-chain-inclusion.patch | 44 -----
.../patches/clang-002-add-musl-triples.patch | 110 ------------
.../clang-003-ppc64-dynamic-linker-path.patch | 13 --
.../patches/clang-004-ppc64-musl-elfv2.patch | 48 ------
.../compiler-rt-aarch64-ucontext.patch | 11 --
.../compiler-rt-sanitizer-glibc-2.36.patch | 59 -------
.../compiler-rt-sanitizer-ppc64-musl.patch | 35 ----
.../llvm12/patches/compiler-rt-size_t.patch | 10 --
.../patches/compiler-rt-xray-ppc64-musl.patch | 62 -------
srcpkgs/llvm12/patches/libcxx-musl.patch | 26 ---
srcpkgs/llvm12/patches/libcxx-ppc.patch | 22 ---
.../llvm12/patches/libcxx-ssp-nonshared.patch | 11 --
srcpkgs/llvm12/patches/libcxxabi-dl.patch | 25 ---
srcpkgs/llvm12/patches/libunwind-ppc32.patch | 63 -------
srcpkgs/llvm12/patches/lldb-musl.patch | 31 ----
srcpkgs/llvm12/patches/llvm-001-musl.patch | 57 -------
.../patches/llvm-002-musl-ppc64-elfv2.patch | 30 ----
.../patches/llvm-003-ppc-secureplt.patch | 11 --
.../patches/llvm-004-override-opt.patch | 18 --
.../llvm12/patches/llvm-005-ppc-bigpic.patch | 36 ----
.../patches/llvm-006-aarch64-mf_exec.patch | 25 ---
srcpkgs/llvm12/patches/llvm-gcc13.patch | 28 ---
.../llvm12/patches/ppc32-compiler-rt.patch | 21 ---
srcpkgs/llvm12/template | 161 ------------------
srcpkgs/llvm12/update | 3 -
srcpkgs/removed-packages/template | 4 +-
28 files changed, 3 insertions(+), 971 deletions(-)
delete mode 120000 srcpkgs/libllvm12
delete mode 100644 srcpkgs/llvm12/files/llvm-Config-llvm-config.h
delete mode 100644 srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-size_t.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ppc.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxxabi-dl.patch
delete mode 100644 srcpkgs/llvm12/patches/libunwind-ppc32.patch
delete mode 100644 srcpkgs/llvm12/patches/lldb-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-001-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-004-override-opt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-gcc13.patch
delete mode 100644 srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
delete mode 100644 srcpkgs/llvm12/template
delete mode 100644 srcpkgs/llvm12/update
diff --git a/srcpkgs/libllvm12 b/srcpkgs/libllvm12
deleted file mode 120000
index cd60fd7a981bdd..00000000000000
--- a/srcpkgs/libllvm12
+++ /dev/null
@@ -1 +0,0 @@
-llvm12
\ No newline at end of file
diff --git a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h b/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
deleted file mode 100644
index 2fa08c9be69621..00000000000000
--- a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
+++ /dev/null
@@ -1,9 +0,0 @@
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 32
-#include "llvm-config-32.h"
-#elif __WORDSIZE == 64
-#include "llvm-config-64.h"
-#else
-#error "Unknown word size"
-#endif
diff --git a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
deleted file mode 100644
index e4eaa7783e7a6c..00000000000000
--- a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 352974169f0d2b5da3d5321f588f5e3b5941330e Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:14:57 +0200
-Subject: [PATCH 2/7] fix unwind chain inclusion
-
----
- lib/Headers/unwind.h | 9 +++++----
- 1 file changed, 5 insertions(+), 4 deletions(-)
-
-diff --git a/lib/Headers/unwind.h b/lib/Headers/unwind.h
-index 303d792..44e10cc 100644
---- a/clang/lib/Headers/unwind.h
-+++ b/clang/lib/Headers/unwind.h
-@@ -9,9 +9,6 @@
-
- /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/
-
--#ifndef __CLANG_UNWIND_H
--#define __CLANG_UNWIND_H
--
- #if defined(__APPLE__) && __has_include_next(<unwind.h>)
- /* Darwin (from 11.x on) provide an unwind.h. If that's available,
- * use it. libunwind wraps some of its definitions in #ifdef _GNU_SOURCE,
-@@ -39,6 +36,9 @@
- # endif
- #else
-
-+#ifndef __CLANG_UNWIND_H
-+#define __CLANG_UNWIND_H
-+
- #include <stdint.h>
-
- #ifdef __cplusplus
-@@ -322,6 +322,7 @@ _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *);
- }
- #endif
-
-+#endif /* __CLANG_UNWIND_H */
-+
- #endif
-
--#endif /* __CLANG_UNWIND_H */
---
-2.5.1
diff --git a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch b/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
deleted file mode 100644
index 25688d40dbc275..00000000000000
--- a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
+++ /dev/null
@@ -1,110 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Gnu.cpp
-+++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2086,7 +2086,8 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
- "armv7hl-redhat-linux-gnueabi",
- "armv6hl-suse-linux-gnueabi",
-- "armv7hl-suse-linux-gnueabi"};
-+ "armv7hl-suse-linux-gnueabi",
-+ "armv7l-linux-gnueabihf"};
- static const char *const ARMebLibDirs[] = {"/lib"};
- static const char *const ARMebTriples[] = {"armeb-linux-gnueabi",
- "armeb-linux-androideabi"};
-@@ -2153,8 +2154,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- "powerpc64-suse-linux", "powerpc-montavista-linuxspe"};
- static const char *const PPCLELibDirs[] = {"/lib32", "/lib"};
- static const char *const PPCLETriples[] = {"powerpcle-linux-gnu",
-- "powerpcle-unknown-linux-gnu",
-- "powerpcle-linux-musl"};
-+ "powerpcle-unknown-linux-gnu"};
-
- static const char *const PPC64LibDirs[] = {"/lib64", "/lib"};
- static const char *const PPC64Triples[] = {
-@@ -2235,6 +2235,87 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- return;
- }
-
-+ if (TargetTriple.isMusl()) {
-+ static const char *const AArch64MuslTriples[] = {"aarch64-linux-musl"};
-+ static const char *const ARMHFMuslTriples[] = {
-+ "arm-linux-musleabihf", "armv7l-linux-musleabihf"
-+ };
-+ static const char *const ARMMuslTriples[] = {"arm-linux-musleabi"};
-+ static const char *const X86_64MuslTriples[] = {"x86_64-linux-musl"};
-+ static const char *const X86MuslTriples[] = {"i686-linux-musl"};
-+ static const char *const MIPSMuslTriples[] = {
-+ "mips-linux-musl", "mipsel-linux-musl",
-+ "mipsel-linux-muslhf", "mips-linux-muslhf"
-+ };
-+ static const char *const PPCMuslTriples[] = {"powerpc-linux-musl"};
-+ static const char *const PPCLEMuslTriples[] = {"powerpcle-linux-musl"};
-+ static const char *const PPC64MuslTriples[] = {"powerpc64-linux-musl"};
-+ static const char *const PPC64LEMuslTriples[] = {"powerpc64le-linux-musl"};
-+
-+ switch (TargetTriple.getArch()) {
-+ case llvm::Triple::aarch64:
-+ LibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ TripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ BiarchLibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ BiarchTripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ break;
-+ case llvm::Triple::arm:
-+ LibDirs.append(begin(ARMLibDirs), end(ARMLibDirs));
-+ if (TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
-+ TripleAliases.append(begin(ARMHFMuslTriples), end(ARMHFMuslTriples));
-+ } else {
-+ TripleAliases.append(begin(ARMMuslTriples), end(ARMMuslTriples));
-+ }
-+ break;
-+ case llvm::Triple::x86_64:
-+ LibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ TripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ BiarchLibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ BiarchTripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ break;
-+ case llvm::Triple::x86:
-+ LibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ TripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ BiarchLibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ BiarchTripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ break;
-+ case llvm::Triple::mips:
-+ LibDirs.append(begin(MIPSLibDirs), end(MIPSLibDirs));
-+ TripleAliases.append(begin(MIPSMuslTriples), end(MIPSMuslTriples));
-+ break;
-+ case llvm::Triple::ppc:
-+ LibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ TripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ BiarchTripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ break;
-+ case llvm::Triple::ppcle:
-+ LibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ TripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ BiarchTripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64:
-+ LibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ TripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ BiarchLibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ BiarchTripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64le:
-+ LibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ TripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ BiarchLibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ BiarchTripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ break;
-+ default:
-+ break;
-+ }
-+ TripleAliases.push_back(TargetTriple.str());
-+ if (TargetTriple.str() != BiarchTriple.str())
-+ BiarchTripleAliases.push_back(BiarchTriple.str());
-+ return;
-+ }
-+
- // Android targets should not use GNU/Linux tools or libraries.
- if (TargetTriple.isAndroid()) {
- static const char *const AArch64AndroidTriples[] = {
diff --git a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
deleted file mode 100644
index 4ad6412d1e6c63..00000000000000
--- a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Linux.cpp
-+++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -504,10 +504,6 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
- Loader = "ld.so.1";
- break;
- case llvm::Triple::ppc64:
-- LibDir = "lib64";
-- Loader =
-- (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
-- break;
- case llvm::Triple::ppc64le:
- LibDir = "lib64";
- Loader =
diff --git a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
deleted file mode 100644
index 21fc8003c5f1a8..00000000000000
--- a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
+++ /dev/null
@@ -1,48 +0,0 @@
---- a/clang/lib/Basic/Targets/PPC.h
-+++ b/clang/lib/Basic/Targets/PPC.h
-@@ -415,11 +415,10 @@ public:
- LongDoubleFormat = &llvm::APFloat::IEEEdouble();
- } else if ((Triple.getArch() == llvm::Triple::ppc64le)) {
- DataLayout = "e-m:e-i64:64-n32:64";
-- ABI = "elfv2";
- } else {
- DataLayout = "E-m:e-i64:64-n32:64";
-- ABI = "elfv1";
- }
-+ ABI = "elfv2";
-
- if (Triple.isOSFreeBSD() || Triple.isOSOpenBSD() || Triple.isMusl()) {
- LongDoubleWidth = LongDoubleAlign = 64;
---- a/clang/lib/CodeGen/TargetInfo.cpp
-+++ b/clang/lib/CodeGen/TargetInfo.cpp
-@@ -10927,9 +10927,9 @@ const TargetCodeGenInfo &CodeGenModule::getTargetCodeGenInfo() {
- return SetCGInfo(new AIXTargetCodeGenInfo(Types, /*Is64Bit*/ true));
-
- if (Triple.isOSBinFormatELF()) {
-- PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv1;
-- if (getTarget().getABI() == "elfv2")
-- Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ if (getTarget().getABI() == "elfv1")
-+ Kind = PPC64_SVR4_ABIInfo::ELFv1;
- bool IsSoftFloat = CodeGenOpts.FloatABI == "soft";
-
- return SetCGInfo(
---- a/clang/lib/Driver/ToolChains/Clang.cpp
-+++ b/clang/lib/Driver/ToolChains/Clang.cpp
-@@ -1920,14 +1920,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
- const llvm::Triple &T = getToolChain().getTriple();
- if (T.isOSBinFormatELF()) {
- switch (getToolChain().getArch()) {
-- case llvm::Triple::ppc64: {
-- if ((T.isOSFreeBSD() && T.getOSMajorVersion() >= 13) ||
-- T.isOSOpenBSD() || T.isMusl())
-- ABIName = "elfv2";
-- else
-- ABIName = "elfv1";
-- break;
-- }
-+ case llvm::Triple::ppc64:
- case llvm::Triple::ppc64le:
- ABIName = "elfv2";
- break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch b/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
deleted file mode 100644
index 893c059d7b8def..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp.orig
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -1799,7 +1799,7 @@
-
- static bool Aarch64GetESR(ucontext_t *ucontext, u64 *esr) {
- static const u32 kEsrMagic = 0x45535201;
-- u8 *aux = ucontext->uc_mcontext.__reserved;
-+ u8 *aux = reinterpret_cast<u8 *>(ucontext->uc_mcontext.__reserved);
- while (true) {
- _aarch64_ctx *ctx = (_aarch64_ctx *)aux;
- if (ctx->size == 0) break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
deleted file mode 100644
index e5f24dab893547..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From 9cf13067cb5088626ba7ee1ec4c42ec59c7995a0 Mon Sep 17 00:00:00 2001
-From: Fangrui Song <i@maskray.me>
-Date: Mon, 11 Jul 2022 12:53:34 -0700
-Subject: [PATCH] [sanitizer] Remove #include <linux/fs.h> to resolve
- fsconfig_command/mount_attr conflict with glibc 2.36
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-It is generally not a good idea to mix usage of glibc headers and Linux UAPI
-headers (https://sourceware.org/glibc/wiki/Synchronizing_Headers). In glibc
-since 7eae6a91e9b1670330c9f15730082c91c0b1d570 (milestone: 2.36), sys/mount.h
-defines `fsconfig_command` which conflicts with linux/mount.h:
-
- .../usr/include/linux/mount.h:95:6: error: redeclaration of ‘enum fsconfig_command’
-
-Remove #include <linux/fs.h> which pulls in linux/mount.h. Expand its 4 macros manually.
-Android sys/mount.h doesn't define BLKBSZGET and it still needs linux/fs.h.
-In the long term we should move Linux specific definitions to sanitizer_platform_limits_linux.cpp
-but this commit is easy to cherry pick into older compiler-rt releases.
-
-Fix https://github.com/llvm/llvm-project/issues/56421
-
-Reviewed By: #sanitizers, vitalybuka, zatrazz
-
-Differential Revision: https://reviews.llvm.org/D129471
----
- .../sanitizer_platform_limits_posix.cpp | 10 ++++++----
- 1 file changed, 6 insertions(+), 4 deletions(-)
-
-diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-index 4bd425435d56d..3a94b260686f1 100644
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -73,7 +73,9 @@
- #include <sys/vt.h>
- #include <linux/cdrom.h>
- #include <linux/fd.h>
-+#if SANITIZER_ANDROID
- #include <linux/fs.h>
-+#endif
- #include <linux/hdreg.h>
- #include <linux/input.h>
- #include <linux/ioctl.h>
-@@ -876,10 +878,10 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr);
- unsigned IOCTL_EVIOCGPROP = IOCTL_NOT_PRESENT;
- unsigned IOCTL_EVIOCSKEYCODE_V2 = IOCTL_NOT_PRESENT;
- #endif
-- unsigned IOCTL_FS_IOC_GETFLAGS = FS_IOC_GETFLAGS;
-- unsigned IOCTL_FS_IOC_GETVERSION = FS_IOC_GETVERSION;
-- unsigned IOCTL_FS_IOC_SETFLAGS = FS_IOC_SETFLAGS;
-- unsigned IOCTL_FS_IOC_SETVERSION = FS_IOC_SETVERSION;
-+ unsigned IOCTL_FS_IOC_GETFLAGS = _IOR('f', 1, long);
-+ unsigned IOCTL_FS_IOC_GETVERSION = _IOR('v', 1, long);
-+ unsigned IOCTL_FS_IOC_SETFLAGS = _IOW('f', 2, long);
-+ unsigned IOCTL_FS_IOC_SETVERSION = _IOW('v', 2, long);
- unsigned IOCTL_GIO_CMAP = GIO_CMAP;
- unsigned IOCTL_GIO_FONT = GIO_FONT;
- unsigned IOCTL_GIO_UNIMAP = GIO_UNIMAP;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
deleted file mode 100644
index 35f16d24f340c6..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
+++ /dev/null
@@ -1,35 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -74,6 +74,10 @@
- #include <sys/utsname.h>
- #endif
-
-+#if SANITIZER_LINUX && defined(__powerpc__)
-+#include <asm/ptrace.h>
-+#endif
-+
- #if SANITIZER_LINUX && !SANITIZER_ANDROID
- #include <sys/personality.h>
- #endif
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -92,7 +92,7 @@
- # include <utime.h>
- # include <sys/ptrace.h>
- #if defined(__mips64) || defined(__aarch64__) || defined(__arm__) || \
-- SANITIZER_RISCV64
-+ defined(__powerpc__) || SANITIZER_RISCV64
- # include <asm/ptrace.h>
- # ifdef __arm__
- typedef struct user_fpregs elf_fpregset_t;
---- a/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-@@ -31,7 +31,7 @@
- #include <sys/types.h> // for pid_t
- #include <sys/uio.h> // for iovec
- #include <elf.h> // for NT_PRSTATUS
--#if (defined(__aarch64__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
-+#if (defined(__aarch64__) || defined(__powerpc__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
- // GLIBC 2.20+ sys/user does not include asm/ptrace.h
- # include <asm/ptrace.h>
- #endif
diff --git a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch b/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
deleted file mode 100644
index 2c63063a5e9e3f..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp.orig
-+++ b/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp
-@@ -25,6 +25,7 @@
- }
-
- #include <cassert>
-+#include <cstddef>
- #include <cstdint>
- #include <dlfcn.h> // for dlsym()
-
diff --git a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
deleted file mode 100644
index d0b61c80c897f4..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
+++ /dev/null
@@ -1,62 +0,0 @@
---- a/compiler-rt/lib/xray/xray_powerpc64.inc
-+++ b/compiler-rt/lib/xray/xray_powerpc64.inc
-@@ -12,7 +12,13 @@
-
- #include <cstdint>
- #include <mutex>
-+#ifdef __GLIBC__
- #include <sys/platform/ppc.h>
-+#else
-+#include <cctype>
-+#include <cstring>
-+#include <cstdlib>
-+#endif
-
- #include "xray_defs.h"
-
-@@ -20,13 +26,45 @@ namespace __xray {
-
- ALWAYS_INLINE uint64_t readTSC(uint8_t &CPU) XRAY_NEVER_INSTRUMENT {
- CPU = 0;
-+#ifdef __GLIBC__
- return __ppc_get_timebase();
-+#else
-+ return __builtin_ppc_get_timebase();
-+#endif
- }
-
- inline uint64_t getTSCFrequency() XRAY_NEVER_INSTRUMENT {
- static std::mutex M;
- std::lock_guard<std::mutex> Guard(M);
-+#ifdef __GLIBC__
- return __ppc_get_timebase_freq();
-+#else
-+ /* FIXME: a less dirty implementation? */
-+ static uint64_t base;
-+ if (!base) {
-+ FILE *f = fopen("/proc/cpuinfo", "rb");
-+ if (f) {
-+ ssize_t nr;
-+ /* virtually always big enough to hold the line */
-+ char buf[512];
-+ while (fgets(buf, sizeof(buf), f)) {
-+ char *ret = strstr(buf, "timebase");
-+ if (!ret) {
-+ continue;
-+ }
-+ ret += sizeof("timebase") - 1;
-+ ret = strchr(ret, ':');
-+ if (!ret) {
-+ continue;
-+ }
-+ base = strtoul(ret + 1, nullptr, 10);
-+ break;
-+ }
-+ fclose(f);
-+ }
-+ }
-+ return base;
-+#endif
- }
-
- inline bool probeRequiredCPUFeatures() XRAY_NEVER_INSTRUMENT {
diff --git a/srcpkgs/llvm12/patches/libcxx-musl.patch b/srcpkgs/llvm12/patches/libcxx-musl.patch
deleted file mode 100644
index bbd31ffc2cb1f4..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-musl.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/libcxx/include/locale
-+++ b/libcxx/include/locale
-@@ -742,7 +742,11 @@ __num_get_signed_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ long long __ll = strtoll(__a, &__p2, __base);
-+#else
- long long __ll = strtoll_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
-@@ -782,7 +786,11 @@ __num_get_unsigned_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ unsigned long long __ll = strtoull(__a, &__p2, __base);
-+#else
- unsigned long long __ll = strtoull_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
diff --git a/srcpkgs/llvm12/patches/libcxx-ppc.patch b/srcpkgs/llvm12/patches/libcxx-ppc.patch
deleted file mode 100644
index 7a92f8004e1cf8..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ppc.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-This ensures `is_iec559` is defined correctly under all long double ABIs,
-including musl and its 64-bit long double. Also, `__ppc__` or `__ppc64__`
-is not defined on gcc.
-
---- a/libcxx/include/limits
-+++ b/libcxx/include/limits
-@@ -426,8 +426,14 @@ protected:
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nansl("");}
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __LDBL_DENORM_MIN__;}
-
--#if (defined(__ppc__) || defined(__ppc64__))
-+#if defined(__powerpc__) || defined(__powerpc64__)
-+#if (__LDBL_MAX_EXP__ > __DBL_MAX_EXP__) || (__LDBL_MANT_DIG__ == __DBL_MANT_DIG__)
-+ /* IEEE 754 quadruple or double precision */
-+ static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
-+#else
-+ /* 128-bit IBM double-double */
- static _LIBCPP_CONSTEXPR const bool is_iec559 = false;
-+#endif
- #else
- static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
- #endif
diff --git a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch b/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
deleted file mode 100644
index 70292beb2fcdbd..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/libcxx/CMakeLists.txt
-+++ b/libcxx/CMakeLists.txt
-@@ -769,6 +769,8 @@ function(cxx_link_system_libraries target)
- target_link_libraries(${target} PRIVATE atomic)
- endif()
-
-+#ssp target_link_libraries(${target} PRIVATE ssp_nonshared)
-+
- if (MINGW)
- target_link_libraries(${target} PRIVATE "${MINGW_LIBRARIES}")
- endif()
diff --git a/srcpkgs/llvm12/patches/libcxxabi-dl.patch b/srcpkgs/llvm12/patches/libcxxabi-dl.patch
deleted file mode 100644
index 3a15f9db8c981e..00000000000000
--- a/srcpkgs/llvm12/patches/libcxxabi-dl.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-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()
diff --git a/srcpkgs/llvm12/patches/libunwind-ppc32.patch b/srcpkgs/llvm12/patches/libunwind-ppc32.patch
deleted file mode 100644
index 74aa7576ecf9df..00000000000000
--- a/srcpkgs/llvm12/patches/libunwind-ppc32.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-This fixes build at least with gcc9 which does not define `__ppc__`.
-
---- a/libunwind/include/__libunwind_config.h
-+++ b/libunwind/include/__libunwind_config.h
-@@ -49,7 +49,7 @@
- # define _LIBUNWIND_CONTEXT_SIZE 167
- # define _LIBUNWIND_CURSOR_SIZE 179
- # define _LIBUNWIND_HIGHEST_DWARF_REGISTER _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC64
--# elif defined(__ppc__)
-+# elif defined(__powerpc__)
- # define _LIBUNWIND_TARGET_PPC 1
- # define _LIBUNWIND_CONTEXT_SIZE 117
- # define _LIBUNWIND_CURSOR_SIZE 124
---- a/libunwind/src/UnwindRegistersRestore.S
-+++ b/libunwind/src/UnwindRegistersRestore.S
-@@ -392,7 +392,7 @@ Lnovec:
- PPC64_LR(3)
- bctr
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- DEFINE_LIBUNWIND_FUNCTION(_ZN9libunwind13Registers_ppc6jumptoEv)
- //
---- a/libunwind/src/UnwindRegistersSave.S
-+++ b/libunwind/src/UnwindRegistersSave.S
-@@ -554,7 +554,7 @@ DEFINE_LIBUNWIND_FUNCTION(__unw_getcontext)
- blr
-
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- //
- // extern int unw_getcontext(unw_context_t* thread_state)
---- a/libunwind/src/config.h
-+++ b/libunwind/src/config.h
-@@ -95,12 +95,12 @@
- #define _LIBUNWIND_BUILD_SJLJ_APIS
- #endif
-
--#if defined(__i386__) || defined(__x86_64__) || defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__)
-+#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc__) || defined(__powerpc64__)
- #define _LIBUNWIND_SUPPORT_FRAME_APIS
- #endif
-
- #if defined(__i386__) || defined(__x86_64__) || \
-- defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__) || \
-+ defined(__powerpc__) || defined(__powerpc64__) || \
- (!defined(__APPLE__) && defined(__arm__)) || \
- (defined(__arm64__) || defined(__aarch64__)) || \
- defined(__mips__)
---- a/libunwind/src/libunwind.cpp
-+++ b/libunwind/src/libunwind.cpp
-@@ -42,7 +42,7 @@ _LIBUNWIND_HIDDEN int __unw_init_local(unw_cursor_t *cursor,
- # define REGISTER_KIND Registers_x86_64
- #elif defined(__powerpc64__)
- # define REGISTER_KIND Registers_ppc64
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
- # define REGISTER_KIND Registers_ppc
- #elif defined(__aarch64__)
- # define REGISTER_KIND Registers_arm64
diff --git a/srcpkgs/llvm12/patches/lldb-musl.patch b/srcpkgs/llvm12/patches/lldb-musl.patch
deleted file mode 100644
index 601c0d138523e8..00000000000000
--- a/srcpkgs/llvm12/patches/lldb-musl.patch
+++ /dev/null
@@ -1,31 +0,0 @@
---- a/lldb/source/Plugins/Process/Linux/Procfs.h
-+++ b/lldb/source/Plugins/Process/Linux/Procfs.h
-@@ -10,21 +10,12 @@
- // sys/procfs.h on Android/Linux for all supported architectures.
-
- #include <sys/ptrace.h>
-+#include <asm/ptrace.h>
-
--#ifdef __ANDROID__
--#if defined(__arm64__) || defined(__aarch64__)
--typedef unsigned long elf_greg_t;
--typedef elf_greg_t
-- elf_gregset_t[(sizeof(struct user_pt_regs) / sizeof(elf_greg_t))];
--typedef struct user_fpsimd_state elf_fpregset_t;
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#elif defined(__mips__)
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#endif
--#else // __ANDROID__
-+#if !defined(__GLIBC__) && defined(__powerpc__)
-+#define pt_regs musl_pt_regs
-+#include <sys/procfs.h>
-+#undef pt_regs
-+#else
- #include <sys/procfs.h>
--#endif // __ANDROID__
-+#endif
diff --git a/srcpkgs/llvm12/patches/llvm-001-musl.patch b/srcpkgs/llvm12/patches/llvm-001-musl.patch
deleted file mode 100644
index f2a3f8d62813e3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-001-musl.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From faca3fbd15d0c3108493c3c54cd93138e049ac43 Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:03:02 +0200
-Subject: [PATCH 3/3] musl
-
----
- include/llvm/Analysis/TargetLibraryInfo.h | 9 +++++++++
- lib/Support/DynamicLibrary.cpp | 2 +-
- lib/Support/Unix/Signals.inc | 6 +++---
- utils/unittest/googletest/src/gtest.cc | 1 +
- 5 files changed, 17 insertions(+), 6 deletions(-)
-
-diff --git a/include/llvm/Analysis/TargetLibraryInfo.h b/include/llvm/Analysis/TargetLibraryInfo.h
-index 34a8a1e3..1214ece5 100644
---- a/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-+++ b/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-@@ -18,6 +18,15 @@
- #include "llvm/IR/PassManager.h"
- #include "llvm/Pass.h"
-
-+#undef fopen64
-+#undef fseeko64
-+#undef fstat64
-+#undef fstatvfs64
-+#undef ftello64
-+#undef lstat64
-+#undef stat64
-+#undef tmpfile64
-+
- namespace llvm {
- template <typename T> class ArrayRef;
- class Triple;
-diff --git a/lib/Support/Unix/DynamicLibrary.inc b/lib/Support/Unix/DynamicLibrary.inc
-index a2a37996..2f86c470 100644
---- a/llvm/lib/Support/Unix/DynamicLibrary.inc
-+++ b/llvm/lib/Support/Unix/DynamicLibrary.inc
-@@ -102,7 +102,7 @@ static void *DoSearch(const char* SymbolName) {
-
- // This macro returns the address of a well-known, explicit symbol
- #define EXPLICIT_SYMBOL(SYM) \
-- if (!strcmp(SymbolName, #SYM)) return &SYM
-+ if (!strcmp(SymbolName, #SYM)) return (void *)&SYM
-
- // Under glibc we have a weird situation. The stderr/out/in symbols are both
- // macros and global variables because of standards requirements. So, we
-diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
-index d882ab2e..f1fb12d0 100644
---- a/llvm/utils/unittest/googletest/src/gtest.cc
-+++ b/llvm/utils/unittest/googletest/src/gtest.cc
-@@ -128,6 +128,7 @@
-
- #if GTEST_CAN_STREAM_RESULTS_
- # include <arpa/inet.h> // NOLINT
-+# include <sys/socket.h> // NOLINT
- # include <netdb.h> // NOLINT
- # include <sys/socket.h> // NOLINT
- # include <sys/types.h> // NOLINT
diff --git a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
deleted file mode 100644
index 0071d964bd371f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-This patches LLVM to use ELFv2 on ppc64 unconditionally unless overridden. We
-need this because unlike most distros we use ELFv2 for both glibc and musl
-on big endian ppc64.
-
-diff --git a/lib/Target/PowerPC/PPCTargetMachine.cpp b/lib/Target/PowerPC/PPCTargetMachine.cpp
-index 0634833e..b7cbc2e7 100644
---- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-@@ -222,9 +222,8 @@ static PPCTargetMachine::PPCABI computeTargetABI(const Triple &TT,
-
- switch (TT.getArch()) {
- case Triple::ppc64le:
-- return PPCTargetMachine::PPC_ABI_ELFv2;
- case Triple::ppc64:
-- return PPCTargetMachine::PPC_ABI_ELFv1;
-+ return PPCTargetMachine::PPC_ABI_ELFv2;
- default:
- return PPCTargetMachine::PPC_ABI_UNKNOWN;
- }
-diff --git a/test/CodeGen/PowerPC/ppc64-elf-abi.ll b/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-index 8b1cf6b5..296a2afa 100644
---- a/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-+++ b/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-@@ -1,4 +1,5 @@
--; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv1
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-musl < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
diff --git a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch b/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
deleted file mode 100644
index b5d15974375d49..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-@@ -165,7 +165,7 @@ void PPCSubtarget::initSubtargetFeatures(StringRef CPU, StringRef FS) {
-
- if ((TargetTriple.isOSFreeBSD() && TargetTriple.getOSMajorVersion() >= 13) ||
- TargetTriple.isOSNetBSD() || TargetTriple.isOSOpenBSD() ||
-- TargetTriple.isMusl())
-+ isTargetLinux())
- SecurePlt = true;
-
- if (HasSPE && IsPPC64)
diff --git a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch b/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
deleted file mode 100644
index 51d0e4b31b32c3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-This allows us to override the optimization level as not all platforms can
-deal with -O3.
-
---- a/llvm/CMakeLists.txt
-+++ b/llvm/CMakeLists.txt
-@@ -918,6 +918,12 @@ if( MINGW AND NOT "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang" )
- llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "-O2")
- endif()
-
-+set(VOID_CXX_OPT_FLAGS "" CACHE STRING "Optimization level to use")
-+
-+if (NOT VOID_CXX_OPT_FLAGS STREQUAL "")
-+ llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "${VOID_CXX_OPT_FLAGS}")
-+endif()
-+
- # Put this before tblgen. Else we have a circular dependence.
- add_subdirectory(lib/Demangle)
- add_subdirectory(lib/Support)
diff --git a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
deleted file mode 100644
index d332687b9d9295..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From f3dbdd49c06bfafc1d6138094cf42889c14d38b6 Mon Sep 17 00:00:00 2001
-From: Samuel Holland <samuel@sholland.org>
-Date: Sun, 3 Nov 2019 10:57:27 -0600
-Subject: [PATCH] [LLVM][PowerPC] Assume BigPIC if no PIC level is specified
-
----
- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp | 2 +-
- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/lib/Target/PowerPC/PPCAsmPrinter.cpp b/lib/Target/PowerPC/PPCAsmPrinter.cpp
-index cce21f32..87ca5f9b 100644
---- a/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-@@ -520,7 +520,7 @@ void PPCAsmPrinter::EmitTlsCall(const MachineInstr *MI,
-
- // Add 32768 offset to the symbol so we follow up the latest GOT/PLT ABI.
- if (Kind == MCSymbolRefExpr::VK_PLT && Subtarget->isSecurePlt() &&
-- M->getPICLevel() == PICLevel::BigPIC)
-+ M->getPICLevel() != PICLevel::SmallPIC)
- TlsRef = MCBinaryExpr::createAdd(
- TlsRef, MCConstantExpr::create(32768, OutContext), OutContext);
- const MachineOperand &MO = MI->getOperand(2);
-diff --git a/lib/Target/PowerPC/PPCMCInstLower.cpp b/lib/Target/PowerPC/PPCMCInstLower.cpp
-index 5cc180d7..a5b02565 100644
---- a/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-@@ -117,7 +117,7 @@ static MCOperand GetSymbolRef(const MachineOperand &MO, const MCSymbol *Symbol,
- const MCExpr *Expr = MCSymbolRefExpr::create(Symbol, RefKind, Ctx);
- // If -msecure-plt -fPIC, add 32768 to symbol.
- if (Subtarget->isSecurePlt() && TM.isPositionIndependent() &&
-- M->getPICLevel() == PICLevel::BigPIC &&
-+ M->getPICLevel() != PICLevel::SmallPIC &&
- MO.getTargetFlags() == PPCII::MO_PLT)
- Expr =
- MCBinaryExpr::createAdd(Expr, MCConstantExpr::create(32768, Ctx), Ctx);
diff --git a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch b/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
deleted file mode 100644
index a00abd2166651f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Fix failures in AllocationTests/MappedMemoryTest.* on aarch64:
-
- Failing Tests (8):
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.AllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.DuplicateNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.EnabledWrite/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.MultipleAllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.SuccessiveNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.UnalignedNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroSizeNear/3
-
-Upstream-Issue: https://bugs.llvm.org/show_bug.cgi?id=14278#c10
-
---- a/llvm/lib/Support/Unix/Memory.inc
-+++ b/llvm/lib/Support/Unix/Memory.inc
-@@ -58,7 +58,7 @@ static int getPosixProtectionFlags(unsigned Flags) {
- return PROT_READ | PROT_WRITE | PROT_EXEC;
- case llvm::sys::Memory::MF_EXEC:
- #if (defined(__FreeBSD__) || defined(__POWERPC__) || defined (__ppc__) || \
-- defined(_POWER) || defined(_ARCH_PPC))
-+ defined(_POWER) || defined(_ARCH_PPC) || (defined(__linux__) && defined(__aarch64__)))
- // On PowerPC, having an executable page that has no read permission
- // can have unintended consequences. The function InvalidateInstruction-
- // Cache uses instructions dcbf and icbi, both of which are treated by
diff --git a/srcpkgs/llvm12/patches/llvm-gcc13.patch b/srcpkgs/llvm12/patches/llvm-gcc13.patch
deleted file mode 100644
index 6895221b73bb75..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-gcc13.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From ff1681ddb303223973653f7f5f3f3435b48a1983 Mon Sep 17 00:00:00 2001
-From: Sergei Trofimovich <slyich@gmail.com>
-Date: Mon, 23 May 2022 08:03:23 +0100
-Subject: [PATCH] [Support] Add missing <cstdint> header to Signals.h
-
-Without the change llvm build fails on this week's gcc-13 snapshot as:
-
- [ 0%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o
- In file included from llvm/lib/Support/Signals.cpp:14:
- llvm/include/llvm/Support/Signals.h:119:8: error: variable or field 'CleanupOnSignal' declared void
- 119 | void CleanupOnSignal(uintptr_t Context);
- | ^~~~~~~~~~~~~~~
----
- llvm/include/llvm/Support/Signals.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/llvm/include/llvm/Support/Signals.h b/llvm/include/llvm/Support/Signals.h
-index 44f5a750ff5cb0..937e0572d4a725 100644
---- a/llvm/include/llvm/Support/Signals.h
-+++ b/llvm/include/llvm/Support/Signals.h
-@@ -14,6 +14,7 @@
- #ifndef LLVM_SUPPORT_SIGNALS_H
- #define LLVM_SUPPORT_SIGNALS_H
-
-+#include <cstdint>
- #include <string>
-
- namespace llvm {
diff --git a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch b/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
deleted file mode 100644
index 8e0a9a779d1bf8..00000000000000
--- a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-commit ba4ede595ff9599232f5dd2b4384c243137b53fc
-Author: Daniel Kolesa <daniel@octaforge.org>
-Date: Tue Jun 22 23:40:54 2021 +0200
-
- enable compiler-rt support for ppc32
-
-diff --git a/compiler-rt/cmake/base-config-ix.cmake b/compiler-rt/cmake/base-config-ix.cmake
-index 1edab43..5c0c8a2 100644
---- a/compiler-rt/cmake/base-config-ix.cmake
-+++ b/compiler-rt/cmake/base-config-ix.cmake
-@@ -182,9 +182,7 @@ macro(test_targets)
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc64le")
- test_target_arch(powerpc64le "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc")
-- if(CMAKE_SYSTEM_NAME MATCHES "AIX")
-- test_target_arch(powerpc "" "-m32")
-- endif()
-+ test_target_arch(powerpc "" "-m32")
- test_target_arch(powerpc64 "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "s390x")
- test_target_arch(s390x "" "")
diff --git a/srcpkgs/llvm12/template b/srcpkgs/llvm12/template
deleted file mode 100644
index 86e86bb96c63f1..00000000000000
--- a/srcpkgs/llvm12/template
+++ /dev/null
@@ -1,161 +0,0 @@
-# Template file for 'llvm12'
-pkgname=llvm12
-version=12.0.1
-revision=4
-build_wrksrc=llvm
-build_style=cmake
-configure_args="
- -DCMAKE_BUILD_TYPE=Release -Wno-dev
- -DENABLE_LINKER_BUILD_ID=YES
- -DLLDB_USE_SYSTEM_SIX=YES
- -DLIBCXX_CXX_ABI=libcxxabi
- -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=YES
- -DLIBCXXABI_USE_LLVM_UNWINDER=YES
- -DLIBCXXABI_ENABLE_STATIC_UNWINDER=YES
- -DLIBOMP_ENABLE_SHARED=YES
- -DLIBOMP_INSTALL_ALIASES=NO
- -DLLVM_INCLUDE_DOCS=YES
- -DLLVM_BUILD_DOCS=YES
- -DLLVM_ENABLE_SPHINX=YES
- -DSPHINX_WARNINGS_AS_ERRORS=NO
- -DLLVM_INSTALL_UTILS=YES
- -DLLVM_BUILD_LLVM_DYLIB=YES
- -DLLVM_LINK_LLVM_DYLIB=YES
- -DLLVM_ENABLE_RTTI=YES
- -DLLVM_ENABLE_FFI=YES
- -DLLVM_BINUTILS_INCDIR=/usr/include"
-hostmakedepends="perl python3 zlib-devel libffi-devel swig python3-Sphinx
- python3-recommonmark python3-sphinx-automodapi"
-makedepends="python3-devel zlib-devel elfutils-devel libffi-devel libedit-devel
- libxml2-devel binutils-devel"
-depends="libllvm12>=${version}_${revision}"
-short_desc="Low Level Virtual Machine"
-maintainer="Orphaned <orphan@voidlinux.org>"
-license="Apache-2.0"
-homepage="https://www.llvm.org"
-distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-project-${version}.src.tar.xz"
-checksum=129cb25cd13677aad951ce5c2deb0fe4afc1e9d98950f53b51bdcfb5a73afa0e
-lib32disabled=yes
-python_version=3
-
-if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
- configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
- makedepends+=" libexecinfo-devel"
- depends+=" libexecinfo-devel"
-fi
-
-# "operand out of range" assembler failures
-case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*) configure_args+=" -DCLANG_ENABLE_CLANGD=OFF" ;;
-esac
-
-post_patch() {
- # update config.guess for better platform detection
- cp $XBPS_COMMONDIR/environment/configure/automake/config.guess \
- ${wrksrc}/llvm/cmake
-
- # fix linker failures on some archs
- vsed -i 's,check_library_exists(gcc_s .*,set(LIBCXXABI_HAS_GCC_S_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
- vsed -i 's,check_library_exists(gcc .*,set(LIBCXXABI_HAS_GCC_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
-
- # need libssp_nonshared on some musl platforms (because of nodefaultlibs)
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*-musl|i686-musl|mips*-musl)
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libunwind/src/CMakeLists.txt
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libcxxabi/src/CMakeLists.txt
- vsed -i 's,#ssp,,' ${wrksrc}/libcxx/CMakeLists.txt
- ;;
- 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
- ;;
- esac
-}
-
-pre_configure() {
- local triplet
-
- # Vastly reduce size of debugging symbols:
- CFLAGS=${CFLAGS/ -g/ -g1}
- CXXFLAGS=${CXXFLAGS/ -g/ -g1}
-
- # since gcc9, the build likes to blow up for ppc32 apparently because
- # of clang being too large for a 24-bit relative call to the PLT, so
- # optimize for size instead
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- mips*-musl|ppc*) configure_args+=" -DVOID_CXX_OPT_FLAGS=-Os" ;;
- esac
-
- if [ "$CROSS_BUILD" ]; then
- msg_normal "Building host tblgen\n"
- mkdir -p build/HOST
- cd build/HOST
- CC="$BUILD_CC" CXX="$BUILD_CXX" CFLAGS="$BUILD_CFLAGS" \
- CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
- cmake ../.. -DCMAKE_BUILD_TYPE=Release
- make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
- [ "$_lldb_enable" = "yes" ] && make ${makejobs} -C tools/lldb/utils/TableGen
- configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/clang-tblgen"
- cd ../..
- fi
-
- case "$XBPS_TARGET_MACHINE" in
- i686*) _arch="X86";;
- x86_64*) _arch="X86";;
- armv5*) _arch="Armv5te";;
- armv6*) _arch="Armv6";;
- armv7*) _arch="Armv7";;
- aarch64*) _arch="AArch64";;
- mips*) _arch="Mips";;
- ppc*) _arch="PowerPC";;
- riscv64*) _arch="RISCV64";;
- esac
-
- triplet=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}
-
- configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
- configure_args+=" -DLLVM_HOST_TRIPLE=${triplet}"
- configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${triplet}"
-}
-
-do_install() {
- cd build
- cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
-
- # Required for multilib.
- if [ "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
- for _header in llvm-config; do
- mv ${DESTDIR}/usr/include/llvm/Config/${_header}{,-64}.h
- vinstall ${FILESDIR}/llvm-Config-${_header}.h 644 \
- usr/include/llvm/Config ${_header}.h
- done
- fi
-
- # Remove llvm-config-host in cross builds.
- if [ "$CROSS_BUILD" ]; then
- rm -f ${DESTDIR}/usr/bin/llvm-config-host
- fi
-}
-
-libllvm12_package() {
- short_desc+=" - runtime library"
- pkg_install() {
- vmove "usr/lib/libLLVM-*.so*"
- }
-}
diff --git a/srcpkgs/llvm12/update b/srcpkgs/llvm12/update
deleted file mode 100644
index e95cf26b3586b7..00000000000000
--- a/srcpkgs/llvm12/update
+++ /dev/null
@@ -1,3 +0,0 @@
-site="https://github.com/llvm/llvm-project/releases"
-pattern="llvmorg-\K(\d+.){2}\d+(-rc\d+)?"
-ignore="*-rc*"
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index e729b51bfc267d..e2bf28e8cb2db3 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
# Template file for 'removed-packages'
pkgname=removed-packages
-version=0.1.20240727
+version=0.1.20240729
revision=1
build_style=meta
short_desc="Uninstalls packages removed from repository"
@@ -376,6 +376,7 @@ replaces="
libgroff<=1.22.4_3
libgtkhtml<=4.10.0_1
libkscreen<=5.27.11_3
+ libllvm12<=12.0.1_4
libllvm10<=10.0.0_8
libllvm11<=11.0.0_2
libllvm15<=15.0.7_4
@@ -440,6 +441,7 @@ replaces="
lldb-devel<=15.0.7_3
lldb15-devel<=15.0.7_4
lldb15<=15.0.7_4
+ llvm12<=12.0.1_4
llvm10<=10.0.0_8
llvm11<=11.0.0_2
llvm15<=15.0.7_4
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (11 preceding siblings ...)
2024-07-31 17:43 ` [PR PATCH] [Updated] " Calandracas606
@ 2024-07-31 17:44 ` Calandracas606
2024-07-31 17:45 ` Calandracas606
2024-07-31 18:13 ` [PR PATCH] [Merged]: " classabbyamp
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-31 17:44 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1422 bytes --]
There is an updated pull request by Calandracas606 against master on the void-packages repository
https://github.com/Calandracas606/void-packages remove-llvm12
https://github.com/void-linux/void-packages/pull/51186
remove llvm12
- **mozjs102: build with llvm18**
- **ghdl: update to 4.1.0.**
- **llvm12: remove package**
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, x86_64
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64-musl
- i686
- aarch64 (cross)
- aarch64-musl (cross)
- armv7l (cross)
- armv7l-musl (cross)
- armv6l (cross)
- armv6l-musl (cross)
A patch file from https://github.com/void-linux/void-packages/pull/51186.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-remove-llvm12-51186.patch --]
[-- Type: text/x-diff, Size: 50190 bytes --]
From 378b0f2ff09a8f9348304f79b5145100de25874e Mon Sep 17 00:00:00 2001
From: Daniel Martinez <danielmartinez@cock.li>
Date: Tue, 9 Jul 2024 22:18:51 -0400
Subject: [PATCH] llvm12: remove package
---
common/shlibs | 1 -
srcpkgs/libllvm12 | 1 -
.../llvm12/files/llvm-Config-llvm-config.h | 9 -
...clang-001-fix-unwind-chain-inclusion.patch | 44 -----
.../patches/clang-002-add-musl-triples.patch | 110 ------------
.../clang-003-ppc64-dynamic-linker-path.patch | 13 --
.../patches/clang-004-ppc64-musl-elfv2.patch | 48 ------
.../compiler-rt-aarch64-ucontext.patch | 11 --
.../compiler-rt-sanitizer-glibc-2.36.patch | 59 -------
.../compiler-rt-sanitizer-ppc64-musl.patch | 35 ----
.../llvm12/patches/compiler-rt-size_t.patch | 10 --
.../patches/compiler-rt-xray-ppc64-musl.patch | 62 -------
srcpkgs/llvm12/patches/libcxx-musl.patch | 26 ---
srcpkgs/llvm12/patches/libcxx-ppc.patch | 22 ---
.../llvm12/patches/libcxx-ssp-nonshared.patch | 11 --
srcpkgs/llvm12/patches/libcxxabi-dl.patch | 25 ---
srcpkgs/llvm12/patches/libunwind-ppc32.patch | 63 -------
srcpkgs/llvm12/patches/lldb-musl.patch | 31 ----
srcpkgs/llvm12/patches/llvm-001-musl.patch | 57 -------
.../patches/llvm-002-musl-ppc64-elfv2.patch | 30 ----
.../patches/llvm-003-ppc-secureplt.patch | 11 --
.../patches/llvm-004-override-opt.patch | 18 --
.../llvm12/patches/llvm-005-ppc-bigpic.patch | 36 ----
.../patches/llvm-006-aarch64-mf_exec.patch | 25 ---
srcpkgs/llvm12/patches/llvm-gcc13.patch | 28 ---
.../llvm12/patches/ppc32-compiler-rt.patch | 21 ---
srcpkgs/llvm12/template | 161 ------------------
srcpkgs/llvm12/update | 3 -
srcpkgs/removed-packages/template | 4 +-
29 files changed, 3 insertions(+), 972 deletions(-)
delete mode 120000 srcpkgs/libllvm12
delete mode 100644 srcpkgs/llvm12/files/llvm-Config-llvm-config.h
delete mode 100644 srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-size_t.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ppc.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxxabi-dl.patch
delete mode 100644 srcpkgs/llvm12/patches/libunwind-ppc32.patch
delete mode 100644 srcpkgs/llvm12/patches/lldb-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-001-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-004-override-opt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-gcc13.patch
delete mode 100644 srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
delete mode 100644 srcpkgs/llvm12/template
delete mode 100644 srcpkgs/llvm12/update
diff --git a/common/shlibs b/common/shlibs
index 12436fd372718c..55bfacdf97f204 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -993,7 +993,6 @@ libclang.so.17 libclang17-17.0.6_1
libclang-cpp.so.18.1 libclang-cpp18-18.1.8_1
libclang-cpp.so.17 libclang-cpp17-17.0.6_1
libLLVM-11.so libllvm11-11.0.0_1
-libLLVM-12.so libllvm12-12.0.0_1
libLLVM-17.so libllvm17-17.0.6_1
libLLVM.so.18.1 libllvm18-18.1.8_1
libLLVMSPIRVLib.so.18.1 SPIRV-LLVM-Translator-18.1.2_1
diff --git a/srcpkgs/libllvm12 b/srcpkgs/libllvm12
deleted file mode 120000
index cd60fd7a981bdd..00000000000000
--- a/srcpkgs/libllvm12
+++ /dev/null
@@ -1 +0,0 @@
-llvm12
\ No newline at end of file
diff --git a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h b/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
deleted file mode 100644
index 2fa08c9be69621..00000000000000
--- a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
+++ /dev/null
@@ -1,9 +0,0 @@
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 32
-#include "llvm-config-32.h"
-#elif __WORDSIZE == 64
-#include "llvm-config-64.h"
-#else
-#error "Unknown word size"
-#endif
diff --git a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
deleted file mode 100644
index e4eaa7783e7a6c..00000000000000
--- a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 352974169f0d2b5da3d5321f588f5e3b5941330e Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:14:57 +0200
-Subject: [PATCH 2/7] fix unwind chain inclusion
-
----
- lib/Headers/unwind.h | 9 +++++----
- 1 file changed, 5 insertions(+), 4 deletions(-)
-
-diff --git a/lib/Headers/unwind.h b/lib/Headers/unwind.h
-index 303d792..44e10cc 100644
---- a/clang/lib/Headers/unwind.h
-+++ b/clang/lib/Headers/unwind.h
-@@ -9,9 +9,6 @@
-
- /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/
-
--#ifndef __CLANG_UNWIND_H
--#define __CLANG_UNWIND_H
--
- #if defined(__APPLE__) && __has_include_next(<unwind.h>)
- /* Darwin (from 11.x on) provide an unwind.h. If that's available,
- * use it. libunwind wraps some of its definitions in #ifdef _GNU_SOURCE,
-@@ -39,6 +36,9 @@
- # endif
- #else
-
-+#ifndef __CLANG_UNWIND_H
-+#define __CLANG_UNWIND_H
-+
- #include <stdint.h>
-
- #ifdef __cplusplus
-@@ -322,6 +322,7 @@ _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *);
- }
- #endif
-
-+#endif /* __CLANG_UNWIND_H */
-+
- #endif
-
--#endif /* __CLANG_UNWIND_H */
---
-2.5.1
diff --git a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch b/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
deleted file mode 100644
index 25688d40dbc275..00000000000000
--- a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
+++ /dev/null
@@ -1,110 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Gnu.cpp
-+++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2086,7 +2086,8 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
- "armv7hl-redhat-linux-gnueabi",
- "armv6hl-suse-linux-gnueabi",
-- "armv7hl-suse-linux-gnueabi"};
-+ "armv7hl-suse-linux-gnueabi",
-+ "armv7l-linux-gnueabihf"};
- static const char *const ARMebLibDirs[] = {"/lib"};
- static const char *const ARMebTriples[] = {"armeb-linux-gnueabi",
- "armeb-linux-androideabi"};
-@@ -2153,8 +2154,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- "powerpc64-suse-linux", "powerpc-montavista-linuxspe"};
- static const char *const PPCLELibDirs[] = {"/lib32", "/lib"};
- static const char *const PPCLETriples[] = {"powerpcle-linux-gnu",
-- "powerpcle-unknown-linux-gnu",
-- "powerpcle-linux-musl"};
-+ "powerpcle-unknown-linux-gnu"};
-
- static const char *const PPC64LibDirs[] = {"/lib64", "/lib"};
- static const char *const PPC64Triples[] = {
-@@ -2235,6 +2235,87 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- return;
- }
-
-+ if (TargetTriple.isMusl()) {
-+ static const char *const AArch64MuslTriples[] = {"aarch64-linux-musl"};
-+ static const char *const ARMHFMuslTriples[] = {
-+ "arm-linux-musleabihf", "armv7l-linux-musleabihf"
-+ };
-+ static const char *const ARMMuslTriples[] = {"arm-linux-musleabi"};
-+ static const char *const X86_64MuslTriples[] = {"x86_64-linux-musl"};
-+ static const char *const X86MuslTriples[] = {"i686-linux-musl"};
-+ static const char *const MIPSMuslTriples[] = {
-+ "mips-linux-musl", "mipsel-linux-musl",
-+ "mipsel-linux-muslhf", "mips-linux-muslhf"
-+ };
-+ static const char *const PPCMuslTriples[] = {"powerpc-linux-musl"};
-+ static const char *const PPCLEMuslTriples[] = {"powerpcle-linux-musl"};
-+ static const char *const PPC64MuslTriples[] = {"powerpc64-linux-musl"};
-+ static const char *const PPC64LEMuslTriples[] = {"powerpc64le-linux-musl"};
-+
-+ switch (TargetTriple.getArch()) {
-+ case llvm::Triple::aarch64:
-+ LibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ TripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ BiarchLibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ BiarchTripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ break;
-+ case llvm::Triple::arm:
-+ LibDirs.append(begin(ARMLibDirs), end(ARMLibDirs));
-+ if (TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
-+ TripleAliases.append(begin(ARMHFMuslTriples), end(ARMHFMuslTriples));
-+ } else {
-+ TripleAliases.append(begin(ARMMuslTriples), end(ARMMuslTriples));
-+ }
-+ break;
-+ case llvm::Triple::x86_64:
-+ LibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ TripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ BiarchLibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ BiarchTripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ break;
-+ case llvm::Triple::x86:
-+ LibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ TripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ BiarchLibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ BiarchTripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ break;
-+ case llvm::Triple::mips:
-+ LibDirs.append(begin(MIPSLibDirs), end(MIPSLibDirs));
-+ TripleAliases.append(begin(MIPSMuslTriples), end(MIPSMuslTriples));
-+ break;
-+ case llvm::Triple::ppc:
-+ LibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ TripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ BiarchTripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ break;
-+ case llvm::Triple::ppcle:
-+ LibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ TripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ BiarchTripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64:
-+ LibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ TripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ BiarchLibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ BiarchTripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64le:
-+ LibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ TripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ BiarchLibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ BiarchTripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ break;
-+ default:
-+ break;
-+ }
-+ TripleAliases.push_back(TargetTriple.str());
-+ if (TargetTriple.str() != BiarchTriple.str())
-+ BiarchTripleAliases.push_back(BiarchTriple.str());
-+ return;
-+ }
-+
- // Android targets should not use GNU/Linux tools or libraries.
- if (TargetTriple.isAndroid()) {
- static const char *const AArch64AndroidTriples[] = {
diff --git a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
deleted file mode 100644
index 4ad6412d1e6c63..00000000000000
--- a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Linux.cpp
-+++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -504,10 +504,6 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
- Loader = "ld.so.1";
- break;
- case llvm::Triple::ppc64:
-- LibDir = "lib64";
-- Loader =
-- (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
-- break;
- case llvm::Triple::ppc64le:
- LibDir = "lib64";
- Loader =
diff --git a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
deleted file mode 100644
index 21fc8003c5f1a8..00000000000000
--- a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
+++ /dev/null
@@ -1,48 +0,0 @@
---- a/clang/lib/Basic/Targets/PPC.h
-+++ b/clang/lib/Basic/Targets/PPC.h
-@@ -415,11 +415,10 @@ public:
- LongDoubleFormat = &llvm::APFloat::IEEEdouble();
- } else if ((Triple.getArch() == llvm::Triple::ppc64le)) {
- DataLayout = "e-m:e-i64:64-n32:64";
-- ABI = "elfv2";
- } else {
- DataLayout = "E-m:e-i64:64-n32:64";
-- ABI = "elfv1";
- }
-+ ABI = "elfv2";
-
- if (Triple.isOSFreeBSD() || Triple.isOSOpenBSD() || Triple.isMusl()) {
- LongDoubleWidth = LongDoubleAlign = 64;
---- a/clang/lib/CodeGen/TargetInfo.cpp
-+++ b/clang/lib/CodeGen/TargetInfo.cpp
-@@ -10927,9 +10927,9 @@ const TargetCodeGenInfo &CodeGenModule::getTargetCodeGenInfo() {
- return SetCGInfo(new AIXTargetCodeGenInfo(Types, /*Is64Bit*/ true));
-
- if (Triple.isOSBinFormatELF()) {
-- PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv1;
-- if (getTarget().getABI() == "elfv2")
-- Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ if (getTarget().getABI() == "elfv1")
-+ Kind = PPC64_SVR4_ABIInfo::ELFv1;
- bool IsSoftFloat = CodeGenOpts.FloatABI == "soft";
-
- return SetCGInfo(
---- a/clang/lib/Driver/ToolChains/Clang.cpp
-+++ b/clang/lib/Driver/ToolChains/Clang.cpp
-@@ -1920,14 +1920,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
- const llvm::Triple &T = getToolChain().getTriple();
- if (T.isOSBinFormatELF()) {
- switch (getToolChain().getArch()) {
-- case llvm::Triple::ppc64: {
-- if ((T.isOSFreeBSD() && T.getOSMajorVersion() >= 13) ||
-- T.isOSOpenBSD() || T.isMusl())
-- ABIName = "elfv2";
-- else
-- ABIName = "elfv1";
-- break;
-- }
-+ case llvm::Triple::ppc64:
- case llvm::Triple::ppc64le:
- ABIName = "elfv2";
- break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch b/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
deleted file mode 100644
index 893c059d7b8def..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp.orig
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -1799,7 +1799,7 @@
-
- static bool Aarch64GetESR(ucontext_t *ucontext, u64 *esr) {
- static const u32 kEsrMagic = 0x45535201;
-- u8 *aux = ucontext->uc_mcontext.__reserved;
-+ u8 *aux = reinterpret_cast<u8 *>(ucontext->uc_mcontext.__reserved);
- while (true) {
- _aarch64_ctx *ctx = (_aarch64_ctx *)aux;
- if (ctx->size == 0) break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
deleted file mode 100644
index e5f24dab893547..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From 9cf13067cb5088626ba7ee1ec4c42ec59c7995a0 Mon Sep 17 00:00:00 2001
-From: Fangrui Song <i@maskray.me>
-Date: Mon, 11 Jul 2022 12:53:34 -0700
-Subject: [PATCH] [sanitizer] Remove #include <linux/fs.h> to resolve
- fsconfig_command/mount_attr conflict with glibc 2.36
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-It is generally not a good idea to mix usage of glibc headers and Linux UAPI
-headers (https://sourceware.org/glibc/wiki/Synchronizing_Headers). In glibc
-since 7eae6a91e9b1670330c9f15730082c91c0b1d570 (milestone: 2.36), sys/mount.h
-defines `fsconfig_command` which conflicts with linux/mount.h:
-
- .../usr/include/linux/mount.h:95:6: error: redeclaration of ‘enum fsconfig_command’
-
-Remove #include <linux/fs.h> which pulls in linux/mount.h. Expand its 4 macros manually.
-Android sys/mount.h doesn't define BLKBSZGET and it still needs linux/fs.h.
-In the long term we should move Linux specific definitions to sanitizer_platform_limits_linux.cpp
-but this commit is easy to cherry pick into older compiler-rt releases.
-
-Fix https://github.com/llvm/llvm-project/issues/56421
-
-Reviewed By: #sanitizers, vitalybuka, zatrazz
-
-Differential Revision: https://reviews.llvm.org/D129471
----
- .../sanitizer_platform_limits_posix.cpp | 10 ++++++----
- 1 file changed, 6 insertions(+), 4 deletions(-)
-
-diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-index 4bd425435d56d..3a94b260686f1 100644
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -73,7 +73,9 @@
- #include <sys/vt.h>
- #include <linux/cdrom.h>
- #include <linux/fd.h>
-+#if SANITIZER_ANDROID
- #include <linux/fs.h>
-+#endif
- #include <linux/hdreg.h>
- #include <linux/input.h>
- #include <linux/ioctl.h>
-@@ -876,10 +878,10 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr);
- unsigned IOCTL_EVIOCGPROP = IOCTL_NOT_PRESENT;
- unsigned IOCTL_EVIOCSKEYCODE_V2 = IOCTL_NOT_PRESENT;
- #endif
-- unsigned IOCTL_FS_IOC_GETFLAGS = FS_IOC_GETFLAGS;
-- unsigned IOCTL_FS_IOC_GETVERSION = FS_IOC_GETVERSION;
-- unsigned IOCTL_FS_IOC_SETFLAGS = FS_IOC_SETFLAGS;
-- unsigned IOCTL_FS_IOC_SETVERSION = FS_IOC_SETVERSION;
-+ unsigned IOCTL_FS_IOC_GETFLAGS = _IOR('f', 1, long);
-+ unsigned IOCTL_FS_IOC_GETVERSION = _IOR('v', 1, long);
-+ unsigned IOCTL_FS_IOC_SETFLAGS = _IOW('f', 2, long);
-+ unsigned IOCTL_FS_IOC_SETVERSION = _IOW('v', 2, long);
- unsigned IOCTL_GIO_CMAP = GIO_CMAP;
- unsigned IOCTL_GIO_FONT = GIO_FONT;
- unsigned IOCTL_GIO_UNIMAP = GIO_UNIMAP;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
deleted file mode 100644
index 35f16d24f340c6..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
+++ /dev/null
@@ -1,35 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -74,6 +74,10 @@
- #include <sys/utsname.h>
- #endif
-
-+#if SANITIZER_LINUX && defined(__powerpc__)
-+#include <asm/ptrace.h>
-+#endif
-+
- #if SANITIZER_LINUX && !SANITIZER_ANDROID
- #include <sys/personality.h>
- #endif
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -92,7 +92,7 @@
- # include <utime.h>
- # include <sys/ptrace.h>
- #if defined(__mips64) || defined(__aarch64__) || defined(__arm__) || \
-- SANITIZER_RISCV64
-+ defined(__powerpc__) || SANITIZER_RISCV64
- # include <asm/ptrace.h>
- # ifdef __arm__
- typedef struct user_fpregs elf_fpregset_t;
---- a/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-@@ -31,7 +31,7 @@
- #include <sys/types.h> // for pid_t
- #include <sys/uio.h> // for iovec
- #include <elf.h> // for NT_PRSTATUS
--#if (defined(__aarch64__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
-+#if (defined(__aarch64__) || defined(__powerpc__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
- // GLIBC 2.20+ sys/user does not include asm/ptrace.h
- # include <asm/ptrace.h>
- #endif
diff --git a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch b/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
deleted file mode 100644
index 2c63063a5e9e3f..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp.orig
-+++ b/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp
-@@ -25,6 +25,7 @@
- }
-
- #include <cassert>
-+#include <cstddef>
- #include <cstdint>
- #include <dlfcn.h> // for dlsym()
-
diff --git a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
deleted file mode 100644
index d0b61c80c897f4..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
+++ /dev/null
@@ -1,62 +0,0 @@
---- a/compiler-rt/lib/xray/xray_powerpc64.inc
-+++ b/compiler-rt/lib/xray/xray_powerpc64.inc
-@@ -12,7 +12,13 @@
-
- #include <cstdint>
- #include <mutex>
-+#ifdef __GLIBC__
- #include <sys/platform/ppc.h>
-+#else
-+#include <cctype>
-+#include <cstring>
-+#include <cstdlib>
-+#endif
-
- #include "xray_defs.h"
-
-@@ -20,13 +26,45 @@ namespace __xray {
-
- ALWAYS_INLINE uint64_t readTSC(uint8_t &CPU) XRAY_NEVER_INSTRUMENT {
- CPU = 0;
-+#ifdef __GLIBC__
- return __ppc_get_timebase();
-+#else
-+ return __builtin_ppc_get_timebase();
-+#endif
- }
-
- inline uint64_t getTSCFrequency() XRAY_NEVER_INSTRUMENT {
- static std::mutex M;
- std::lock_guard<std::mutex> Guard(M);
-+#ifdef __GLIBC__
- return __ppc_get_timebase_freq();
-+#else
-+ /* FIXME: a less dirty implementation? */
-+ static uint64_t base;
-+ if (!base) {
-+ FILE *f = fopen("/proc/cpuinfo", "rb");
-+ if (f) {
-+ ssize_t nr;
-+ /* virtually always big enough to hold the line */
-+ char buf[512];
-+ while (fgets(buf, sizeof(buf), f)) {
-+ char *ret = strstr(buf, "timebase");
-+ if (!ret) {
-+ continue;
-+ }
-+ ret += sizeof("timebase") - 1;
-+ ret = strchr(ret, ':');
-+ if (!ret) {
-+ continue;
-+ }
-+ base = strtoul(ret + 1, nullptr, 10);
-+ break;
-+ }
-+ fclose(f);
-+ }
-+ }
-+ return base;
-+#endif
- }
-
- inline bool probeRequiredCPUFeatures() XRAY_NEVER_INSTRUMENT {
diff --git a/srcpkgs/llvm12/patches/libcxx-musl.patch b/srcpkgs/llvm12/patches/libcxx-musl.patch
deleted file mode 100644
index bbd31ffc2cb1f4..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-musl.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/libcxx/include/locale
-+++ b/libcxx/include/locale
-@@ -742,7 +742,11 @@ __num_get_signed_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ long long __ll = strtoll(__a, &__p2, __base);
-+#else
- long long __ll = strtoll_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
-@@ -782,7 +786,11 @@ __num_get_unsigned_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ unsigned long long __ll = strtoull(__a, &__p2, __base);
-+#else
- unsigned long long __ll = strtoull_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
diff --git a/srcpkgs/llvm12/patches/libcxx-ppc.patch b/srcpkgs/llvm12/patches/libcxx-ppc.patch
deleted file mode 100644
index 7a92f8004e1cf8..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ppc.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-This ensures `is_iec559` is defined correctly under all long double ABIs,
-including musl and its 64-bit long double. Also, `__ppc__` or `__ppc64__`
-is not defined on gcc.
-
---- a/libcxx/include/limits
-+++ b/libcxx/include/limits
-@@ -426,8 +426,14 @@ protected:
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nansl("");}
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __LDBL_DENORM_MIN__;}
-
--#if (defined(__ppc__) || defined(__ppc64__))
-+#if defined(__powerpc__) || defined(__powerpc64__)
-+#if (__LDBL_MAX_EXP__ > __DBL_MAX_EXP__) || (__LDBL_MANT_DIG__ == __DBL_MANT_DIG__)
-+ /* IEEE 754 quadruple or double precision */
-+ static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
-+#else
-+ /* 128-bit IBM double-double */
- static _LIBCPP_CONSTEXPR const bool is_iec559 = false;
-+#endif
- #else
- static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
- #endif
diff --git a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch b/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
deleted file mode 100644
index 70292beb2fcdbd..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/libcxx/CMakeLists.txt
-+++ b/libcxx/CMakeLists.txt
-@@ -769,6 +769,8 @@ function(cxx_link_system_libraries target)
- target_link_libraries(${target} PRIVATE atomic)
- endif()
-
-+#ssp target_link_libraries(${target} PRIVATE ssp_nonshared)
-+
- if (MINGW)
- target_link_libraries(${target} PRIVATE "${MINGW_LIBRARIES}")
- endif()
diff --git a/srcpkgs/llvm12/patches/libcxxabi-dl.patch b/srcpkgs/llvm12/patches/libcxxabi-dl.patch
deleted file mode 100644
index 3a15f9db8c981e..00000000000000
--- a/srcpkgs/llvm12/patches/libcxxabi-dl.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-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()
diff --git a/srcpkgs/llvm12/patches/libunwind-ppc32.patch b/srcpkgs/llvm12/patches/libunwind-ppc32.patch
deleted file mode 100644
index 74aa7576ecf9df..00000000000000
--- a/srcpkgs/llvm12/patches/libunwind-ppc32.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-This fixes build at least with gcc9 which does not define `__ppc__`.
-
---- a/libunwind/include/__libunwind_config.h
-+++ b/libunwind/include/__libunwind_config.h
-@@ -49,7 +49,7 @@
- # define _LIBUNWIND_CONTEXT_SIZE 167
- # define _LIBUNWIND_CURSOR_SIZE 179
- # define _LIBUNWIND_HIGHEST_DWARF_REGISTER _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC64
--# elif defined(__ppc__)
-+# elif defined(__powerpc__)
- # define _LIBUNWIND_TARGET_PPC 1
- # define _LIBUNWIND_CONTEXT_SIZE 117
- # define _LIBUNWIND_CURSOR_SIZE 124
---- a/libunwind/src/UnwindRegistersRestore.S
-+++ b/libunwind/src/UnwindRegistersRestore.S
-@@ -392,7 +392,7 @@ Lnovec:
- PPC64_LR(3)
- bctr
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- DEFINE_LIBUNWIND_FUNCTION(_ZN9libunwind13Registers_ppc6jumptoEv)
- //
---- a/libunwind/src/UnwindRegistersSave.S
-+++ b/libunwind/src/UnwindRegistersSave.S
-@@ -554,7 +554,7 @@ DEFINE_LIBUNWIND_FUNCTION(__unw_getcontext)
- blr
-
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- //
- // extern int unw_getcontext(unw_context_t* thread_state)
---- a/libunwind/src/config.h
-+++ b/libunwind/src/config.h
-@@ -95,12 +95,12 @@
- #define _LIBUNWIND_BUILD_SJLJ_APIS
- #endif
-
--#if defined(__i386__) || defined(__x86_64__) || defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__)
-+#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc__) || defined(__powerpc64__)
- #define _LIBUNWIND_SUPPORT_FRAME_APIS
- #endif
-
- #if defined(__i386__) || defined(__x86_64__) || \
-- defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__) || \
-+ defined(__powerpc__) || defined(__powerpc64__) || \
- (!defined(__APPLE__) && defined(__arm__)) || \
- (defined(__arm64__) || defined(__aarch64__)) || \
- defined(__mips__)
---- a/libunwind/src/libunwind.cpp
-+++ b/libunwind/src/libunwind.cpp
-@@ -42,7 +42,7 @@ _LIBUNWIND_HIDDEN int __unw_init_local(unw_cursor_t *cursor,
- # define REGISTER_KIND Registers_x86_64
- #elif defined(__powerpc64__)
- # define REGISTER_KIND Registers_ppc64
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
- # define REGISTER_KIND Registers_ppc
- #elif defined(__aarch64__)
- # define REGISTER_KIND Registers_arm64
diff --git a/srcpkgs/llvm12/patches/lldb-musl.patch b/srcpkgs/llvm12/patches/lldb-musl.patch
deleted file mode 100644
index 601c0d138523e8..00000000000000
--- a/srcpkgs/llvm12/patches/lldb-musl.patch
+++ /dev/null
@@ -1,31 +0,0 @@
---- a/lldb/source/Plugins/Process/Linux/Procfs.h
-+++ b/lldb/source/Plugins/Process/Linux/Procfs.h
-@@ -10,21 +10,12 @@
- // sys/procfs.h on Android/Linux for all supported architectures.
-
- #include <sys/ptrace.h>
-+#include <asm/ptrace.h>
-
--#ifdef __ANDROID__
--#if defined(__arm64__) || defined(__aarch64__)
--typedef unsigned long elf_greg_t;
--typedef elf_greg_t
-- elf_gregset_t[(sizeof(struct user_pt_regs) / sizeof(elf_greg_t))];
--typedef struct user_fpsimd_state elf_fpregset_t;
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#elif defined(__mips__)
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#endif
--#else // __ANDROID__
-+#if !defined(__GLIBC__) && defined(__powerpc__)
-+#define pt_regs musl_pt_regs
-+#include <sys/procfs.h>
-+#undef pt_regs
-+#else
- #include <sys/procfs.h>
--#endif // __ANDROID__
-+#endif
diff --git a/srcpkgs/llvm12/patches/llvm-001-musl.patch b/srcpkgs/llvm12/patches/llvm-001-musl.patch
deleted file mode 100644
index f2a3f8d62813e3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-001-musl.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From faca3fbd15d0c3108493c3c54cd93138e049ac43 Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:03:02 +0200
-Subject: [PATCH 3/3] musl
-
----
- include/llvm/Analysis/TargetLibraryInfo.h | 9 +++++++++
- lib/Support/DynamicLibrary.cpp | 2 +-
- lib/Support/Unix/Signals.inc | 6 +++---
- utils/unittest/googletest/src/gtest.cc | 1 +
- 5 files changed, 17 insertions(+), 6 deletions(-)
-
-diff --git a/include/llvm/Analysis/TargetLibraryInfo.h b/include/llvm/Analysis/TargetLibraryInfo.h
-index 34a8a1e3..1214ece5 100644
---- a/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-+++ b/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-@@ -18,6 +18,15 @@
- #include "llvm/IR/PassManager.h"
- #include "llvm/Pass.h"
-
-+#undef fopen64
-+#undef fseeko64
-+#undef fstat64
-+#undef fstatvfs64
-+#undef ftello64
-+#undef lstat64
-+#undef stat64
-+#undef tmpfile64
-+
- namespace llvm {
- template <typename T> class ArrayRef;
- class Triple;
-diff --git a/lib/Support/Unix/DynamicLibrary.inc b/lib/Support/Unix/DynamicLibrary.inc
-index a2a37996..2f86c470 100644
---- a/llvm/lib/Support/Unix/DynamicLibrary.inc
-+++ b/llvm/lib/Support/Unix/DynamicLibrary.inc
-@@ -102,7 +102,7 @@ static void *DoSearch(const char* SymbolName) {
-
- // This macro returns the address of a well-known, explicit symbol
- #define EXPLICIT_SYMBOL(SYM) \
-- if (!strcmp(SymbolName, #SYM)) return &SYM
-+ if (!strcmp(SymbolName, #SYM)) return (void *)&SYM
-
- // Under glibc we have a weird situation. The stderr/out/in symbols are both
- // macros and global variables because of standards requirements. So, we
-diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
-index d882ab2e..f1fb12d0 100644
---- a/llvm/utils/unittest/googletest/src/gtest.cc
-+++ b/llvm/utils/unittest/googletest/src/gtest.cc
-@@ -128,6 +128,7 @@
-
- #if GTEST_CAN_STREAM_RESULTS_
- # include <arpa/inet.h> // NOLINT
-+# include <sys/socket.h> // NOLINT
- # include <netdb.h> // NOLINT
- # include <sys/socket.h> // NOLINT
- # include <sys/types.h> // NOLINT
diff --git a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
deleted file mode 100644
index 0071d964bd371f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-This patches LLVM to use ELFv2 on ppc64 unconditionally unless overridden. We
-need this because unlike most distros we use ELFv2 for both glibc and musl
-on big endian ppc64.
-
-diff --git a/lib/Target/PowerPC/PPCTargetMachine.cpp b/lib/Target/PowerPC/PPCTargetMachine.cpp
-index 0634833e..b7cbc2e7 100644
---- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-@@ -222,9 +222,8 @@ static PPCTargetMachine::PPCABI computeTargetABI(const Triple &TT,
-
- switch (TT.getArch()) {
- case Triple::ppc64le:
-- return PPCTargetMachine::PPC_ABI_ELFv2;
- case Triple::ppc64:
-- return PPCTargetMachine::PPC_ABI_ELFv1;
-+ return PPCTargetMachine::PPC_ABI_ELFv2;
- default:
- return PPCTargetMachine::PPC_ABI_UNKNOWN;
- }
-diff --git a/test/CodeGen/PowerPC/ppc64-elf-abi.ll b/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-index 8b1cf6b5..296a2afa 100644
---- a/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-+++ b/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-@@ -1,4 +1,5 @@
--; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv1
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-musl < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
diff --git a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch b/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
deleted file mode 100644
index b5d15974375d49..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-@@ -165,7 +165,7 @@ void PPCSubtarget::initSubtargetFeatures(StringRef CPU, StringRef FS) {
-
- if ((TargetTriple.isOSFreeBSD() && TargetTriple.getOSMajorVersion() >= 13) ||
- TargetTriple.isOSNetBSD() || TargetTriple.isOSOpenBSD() ||
-- TargetTriple.isMusl())
-+ isTargetLinux())
- SecurePlt = true;
-
- if (HasSPE && IsPPC64)
diff --git a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch b/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
deleted file mode 100644
index 51d0e4b31b32c3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-This allows us to override the optimization level as not all platforms can
-deal with -O3.
-
---- a/llvm/CMakeLists.txt
-+++ b/llvm/CMakeLists.txt
-@@ -918,6 +918,12 @@ if( MINGW AND NOT "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang" )
- llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "-O2")
- endif()
-
-+set(VOID_CXX_OPT_FLAGS "" CACHE STRING "Optimization level to use")
-+
-+if (NOT VOID_CXX_OPT_FLAGS STREQUAL "")
-+ llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "${VOID_CXX_OPT_FLAGS}")
-+endif()
-+
- # Put this before tblgen. Else we have a circular dependence.
- add_subdirectory(lib/Demangle)
- add_subdirectory(lib/Support)
diff --git a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
deleted file mode 100644
index d332687b9d9295..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From f3dbdd49c06bfafc1d6138094cf42889c14d38b6 Mon Sep 17 00:00:00 2001
-From: Samuel Holland <samuel@sholland.org>
-Date: Sun, 3 Nov 2019 10:57:27 -0600
-Subject: [PATCH] [LLVM][PowerPC] Assume BigPIC if no PIC level is specified
-
----
- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp | 2 +-
- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/lib/Target/PowerPC/PPCAsmPrinter.cpp b/lib/Target/PowerPC/PPCAsmPrinter.cpp
-index cce21f32..87ca5f9b 100644
---- a/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-@@ -520,7 +520,7 @@ void PPCAsmPrinter::EmitTlsCall(const MachineInstr *MI,
-
- // Add 32768 offset to the symbol so we follow up the latest GOT/PLT ABI.
- if (Kind == MCSymbolRefExpr::VK_PLT && Subtarget->isSecurePlt() &&
-- M->getPICLevel() == PICLevel::BigPIC)
-+ M->getPICLevel() != PICLevel::SmallPIC)
- TlsRef = MCBinaryExpr::createAdd(
- TlsRef, MCConstantExpr::create(32768, OutContext), OutContext);
- const MachineOperand &MO = MI->getOperand(2);
-diff --git a/lib/Target/PowerPC/PPCMCInstLower.cpp b/lib/Target/PowerPC/PPCMCInstLower.cpp
-index 5cc180d7..a5b02565 100644
---- a/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-@@ -117,7 +117,7 @@ static MCOperand GetSymbolRef(const MachineOperand &MO, const MCSymbol *Symbol,
- const MCExpr *Expr = MCSymbolRefExpr::create(Symbol, RefKind, Ctx);
- // If -msecure-plt -fPIC, add 32768 to symbol.
- if (Subtarget->isSecurePlt() && TM.isPositionIndependent() &&
-- M->getPICLevel() == PICLevel::BigPIC &&
-+ M->getPICLevel() != PICLevel::SmallPIC &&
- MO.getTargetFlags() == PPCII::MO_PLT)
- Expr =
- MCBinaryExpr::createAdd(Expr, MCConstantExpr::create(32768, Ctx), Ctx);
diff --git a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch b/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
deleted file mode 100644
index a00abd2166651f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Fix failures in AllocationTests/MappedMemoryTest.* on aarch64:
-
- Failing Tests (8):
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.AllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.DuplicateNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.EnabledWrite/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.MultipleAllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.SuccessiveNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.UnalignedNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroSizeNear/3
-
-Upstream-Issue: https://bugs.llvm.org/show_bug.cgi?id=14278#c10
-
---- a/llvm/lib/Support/Unix/Memory.inc
-+++ b/llvm/lib/Support/Unix/Memory.inc
-@@ -58,7 +58,7 @@ static int getPosixProtectionFlags(unsigned Flags) {
- return PROT_READ | PROT_WRITE | PROT_EXEC;
- case llvm::sys::Memory::MF_EXEC:
- #if (defined(__FreeBSD__) || defined(__POWERPC__) || defined (__ppc__) || \
-- defined(_POWER) || defined(_ARCH_PPC))
-+ defined(_POWER) || defined(_ARCH_PPC) || (defined(__linux__) && defined(__aarch64__)))
- // On PowerPC, having an executable page that has no read permission
- // can have unintended consequences. The function InvalidateInstruction-
- // Cache uses instructions dcbf and icbi, both of which are treated by
diff --git a/srcpkgs/llvm12/patches/llvm-gcc13.patch b/srcpkgs/llvm12/patches/llvm-gcc13.patch
deleted file mode 100644
index 6895221b73bb75..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-gcc13.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From ff1681ddb303223973653f7f5f3f3435b48a1983 Mon Sep 17 00:00:00 2001
-From: Sergei Trofimovich <slyich@gmail.com>
-Date: Mon, 23 May 2022 08:03:23 +0100
-Subject: [PATCH] [Support] Add missing <cstdint> header to Signals.h
-
-Without the change llvm build fails on this week's gcc-13 snapshot as:
-
- [ 0%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o
- In file included from llvm/lib/Support/Signals.cpp:14:
- llvm/include/llvm/Support/Signals.h:119:8: error: variable or field 'CleanupOnSignal' declared void
- 119 | void CleanupOnSignal(uintptr_t Context);
- | ^~~~~~~~~~~~~~~
----
- llvm/include/llvm/Support/Signals.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/llvm/include/llvm/Support/Signals.h b/llvm/include/llvm/Support/Signals.h
-index 44f5a750ff5cb0..937e0572d4a725 100644
---- a/llvm/include/llvm/Support/Signals.h
-+++ b/llvm/include/llvm/Support/Signals.h
-@@ -14,6 +14,7 @@
- #ifndef LLVM_SUPPORT_SIGNALS_H
- #define LLVM_SUPPORT_SIGNALS_H
-
-+#include <cstdint>
- #include <string>
-
- namespace llvm {
diff --git a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch b/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
deleted file mode 100644
index 8e0a9a779d1bf8..00000000000000
--- a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-commit ba4ede595ff9599232f5dd2b4384c243137b53fc
-Author: Daniel Kolesa <daniel@octaforge.org>
-Date: Tue Jun 22 23:40:54 2021 +0200
-
- enable compiler-rt support for ppc32
-
-diff --git a/compiler-rt/cmake/base-config-ix.cmake b/compiler-rt/cmake/base-config-ix.cmake
-index 1edab43..5c0c8a2 100644
---- a/compiler-rt/cmake/base-config-ix.cmake
-+++ b/compiler-rt/cmake/base-config-ix.cmake
-@@ -182,9 +182,7 @@ macro(test_targets)
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc64le")
- test_target_arch(powerpc64le "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc")
-- if(CMAKE_SYSTEM_NAME MATCHES "AIX")
-- test_target_arch(powerpc "" "-m32")
-- endif()
-+ test_target_arch(powerpc "" "-m32")
- test_target_arch(powerpc64 "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "s390x")
- test_target_arch(s390x "" "")
diff --git a/srcpkgs/llvm12/template b/srcpkgs/llvm12/template
deleted file mode 100644
index 86e86bb96c63f1..00000000000000
--- a/srcpkgs/llvm12/template
+++ /dev/null
@@ -1,161 +0,0 @@
-# Template file for 'llvm12'
-pkgname=llvm12
-version=12.0.1
-revision=4
-build_wrksrc=llvm
-build_style=cmake
-configure_args="
- -DCMAKE_BUILD_TYPE=Release -Wno-dev
- -DENABLE_LINKER_BUILD_ID=YES
- -DLLDB_USE_SYSTEM_SIX=YES
- -DLIBCXX_CXX_ABI=libcxxabi
- -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=YES
- -DLIBCXXABI_USE_LLVM_UNWINDER=YES
- -DLIBCXXABI_ENABLE_STATIC_UNWINDER=YES
- -DLIBOMP_ENABLE_SHARED=YES
- -DLIBOMP_INSTALL_ALIASES=NO
- -DLLVM_INCLUDE_DOCS=YES
- -DLLVM_BUILD_DOCS=YES
- -DLLVM_ENABLE_SPHINX=YES
- -DSPHINX_WARNINGS_AS_ERRORS=NO
- -DLLVM_INSTALL_UTILS=YES
- -DLLVM_BUILD_LLVM_DYLIB=YES
- -DLLVM_LINK_LLVM_DYLIB=YES
- -DLLVM_ENABLE_RTTI=YES
- -DLLVM_ENABLE_FFI=YES
- -DLLVM_BINUTILS_INCDIR=/usr/include"
-hostmakedepends="perl python3 zlib-devel libffi-devel swig python3-Sphinx
- python3-recommonmark python3-sphinx-automodapi"
-makedepends="python3-devel zlib-devel elfutils-devel libffi-devel libedit-devel
- libxml2-devel binutils-devel"
-depends="libllvm12>=${version}_${revision}"
-short_desc="Low Level Virtual Machine"
-maintainer="Orphaned <orphan@voidlinux.org>"
-license="Apache-2.0"
-homepage="https://www.llvm.org"
-distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-project-${version}.src.tar.xz"
-checksum=129cb25cd13677aad951ce5c2deb0fe4afc1e9d98950f53b51bdcfb5a73afa0e
-lib32disabled=yes
-python_version=3
-
-if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
- configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
- makedepends+=" libexecinfo-devel"
- depends+=" libexecinfo-devel"
-fi
-
-# "operand out of range" assembler failures
-case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*) configure_args+=" -DCLANG_ENABLE_CLANGD=OFF" ;;
-esac
-
-post_patch() {
- # update config.guess for better platform detection
- cp $XBPS_COMMONDIR/environment/configure/automake/config.guess \
- ${wrksrc}/llvm/cmake
-
- # fix linker failures on some archs
- vsed -i 's,check_library_exists(gcc_s .*,set(LIBCXXABI_HAS_GCC_S_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
- vsed -i 's,check_library_exists(gcc .*,set(LIBCXXABI_HAS_GCC_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
-
- # need libssp_nonshared on some musl platforms (because of nodefaultlibs)
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*-musl|i686-musl|mips*-musl)
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libunwind/src/CMakeLists.txt
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libcxxabi/src/CMakeLists.txt
- vsed -i 's,#ssp,,' ${wrksrc}/libcxx/CMakeLists.txt
- ;;
- 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
- ;;
- esac
-}
-
-pre_configure() {
- local triplet
-
- # Vastly reduce size of debugging symbols:
- CFLAGS=${CFLAGS/ -g/ -g1}
- CXXFLAGS=${CXXFLAGS/ -g/ -g1}
-
- # since gcc9, the build likes to blow up for ppc32 apparently because
- # of clang being too large for a 24-bit relative call to the PLT, so
- # optimize for size instead
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- mips*-musl|ppc*) configure_args+=" -DVOID_CXX_OPT_FLAGS=-Os" ;;
- esac
-
- if [ "$CROSS_BUILD" ]; then
- msg_normal "Building host tblgen\n"
- mkdir -p build/HOST
- cd build/HOST
- CC="$BUILD_CC" CXX="$BUILD_CXX" CFLAGS="$BUILD_CFLAGS" \
- CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
- cmake ../.. -DCMAKE_BUILD_TYPE=Release
- make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
- [ "$_lldb_enable" = "yes" ] && make ${makejobs} -C tools/lldb/utils/TableGen
- configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/clang-tblgen"
- cd ../..
- fi
-
- case "$XBPS_TARGET_MACHINE" in
- i686*) _arch="X86";;
- x86_64*) _arch="X86";;
- armv5*) _arch="Armv5te";;
- armv6*) _arch="Armv6";;
- armv7*) _arch="Armv7";;
- aarch64*) _arch="AArch64";;
- mips*) _arch="Mips";;
- ppc*) _arch="PowerPC";;
- riscv64*) _arch="RISCV64";;
- esac
-
- triplet=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}
-
- configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
- configure_args+=" -DLLVM_HOST_TRIPLE=${triplet}"
- configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${triplet}"
-}
-
-do_install() {
- cd build
- cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
-
- # Required for multilib.
- if [ "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
- for _header in llvm-config; do
- mv ${DESTDIR}/usr/include/llvm/Config/${_header}{,-64}.h
- vinstall ${FILESDIR}/llvm-Config-${_header}.h 644 \
- usr/include/llvm/Config ${_header}.h
- done
- fi
-
- # Remove llvm-config-host in cross builds.
- if [ "$CROSS_BUILD" ]; then
- rm -f ${DESTDIR}/usr/bin/llvm-config-host
- fi
-}
-
-libllvm12_package() {
- short_desc+=" - runtime library"
- pkg_install() {
- vmove "usr/lib/libLLVM-*.so*"
- }
-}
diff --git a/srcpkgs/llvm12/update b/srcpkgs/llvm12/update
deleted file mode 100644
index e95cf26b3586b7..00000000000000
--- a/srcpkgs/llvm12/update
+++ /dev/null
@@ -1,3 +0,0 @@
-site="https://github.com/llvm/llvm-project/releases"
-pattern="llvmorg-\K(\d+.){2}\d+(-rc\d+)?"
-ignore="*-rc*"
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index e729b51bfc267d..e2bf28e8cb2db3 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
# Template file for 'removed-packages'
pkgname=removed-packages
-version=0.1.20240727
+version=0.1.20240729
revision=1
build_style=meta
short_desc="Uninstalls packages removed from repository"
@@ -376,6 +376,7 @@ replaces="
libgroff<=1.22.4_3
libgtkhtml<=4.10.0_1
libkscreen<=5.27.11_3
+ libllvm12<=12.0.1_4
libllvm10<=10.0.0_8
libllvm11<=11.0.0_2
libllvm15<=15.0.7_4
@@ -440,6 +441,7 @@ replaces="
lldb-devel<=15.0.7_3
lldb15-devel<=15.0.7_4
lldb15<=15.0.7_4
+ llvm12<=12.0.1_4
llvm10<=10.0.0_8
llvm11<=11.0.0_2
llvm15<=15.0.7_4
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (12 preceding siblings ...)
2024-07-31 17:44 ` Calandracas606
@ 2024-07-31 17:45 ` Calandracas606
2024-07-31 18:13 ` [PR PATCH] [Merged]: " classabbyamp
14 siblings, 0 replies; 16+ messages in thread
From: Calandracas606 @ 2024-07-31 17:45 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1422 bytes --]
There is an updated pull request by Calandracas606 against master on the void-packages repository
https://github.com/Calandracas606/void-packages remove-llvm12
https://github.com/void-linux/void-packages/pull/51186
remove llvm12
- **mozjs102: build with llvm18**
- **ghdl: update to 4.1.0.**
- **llvm12: remove package**
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, x86_64
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64-musl
- i686
- aarch64 (cross)
- aarch64-musl (cross)
- armv7l (cross)
- armv7l-musl (cross)
- armv6l (cross)
- armv6l-musl (cross)
A patch file from https://github.com/void-linux/void-packages/pull/51186.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-remove-llvm12-51186.patch --]
[-- Type: text/x-diff, Size: 50228 bytes --]
From 530da5c39c26b89734467b10aebdfeb49ac5cec0 Mon Sep 17 00:00:00 2001
From: Daniel Martinez <danielmartinez@cock.li>
Date: Tue, 9 Jul 2024 22:18:51 -0400
Subject: [PATCH] llvm12: remove package
---
common/shlibs | 2 -
srcpkgs/libllvm12 | 1 -
.../llvm12/files/llvm-Config-llvm-config.h | 9 -
...clang-001-fix-unwind-chain-inclusion.patch | 44 -----
.../patches/clang-002-add-musl-triples.patch | 110 ------------
.../clang-003-ppc64-dynamic-linker-path.patch | 13 --
.../patches/clang-004-ppc64-musl-elfv2.patch | 48 ------
.../compiler-rt-aarch64-ucontext.patch | 11 --
.../compiler-rt-sanitizer-glibc-2.36.patch | 59 -------
.../compiler-rt-sanitizer-ppc64-musl.patch | 35 ----
.../llvm12/patches/compiler-rt-size_t.patch | 10 --
.../patches/compiler-rt-xray-ppc64-musl.patch | 62 -------
srcpkgs/llvm12/patches/libcxx-musl.patch | 26 ---
srcpkgs/llvm12/patches/libcxx-ppc.patch | 22 ---
.../llvm12/patches/libcxx-ssp-nonshared.patch | 11 --
srcpkgs/llvm12/patches/libcxxabi-dl.patch | 25 ---
srcpkgs/llvm12/patches/libunwind-ppc32.patch | 63 -------
srcpkgs/llvm12/patches/lldb-musl.patch | 31 ----
srcpkgs/llvm12/patches/llvm-001-musl.patch | 57 -------
.../patches/llvm-002-musl-ppc64-elfv2.patch | 30 ----
.../patches/llvm-003-ppc-secureplt.patch | 11 --
.../patches/llvm-004-override-opt.patch | 18 --
.../llvm12/patches/llvm-005-ppc-bigpic.patch | 36 ----
.../patches/llvm-006-aarch64-mf_exec.patch | 25 ---
srcpkgs/llvm12/patches/llvm-gcc13.patch | 28 ---
.../llvm12/patches/ppc32-compiler-rt.patch | 21 ---
srcpkgs/llvm12/template | 161 ------------------
srcpkgs/llvm12/update | 3 -
srcpkgs/removed-packages/template | 4 +-
29 files changed, 3 insertions(+), 973 deletions(-)
delete mode 120000 srcpkgs/libllvm12
delete mode 100644 srcpkgs/llvm12/files/llvm-Config-llvm-config.h
delete mode 100644 srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
delete mode 100644 srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-size_t.patch
delete mode 100644 srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ppc.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
delete mode 100644 srcpkgs/llvm12/patches/libcxxabi-dl.patch
delete mode 100644 srcpkgs/llvm12/patches/libunwind-ppc32.patch
delete mode 100644 srcpkgs/llvm12/patches/lldb-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-001-musl.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-004-override-opt.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
delete mode 100644 srcpkgs/llvm12/patches/llvm-gcc13.patch
delete mode 100644 srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
delete mode 100644 srcpkgs/llvm12/template
delete mode 100644 srcpkgs/llvm12/update
diff --git a/common/shlibs b/common/shlibs
index 12436fd372718c..1ec4dc5bc698e8 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -992,8 +992,6 @@ libclang.so.18.1 libclang18-18.1.8_1
libclang.so.17 libclang17-17.0.6_1
libclang-cpp.so.18.1 libclang-cpp18-18.1.8_1
libclang-cpp.so.17 libclang-cpp17-17.0.6_1
-libLLVM-11.so libllvm11-11.0.0_1
-libLLVM-12.so libllvm12-12.0.0_1
libLLVM-17.so libllvm17-17.0.6_1
libLLVM.so.18.1 libllvm18-18.1.8_1
libLLVMSPIRVLib.so.18.1 SPIRV-LLVM-Translator-18.1.2_1
diff --git a/srcpkgs/libllvm12 b/srcpkgs/libllvm12
deleted file mode 120000
index cd60fd7a981bdd..00000000000000
--- a/srcpkgs/libllvm12
+++ /dev/null
@@ -1 +0,0 @@
-llvm12
\ No newline at end of file
diff --git a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h b/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
deleted file mode 100644
index 2fa08c9be69621..00000000000000
--- a/srcpkgs/llvm12/files/llvm-Config-llvm-config.h
+++ /dev/null
@@ -1,9 +0,0 @@
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 32
-#include "llvm-config-32.h"
-#elif __WORDSIZE == 64
-#include "llvm-config-64.h"
-#else
-#error "Unknown word size"
-#endif
diff --git a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
deleted file mode 100644
index e4eaa7783e7a6c..00000000000000
--- a/srcpkgs/llvm12/patches/clang-001-fix-unwind-chain-inclusion.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 352974169f0d2b5da3d5321f588f5e3b5941330e Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:14:57 +0200
-Subject: [PATCH 2/7] fix unwind chain inclusion
-
----
- lib/Headers/unwind.h | 9 +++++----
- 1 file changed, 5 insertions(+), 4 deletions(-)
-
-diff --git a/lib/Headers/unwind.h b/lib/Headers/unwind.h
-index 303d792..44e10cc 100644
---- a/clang/lib/Headers/unwind.h
-+++ b/clang/lib/Headers/unwind.h
-@@ -9,9 +9,6 @@
-
- /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/
-
--#ifndef __CLANG_UNWIND_H
--#define __CLANG_UNWIND_H
--
- #if defined(__APPLE__) && __has_include_next(<unwind.h>)
- /* Darwin (from 11.x on) provide an unwind.h. If that's available,
- * use it. libunwind wraps some of its definitions in #ifdef _GNU_SOURCE,
-@@ -39,6 +36,9 @@
- # endif
- #else
-
-+#ifndef __CLANG_UNWIND_H
-+#define __CLANG_UNWIND_H
-+
- #include <stdint.h>
-
- #ifdef __cplusplus
-@@ -322,6 +322,7 @@ _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *);
- }
- #endif
-
-+#endif /* __CLANG_UNWIND_H */
-+
- #endif
-
--#endif /* __CLANG_UNWIND_H */
---
-2.5.1
diff --git a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch b/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
deleted file mode 100644
index 25688d40dbc275..00000000000000
--- a/srcpkgs/llvm12/patches/clang-002-add-musl-triples.patch
+++ /dev/null
@@ -1,110 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Gnu.cpp
-+++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2086,7 +2086,8 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
- "armv7hl-redhat-linux-gnueabi",
- "armv6hl-suse-linux-gnueabi",
-- "armv7hl-suse-linux-gnueabi"};
-+ "armv7hl-suse-linux-gnueabi",
-+ "armv7l-linux-gnueabihf"};
- static const char *const ARMebLibDirs[] = {"/lib"};
- static const char *const ARMebTriples[] = {"armeb-linux-gnueabi",
- "armeb-linux-androideabi"};
-@@ -2153,8 +2154,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- "powerpc64-suse-linux", "powerpc-montavista-linuxspe"};
- static const char *const PPCLELibDirs[] = {"/lib32", "/lib"};
- static const char *const PPCLETriples[] = {"powerpcle-linux-gnu",
-- "powerpcle-unknown-linux-gnu",
-- "powerpcle-linux-musl"};
-+ "powerpcle-unknown-linux-gnu"};
-
- static const char *const PPC64LibDirs[] = {"/lib64", "/lib"};
- static const char *const PPC64Triples[] = {
-@@ -2235,6 +2235,87 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
- return;
- }
-
-+ if (TargetTriple.isMusl()) {
-+ static const char *const AArch64MuslTriples[] = {"aarch64-linux-musl"};
-+ static const char *const ARMHFMuslTriples[] = {
-+ "arm-linux-musleabihf", "armv7l-linux-musleabihf"
-+ };
-+ static const char *const ARMMuslTriples[] = {"arm-linux-musleabi"};
-+ static const char *const X86_64MuslTriples[] = {"x86_64-linux-musl"};
-+ static const char *const X86MuslTriples[] = {"i686-linux-musl"};
-+ static const char *const MIPSMuslTriples[] = {
-+ "mips-linux-musl", "mipsel-linux-musl",
-+ "mipsel-linux-muslhf", "mips-linux-muslhf"
-+ };
-+ static const char *const PPCMuslTriples[] = {"powerpc-linux-musl"};
-+ static const char *const PPCLEMuslTriples[] = {"powerpcle-linux-musl"};
-+ static const char *const PPC64MuslTriples[] = {"powerpc64-linux-musl"};
-+ static const char *const PPC64LEMuslTriples[] = {"powerpc64le-linux-musl"};
-+
-+ switch (TargetTriple.getArch()) {
-+ case llvm::Triple::aarch64:
-+ LibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ TripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ BiarchLibDirs.append(begin(AArch64LibDirs), end(AArch64LibDirs));
-+ BiarchTripleAliases.append(begin(AArch64MuslTriples), end(AArch64MuslTriples));
-+ break;
-+ case llvm::Triple::arm:
-+ LibDirs.append(begin(ARMLibDirs), end(ARMLibDirs));
-+ if (TargetTriple.getEnvironment() == llvm::Triple::MuslEABIHF) {
-+ TripleAliases.append(begin(ARMHFMuslTriples), end(ARMHFMuslTriples));
-+ } else {
-+ TripleAliases.append(begin(ARMMuslTriples), end(ARMMuslTriples));
-+ }
-+ break;
-+ case llvm::Triple::x86_64:
-+ LibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ TripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ BiarchLibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ BiarchTripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ break;
-+ case llvm::Triple::x86:
-+ LibDirs.append(begin(X86LibDirs), end(X86LibDirs));
-+ TripleAliases.append(begin(X86MuslTriples), end(X86MuslTriples));
-+ BiarchLibDirs.append(begin(X86_64LibDirs), end(X86_64LibDirs));
-+ BiarchTripleAliases.append(begin(X86_64MuslTriples), end(X86_64MuslTriples));
-+ break;
-+ case llvm::Triple::mips:
-+ LibDirs.append(begin(MIPSLibDirs), end(MIPSLibDirs));
-+ TripleAliases.append(begin(MIPSMuslTriples), end(MIPSMuslTriples));
-+ break;
-+ case llvm::Triple::ppc:
-+ LibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ TripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ BiarchTripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ break;
-+ case llvm::Triple::ppcle:
-+ LibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ TripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ BiarchLibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ BiarchTripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64:
-+ LibDirs.append(begin(PPC64LibDirs), end(PPC64LibDirs));
-+ TripleAliases.append(begin(PPC64MuslTriples), end(PPC64MuslTriples));
-+ BiarchLibDirs.append(begin(PPCLibDirs), end(PPCLibDirs));
-+ BiarchTripleAliases.append(begin(PPCMuslTriples), end(PPCMuslTriples));
-+ break;
-+ case llvm::Triple::ppc64le:
-+ LibDirs.append(begin(PPC64LELibDirs), end(PPC64LELibDirs));
-+ TripleAliases.append(begin(PPC64LEMuslTriples), end(PPC64LEMuslTriples));
-+ BiarchLibDirs.append(begin(PPCLELibDirs), end(PPCLELibDirs));
-+ BiarchTripleAliases.append(begin(PPCLEMuslTriples), end(PPCLEMuslTriples));
-+ break;
-+ default:
-+ break;
-+ }
-+ TripleAliases.push_back(TargetTriple.str());
-+ if (TargetTriple.str() != BiarchTriple.str())
-+ BiarchTripleAliases.push_back(BiarchTriple.str());
-+ return;
-+ }
-+
- // Android targets should not use GNU/Linux tools or libraries.
- if (TargetTriple.isAndroid()) {
- static const char *const AArch64AndroidTriples[] = {
diff --git a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
deleted file mode 100644
index 4ad6412d1e6c63..00000000000000
--- a/srcpkgs/llvm12/patches/clang-003-ppc64-dynamic-linker-path.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- a/clang/lib/Driver/ToolChains/Linux.cpp
-+++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -504,10 +504,6 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
- Loader = "ld.so.1";
- break;
- case llvm::Triple::ppc64:
-- LibDir = "lib64";
-- Loader =
-- (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
-- break;
- case llvm::Triple::ppc64le:
- LibDir = "lib64";
- Loader =
diff --git a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
deleted file mode 100644
index 21fc8003c5f1a8..00000000000000
--- a/srcpkgs/llvm12/patches/clang-004-ppc64-musl-elfv2.patch
+++ /dev/null
@@ -1,48 +0,0 @@
---- a/clang/lib/Basic/Targets/PPC.h
-+++ b/clang/lib/Basic/Targets/PPC.h
-@@ -415,11 +415,10 @@ public:
- LongDoubleFormat = &llvm::APFloat::IEEEdouble();
- } else if ((Triple.getArch() == llvm::Triple::ppc64le)) {
- DataLayout = "e-m:e-i64:64-n32:64";
-- ABI = "elfv2";
- } else {
- DataLayout = "E-m:e-i64:64-n32:64";
-- ABI = "elfv1";
- }
-+ ABI = "elfv2";
-
- if (Triple.isOSFreeBSD() || Triple.isOSOpenBSD() || Triple.isMusl()) {
- LongDoubleWidth = LongDoubleAlign = 64;
---- a/clang/lib/CodeGen/TargetInfo.cpp
-+++ b/clang/lib/CodeGen/TargetInfo.cpp
-@@ -10927,9 +10927,9 @@ const TargetCodeGenInfo &CodeGenModule::getTargetCodeGenInfo() {
- return SetCGInfo(new AIXTargetCodeGenInfo(Types, /*Is64Bit*/ true));
-
- if (Triple.isOSBinFormatELF()) {
-- PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv1;
-- if (getTarget().getABI() == "elfv2")
-- Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ PPC64_SVR4_ABIInfo::ABIKind Kind = PPC64_SVR4_ABIInfo::ELFv2;
-+ if (getTarget().getABI() == "elfv1")
-+ Kind = PPC64_SVR4_ABIInfo::ELFv1;
- bool IsSoftFloat = CodeGenOpts.FloatABI == "soft";
-
- return SetCGInfo(
---- a/clang/lib/Driver/ToolChains/Clang.cpp
-+++ b/clang/lib/Driver/ToolChains/Clang.cpp
-@@ -1920,14 +1920,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
- const llvm::Triple &T = getToolChain().getTriple();
- if (T.isOSBinFormatELF()) {
- switch (getToolChain().getArch()) {
-- case llvm::Triple::ppc64: {
-- if ((T.isOSFreeBSD() && T.getOSMajorVersion() >= 13) ||
-- T.isOSOpenBSD() || T.isMusl())
-- ABIName = "elfv2";
-- else
-- ABIName = "elfv1";
-- break;
-- }
-+ case llvm::Triple::ppc64:
- case llvm::Triple::ppc64le:
- ABIName = "elfv2";
- break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch b/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
deleted file mode 100644
index 893c059d7b8def..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-aarch64-ucontext.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp.orig
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -1799,7 +1799,7 @@
-
- static bool Aarch64GetESR(ucontext_t *ucontext, u64 *esr) {
- static const u32 kEsrMagic = 0x45535201;
-- u8 *aux = ucontext->uc_mcontext.__reserved;
-+ u8 *aux = reinterpret_cast<u8 *>(ucontext->uc_mcontext.__reserved);
- while (true) {
- _aarch64_ctx *ctx = (_aarch64_ctx *)aux;
- if (ctx->size == 0) break;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
deleted file mode 100644
index e5f24dab893547..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-glibc-2.36.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From 9cf13067cb5088626ba7ee1ec4c42ec59c7995a0 Mon Sep 17 00:00:00 2001
-From: Fangrui Song <i@maskray.me>
-Date: Mon, 11 Jul 2022 12:53:34 -0700
-Subject: [PATCH] [sanitizer] Remove #include <linux/fs.h> to resolve
- fsconfig_command/mount_attr conflict with glibc 2.36
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-It is generally not a good idea to mix usage of glibc headers and Linux UAPI
-headers (https://sourceware.org/glibc/wiki/Synchronizing_Headers). In glibc
-since 7eae6a91e9b1670330c9f15730082c91c0b1d570 (milestone: 2.36), sys/mount.h
-defines `fsconfig_command` which conflicts with linux/mount.h:
-
- .../usr/include/linux/mount.h:95:6: error: redeclaration of ‘enum fsconfig_command’
-
-Remove #include <linux/fs.h> which pulls in linux/mount.h. Expand its 4 macros manually.
-Android sys/mount.h doesn't define BLKBSZGET and it still needs linux/fs.h.
-In the long term we should move Linux specific definitions to sanitizer_platform_limits_linux.cpp
-but this commit is easy to cherry pick into older compiler-rt releases.
-
-Fix https://github.com/llvm/llvm-project/issues/56421
-
-Reviewed By: #sanitizers, vitalybuka, zatrazz
-
-Differential Revision: https://reviews.llvm.org/D129471
----
- .../sanitizer_platform_limits_posix.cpp | 10 ++++++----
- 1 file changed, 6 insertions(+), 4 deletions(-)
-
-diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-index 4bd425435d56d..3a94b260686f1 100644
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -73,7 +73,9 @@
- #include <sys/vt.h>
- #include <linux/cdrom.h>
- #include <linux/fd.h>
-+#if SANITIZER_ANDROID
- #include <linux/fs.h>
-+#endif
- #include <linux/hdreg.h>
- #include <linux/input.h>
- #include <linux/ioctl.h>
-@@ -876,10 +878,10 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr);
- unsigned IOCTL_EVIOCGPROP = IOCTL_NOT_PRESENT;
- unsigned IOCTL_EVIOCSKEYCODE_V2 = IOCTL_NOT_PRESENT;
- #endif
-- unsigned IOCTL_FS_IOC_GETFLAGS = FS_IOC_GETFLAGS;
-- unsigned IOCTL_FS_IOC_GETVERSION = FS_IOC_GETVERSION;
-- unsigned IOCTL_FS_IOC_SETFLAGS = FS_IOC_SETFLAGS;
-- unsigned IOCTL_FS_IOC_SETVERSION = FS_IOC_SETVERSION;
-+ unsigned IOCTL_FS_IOC_GETFLAGS = _IOR('f', 1, long);
-+ unsigned IOCTL_FS_IOC_GETVERSION = _IOR('v', 1, long);
-+ unsigned IOCTL_FS_IOC_SETFLAGS = _IOW('f', 2, long);
-+ unsigned IOCTL_FS_IOC_SETVERSION = _IOW('v', 2, long);
- unsigned IOCTL_GIO_CMAP = GIO_CMAP;
- unsigned IOCTL_GIO_FONT = GIO_FONT;
- unsigned IOCTL_GIO_UNIMAP = GIO_UNIMAP;
diff --git a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
deleted file mode 100644
index 35f16d24f340c6..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-sanitizer-ppc64-musl.patch
+++ /dev/null
@@ -1,35 +0,0 @@
---- a/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp
-@@ -74,6 +74,10 @@
- #include <sys/utsname.h>
- #endif
-
-+#if SANITIZER_LINUX && defined(__powerpc__)
-+#include <asm/ptrace.h>
-+#endif
-+
- #if SANITIZER_LINUX && !SANITIZER_ANDROID
- #include <sys/personality.h>
- #endif
---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
-@@ -92,7 +92,7 @@
- # include <utime.h>
- # include <sys/ptrace.h>
- #if defined(__mips64) || defined(__aarch64__) || defined(__arm__) || \
-- SANITIZER_RISCV64
-+ defined(__powerpc__) || SANITIZER_RISCV64
- # include <asm/ptrace.h>
- # ifdef __arm__
- typedef struct user_fpregs elf_fpregset_t;
---- a/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-+++ b/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cpp
-@@ -31,7 +31,7 @@
- #include <sys/types.h> // for pid_t
- #include <sys/uio.h> // for iovec
- #include <elf.h> // for NT_PRSTATUS
--#if (defined(__aarch64__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
-+#if (defined(__aarch64__) || defined(__powerpc__) || SANITIZER_RISCV64) && !SANITIZER_ANDROID
- // GLIBC 2.20+ sys/user does not include asm/ptrace.h
- # include <asm/ptrace.h>
- #endif
diff --git a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch b/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
deleted file mode 100644
index 2c63063a5e9e3f..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-size_t.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp.orig
-+++ b/compiler-rt/lib/fuzzer/FuzzerInterceptors.cpp
-@@ -25,6 +25,7 @@
- }
-
- #include <cassert>
-+#include <cstddef>
- #include <cstdint>
- #include <dlfcn.h> // for dlsym()
-
diff --git a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch b/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
deleted file mode 100644
index d0b61c80c897f4..00000000000000
--- a/srcpkgs/llvm12/patches/compiler-rt-xray-ppc64-musl.patch
+++ /dev/null
@@ -1,62 +0,0 @@
---- a/compiler-rt/lib/xray/xray_powerpc64.inc
-+++ b/compiler-rt/lib/xray/xray_powerpc64.inc
-@@ -12,7 +12,13 @@
-
- #include <cstdint>
- #include <mutex>
-+#ifdef __GLIBC__
- #include <sys/platform/ppc.h>
-+#else
-+#include <cctype>
-+#include <cstring>
-+#include <cstdlib>
-+#endif
-
- #include "xray_defs.h"
-
-@@ -20,13 +26,45 @@ namespace __xray {
-
- ALWAYS_INLINE uint64_t readTSC(uint8_t &CPU) XRAY_NEVER_INSTRUMENT {
- CPU = 0;
-+#ifdef __GLIBC__
- return __ppc_get_timebase();
-+#else
-+ return __builtin_ppc_get_timebase();
-+#endif
- }
-
- inline uint64_t getTSCFrequency() XRAY_NEVER_INSTRUMENT {
- static std::mutex M;
- std::lock_guard<std::mutex> Guard(M);
-+#ifdef __GLIBC__
- return __ppc_get_timebase_freq();
-+#else
-+ /* FIXME: a less dirty implementation? */
-+ static uint64_t base;
-+ if (!base) {
-+ FILE *f = fopen("/proc/cpuinfo", "rb");
-+ if (f) {
-+ ssize_t nr;
-+ /* virtually always big enough to hold the line */
-+ char buf[512];
-+ while (fgets(buf, sizeof(buf), f)) {
-+ char *ret = strstr(buf, "timebase");
-+ if (!ret) {
-+ continue;
-+ }
-+ ret += sizeof("timebase") - 1;
-+ ret = strchr(ret, ':');
-+ if (!ret) {
-+ continue;
-+ }
-+ base = strtoul(ret + 1, nullptr, 10);
-+ break;
-+ }
-+ fclose(f);
-+ }
-+ }
-+ return base;
-+#endif
- }
-
- inline bool probeRequiredCPUFeatures() XRAY_NEVER_INSTRUMENT {
diff --git a/srcpkgs/llvm12/patches/libcxx-musl.patch b/srcpkgs/llvm12/patches/libcxx-musl.patch
deleted file mode 100644
index bbd31ffc2cb1f4..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-musl.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/libcxx/include/locale
-+++ b/libcxx/include/locale
-@@ -742,7 +742,11 @@ __num_get_signed_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ long long __ll = strtoll(__a, &__p2, __base);
-+#else
- long long __ll = strtoll_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
-@@ -782,7 +786,11 @@ __num_get_unsigned_integral(const char* __a, const char* __a_end,
- typename remove_reference<decltype(errno)>::type __save_errno = errno;
- errno = 0;
- char *__p2;
-+#if defined(__linux__) && !defined(__GLIBC__)
-+ unsigned long long __ll = strtoull(__a, &__p2, __base);
-+#else
- unsigned long long __ll = strtoull_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE);
-+#endif
- typename remove_reference<decltype(errno)>::type __current_errno = errno;
- if (__current_errno == 0)
- errno = __save_errno;
diff --git a/srcpkgs/llvm12/patches/libcxx-ppc.patch b/srcpkgs/llvm12/patches/libcxx-ppc.patch
deleted file mode 100644
index 7a92f8004e1cf8..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ppc.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-This ensures `is_iec559` is defined correctly under all long double ABIs,
-including musl and its 64-bit long double. Also, `__ppc__` or `__ppc64__`
-is not defined on gcc.
-
---- a/libcxx/include/limits
-+++ b/libcxx/include/limits
-@@ -426,8 +426,14 @@ protected:
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return __builtin_nansl("");}
- _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type denorm_min() _NOEXCEPT {return __LDBL_DENORM_MIN__;}
-
--#if (defined(__ppc__) || defined(__ppc64__))
-+#if defined(__powerpc__) || defined(__powerpc64__)
-+#if (__LDBL_MAX_EXP__ > __DBL_MAX_EXP__) || (__LDBL_MANT_DIG__ == __DBL_MANT_DIG__)
-+ /* IEEE 754 quadruple or double precision */
-+ static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
-+#else
-+ /* 128-bit IBM double-double */
- static _LIBCPP_CONSTEXPR const bool is_iec559 = false;
-+#endif
- #else
- static _LIBCPP_CONSTEXPR const bool is_iec559 = true;
- #endif
diff --git a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch b/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
deleted file mode 100644
index 70292beb2fcdbd..00000000000000
--- a/srcpkgs/llvm12/patches/libcxx-ssp-nonshared.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/libcxx/CMakeLists.txt
-+++ b/libcxx/CMakeLists.txt
-@@ -769,6 +769,8 @@ function(cxx_link_system_libraries target)
- target_link_libraries(${target} PRIVATE atomic)
- endif()
-
-+#ssp target_link_libraries(${target} PRIVATE ssp_nonshared)
-+
- if (MINGW)
- target_link_libraries(${target} PRIVATE "${MINGW_LIBRARIES}")
- endif()
diff --git a/srcpkgs/llvm12/patches/libcxxabi-dl.patch b/srcpkgs/llvm12/patches/libcxxabi-dl.patch
deleted file mode 100644
index 3a15f9db8c981e..00000000000000
--- a/srcpkgs/llvm12/patches/libcxxabi-dl.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-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()
diff --git a/srcpkgs/llvm12/patches/libunwind-ppc32.patch b/srcpkgs/llvm12/patches/libunwind-ppc32.patch
deleted file mode 100644
index 74aa7576ecf9df..00000000000000
--- a/srcpkgs/llvm12/patches/libunwind-ppc32.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-This fixes build at least with gcc9 which does not define `__ppc__`.
-
---- a/libunwind/include/__libunwind_config.h
-+++ b/libunwind/include/__libunwind_config.h
-@@ -49,7 +49,7 @@
- # define _LIBUNWIND_CONTEXT_SIZE 167
- # define _LIBUNWIND_CURSOR_SIZE 179
- # define _LIBUNWIND_HIGHEST_DWARF_REGISTER _LIBUNWIND_HIGHEST_DWARF_REGISTER_PPC64
--# elif defined(__ppc__)
-+# elif defined(__powerpc__)
- # define _LIBUNWIND_TARGET_PPC 1
- # define _LIBUNWIND_CONTEXT_SIZE 117
- # define _LIBUNWIND_CURSOR_SIZE 124
---- a/libunwind/src/UnwindRegistersRestore.S
-+++ b/libunwind/src/UnwindRegistersRestore.S
-@@ -392,7 +392,7 @@ Lnovec:
- PPC64_LR(3)
- bctr
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- DEFINE_LIBUNWIND_FUNCTION(_ZN9libunwind13Registers_ppc6jumptoEv)
- //
---- a/libunwind/src/UnwindRegistersSave.S
-+++ b/libunwind/src/UnwindRegistersSave.S
-@@ -554,7 +554,7 @@ DEFINE_LIBUNWIND_FUNCTION(__unw_getcontext)
- blr
-
-
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
-
- //
- // extern int unw_getcontext(unw_context_t* thread_state)
---- a/libunwind/src/config.h
-+++ b/libunwind/src/config.h
-@@ -95,12 +95,12 @@
- #define _LIBUNWIND_BUILD_SJLJ_APIS
- #endif
-
--#if defined(__i386__) || defined(__x86_64__) || defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__)
-+#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc__) || defined(__powerpc64__)
- #define _LIBUNWIND_SUPPORT_FRAME_APIS
- #endif
-
- #if defined(__i386__) || defined(__x86_64__) || \
-- defined(__ppc__) || defined(__ppc64__) || defined(__powerpc64__) || \
-+ defined(__powerpc__) || defined(__powerpc64__) || \
- (!defined(__APPLE__) && defined(__arm__)) || \
- (defined(__arm64__) || defined(__aarch64__)) || \
- defined(__mips__)
---- a/libunwind/src/libunwind.cpp
-+++ b/libunwind/src/libunwind.cpp
-@@ -42,7 +42,7 @@ _LIBUNWIND_HIDDEN int __unw_init_local(unw_cursor_t *cursor,
- # define REGISTER_KIND Registers_x86_64
- #elif defined(__powerpc64__)
- # define REGISTER_KIND Registers_ppc64
--#elif defined(__ppc__)
-+#elif defined(__powerpc__)
- # define REGISTER_KIND Registers_ppc
- #elif defined(__aarch64__)
- # define REGISTER_KIND Registers_arm64
diff --git a/srcpkgs/llvm12/patches/lldb-musl.patch b/srcpkgs/llvm12/patches/lldb-musl.patch
deleted file mode 100644
index 601c0d138523e8..00000000000000
--- a/srcpkgs/llvm12/patches/lldb-musl.patch
+++ /dev/null
@@ -1,31 +0,0 @@
---- a/lldb/source/Plugins/Process/Linux/Procfs.h
-+++ b/lldb/source/Plugins/Process/Linux/Procfs.h
-@@ -10,21 +10,12 @@
- // sys/procfs.h on Android/Linux for all supported architectures.
-
- #include <sys/ptrace.h>
-+#include <asm/ptrace.h>
-
--#ifdef __ANDROID__
--#if defined(__arm64__) || defined(__aarch64__)
--typedef unsigned long elf_greg_t;
--typedef elf_greg_t
-- elf_gregset_t[(sizeof(struct user_pt_regs) / sizeof(elf_greg_t))];
--typedef struct user_fpsimd_state elf_fpregset_t;
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#elif defined(__mips__)
--#ifndef NT_FPREGSET
--#define NT_FPREGSET NT_PRFPREG
--#endif // NT_FPREGSET
--#endif
--#else // __ANDROID__
-+#if !defined(__GLIBC__) && defined(__powerpc__)
-+#define pt_regs musl_pt_regs
-+#include <sys/procfs.h>
-+#undef pt_regs
-+#else
- #include <sys/procfs.h>
--#endif // __ANDROID__
-+#endif
diff --git a/srcpkgs/llvm12/patches/llvm-001-musl.patch b/srcpkgs/llvm12/patches/llvm-001-musl.patch
deleted file mode 100644
index f2a3f8d62813e3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-001-musl.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From faca3fbd15d0c3108493c3c54cd93138e049ac43 Mon Sep 17 00:00:00 2001
-From: Andrea Brancaleoni <miwaxe@gmail.com>
-Date: Tue, 8 Sep 2015 22:03:02 +0200
-Subject: [PATCH 3/3] musl
-
----
- include/llvm/Analysis/TargetLibraryInfo.h | 9 +++++++++
- lib/Support/DynamicLibrary.cpp | 2 +-
- lib/Support/Unix/Signals.inc | 6 +++---
- utils/unittest/googletest/src/gtest.cc | 1 +
- 5 files changed, 17 insertions(+), 6 deletions(-)
-
-diff --git a/include/llvm/Analysis/TargetLibraryInfo.h b/include/llvm/Analysis/TargetLibraryInfo.h
-index 34a8a1e3..1214ece5 100644
---- a/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-+++ b/llvm/include/llvm/Analysis/TargetLibraryInfo.h
-@@ -18,6 +18,15 @@
- #include "llvm/IR/PassManager.h"
- #include "llvm/Pass.h"
-
-+#undef fopen64
-+#undef fseeko64
-+#undef fstat64
-+#undef fstatvfs64
-+#undef ftello64
-+#undef lstat64
-+#undef stat64
-+#undef tmpfile64
-+
- namespace llvm {
- template <typename T> class ArrayRef;
- class Triple;
-diff --git a/lib/Support/Unix/DynamicLibrary.inc b/lib/Support/Unix/DynamicLibrary.inc
-index a2a37996..2f86c470 100644
---- a/llvm/lib/Support/Unix/DynamicLibrary.inc
-+++ b/llvm/lib/Support/Unix/DynamicLibrary.inc
-@@ -102,7 +102,7 @@ static void *DoSearch(const char* SymbolName) {
-
- // This macro returns the address of a well-known, explicit symbol
- #define EXPLICIT_SYMBOL(SYM) \
-- if (!strcmp(SymbolName, #SYM)) return &SYM
-+ if (!strcmp(SymbolName, #SYM)) return (void *)&SYM
-
- // Under glibc we have a weird situation. The stderr/out/in symbols are both
- // macros and global variables because of standards requirements. So, we
-diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
-index d882ab2e..f1fb12d0 100644
---- a/llvm/utils/unittest/googletest/src/gtest.cc
-+++ b/llvm/utils/unittest/googletest/src/gtest.cc
-@@ -128,6 +128,7 @@
-
- #if GTEST_CAN_STREAM_RESULTS_
- # include <arpa/inet.h> // NOLINT
-+# include <sys/socket.h> // NOLINT
- # include <netdb.h> // NOLINT
- # include <sys/socket.h> // NOLINT
- # include <sys/types.h> // NOLINT
diff --git a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
deleted file mode 100644
index 0071d964bd371f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-002-musl-ppc64-elfv2.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-This patches LLVM to use ELFv2 on ppc64 unconditionally unless overridden. We
-need this because unlike most distros we use ELFv2 for both glibc and musl
-on big endian ppc64.
-
-diff --git a/lib/Target/PowerPC/PPCTargetMachine.cpp b/lib/Target/PowerPC/PPCTargetMachine.cpp
-index 0634833e..b7cbc2e7 100644
---- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
-@@ -222,9 +222,8 @@ static PPCTargetMachine::PPCABI computeTargetABI(const Triple &TT,
-
- switch (TT.getArch()) {
- case Triple::ppc64le:
-- return PPCTargetMachine::PPC_ABI_ELFv2;
- case Triple::ppc64:
-- return PPCTargetMachine::PPC_ABI_ELFv1;
-+ return PPCTargetMachine::PPC_ABI_ELFv2;
- default:
- return PPCTargetMachine::PPC_ABI_UNKNOWN;
- }
-diff --git a/test/CodeGen/PowerPC/ppc64-elf-abi.ll b/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-index 8b1cf6b5..296a2afa 100644
---- a/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-+++ b/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll
-@@ -1,4 +1,5 @@
--; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv1
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
-+; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-musl < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2
- ; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2
diff --git a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch b/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
deleted file mode 100644
index b5d15974375d49..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-003-ppc-secureplt.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
-@@ -165,7 +165,7 @@ void PPCSubtarget::initSubtargetFeatures(StringRef CPU, StringRef FS) {
-
- if ((TargetTriple.isOSFreeBSD() && TargetTriple.getOSMajorVersion() >= 13) ||
- TargetTriple.isOSNetBSD() || TargetTriple.isOSOpenBSD() ||
-- TargetTriple.isMusl())
-+ isTargetLinux())
- SecurePlt = true;
-
- if (HasSPE && IsPPC64)
diff --git a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch b/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
deleted file mode 100644
index 51d0e4b31b32c3..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-004-override-opt.patch
+++ /dev/null
@@ -1,18 +0,0 @@
-This allows us to override the optimization level as not all platforms can
-deal with -O3.
-
---- a/llvm/CMakeLists.txt
-+++ b/llvm/CMakeLists.txt
-@@ -918,6 +918,12 @@ if( MINGW AND NOT "${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang" )
- llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "-O2")
- endif()
-
-+set(VOID_CXX_OPT_FLAGS "" CACHE STRING "Optimization level to use")
-+
-+if (NOT VOID_CXX_OPT_FLAGS STREQUAL "")
-+ llvm_replace_compiler_option(CMAKE_CXX_FLAGS_RELEASE "-O3" "${VOID_CXX_OPT_FLAGS}")
-+endif()
-+
- # Put this before tblgen. Else we have a circular dependence.
- add_subdirectory(lib/Demangle)
- add_subdirectory(lib/Support)
diff --git a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
deleted file mode 100644
index d332687b9d9295..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-005-ppc-bigpic.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From f3dbdd49c06bfafc1d6138094cf42889c14d38b6 Mon Sep 17 00:00:00 2001
-From: Samuel Holland <samuel@sholland.org>
-Date: Sun, 3 Nov 2019 10:57:27 -0600
-Subject: [PATCH] [LLVM][PowerPC] Assume BigPIC if no PIC level is specified
-
----
- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp | 2 +-
- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/lib/Target/PowerPC/PPCAsmPrinter.cpp b/lib/Target/PowerPC/PPCAsmPrinter.cpp
-index cce21f32..87ca5f9b 100644
---- a/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
-@@ -520,7 +520,7 @@ void PPCAsmPrinter::EmitTlsCall(const MachineInstr *MI,
-
- // Add 32768 offset to the symbol so we follow up the latest GOT/PLT ABI.
- if (Kind == MCSymbolRefExpr::VK_PLT && Subtarget->isSecurePlt() &&
-- M->getPICLevel() == PICLevel::BigPIC)
-+ M->getPICLevel() != PICLevel::SmallPIC)
- TlsRef = MCBinaryExpr::createAdd(
- TlsRef, MCConstantExpr::create(32768, OutContext), OutContext);
- const MachineOperand &MO = MI->getOperand(2);
-diff --git a/lib/Target/PowerPC/PPCMCInstLower.cpp b/lib/Target/PowerPC/PPCMCInstLower.cpp
-index 5cc180d7..a5b02565 100644
---- a/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-+++ b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
-@@ -117,7 +117,7 @@ static MCOperand GetSymbolRef(const MachineOperand &MO, const MCSymbol *Symbol,
- const MCExpr *Expr = MCSymbolRefExpr::create(Symbol, RefKind, Ctx);
- // If -msecure-plt -fPIC, add 32768 to symbol.
- if (Subtarget->isSecurePlt() && TM.isPositionIndependent() &&
-- M->getPICLevel() == PICLevel::BigPIC &&
-+ M->getPICLevel() != PICLevel::SmallPIC &&
- MO.getTargetFlags() == PPCII::MO_PLT)
- Expr =
- MCBinaryExpr::createAdd(Expr, MCConstantExpr::create(32768, Ctx), Ctx);
diff --git a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch b/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
deleted file mode 100644
index a00abd2166651f..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-006-aarch64-mf_exec.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-Fix failures in AllocationTests/MappedMemoryTest.* on aarch64:
-
- Failing Tests (8):
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.AllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.DuplicateNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.EnabledWrite/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.MultipleAllocAndRelease/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.SuccessiveNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.UnalignedNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroNear/3
- LLVM-Unit :: Support/./SupportTests/AllocationTests/MappedMemoryTest.ZeroSizeNear/3
-
-Upstream-Issue: https://bugs.llvm.org/show_bug.cgi?id=14278#c10
-
---- a/llvm/lib/Support/Unix/Memory.inc
-+++ b/llvm/lib/Support/Unix/Memory.inc
-@@ -58,7 +58,7 @@ static int getPosixProtectionFlags(unsigned Flags) {
- return PROT_READ | PROT_WRITE | PROT_EXEC;
- case llvm::sys::Memory::MF_EXEC:
- #if (defined(__FreeBSD__) || defined(__POWERPC__) || defined (__ppc__) || \
-- defined(_POWER) || defined(_ARCH_PPC))
-+ defined(_POWER) || defined(_ARCH_PPC) || (defined(__linux__) && defined(__aarch64__)))
- // On PowerPC, having an executable page that has no read permission
- // can have unintended consequences. The function InvalidateInstruction-
- // Cache uses instructions dcbf and icbi, both of which are treated by
diff --git a/srcpkgs/llvm12/patches/llvm-gcc13.patch b/srcpkgs/llvm12/patches/llvm-gcc13.patch
deleted file mode 100644
index 6895221b73bb75..00000000000000
--- a/srcpkgs/llvm12/patches/llvm-gcc13.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From ff1681ddb303223973653f7f5f3f3435b48a1983 Mon Sep 17 00:00:00 2001
-From: Sergei Trofimovich <slyich@gmail.com>
-Date: Mon, 23 May 2022 08:03:23 +0100
-Subject: [PATCH] [Support] Add missing <cstdint> header to Signals.h
-
-Without the change llvm build fails on this week's gcc-13 snapshot as:
-
- [ 0%] Building CXX object lib/Support/CMakeFiles/LLVMSupport.dir/Signals.cpp.o
- In file included from llvm/lib/Support/Signals.cpp:14:
- llvm/include/llvm/Support/Signals.h:119:8: error: variable or field 'CleanupOnSignal' declared void
- 119 | void CleanupOnSignal(uintptr_t Context);
- | ^~~~~~~~~~~~~~~
----
- llvm/include/llvm/Support/Signals.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/llvm/include/llvm/Support/Signals.h b/llvm/include/llvm/Support/Signals.h
-index 44f5a750ff5cb0..937e0572d4a725 100644
---- a/llvm/include/llvm/Support/Signals.h
-+++ b/llvm/include/llvm/Support/Signals.h
-@@ -14,6 +14,7 @@
- #ifndef LLVM_SUPPORT_SIGNALS_H
- #define LLVM_SUPPORT_SIGNALS_H
-
-+#include <cstdint>
- #include <string>
-
- namespace llvm {
diff --git a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch b/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
deleted file mode 100644
index 8e0a9a779d1bf8..00000000000000
--- a/srcpkgs/llvm12/patches/ppc32-compiler-rt.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-commit ba4ede595ff9599232f5dd2b4384c243137b53fc
-Author: Daniel Kolesa <daniel@octaforge.org>
-Date: Tue Jun 22 23:40:54 2021 +0200
-
- enable compiler-rt support for ppc32
-
-diff --git a/compiler-rt/cmake/base-config-ix.cmake b/compiler-rt/cmake/base-config-ix.cmake
-index 1edab43..5c0c8a2 100644
---- a/compiler-rt/cmake/base-config-ix.cmake
-+++ b/compiler-rt/cmake/base-config-ix.cmake
-@@ -182,9 +182,7 @@ macro(test_targets)
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc64le")
- test_target_arch(powerpc64le "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "powerpc")
-- if(CMAKE_SYSTEM_NAME MATCHES "AIX")
-- test_target_arch(powerpc "" "-m32")
-- endif()
-+ test_target_arch(powerpc "" "-m32")
- test_target_arch(powerpc64 "" "-m64")
- elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "s390x")
- test_target_arch(s390x "" "")
diff --git a/srcpkgs/llvm12/template b/srcpkgs/llvm12/template
deleted file mode 100644
index 86e86bb96c63f1..00000000000000
--- a/srcpkgs/llvm12/template
+++ /dev/null
@@ -1,161 +0,0 @@
-# Template file for 'llvm12'
-pkgname=llvm12
-version=12.0.1
-revision=4
-build_wrksrc=llvm
-build_style=cmake
-configure_args="
- -DCMAKE_BUILD_TYPE=Release -Wno-dev
- -DENABLE_LINKER_BUILD_ID=YES
- -DLLDB_USE_SYSTEM_SIX=YES
- -DLIBCXX_CXX_ABI=libcxxabi
- -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=YES
- -DLIBCXXABI_USE_LLVM_UNWINDER=YES
- -DLIBCXXABI_ENABLE_STATIC_UNWINDER=YES
- -DLIBOMP_ENABLE_SHARED=YES
- -DLIBOMP_INSTALL_ALIASES=NO
- -DLLVM_INCLUDE_DOCS=YES
- -DLLVM_BUILD_DOCS=YES
- -DLLVM_ENABLE_SPHINX=YES
- -DSPHINX_WARNINGS_AS_ERRORS=NO
- -DLLVM_INSTALL_UTILS=YES
- -DLLVM_BUILD_LLVM_DYLIB=YES
- -DLLVM_LINK_LLVM_DYLIB=YES
- -DLLVM_ENABLE_RTTI=YES
- -DLLVM_ENABLE_FFI=YES
- -DLLVM_BINUTILS_INCDIR=/usr/include"
-hostmakedepends="perl python3 zlib-devel libffi-devel swig python3-Sphinx
- python3-recommonmark python3-sphinx-automodapi"
-makedepends="python3-devel zlib-devel elfutils-devel libffi-devel libedit-devel
- libxml2-devel binutils-devel"
-depends="libllvm12>=${version}_${revision}"
-short_desc="Low Level Virtual Machine"
-maintainer="Orphaned <orphan@voidlinux.org>"
-license="Apache-2.0"
-homepage="https://www.llvm.org"
-distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-project-${version}.src.tar.xz"
-checksum=129cb25cd13677aad951ce5c2deb0fe4afc1e9d98950f53b51bdcfb5a73afa0e
-lib32disabled=yes
-python_version=3
-
-if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
- configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
- makedepends+=" libexecinfo-devel"
- depends+=" libexecinfo-devel"
-fi
-
-# "operand out of range" assembler failures
-case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*) configure_args+=" -DCLANG_ENABLE_CLANGD=OFF" ;;
-esac
-
-post_patch() {
- # update config.guess for better platform detection
- cp $XBPS_COMMONDIR/environment/configure/automake/config.guess \
- ${wrksrc}/llvm/cmake
-
- # fix linker failures on some archs
- vsed -i 's,check_library_exists(gcc_s .*,set(LIBCXXABI_HAS_GCC_S_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
- vsed -i 's,check_library_exists(gcc .*,set(LIBCXXABI_HAS_GCC_LIB ON),' \
- ${wrksrc}/libcxxabi/cmake/config-ix.cmake
-
- # need libssp_nonshared on some musl platforms (because of nodefaultlibs)
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- ppc*-musl|i686-musl|mips*-musl)
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libunwind/src/CMakeLists.txt
- vsed -i 's,^# Setup flags.$,add_library_flags(ssp_nonshared),' \
- ${wrksrc}/libcxxabi/src/CMakeLists.txt
- vsed -i 's,#ssp,,' ${wrksrc}/libcxx/CMakeLists.txt
- ;;
- 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
- ;;
- esac
-}
-
-pre_configure() {
- local triplet
-
- # Vastly reduce size of debugging symbols:
- CFLAGS=${CFLAGS/ -g/ -g1}
- CXXFLAGS=${CXXFLAGS/ -g/ -g1}
-
- # since gcc9, the build likes to blow up for ppc32 apparently because
- # of clang being too large for a 24-bit relative call to the PLT, so
- # optimize for size instead
- case "$XBPS_TARGET_MACHINE" in
- ppc64*) ;;
- mips*-musl|ppc*) configure_args+=" -DVOID_CXX_OPT_FLAGS=-Os" ;;
- esac
-
- if [ "$CROSS_BUILD" ]; then
- msg_normal "Building host tblgen\n"
- mkdir -p build/HOST
- cd build/HOST
- CC="$BUILD_CC" CXX="$BUILD_CXX" CFLAGS="$BUILD_CFLAGS" \
- CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
- cmake ../.. -DCMAKE_BUILD_TYPE=Release
- make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
- [ "$_lldb_enable" = "yes" ] && make ${makejobs} -C tools/lldb/utils/TableGen
- configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/llvm/build/HOST/bin/clang-tblgen"
- cd ../..
- fi
-
- case "$XBPS_TARGET_MACHINE" in
- i686*) _arch="X86";;
- x86_64*) _arch="X86";;
- armv5*) _arch="Armv5te";;
- armv6*) _arch="Armv6";;
- armv7*) _arch="Armv7";;
- aarch64*) _arch="AArch64";;
- mips*) _arch="Mips";;
- ppc*) _arch="PowerPC";;
- riscv64*) _arch="RISCV64";;
- esac
-
- triplet=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}
-
- configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
- configure_args+=" -DLLVM_HOST_TRIPLE=${triplet}"
- configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${triplet}"
-}
-
-do_install() {
- cd build
- cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
-
- # Required for multilib.
- if [ "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
- for _header in llvm-config; do
- mv ${DESTDIR}/usr/include/llvm/Config/${_header}{,-64}.h
- vinstall ${FILESDIR}/llvm-Config-${_header}.h 644 \
- usr/include/llvm/Config ${_header}.h
- done
- fi
-
- # Remove llvm-config-host in cross builds.
- if [ "$CROSS_BUILD" ]; then
- rm -f ${DESTDIR}/usr/bin/llvm-config-host
- fi
-}
-
-libllvm12_package() {
- short_desc+=" - runtime library"
- pkg_install() {
- vmove "usr/lib/libLLVM-*.so*"
- }
-}
diff --git a/srcpkgs/llvm12/update b/srcpkgs/llvm12/update
deleted file mode 100644
index e95cf26b3586b7..00000000000000
--- a/srcpkgs/llvm12/update
+++ /dev/null
@@ -1,3 +0,0 @@
-site="https://github.com/llvm/llvm-project/releases"
-pattern="llvmorg-\K(\d+.){2}\d+(-rc\d+)?"
-ignore="*-rc*"
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index e729b51bfc267d..e2bf28e8cb2db3 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
# Template file for 'removed-packages'
pkgname=removed-packages
-version=0.1.20240727
+version=0.1.20240729
revision=1
build_style=meta
short_desc="Uninstalls packages removed from repository"
@@ -376,6 +376,7 @@ replaces="
libgroff<=1.22.4_3
libgtkhtml<=4.10.0_1
libkscreen<=5.27.11_3
+ libllvm12<=12.0.1_4
libllvm10<=10.0.0_8
libllvm11<=11.0.0_2
libllvm15<=15.0.7_4
@@ -440,6 +441,7 @@ replaces="
lldb-devel<=15.0.7_3
lldb15-devel<=15.0.7_4
lldb15<=15.0.7_4
+ llvm12<=12.0.1_4
llvm10<=10.0.0_8
llvm11<=11.0.0_2
llvm15<=15.0.7_4
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Merged]: remove llvm12
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
` (13 preceding siblings ...)
2024-07-31 17:45 ` Calandracas606
@ 2024-07-31 18:13 ` classabbyamp
14 siblings, 0 replies; 16+ messages in thread
From: classabbyamp @ 2024-07-31 18:13 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1246 bytes --]
There's a merged pull request on the void-packages repository
remove llvm12
https://github.com/void-linux/void-packages/pull/51186
Description:
- **mozjs102: build with llvm18**
- **ghdl: update to 4.1.0.**
- **llvm12: remove package**
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
#### Local build testing
- I built this PR locally for my native architecture, x86_64
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- x86_64-musl
- i686
- aarch64 (cross)
- aarch64-musl (cross)
- armv7l (cross)
- armv7l-musl (cross)
- armv6l (cross)
- armv6l-musl (cross)
^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2024-07-31 18:13 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-07-10 3:07 [PR PATCH] remove llvm12 Calandracas606
2024-07-10 3:10 ` [PR REVIEW] " Calandracas606
2024-07-10 3:12 ` Calandracas606
2024-07-10 4:17 ` Calandracas606
2024-07-29 8:40 ` tranzystorekk
2024-07-29 12:00 ` [PR PATCH] [Updated] " Calandracas606
2024-07-29 12:01 ` Calandracas606
2024-07-30 19:41 ` [PR REVIEW] " classabbyamp
2024-07-30 19:41 ` classabbyamp
2024-07-30 20:38 ` [PR PATCH] [Updated] " Calandracas606
2024-07-30 20:39 ` Calandracas606
2024-07-30 20:42 ` [PR REVIEW] " Calandracas606
2024-07-31 17:43 ` [PR PATCH] [Updated] " Calandracas606
2024-07-31 17:44 ` Calandracas606
2024-07-31 17:45 ` Calandracas606
2024-07-31 18:13 ` [PR PATCH] [Merged]: " classabbyamp
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).