* [PR PATCH] LLVM/Clang 10
@ 2020-05-08 19:29 q66
2020-05-08 19:57 ` [PR PATCH] [Updated] " q66
` (14 more replies)
0 siblings, 15 replies; 16+ messages in thread
From: q66 @ 2020-05-08 19:29 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 964 bytes --]
There is a new pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [ ] afl (x86 only, need help)
- [ ] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [ ] hfsprogs
- [ ] godot
- [ ] firefox
- [ ] firefox-esr
- [ ] thunderbird
- [ ] bat
- [ ] blender
- [ ] ardour
- [ ] pijul
- [ ] qv4l2
- [ ] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 64702 bytes --]
From 8cf3b4be27a68182c605f6d3225906c574af47df Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 288 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 191 +-----------
26 files changed, 496 insertions(+), 213 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..fd0c0b38d8a
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,288 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+disable_parallel_builds=yes
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..7692cb2540c 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,15 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
disable_parallel_builds=yes
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +37,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +59,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +101,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 751508b717fa3d86ce96e937468a3878c7abdf14 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 88e6590289d4a4e5e6687a7a1b84c87178cd7864 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 2119606fac5963b4079455cd2d02c12cb7f10564 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From 81e0873638ef7d762ba83f7acb53df0d8deaddbb Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From 8cbfaa91146a65a758338e9a3be0fc7dcd5c8688 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From e72dced3d170d6a18c584514221a92b830cd6a7d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From d97da6eeda8c3437022a94cdbc446c92e15ddedf Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 2405026d8e1d11339206390d33f95744d186a4c0 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 6b7e046009f3132c0b816d9dd013d912b1adf582 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From e5c9106e44b32f1d52d90d6a43305f560cf4c016 Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 033298a765360231148c7b40bfd73279b58051dd Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: update to 0.10.0
---
srcpkgs/bpftrace/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 28a1db1a12f..e830e1f0df3 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -1,6 +1,6 @@
# Template file for 'bpftrace'
pkgname=bpftrace
-version=0.9.4
+version=0.10.0
revision=1
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
@@ -11,7 +11,7 @@ maintainer="Leah Neukirchen <leah@vuxu.org>"
license="Apache-2.0"
homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
-checksum=6f978d27cb44f69776f477dada420a70bb0a366123140f33be193ba5e752c5af
+checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
post_install() {
# clashes with bcc-tools anyway
From 4bc40a280a0b52b1a09d67151dc26b4b69fd5da3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 867c8b43d6285a0bd85fec72df09fe33613b45a9 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From bfbc6d85eb20279cf1c3ac2afb82fc42d1fd7ffe Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From 5abf74b251a3b2f7250701e7e36e8432636de810 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From ba54060963c72a0706f9d5602cf54b03013d3d35 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From 67182338a036ddf5eff47f35d4153620e020676b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From fa7555e33f2c447ad7ac652a45a24825feecea26 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From 09a8fd901fd5190412e316a35dd7486de768c6dd Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From ce48f8f665322fc36f492d3d45b1efdbca147699 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 2994d65380f8f393c4a7e33049e8f032c2dd2c53 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 6e1d0ef7c05a97d67346d2c0799cc892d13e1b03 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
srcpkgs/beignet/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..a06fd40dc12 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,7 +1,7 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
+revision=7
archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
From fde7849538b1de22958923611920ed261a43d557 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: rebuild for llvm10
[ci skip]
---
srcpkgs/ispc/template | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..e1de8aaae3f 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,25 @@
# Template file for 'ispc'
pkgname=ispc
version=1.12.0
-revision=2
+revision=3
archs="i686 x86_64"
build_style=cmake
-hostmakedepends="clang python3 m4 bison flex llvm"
configure_args="-DISPC_NO_DUMPS=yes"
+hostmakedepends="clang python3 m4 bison flex llvm"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
-patch_args="-p1"
checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+patch_args="-p1"
nopie=yes
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
@ 2020-05-08 19:57 ` q66
2020-05-08 20:05 ` q66
` (13 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 19:57 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 969 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [ ] afl (x86 only, need help)
- [ ] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [ ] godot
- [ ] firefox
- [ ] firefox-esr
- [ ] thunderbird
- [ ] bat
- [ ] blender
- [ ] ardour
- [ ] pijul
- [ ] qv4l2
- [ ] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 77828 bytes --]
From 8cf3b4be27a68182c605f6d3225906c574af47df Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 288 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 191 +-----------
26 files changed, 496 insertions(+), 213 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..fd0c0b38d8a
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,288 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+disable_parallel_builds=yes
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..7692cb2540c 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,15 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
disable_parallel_builds=yes
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +37,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +59,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +101,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 751508b717fa3d86ce96e937468a3878c7abdf14 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 88e6590289d4a4e5e6687a7a1b84c87178cd7864 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 2119606fac5963b4079455cd2d02c12cb7f10564 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From 81e0873638ef7d762ba83f7acb53df0d8deaddbb Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From 8cbfaa91146a65a758338e9a3be0fc7dcd5c8688 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From e72dced3d170d6a18c584514221a92b830cd6a7d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From d97da6eeda8c3437022a94cdbc446c92e15ddedf Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 2405026d8e1d11339206390d33f95744d186a4c0 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 6b7e046009f3132c0b816d9dd013d912b1adf582 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From e5c9106e44b32f1d52d90d6a43305f560cf4c016 Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 033298a765360231148c7b40bfd73279b58051dd Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: update to 0.10.0
---
srcpkgs/bpftrace/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 28a1db1a12f..e830e1f0df3 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -1,6 +1,6 @@
# Template file for 'bpftrace'
pkgname=bpftrace
-version=0.9.4
+version=0.10.0
revision=1
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
@@ -11,7 +11,7 @@ maintainer="Leah Neukirchen <leah@vuxu.org>"
license="Apache-2.0"
homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
-checksum=6f978d27cb44f69776f477dada420a70bb0a366123140f33be193ba5e752c5af
+checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
post_install() {
# clashes with bcc-tools anyway
From 4bc40a280a0b52b1a09d67151dc26b4b69fd5da3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 867c8b43d6285a0bd85fec72df09fe33613b45a9 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From bfbc6d85eb20279cf1c3ac2afb82fc42d1fd7ffe Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From 5abf74b251a3b2f7250701e7e36e8432636de810 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From ba54060963c72a0706f9d5602cf54b03013d3d35 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From 67182338a036ddf5eff47f35d4153620e020676b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From fa7555e33f2c447ad7ac652a45a24825feecea26 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From 09a8fd901fd5190412e316a35dd7486de768c6dd Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From ce48f8f665322fc36f492d3d45b1efdbca147699 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 2994d65380f8f393c4a7e33049e8f032c2dd2c53 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 04cb90529552ece3208c94ef55d37c299d7cc75d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
srcpkgs/beignet/patches/llvm10.patch | 347 +++++++++++++++++++++++++++
srcpkgs/beignet/template | 2 +-
2 files changed, 348 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..a06fd40dc12 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,7 +1,7 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
+revision=7
archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
From caca33581950f3e2b50cfb69394674185ebbafd0 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: rebuild for llvm10
[ci skip]
---
srcpkgs/ispc/template | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..e1de8aaae3f 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,25 @@
# Template file for 'ispc'
pkgname=ispc
version=1.12.0
-revision=2
+revision=3
archs="i686 x86_64"
build_style=cmake
-hostmakedepends="clang python3 m4 bison flex llvm"
configure_args="-DISPC_NO_DUMPS=yes"
+hostmakedepends="clang python3 m4 bison flex llvm"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
-patch_args="-p1"
checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+patch_args="-p1"
nopie=yes
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
2020-05-08 19:57 ` [PR PATCH] [Updated] " q66
@ 2020-05-08 20:05 ` q66
2020-05-08 20:32 ` q66
` (12 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 20:05 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 969 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [ ] afl (x86 only, need help)
- [ ] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [ ] godot
- [ ] firefox
- [ ] firefox-esr
- [ ] thunderbird
- [ ] bat
- [ ] blender
- [ ] ardour
- [ ] pijul
- [ ] qv4l2
- [ ] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 77897 bytes --]
From 8cf3b4be27a68182c605f6d3225906c574af47df Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 288 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 191 +-----------
26 files changed, 496 insertions(+), 213 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..fd0c0b38d8a
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,288 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+disable_parallel_builds=yes
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..7692cb2540c 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,15 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
disable_parallel_builds=yes
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +37,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +59,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +101,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 751508b717fa3d86ce96e937468a3878c7abdf14 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 88e6590289d4a4e5e6687a7a1b84c87178cd7864 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 2119606fac5963b4079455cd2d02c12cb7f10564 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From 81e0873638ef7d762ba83f7acb53df0d8deaddbb Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From 8cbfaa91146a65a758338e9a3be0fc7dcd5c8688 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From e72dced3d170d6a18c584514221a92b830cd6a7d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From d97da6eeda8c3437022a94cdbc446c92e15ddedf Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 2405026d8e1d11339206390d33f95744d186a4c0 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 6b7e046009f3132c0b816d9dd013d912b1adf582 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From e5c9106e44b32f1d52d90d6a43305f560cf4c016 Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From a2b4b126b08863a51d8d00afb4e3f016dcb5f5ac Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: update to 0.10.0
---
srcpkgs/bpftrace/template | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 28a1db1a12f..b556a6d6c8b 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -1,7 +1,8 @@
# Template file for 'bpftrace'
pkgname=bpftrace
-version=0.9.4
+version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -11,7 +12,7 @@ maintainer="Leah Neukirchen <leah@vuxu.org>"
license="Apache-2.0"
homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
-checksum=6f978d27cb44f69776f477dada420a70bb0a366123140f33be193ba5e752c5af
+checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
post_install() {
# clashes with bcc-tools anyway
From ff2ad642cce4382c9f5278badb1756e0099ae07f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 414ae3757492df2286f6f0d681adf59743f74e85 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From 68d06e609c525928830639aa6317736151155358 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From d1048d3caa677fe0cd29d5b14330855f0f13a38a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From 3e79f5508a26dd045f947ec74c8b8076eeef3518 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From c3c6c1949b6b75e707583499e3b9c5d39cbe37de Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From eb66fef86c557349c91c3b64507a7983b1c0324f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From d92c36afb1747f8eda541dde6c6a9f16cd66e3f1 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From 8bdabcf1bb8d43c50a712359a67db2a5da3ba50b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 437b913c8cdf0f87da531f7aa57be44e0fdd9c45 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 0c05ceed965d010a75de40d1663c63e07d6db67e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
srcpkgs/beignet/patches/llvm10.patch | 347 +++++++++++++++++++++++++++
srcpkgs/beignet/template | 2 +-
2 files changed, 348 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..a06fd40dc12 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,7 +1,7 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
+revision=7
archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
From cda44659795e58fafb142fe1bf0cc04c52e33142 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: rebuild for llvm10
[ci skip]
---
srcpkgs/ispc/template | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..e1de8aaae3f 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,25 @@
# Template file for 'ispc'
pkgname=ispc
version=1.12.0
-revision=2
+revision=3
archs="i686 x86_64"
build_style=cmake
-hostmakedepends="clang python3 m4 bison flex llvm"
configure_args="-DISPC_NO_DUMPS=yes"
+hostmakedepends="clang python3 m4 bison flex llvm"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
-patch_args="-p1"
checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+patch_args="-p1"
nopie=yes
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
2020-05-08 19:57 ` [PR PATCH] [Updated] " q66
2020-05-08 20:05 ` q66
@ 2020-05-08 20:32 ` q66
2020-05-08 20:37 ` q66
` (11 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 20:32 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 969 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [ ] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [ ] godot
- [ ] firefox
- [ ] firefox-esr
- [ ] thunderbird
- [x] bat
- [ ] blender
- [ ] ardour
- [ ] pijul
- [ ] qv4l2
- [ ] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 79083 bytes --]
From 8cf3b4be27a68182c605f6d3225906c574af47df Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 288 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 191 +-----------
26 files changed, 496 insertions(+), 213 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..fd0c0b38d8a
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,288 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+disable_parallel_builds=yes
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..7692cb2540c 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,15 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
disable_parallel_builds=yes
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +37,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +59,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +101,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 751508b717fa3d86ce96e937468a3878c7abdf14 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 88e6590289d4a4e5e6687a7a1b84c87178cd7864 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 2119606fac5963b4079455cd2d02c12cb7f10564 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From 81e0873638ef7d762ba83f7acb53df0d8deaddbb Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From 8cbfaa91146a65a758338e9a3be0fc7dcd5c8688 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From e72dced3d170d6a18c584514221a92b830cd6a7d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From d97da6eeda8c3437022a94cdbc446c92e15ddedf Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 2405026d8e1d11339206390d33f95744d186a4c0 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 6b7e046009f3132c0b816d9dd013d912b1adf582 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From e5c9106e44b32f1d52d90d6a43305f560cf4c016 Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From a2b4b126b08863a51d8d00afb4e3f016dcb5f5ac Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: update to 0.10.0
---
srcpkgs/bpftrace/template | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 28a1db1a12f..b556a6d6c8b 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -1,7 +1,8 @@
# Template file for 'bpftrace'
pkgname=bpftrace
-version=0.9.4
+version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -11,7 +12,7 @@ maintainer="Leah Neukirchen <leah@vuxu.org>"
license="Apache-2.0"
homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
-checksum=6f978d27cb44f69776f477dada420a70bb0a366123140f33be193ba5e752c5af
+checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
post_install() {
# clashes with bcc-tools anyway
From ff2ad642cce4382c9f5278badb1756e0099ae07f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 414ae3757492df2286f6f0d681adf59743f74e85 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From 68d06e609c525928830639aa6317736151155358 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From d1048d3caa677fe0cd29d5b14330855f0f13a38a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From 3e79f5508a26dd045f947ec74c8b8076eeef3518 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From c3c6c1949b6b75e707583499e3b9c5d39cbe37de Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From eb66fef86c557349c91c3b64507a7983b1c0324f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From d92c36afb1747f8eda541dde6c6a9f16cd66e3f1 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From 8bdabcf1bb8d43c50a712359a67db2a5da3ba50b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 437b913c8cdf0f87da531f7aa57be44e0fdd9c45 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 5fc6bf58f7dfad81cad9e5676378e4c49fef9ede Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
.../patches/{llvm6.patch => llvm06.patch} | 0
.../patches/{llvm8.patch => llvm08.patch} | 0
.../patches/{llvm9.patch => llvm09.patch} | 0
srcpkgs/beignet/patches/llvm10.patch | 347 ++++++++++++++++++
srcpkgs/beignet/template | 4 +-
5 files changed, 349 insertions(+), 2 deletions(-)
rename srcpkgs/beignet/patches/{llvm6.patch => llvm06.patch} (100%)
rename srcpkgs/beignet/patches/{llvm8.patch => llvm08.patch} (100%)
rename srcpkgs/beignet/patches/{llvm9.patch => llvm09.patch} (100%)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm6.patch b/srcpkgs/beignet/patches/llvm06.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm6.patch
rename to srcpkgs/beignet/patches/llvm06.patch
diff --git a/srcpkgs/beignet/patches/llvm8.patch b/srcpkgs/beignet/patches/llvm08.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm8.patch
rename to srcpkgs/beignet/patches/llvm08.patch
diff --git a/srcpkgs/beignet/patches/llvm9.patch b/srcpkgs/beignet/patches/llvm09.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm9.patch
rename to srcpkgs/beignet/patches/llvm09.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..130aa57d790 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,8 +1,8 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
-archs="i686* x86_64*"
+revision=7
+#archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
hostmakedepends="clang llvm pkg-config"
From 59e9cd9341b6054ea4e4b716b6c5f5ad17671f15 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: rebuild for llvm10
[ci skip]
---
srcpkgs/ispc/template | 19 ++++++++++++-------
1 file changed, 12 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..0c15a9193c9 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,26 @@
# Template file for 'ispc'
pkgname=ispc
-version=1.12.0
-revision=2
-archs="i686 x86_64"
+version=1.13.0
+revision=1
+archs="i686 x86_64 armv[67] aarch64"
build_style=cmake
-hostmakedepends="clang python3 m4 bison flex llvm"
configure_args="-DISPC_NO_DUMPS=yes"
+hostmakedepends="clang python3 m4 bison flex llvm"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
+checksum=cc74c4c490ddf4e0a63f01948ec8d6eb575d85ab5932d30ca4ad01c0e8f079ce
patch_args="-p1"
-checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+nocross=yes
nopie=yes
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (2 preceding siblings ...)
2020-05-08 20:32 ` q66
@ 2020-05-08 20:37 ` q66
2020-05-08 20:38 ` q66
` (10 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 20:37 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 969 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [ ] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [ ] godot
- [ ] firefox
- [ ] firefox-esr
- [ ] thunderbird
- [x] bat
- [ ] blender
- [ ] ardour
- [ ] pijul
- [ ] qv4l2
- [ ] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 79054 bytes --]
From 216bd8dd5421528241df72b0d362773c32a064c0 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 287 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 192 +-----------
26 files changed, 495 insertions(+), 214 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..8fe09a332b2
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,287 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..75d9c8aed7d 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,14 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
-disable_parallel_builds=yes
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +36,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +58,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +100,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 468170103da2d06c4747897ef11689bed4e6fa67 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From c1a9de087bc01bf24aa7337b58e4345c48d1eda4 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 7a67564487e05e4fb1f916848283ff61033b9d1e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From badac271270b4d581da75d9fc409584ff7b7f20f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From c1eab95b8eb3c26e339aa62618af95f40c7bab93 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From dd1d72ea6dc4c47bad1e79ad103e94d651dffa85 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From e1ac9934d38654c41e1db50dd457870173ff7ecc Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 6c4ab14b5d2a4fcbcfb10ab086beec76507e177a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 91211593e0af3e6605d57d96841ef41a3bef90e9 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From 733de234b7a1b3182ad198a8959bb9978c981612 Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 47ddd9f411f8b05f53d0a6c2f4b8767ca0a407a3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: update to 0.10.0
---
srcpkgs/bpftrace/template | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 28a1db1a12f..b556a6d6c8b 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -1,7 +1,8 @@
# Template file for 'bpftrace'
pkgname=bpftrace
-version=0.9.4
+version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -11,7 +12,7 @@ maintainer="Leah Neukirchen <leah@vuxu.org>"
license="Apache-2.0"
homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
-checksum=6f978d27cb44f69776f477dada420a70bb0a366123140f33be193ba5e752c5af
+checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
post_install() {
# clashes with bcc-tools anyway
From 9bf0022e3433e45fd572e5704dab90670e112bac Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 79f719865a91acc2e679220ec0dfa2fde96faaa6 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From 967517741087179a773c7238f547a0030883be2f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From e05134ed614a21165360aae4139d89ac61b5465f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From 1f8301085a6fbfd46c7158aa8fffb9b4555e87e1 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From e8ba1c87c54287e2394f957a5a173d7b9e97961a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From 867b69e3af614e486f92ca025a0cab8f7fb20a8a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From e8de46365ccd1fc5c8c7ccd79bdef91fc547aa17 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From 37aa7af818f4ed7ff432d014df4a1a78339b5de4 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 8f3937c4d296f01f66ebe7c2a4093da8711dcf7c Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 07c2403e3cdde82326ab37d32a92400f7755f6c3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
.../patches/{llvm6.patch => llvm06.patch} | 0
.../patches/{llvm8.patch => llvm08.patch} | 0
.../patches/{llvm9.patch => llvm09.patch} | 0
srcpkgs/beignet/patches/llvm10.patch | 347 ++++++++++++++++++
srcpkgs/beignet/template | 4 +-
5 files changed, 349 insertions(+), 2 deletions(-)
rename srcpkgs/beignet/patches/{llvm6.patch => llvm06.patch} (100%)
rename srcpkgs/beignet/patches/{llvm8.patch => llvm08.patch} (100%)
rename srcpkgs/beignet/patches/{llvm9.patch => llvm09.patch} (100%)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm6.patch b/srcpkgs/beignet/patches/llvm06.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm6.patch
rename to srcpkgs/beignet/patches/llvm06.patch
diff --git a/srcpkgs/beignet/patches/llvm8.patch b/srcpkgs/beignet/patches/llvm08.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm8.patch
rename to srcpkgs/beignet/patches/llvm08.patch
diff --git a/srcpkgs/beignet/patches/llvm9.patch b/srcpkgs/beignet/patches/llvm09.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm9.patch
rename to srcpkgs/beignet/patches/llvm09.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..130aa57d790 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,8 +1,8 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
-archs="i686* x86_64*"
+revision=7
+#archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
hostmakedepends="clang llvm pkg-config"
From 5db53fe0d3ec32096d87e359fe63b088f77dd2ec Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: rebuild for llvm10
[ci skip]
---
srcpkgs/ispc/template | 19 ++++++++++++-------
1 file changed, 12 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..0c15a9193c9 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,26 @@
# Template file for 'ispc'
pkgname=ispc
-version=1.12.0
-revision=2
-archs="i686 x86_64"
+version=1.13.0
+revision=1
+archs="i686 x86_64 armv[67] aarch64"
build_style=cmake
-hostmakedepends="clang python3 m4 bison flex llvm"
configure_args="-DISPC_NO_DUMPS=yes"
+hostmakedepends="clang python3 m4 bison flex llvm"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
+checksum=cc74c4c490ddf4e0a63f01948ec8d6eb575d85ab5932d30ca4ad01c0e8f079ce
patch_args="-p1"
-checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+nocross=yes
nopie=yes
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (3 preceding siblings ...)
2020-05-08 20:37 ` q66
@ 2020-05-08 20:38 ` q66
2020-05-08 21:27 ` pullmoll
` (9 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 20:38 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 187 bytes --]
New comment by q66 on void-packages repository
https://github.com/void-linux/void-packages/pull/21756#issuecomment-626009960
Comment:
yeah, that line never had any effect, i removed it
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (4 preceding siblings ...)
2020-05-08 20:38 ` q66
@ 2020-05-08 21:27 ` pullmoll
2020-05-08 21:40 ` [PR PATCH] [Updated] " q66
` (8 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: pullmoll @ 2020-05-08 21:27 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 214 bytes --]
New comment by pullmoll on void-packages repository
https://github.com/void-linux/void-packages/pull/21756#issuecomment-626028658
Comment:
So `bpftrace` no longer supports 32 bit targets. Please rebase that one.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (5 preceding siblings ...)
2020-05-08 21:27 ` pullmoll
@ 2020-05-08 21:40 ` q66
2020-05-08 21:45 ` q66
` (7 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 21:40 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 969 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [x] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [x] godot
- [ ] firefox
- [ ] firefox-esr
- [ ] thunderbird
- [x] bat
- [x] blender
- [x] ardour
- [x] pijul
- [x] qv4l2
- [x] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 79163 bytes --]
From 216bd8dd5421528241df72b0d362773c32a064c0 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 287 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 192 +-----------
26 files changed, 495 insertions(+), 214 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..8fe09a332b2
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,287 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..75d9c8aed7d 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,14 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
-disable_parallel_builds=yes
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +36,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +58,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +100,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 468170103da2d06c4747897ef11689bed4e6fa67 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From c1a9de087bc01bf24aa7337b58e4345c48d1eda4 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 7a67564487e05e4fb1f916848283ff61033b9d1e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From badac271270b4d581da75d9fc409584ff7b7f20f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From c1eab95b8eb3c26e339aa62618af95f40c7bab93 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From dd1d72ea6dc4c47bad1e79ad103e94d651dffa85 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From e1ac9934d38654c41e1db50dd457870173ff7ecc Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 6c4ab14b5d2a4fcbcfb10ab086beec76507e177a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 91211593e0af3e6605d57d96841ef41a3bef90e9 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From 733de234b7a1b3182ad198a8959bb9978c981612 Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 47ddd9f411f8b05f53d0a6c2f4b8767ca0a407a3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: update to 0.10.0
---
srcpkgs/bpftrace/template | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 28a1db1a12f..b556a6d6c8b 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -1,7 +1,8 @@
# Template file for 'bpftrace'
pkgname=bpftrace
-version=0.9.4
+version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -11,7 +12,7 @@ maintainer="Leah Neukirchen <leah@vuxu.org>"
license="Apache-2.0"
homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
-checksum=6f978d27cb44f69776f477dada420a70bb0a366123140f33be193ba5e752c5af
+checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
post_install() {
# clashes with bcc-tools anyway
From 9bf0022e3433e45fd572e5704dab90670e112bac Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 79f719865a91acc2e679220ec0dfa2fde96faaa6 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From 967517741087179a773c7238f547a0030883be2f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From e05134ed614a21165360aae4139d89ac61b5465f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From 1f8301085a6fbfd46c7158aa8fffb9b4555e87e1 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From e8ba1c87c54287e2394f957a5a173d7b9e97961a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From 867b69e3af614e486f92ca025a0cab8f7fb20a8a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From e8de46365ccd1fc5c8c7ccd79bdef91fc547aa17 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From 37aa7af818f4ed7ff432d014df4a1a78339b5de4 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 8f3937c4d296f01f66ebe7c2a4093da8711dcf7c Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 07c2403e3cdde82326ab37d32a92400f7755f6c3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
.../patches/{llvm6.patch => llvm06.patch} | 0
.../patches/{llvm8.patch => llvm08.patch} | 0
.../patches/{llvm9.patch => llvm09.patch} | 0
srcpkgs/beignet/patches/llvm10.patch | 347 ++++++++++++++++++
srcpkgs/beignet/template | 4 +-
5 files changed, 349 insertions(+), 2 deletions(-)
rename srcpkgs/beignet/patches/{llvm6.patch => llvm06.patch} (100%)
rename srcpkgs/beignet/patches/{llvm8.patch => llvm08.patch} (100%)
rename srcpkgs/beignet/patches/{llvm9.patch => llvm09.patch} (100%)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm6.patch b/srcpkgs/beignet/patches/llvm06.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm6.patch
rename to srcpkgs/beignet/patches/llvm06.patch
diff --git a/srcpkgs/beignet/patches/llvm8.patch b/srcpkgs/beignet/patches/llvm08.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm8.patch
rename to srcpkgs/beignet/patches/llvm08.patch
diff --git a/srcpkgs/beignet/patches/llvm9.patch b/srcpkgs/beignet/patches/llvm09.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm9.patch
rename to srcpkgs/beignet/patches/llvm09.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..130aa57d790 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,8 +1,8 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
-archs="i686* x86_64*"
+revision=7
+#archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
hostmakedepends="clang llvm pkg-config"
From bdaf52439d60a447dc6870eb778c96b9164f7b83 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: rebuild for llvm10
[ci skip]
---
srcpkgs/ispc/template | 22 ++++++++++++++++------
1 file changed, 16 insertions(+), 6 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..72decd3d499 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,31 @@
# Template file for 'ispc'
pkgname=ispc
-version=1.12.0
-revision=2
+version=1.13.0
+revision=1
archs="i686 x86_64"
build_style=cmake
+configure_args="-DISPC_NO_DUMPS=ON -DARM_ENABLED=OFF"
hostmakedepends="clang python3 m4 bison flex llvm"
-configure_args="-DISPC_NO_DUMPS=yes"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
+checksum=cc74c4c490ddf4e0a63f01948ec8d6eb575d85ab5932d30ca4ad01c0e8f079ce
patch_args="-p1"
-checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+nocross=yes
nopie=yes
+# hack to make -m32 work so it can build 32-bit target
+case "$XBPS_TARGET_MACHINE" in
+ x86_64) hostmakedepends+=" gcc-multilib";;
+esac
+
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (6 preceding siblings ...)
2020-05-08 21:40 ` [PR PATCH] [Updated] " q66
@ 2020-05-08 21:45 ` q66
2020-05-08 21:49 ` [PR PATCH] [Updated] " q66
` (6 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 21:45 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 324 bytes --]
New comment by q66 on void-packages repository
https://github.com/void-linux/void-packages/pull/21756#issuecomment-626034706
Comment:
the bpftrace change in this PR was done correctly from the start, but then @leahneukirchen did the update and you put your own check on top, so now it conflicts and will need another bump
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (7 preceding siblings ...)
2020-05-08 21:45 ` q66
@ 2020-05-08 21:49 ` q66
2020-05-08 21:49 ` q66
` (5 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 21:49 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 950 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [x] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [x] godot
- [x] firefox
- [ ] firefox-esr
- [x] bat
- [x] blender
- [x] ardour
- [x] pijul
- [x] qv4l2
- [x] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 79151 bytes --]
From ae6db787505047a59d0a4c113fc7dab58cea880b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 287 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 192 +-----------
26 files changed, 495 insertions(+), 214 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..8fe09a332b2
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,287 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..75d9c8aed7d 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,14 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
-disable_parallel_builds=yes
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +36,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +58,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +100,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 96cdeba7fcf9da94562a31ba26f1ec1ba3f132a7 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 77a861fb12195a657fc16e9c2c254de42a7071fc Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 692efdb40a6bc7752dc0938cc439ded803ee0184 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From 253aa78af082759d2fb625620d4a24e62ca2905d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From ec7739598fb1f5ed0ed2b1cf858f0b98de765325 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From 3547624c6a5d41e527c078e46a65a3f598fa3ff2 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From a2a4e5f34238d01ac1e55a13303d958109eda93e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 1e54df5dfe86699a2f1aa4151fbbf7580c953263 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 4aa5f9ddb27f5f442c43f3ceb35ebcd9fc1b094f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From 44a08de87fc498441a1aa96c19ce3bf07131ce3c Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 7536f7d834461fc56ba794e8f1d283400fe27aee Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: update to 0.10.0
---
srcpkgs/bpftrace/template | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 59693fceddb..9ae175bad8c 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -2,6 +2,7 @@
pkgname=bpftrace
version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -13,10 +14,6 @@ homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
-if [ "$XBPS_TARGET_WORDSIZE" != 64 ]; then
- broken="Only 64 bit targets are supported. ${XBPS_TARGET_MACHINE} is ${XBPS_TARGET_WORDSIZE} bit."
-fi
-
post_install() {
# clashes with bcc-tools
rm -rf ${DESTDIR}/usr/share/man
From d70eca52c54b37d5659212a286a4c5eabcadba6d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 6677e2e3610aff17b16832fc4ef8a937fcbc2cd7 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From 056abe6a2eac72682f676df6b72c23308e52f3b3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From 858f103e3a8a9649571ddb2d966607b1503775a4 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From e45e18b4e6d015894d230c37c60f422357eae1ca Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From ededff5c3555e688c394e80e35e901dafd641f93 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From b4df0eb5baaea772d5e4bcb3cd9992d270a995e4 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From fc3e6c31476ae9783b6a8bef7e2e2eb499139687 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From a64e21782bc014b40a846e93e0b545eadb4d38f3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From aacb8a345e8d059e4c46327999e7f99d85d68e6a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From b0444b4c381bb163300815b645f43e846ebc8bba Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
.../patches/{llvm6.patch => llvm06.patch} | 0
.../patches/{llvm8.patch => llvm08.patch} | 0
.../patches/{llvm9.patch => llvm09.patch} | 0
srcpkgs/beignet/patches/llvm10.patch | 347 ++++++++++++++++++
srcpkgs/beignet/template | 4 +-
5 files changed, 349 insertions(+), 2 deletions(-)
rename srcpkgs/beignet/patches/{llvm6.patch => llvm06.patch} (100%)
rename srcpkgs/beignet/patches/{llvm8.patch => llvm08.patch} (100%)
rename srcpkgs/beignet/patches/{llvm9.patch => llvm09.patch} (100%)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm6.patch b/srcpkgs/beignet/patches/llvm06.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm6.patch
rename to srcpkgs/beignet/patches/llvm06.patch
diff --git a/srcpkgs/beignet/patches/llvm8.patch b/srcpkgs/beignet/patches/llvm08.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm8.patch
rename to srcpkgs/beignet/patches/llvm08.patch
diff --git a/srcpkgs/beignet/patches/llvm9.patch b/srcpkgs/beignet/patches/llvm09.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm9.patch
rename to srcpkgs/beignet/patches/llvm09.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..130aa57d790 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,8 +1,8 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
-archs="i686* x86_64*"
+revision=7
+#archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
hostmakedepends="clang llvm pkg-config"
From b478b4305ea899d1d46070fe6ffe209acd01d916 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: rebuild for llvm10
[ci skip]
---
srcpkgs/ispc/template | 22 ++++++++++++++++------
1 file changed, 16 insertions(+), 6 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..72decd3d499 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,31 @@
# Template file for 'ispc'
pkgname=ispc
-version=1.12.0
-revision=2
+version=1.13.0
+revision=1
archs="i686 x86_64"
build_style=cmake
+configure_args="-DISPC_NO_DUMPS=ON -DARM_ENABLED=OFF"
hostmakedepends="clang python3 m4 bison flex llvm"
-configure_args="-DISPC_NO_DUMPS=yes"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
+checksum=cc74c4c490ddf4e0a63f01948ec8d6eb575d85ab5932d30ca4ad01c0e8f079ce
patch_args="-p1"
-checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+nocross=yes
nopie=yes
+# hack to make -m32 work so it can build 32-bit target
+case "$XBPS_TARGET_MACHINE" in
+ x86_64) hostmakedepends+=" gcc-multilib";;
+esac
+
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (8 preceding siblings ...)
2020-05-08 21:49 ` [PR PATCH] [Updated] " q66
@ 2020-05-08 21:49 ` q66
2020-05-08 21:57 ` q66
` (4 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 21:49 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 950 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [x] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [x] godot
- [x] firefox
- [ ] firefox-esr
- [x] bat
- [x] blender
- [x] ardour
- [x] pijul
- [x] qv4l2
- [x] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 79157 bytes --]
From ae6db787505047a59d0a4c113fc7dab58cea880b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 287 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 192 +-----------
26 files changed, 495 insertions(+), 214 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..8fe09a332b2
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,287 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..75d9c8aed7d 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,14 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
-disable_parallel_builds=yes
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +36,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +58,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +100,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 96cdeba7fcf9da94562a31ba26f1ec1ba3f132a7 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 77a861fb12195a657fc16e9c2c254de42a7071fc Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 692efdb40a6bc7752dc0938cc439ded803ee0184 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From 253aa78af082759d2fb625620d4a24e62ca2905d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From ec7739598fb1f5ed0ed2b1cf858f0b98de765325 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From 3547624c6a5d41e527c078e46a65a3f598fa3ff2 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From a2a4e5f34238d01ac1e55a13303d958109eda93e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 1e54df5dfe86699a2f1aa4151fbbf7580c953263 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 4aa5f9ddb27f5f442c43f3ceb35ebcd9fc1b094f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From 44a08de87fc498441a1aa96c19ce3bf07131ce3c Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 98b3a3e10b612ec9a46b04e280b0a892f0189700 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: rebuild against llvm10
---
srcpkgs/bpftrace/template | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 59693fceddb..9ae175bad8c 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -2,6 +2,7 @@
pkgname=bpftrace
version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -13,10 +14,6 @@ homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
-if [ "$XBPS_TARGET_WORDSIZE" != 64 ]; then
- broken="Only 64 bit targets are supported. ${XBPS_TARGET_MACHINE} is ${XBPS_TARGET_WORDSIZE} bit."
-fi
-
post_install() {
# clashes with bcc-tools
rm -rf ${DESTDIR}/usr/share/man
From 5697d85a15b4f2808b8e7fae1264a910a192b53a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 0875b50e3c4ac1b8d0c845ece96e46b54a50e133 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From a86d10772e3855d64b95cb21e06f98a85147e51b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From 138a0aef03b87d7e176b51370c74da7a4a5cbf92 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From 32772baac8df245b562aad2e5e2fcb4326bfeb3e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From f1f67d78c890572e28ee95a95b2bd8904e9f3bfb Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From 3a1af1135358a88297d0a6dffceef57245e2736d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From 65b34375e0344aa48300becf4f18429fe8251aa6 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From 8930deaa6bd5a42798ec6121fff25d48bfcc465e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 399485e380195f54552cf980205a9a54bdcb2221 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 591d1153961d3638acc969aa7e8dc34b703031c3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
.../patches/{llvm6.patch => llvm06.patch} | 0
.../patches/{llvm8.patch => llvm08.patch} | 0
.../patches/{llvm9.patch => llvm09.patch} | 0
srcpkgs/beignet/patches/llvm10.patch | 347 ++++++++++++++++++
srcpkgs/beignet/template | 4 +-
5 files changed, 349 insertions(+), 2 deletions(-)
rename srcpkgs/beignet/patches/{llvm6.patch => llvm06.patch} (100%)
rename srcpkgs/beignet/patches/{llvm8.patch => llvm08.patch} (100%)
rename srcpkgs/beignet/patches/{llvm9.patch => llvm09.patch} (100%)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm6.patch b/srcpkgs/beignet/patches/llvm06.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm6.patch
rename to srcpkgs/beignet/patches/llvm06.patch
diff --git a/srcpkgs/beignet/patches/llvm8.patch b/srcpkgs/beignet/patches/llvm08.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm8.patch
rename to srcpkgs/beignet/patches/llvm08.patch
diff --git a/srcpkgs/beignet/patches/llvm9.patch b/srcpkgs/beignet/patches/llvm09.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm9.patch
rename to srcpkgs/beignet/patches/llvm09.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..130aa57d790 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,8 +1,8 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
-archs="i686* x86_64*"
+revision=7
+#archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
hostmakedepends="clang llvm pkg-config"
From c903c488897ab0d5a070cda69f99f13232d91c07 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: rebuild for llvm10
[ci skip]
---
srcpkgs/ispc/template | 22 ++++++++++++++++------
1 file changed, 16 insertions(+), 6 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..72decd3d499 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,31 @@
# Template file for 'ispc'
pkgname=ispc
-version=1.12.0
-revision=2
+version=1.13.0
+revision=1
archs="i686 x86_64"
build_style=cmake
+configure_args="-DISPC_NO_DUMPS=ON -DARM_ENABLED=OFF"
hostmakedepends="clang python3 m4 bison flex llvm"
-configure_args="-DISPC_NO_DUMPS=yes"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
+checksum=cc74c4c490ddf4e0a63f01948ec8d6eb575d85ab5932d30ca4ad01c0e8f079ce
patch_args="-p1"
-checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+nocross=yes
nopie=yes
+# hack to make -m32 work so it can build 32-bit target
+case "$XBPS_TARGET_MACHINE" in
+ x86_64) hostmakedepends+=" gcc-multilib";;
+esac
+
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (9 preceding siblings ...)
2020-05-08 21:49 ` q66
@ 2020-05-08 21:57 ` q66
2020-05-08 22:15 ` q66
` (3 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 21:57 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 950 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [x] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [x] godot
- [x] firefox
- [ ] firefox-esr
- [x] bat
- [x] blender
- [x] ardour
- [x] pijul
- [x] qv4l2
- [x] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 79155 bytes --]
From ae6db787505047a59d0a4c113fc7dab58cea880b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 287 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 192 +-----------
26 files changed, 495 insertions(+), 214 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..8fe09a332b2
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,287 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..75d9c8aed7d 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,14 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
-disable_parallel_builds=yes
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +36,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +58,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +100,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 96cdeba7fcf9da94562a31ba26f1ec1ba3f132a7 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 77a861fb12195a657fc16e9c2c254de42a7071fc Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 692efdb40a6bc7752dc0938cc439ded803ee0184 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From 253aa78af082759d2fb625620d4a24e62ca2905d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From ec7739598fb1f5ed0ed2b1cf858f0b98de765325 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From 3547624c6a5d41e527c078e46a65a3f598fa3ff2 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From a2a4e5f34238d01ac1e55a13303d958109eda93e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 1e54df5dfe86699a2f1aa4151fbbf7580c953263 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 4aa5f9ddb27f5f442c43f3ceb35ebcd9fc1b094f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From 44a08de87fc498441a1aa96c19ce3bf07131ce3c Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 98b3a3e10b612ec9a46b04e280b0a892f0189700 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: rebuild against llvm10
---
srcpkgs/bpftrace/template | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 59693fceddb..9ae175bad8c 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -2,6 +2,7 @@
pkgname=bpftrace
version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -13,10 +14,6 @@ homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
-if [ "$XBPS_TARGET_WORDSIZE" != 64 ]; then
- broken="Only 64 bit targets are supported. ${XBPS_TARGET_MACHINE} is ${XBPS_TARGET_WORDSIZE} bit."
-fi
-
post_install() {
# clashes with bcc-tools
rm -rf ${DESTDIR}/usr/share/man
From 5697d85a15b4f2808b8e7fae1264a910a192b53a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 0875b50e3c4ac1b8d0c845ece96e46b54a50e133 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From a86d10772e3855d64b95cb21e06f98a85147e51b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From 138a0aef03b87d7e176b51370c74da7a4a5cbf92 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From 32772baac8df245b562aad2e5e2fcb4326bfeb3e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From f1f67d78c890572e28ee95a95b2bd8904e9f3bfb Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From 3a1af1135358a88297d0a6dffceef57245e2736d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From 65b34375e0344aa48300becf4f18429fe8251aa6 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From 8930deaa6bd5a42798ec6121fff25d48bfcc465e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 399485e380195f54552cf980205a9a54bdcb2221 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 591d1153961d3638acc969aa7e8dc34b703031c3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
.../patches/{llvm6.patch => llvm06.patch} | 0
.../patches/{llvm8.patch => llvm08.patch} | 0
.../patches/{llvm9.patch => llvm09.patch} | 0
srcpkgs/beignet/patches/llvm10.patch | 347 ++++++++++++++++++
srcpkgs/beignet/template | 4 +-
5 files changed, 349 insertions(+), 2 deletions(-)
rename srcpkgs/beignet/patches/{llvm6.patch => llvm06.patch} (100%)
rename srcpkgs/beignet/patches/{llvm8.patch => llvm08.patch} (100%)
rename srcpkgs/beignet/patches/{llvm9.patch => llvm09.patch} (100%)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm6.patch b/srcpkgs/beignet/patches/llvm06.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm6.patch
rename to srcpkgs/beignet/patches/llvm06.patch
diff --git a/srcpkgs/beignet/patches/llvm8.patch b/srcpkgs/beignet/patches/llvm08.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm8.patch
rename to srcpkgs/beignet/patches/llvm08.patch
diff --git a/srcpkgs/beignet/patches/llvm9.patch b/srcpkgs/beignet/patches/llvm09.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm9.patch
rename to srcpkgs/beignet/patches/llvm09.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..130aa57d790 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,8 +1,8 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
-archs="i686* x86_64*"
+revision=7
+#archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
hostmakedepends="clang llvm pkg-config"
From e173d98cd7bad873dccdfca1bda8bdf9b3f68fe3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: update to 1.13.0
[ci skip]
---
srcpkgs/ispc/template | 22 ++++++++++++++++------
1 file changed, 16 insertions(+), 6 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..72decd3d499 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,31 @@
# Template file for 'ispc'
pkgname=ispc
-version=1.12.0
-revision=2
+version=1.13.0
+revision=1
archs="i686 x86_64"
build_style=cmake
+configure_args="-DISPC_NO_DUMPS=ON -DARM_ENABLED=OFF"
hostmakedepends="clang python3 m4 bison flex llvm"
-configure_args="-DISPC_NO_DUMPS=yes"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
+checksum=cc74c4c490ddf4e0a63f01948ec8d6eb575d85ab5932d30ca4ad01c0e8f079ce
patch_args="-p1"
-checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+nocross=yes
nopie=yes
+# hack to make -m32 work so it can build 32-bit target
+case "$XBPS_TARGET_MACHINE" in
+ x86_64) hostmakedepends+=" gcc-multilib";;
+esac
+
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (10 preceding siblings ...)
2020-05-08 21:57 ` q66
@ 2020-05-08 22:15 ` q66
2020-05-08 22:32 ` q66
` (2 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 22:15 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 950 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [x] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [x] godot
- [x] firefox
- [x] firefox-esr
- [x] bat
- [x] blender
- [x] ardour
- [x] pijul
- [x] qv4l2
- [x] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 79338 bytes --]
From ae6db787505047a59d0a4c113fc7dab58cea880b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 287 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 192 +-----------
26 files changed, 495 insertions(+), 214 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..8fe09a332b2
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,287 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..75d9c8aed7d 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,14 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
-disable_parallel_builds=yes
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +36,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +58,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +100,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 96cdeba7fcf9da94562a31ba26f1ec1ba3f132a7 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 77a861fb12195a657fc16e9c2c254de42a7071fc Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 692efdb40a6bc7752dc0938cc439ded803ee0184 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From 253aa78af082759d2fb625620d4a24e62ca2905d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From ec7739598fb1f5ed0ed2b1cf858f0b98de765325 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From 3547624c6a5d41e527c078e46a65a3f598fa3ff2 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From a2a4e5f34238d01ac1e55a13303d958109eda93e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 1e54df5dfe86699a2f1aa4151fbbf7580c953263 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 4aa5f9ddb27f5f442c43f3ceb35ebcd9fc1b094f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From 44a08de87fc498441a1aa96c19ce3bf07131ce3c Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 98b3a3e10b612ec9a46b04e280b0a892f0189700 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: rebuild against llvm10
---
srcpkgs/bpftrace/template | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 59693fceddb..9ae175bad8c 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -2,6 +2,7 @@
pkgname=bpftrace
version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -13,10 +14,6 @@ homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
-if [ "$XBPS_TARGET_WORDSIZE" != 64 ]; then
- broken="Only 64 bit targets are supported. ${XBPS_TARGET_MACHINE} is ${XBPS_TARGET_WORDSIZE} bit."
-fi
-
post_install() {
# clashes with bcc-tools
rm -rf ${DESTDIR}/usr/share/man
From 5697d85a15b4f2808b8e7fae1264a910a192b53a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 0875b50e3c4ac1b8d0c845ece96e46b54a50e133 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From a86d10772e3855d64b95cb21e06f98a85147e51b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From 138a0aef03b87d7e176b51370c74da7a4a5cbf92 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From 32772baac8df245b562aad2e5e2fcb4326bfeb3e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From f1f67d78c890572e28ee95a95b2bd8904e9f3bfb Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From 3a1af1135358a88297d0a6dffceef57245e2736d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From 65b34375e0344aa48300becf4f18429fe8251aa6 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From 8930deaa6bd5a42798ec6121fff25d48bfcc465e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 399485e380195f54552cf980205a9a54bdcb2221 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 591d1153961d3638acc969aa7e8dc34b703031c3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
.../patches/{llvm6.patch => llvm06.patch} | 0
.../patches/{llvm8.patch => llvm08.patch} | 0
.../patches/{llvm9.patch => llvm09.patch} | 0
srcpkgs/beignet/patches/llvm10.patch | 347 ++++++++++++++++++
srcpkgs/beignet/template | 4 +-
5 files changed, 349 insertions(+), 2 deletions(-)
rename srcpkgs/beignet/patches/{llvm6.patch => llvm06.patch} (100%)
rename srcpkgs/beignet/patches/{llvm8.patch => llvm08.patch} (100%)
rename srcpkgs/beignet/patches/{llvm9.patch => llvm09.patch} (100%)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm6.patch b/srcpkgs/beignet/patches/llvm06.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm6.patch
rename to srcpkgs/beignet/patches/llvm06.patch
diff --git a/srcpkgs/beignet/patches/llvm8.patch b/srcpkgs/beignet/patches/llvm08.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm8.patch
rename to srcpkgs/beignet/patches/llvm08.patch
diff --git a/srcpkgs/beignet/patches/llvm9.patch b/srcpkgs/beignet/patches/llvm09.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm9.patch
rename to srcpkgs/beignet/patches/llvm09.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..130aa57d790 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,8 +1,8 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
-archs="i686* x86_64*"
+revision=7
+#archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
hostmakedepends="clang llvm pkg-config"
From f514b2b969d939b1154beff3d996ad67e67c7f7d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: update to 1.13.0
[ci skip]
---
srcpkgs/ispc/template | 29 +++++++++++++++++++++++------
1 file changed, 23 insertions(+), 6 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..6069ed3c72d 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,38 @@
# Template file for 'ispc'
pkgname=ispc
-version=1.12.0
-revision=2
+version=1.13.0
+revision=1
archs="i686 x86_64"
build_style=cmake
+configure_args="-DISPC_NO_DUMPS=ON -DARM_ENABLED=OFF"
hostmakedepends="clang python3 m4 bison flex llvm"
-configure_args="-DISPC_NO_DUMPS=yes"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
+checksum=cc74c4c490ddf4e0a63f01948ec8d6eb575d85ab5932d30ca4ad01c0e8f079ce
patch_args="-p1"
-checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+nocross=yes
nopie=yes
+# hack to make -m32 work so it can build 32-bit target
+case "$XBPS_TARGET_MACHINE" in
+ x86_64) hostmakedepends+=" gcc-multilib";;
+esac
+
+post_extract() {
+ # skip 64-bit targets on 32-bit hosts
+ if [ "$XBPS_TARGET_WORDSIZE" = "32" ]; then
+ vsed -i 's,bit 32 64,bit 32,' cmake/GenerateBuiltins.cmake
+ fi
+}
+
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (11 preceding siblings ...)
2020-05-08 22:15 ` q66
@ 2020-05-08 22:32 ` q66
2020-05-08 22:51 ` q66
2020-05-08 23:31 ` [PR PATCH] [Merged]: " q66
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 22:32 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 950 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [x] beignet (x86 only, need hlep)
- [ ] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [x] godot
- [x] firefox
- [x] firefox-esr
- [x] bat
- [x] blender
- [x] ardour
- [x] pijul
- [x] qv4l2
- [x] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 79190 bytes --]
From ae6db787505047a59d0a4c113fc7dab58cea880b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
srcpkgs/llvm10/template | 287 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
srcpkgs/llvm9/template | 192 +-----------
26 files changed, 495 insertions(+), 214 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..8fe09a332b2
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,287 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..75d9c8aed7d 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,14 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
-disable_parallel_builds=yes
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +36,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +58,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +100,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From 96cdeba7fcf9da94562a31ba26f1ec1ba3f132a7 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 77a861fb12195a657fc16e9c2c254de42a7071fc Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From 692efdb40a6bc7752dc0938cc439ded803ee0184 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From 253aa78af082759d2fb625620d4a24e62ca2905d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From ec7739598fb1f5ed0ed2b1cf858f0b98de765325 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From 3547624c6a5d41e527c078e46a65a3f598fa3ff2 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From a2a4e5f34238d01ac1e55a13303d958109eda93e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 1e54df5dfe86699a2f1aa4151fbbf7580c953263 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From 4aa5f9ddb27f5f442c43f3ceb35ebcd9fc1b094f Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From 44a08de87fc498441a1aa96c19ce3bf07131ce3c Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 98b3a3e10b612ec9a46b04e280b0a892f0189700 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: rebuild against llvm10
---
srcpkgs/bpftrace/template | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 59693fceddb..9ae175bad8c 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -2,6 +2,7 @@
pkgname=bpftrace
version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -13,10 +14,6 @@ homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
-if [ "$XBPS_TARGET_WORDSIZE" != 64 ]; then
- broken="Only 64 bit targets are supported. ${XBPS_TARGET_MACHINE} is ${XBPS_TARGET_WORDSIZE} bit."
-fi
-
post_install() {
# clashes with bcc-tools
rm -rf ${DESTDIR}/usr/share/man
From 5697d85a15b4f2808b8e7fae1264a910a192b53a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From 0875b50e3c4ac1b8d0c845ece96e46b54a50e133 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From a86d10772e3855d64b95cb21e06f98a85147e51b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From 138a0aef03b87d7e176b51370c74da7a4a5cbf92 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From 32772baac8df245b562aad2e5e2fcb4326bfeb3e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From f1f67d78c890572e28ee95a95b2bd8904e9f3bfb Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From 3a1af1135358a88297d0a6dffceef57245e2736d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From 65b34375e0344aa48300becf4f18429fe8251aa6 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From 8930deaa6bd5a42798ec6121fff25d48bfcc465e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From 399485e380195f54552cf980205a9a54bdcb2221 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 591d1153961d3638acc969aa7e8dc34b703031c3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
.../patches/{llvm6.patch => llvm06.patch} | 0
.../patches/{llvm8.patch => llvm08.patch} | 0
.../patches/{llvm9.patch => llvm09.patch} | 0
srcpkgs/beignet/patches/llvm10.patch | 347 ++++++++++++++++++
srcpkgs/beignet/template | 4 +-
5 files changed, 349 insertions(+), 2 deletions(-)
rename srcpkgs/beignet/patches/{llvm6.patch => llvm06.patch} (100%)
rename srcpkgs/beignet/patches/{llvm8.patch => llvm08.patch} (100%)
rename srcpkgs/beignet/patches/{llvm9.patch => llvm09.patch} (100%)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm6.patch b/srcpkgs/beignet/patches/llvm06.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm6.patch
rename to srcpkgs/beignet/patches/llvm06.patch
diff --git a/srcpkgs/beignet/patches/llvm8.patch b/srcpkgs/beignet/patches/llvm08.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm8.patch
rename to srcpkgs/beignet/patches/llvm08.patch
diff --git a/srcpkgs/beignet/patches/llvm9.patch b/srcpkgs/beignet/patches/llvm09.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm9.patch
rename to srcpkgs/beignet/patches/llvm09.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..130aa57d790 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,8 +1,8 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
-archs="i686* x86_64*"
+revision=7
+#archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
hostmakedepends="clang llvm pkg-config"
From 9b8c2d5f369968f7922e16df5b31db686ca6931e Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: update to 1.13.0, limit to x86_64
[ci skip]
---
srcpkgs/ispc/template | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..b9160d5664a 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,31 @@
# Template file for 'ispc'
pkgname=ispc
-version=1.12.0
-revision=2
-archs="i686 x86_64"
+version=1.13.0
+revision=1
+archs="x86_64"
build_style=cmake
+configure_args="-DISPC_NO_DUMPS=ON -DARM_ENABLED=OFF"
hostmakedepends="clang python3 m4 bison flex llvm"
-configure_args="-DISPC_NO_DUMPS=yes"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
+checksum=cc74c4c490ddf4e0a63f01948ec8d6eb575d85ab5932d30ca4ad01c0e8f079ce
patch_args="-p1"
-checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+nocross=yes
nopie=yes
+# hack to make -m32 work so it can build 32-bit target
+case "$XBPS_TARGET_MACHINE" in
+ x86_64) hostmakedepends+=" gcc-multilib";;
+esac
+
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Updated] LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (12 preceding siblings ...)
2020-05-08 22:32 ` q66
@ 2020-05-08 22:51 ` q66
2020-05-08 23:31 ` [PR PATCH] [Merged]: " q66
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 22:51 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 950 bytes --]
There is an updated pull request by q66 against master on the void-packages repository
https://github.com/void-ppc/void-packages llvm10
https://github.com/void-linux/void-packages/pull/21756
LLVM/Clang 10
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [x] beignet (x86 only, need hlep)
- [x] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [x] godot
- [x] firefox
- [x] firefox-esr
- [x] bat
- [x] blender
- [x] ardour
- [x] pijul
- [x] qv4l2
- [x] yosys
A patch file from https://github.com/void-linux/void-packages/pull/21756.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-llvm10-21756.patch --]
[-- Type: text/x-diff, Size: 83150 bytes --]
From ba2da2853366e0692c38565126f6d2a651c15471 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:06:28 +0200
Subject: [PATCH 01/24] New package: llvm10-10.0.0, rebuild llvm9 standalone
---
common/shlibs | 7 +-
srcpkgs/clang | 2 +-
srcpkgs/clang-analyzer | 2 +-
| 2 +-
srcpkgs/libllvm10 | 1 +
srcpkgs/lld | 2 +-
srcpkgs/lld-devel | 2 +-
srcpkgs/lldb | 2 +-
srcpkgs/lldb-devel | 2 +-
srcpkgs/llvm10/files/llvm-Config-config.h | 9 +
.../llvm10/files/llvm-Config-llvm-config.h | 9 +
...clang-001-fix-unwind-chain-inclusion.patch | 0
.../clang/clang-002-add-musl-triples.patch | 0
.../clang-003-ppc64-dynamic-linker-path.patch | 0
.../clang/clang-004-ppc64-musl-elfv2.patch | 15 +-
.../compiler-rt/compiler-rt-armv5.patch | 11 +
.../files/patches/lldb/musl.patch | 0
.../files/patches/llvm/llvm-001-musl.patch | 58 ++++
.../llvm/llvm-002-musl-ppc64-elfv2.patch | 26 ++
.../patches/llvm/llvm-003-secureplt.patch | 11 +
.../patches/llvm/llvm-004-override-opt.patch | 18 ++
.../patches/llvm/llvm-005-ppc-bigpic.patch | 38 +++
.../llvm/llvm-006-aarch64-mf_exec.patch | 25 ++
srcpkgs/llvm10/template | 287 ++++++++++++++++++
srcpkgs/llvm10/update | 2 +
.../compiler-rt/compiler-rt-armv5.patch | 11 -
.../llvm/llvm-007-aarch64-mf_exec.patch | 25 ++
srcpkgs/llvm9/template | 192 +-----------
28 files changed, 545 insertions(+), 214 deletions(-)
create mode 120000 srcpkgs/libllvm10
create mode 100644 srcpkgs/llvm10/files/llvm-Config-config.h
create mode 100644 srcpkgs/llvm10/files/llvm-Config-llvm-config.h
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-002-add-musl-triples.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch (100%)
rename srcpkgs/{llvm9 => llvm10}/files/patches/clang/clang-004-ppc64-musl-elfv2.patch (63%)
create mode 100644 srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
rename srcpkgs/{llvm9 => llvm10}/files/patches/lldb/musl.patch (100%)
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
create mode 100644 srcpkgs/llvm10/files/patches/llvm/llvm-006-aarch64-mf_exec.patch
create mode 100644 srcpkgs/llvm10/template
create mode 100644 srcpkgs/llvm10/update
delete mode 100644 srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
create mode 100644 srcpkgs/llvm9/files/patches/llvm/llvm-007-aarch64-mf_exec.patch
diff --git a/common/shlibs b/common/shlibs
index fa8af66f925..8342e117092 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1026,9 +1026,10 @@ libuchardet.so.0 uchardet-0.0.6_1
libgtksourceviewmm-3.0.so.0 gtksourceviewmm-3.2.0_1
libyajl.so.2 yajl-2.0.1_1
libconfuse.so.2 confuse-3.2.1_1
-liblldb.so.9 lldb-9.0.0_1
-libclang.so.9 clang-9.0.0_1
-libclang-cpp.so.9 clang-9.0.0_1
+liblldb.so.10 lldb-10.0.0_1
+libclang.so.10 clang-10.0.0_1
+libclang-cpp.so.10 clang-10.0.0_1
+libLLVM-10.so libllvm10-10.0.0_1
libLLVM-9.so libllvm9-9.0.0_1
libisofs.so.6 libisofs-0.6.24_1
libmpack.so.0 libmpack-1.0.5_1
diff --git a/srcpkgs/clang b/srcpkgs/clang
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang
+++ b/srcpkgs/clang
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/clang-analyzer b/srcpkgs/clang-analyzer
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-analyzer
+++ b/srcpkgs/clang-analyzer
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
--git a/srcpkgs/clang-tools-extra b/srcpkgs/clang-tools-extra
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/clang-tools-extra
+++ b/srcpkgs/clang-tools-extra
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/libllvm10 b/srcpkgs/libllvm10
new file mode 120000
index 00000000000..59f26575cb3
--- /dev/null
+++ b/srcpkgs/libllvm10
@@ -0,0 +1 @@
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld b/srcpkgs/lld
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld
+++ b/srcpkgs/lld
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lld-devel b/srcpkgs/lld-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lld-devel
+++ b/srcpkgs/lld-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb b/srcpkgs/lldb
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb
+++ b/srcpkgs/lldb
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/lldb-devel b/srcpkgs/lldb-devel
index 14540d7bad2..59f26575cb3 120000
--- a/srcpkgs/lldb-devel
+++ b/srcpkgs/lldb-devel
@@ -1 +1 @@
-llvm9
\ No newline at end of file
+llvm10
\ No newline at end of file
diff --git a/srcpkgs/llvm10/files/llvm-Config-config.h b/srcpkgs/llvm10/files/llvm-Config-config.h
new file mode 100644
index 00000000000..c369b4551f7
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-config.h
@@ -0,0 +1,9 @@
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 32
+#include "config-32.h"
+#elif __WORDSIZE == 64
+#include "config-64.h"
+#else
+#error "Unknown word size"
+#endif
diff --git a/srcpkgs/llvm10/files/llvm-Config-llvm-config.h b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
new file mode 100644
index 00000000000..2fa08c9be69
--- /dev/null
+++ b/srcpkgs/llvm10/files/llvm-Config-llvm-config.h
@@ -0,0 +1,9 @@
+#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/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch b/srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-001-fix-unwind-chain-inclusion.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch b/srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-002-add-musl-triples.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-002-add-musl-triples.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch b/srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-003-ppc64-dynamic-linker-path.patch
diff --git a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
similarity index 63%
rename from srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
rename to srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
index 14dfc007ed3..f1af1b79b5f 100644
--- a/srcpkgs/llvm9/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
+++ b/srcpkgs/llvm10/files/patches/clang/clang-004-ppc64-musl-elfv2.patch
@@ -1,26 +1,29 @@
--- a/lib/Basic/Targets/PPC.h
+++ b/lib/Basic/Targets/PPC.h
-@@ -376,11 +376,11 @@ public:
+@@ -386,11 +386,10 @@ public:
if ((Triple.getArch() == llvm::Triple::ppc64le)) {
resetDataLayout("e-m:e-i64:64-n32:64");
- ABI = "elfv2";
} else {
resetDataLayout("E-m:e-i64:64-n32:64");
-- ABI = Triple.getEnvironment() == llvm::Triple::ELFv2 ? "elfv2" : "elfv1";
+- ABI = "elfv1";
}
-+ /* default to elfv2 always, ignore llvm's elfv2 triples */
+ ABI = "elfv2";
if (Triple.getOS() == llvm::Triple::AIX)
SuitableAlign = 64;
--- a/lib/Driver/ToolChains/Clang.cpp
+++ b/lib/Driver/ToolChains/Clang.cpp
-@@ -1804,7 +1804,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+@@ -1918,11 +1918,7 @@ void Clang::AddPPCTargetArgs(const ArgList &Args,
+ ABIName = "elfv1-qpx";
break;
}
-
-- ABIName = "elfv1";
+-
+- if (T.isMusl() || (T.isOSFreeBSD() && T.getOSMajorVersion() >= 13))
+- ABIName = "elfv2";
+- else
+- ABIName = "elfv1";
+ ABIName = "elfv2";
break;
}
diff --git a/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
new file mode 100644
index 00000000000..893dd244c5b
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/compiler-rt/compiler-rt-armv5.patch
@@ -0,0 +1,11 @@
+--- compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
++++ compiler-rt-10.0.0.src/lib/builtins/CMakeLists.txt
+@@ -428,8 +428,6 @@
+ )
+ set(arm_Thumb1_SOURCES
+ ${arm_Thumb1_JT_SOURCES}
+- ${arm_Thumb1_SjLj_EH_SOURCES}
+- ${arm_Thumb1_VFPv2_SOURCES}
+ ${arm_Thumb1_icache_SOURCES}
+ )
+
diff --git a/srcpkgs/llvm9/files/patches/lldb/musl.patch b/srcpkgs/llvm10/files/patches/lldb/musl.patch
similarity index 100%
rename from srcpkgs/llvm9/files/patches/lldb/musl.patch
rename to srcpkgs/llvm10/files/patches/lldb/musl.patch
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
new file mode 100644
index 00000000000..a0eddbf58be
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-001-musl.patch
@@ -0,0 +1,58 @@
+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 e0a1ee3..465b65a 100644
+--- a/include/llvm/Analysis/TargetLibraryInfo.h
++++ b/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;
+
+diff --git a/utils/unittest/googletest/src/gtest.cc b/utils/unittest/googletest/src/gtest.cc
+index 5780764..1d548c1 100644
+--- a/utils/unittest/googletest/src/gtest.cc
++++ b/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
+--
+2.5.1
+
+--- a/lib/Support/Unix/DynamicLibrary.inc
++++ b/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/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
new file mode 100644
index 00000000000..1ff8aaa239c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-002-musl-ppc64-elfv2.patch
@@ -0,0 +1,26 @@
+This patches LLVM to use ELFv2 on ppc64 uncoditionally unless overridden. We
+need this because unlike most distros we use ELFv2 for both glibc and musl
+on big endian ppc64.
+
+--- a/lib/Target/PowerPC/PPCTargetMachine.cpp
++++ b/lib/Target/PowerPC/PPCTargetMachine.cpp
+@@ -213,9 +213,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;
+ }
+--- a/test/CodeGen/PowerPC/ppc64-elf-abi.ll
++++ b/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/llvm10/files/patches/llvm/llvm-003-secureplt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
new file mode 100644
index 00000000000..fcbaba86335
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-003-secureplt.patch
@@ -0,0 +1,11 @@
+--- llvm/lib/Target/PowerPC/PPCSubtarget.cpp
++++ llvm/lib/Target/PowerPC/PPCSubtarget.cpp
+@@ -150,7 +150,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/llvm10/files/patches/llvm/llvm-004-override-opt.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
new file mode 100644
index 00000000000..30d1e14e193
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-004-override-opt.patch
@@ -0,0 +1,18 @@
+This allows us to override the optimization level as not all platforms can
+deal with -O3.
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -893,6 +893,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/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
new file mode 100644
index 00000000000..4e0045d97d3
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-005-ppc-bigpic.patch
@@ -0,0 +1,38 @@
+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/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp b/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+index 269b84b4e8d..03246a5242c 100644
+--- llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
++++ llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
+@@ -488,7 +488,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/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp b/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+index 027e6bd1ba0..ae461f4eea9 100644
+--- llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
++++ llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
+@@ -116,7 +116,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);
+--
+2.23.0
diff --git a/srcpkgs/llvm10/files/patches/llvm/llvm-006-aarch64-mf_exec.patch b/srcpkgs/llvm10/files/patches/llvm/llvm-006-aarch64-mf_exec.patch
new file mode 100644
index 00000000000..a64a317ee6c
--- /dev/null
+++ b/srcpkgs/llvm10/files/patches/llvm/llvm-006-aarch64-mf_exec.patch
@@ -0,0 +1,25 @@
+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/lib/Support/Unix/Memory.inc
++++ b/lib/Support/Unix/Memory.inc
+@@ -59,7 +59,7 @@
+ 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/llvm10/template b/srcpkgs/llvm10/template
new file mode 100644
index 00000000000..8fe09a332b2
--- /dev/null
+++ b/srcpkgs/llvm10/template
@@ -0,0 +1,287 @@
+# Template file for 'llvm10'
+pkgname=llvm10
+version=10.0.0
+revision=1
+wrksrc="llvm-${version}.src"
+build_style=cmake
+configure_args="
+ -DCMAKE_BUILD_TYPE=Release
+ -DLLVM_INSTALL_UTILS=ON
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_ENABLE_RTTI=ON
+ -DLLVM_ENABLE_FFI=ON
+ -DLLVM_BINUTILS_INCDIR=/usr/include"
+hostmakedepends="groff perl python3 zlib-devel libffi-devel swig"
+makedepends="python3-devel zlib-devel libffi-devel libedit-devel
+ libxml2-devel binutils-devel libatomic-devel"
+depends="libllvm10"
+short_desc="Low Level Virtual Machine"
+maintainer="q66 <daniel@octaforge.org>"
+license="NCSA"
+homepage="https://www.llvm.org"
+distfiles="
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
+checksum="
+ df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf
+ dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135
+ b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708
+ 885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21
+ acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c
+ 6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75"
+lib32disabled=yes
+python_version=3
+
+_lldb_enable=yes
+
+if [ "$CROSS_BUILD" ]; then
+ _lldb_enable=no
+fi
+
+case "$XBPS_TARGET_MACHINE" in
+ ppc64le*) ;;
+ ppc*) _lldb_enable=no ;;
+esac
+
+subpackages="clang-tools-extra clang clang-analyzer libllvm10"
+if [ "$_lldb_enable" = "yes" ]; then
+ # XXX fails to cross compile due to python
+ subpackages+=" lldb lldb-devel"
+fi
+subpackages+=" lld lld-devel"
+
+post_patch() {
+ # patches
+ cd ${XBPS_BUILDDIR}/llvm-${version}.src
+ for i in ${FILESDIR}/patches/llvm/llvm-*.patch; do
+ msg_normal "Applying $i to llvm\n"
+ patch -sNp1 -i ${i}
+ done
+
+ cd ${XBPS_BUILDDIR}/clang-${version}.src
+ for i in ${FILESDIR}/patches/clang/clang-*.patch; do
+ msg_normal "Applying $i to clang\n"
+ patch -sNp1 -i ${i}
+ done
+
+ case "$XBPS_TARGET_MACHINE" in
+ armv5*)
+ cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
+ for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
+ msg_normal "Applying $i to compiler-rt\n"
+ patch -sNp1 -i ${i}
+ done
+ ;;
+ esac
+
+ if [ "$_lldb_enable" = "yes" ]; then
+ cd ${XBPS_BUILDDIR}/lldb-${version}.src
+ for i in ${FILESDIR}/patches/lldb/*.patch; do
+ msg_normal "Applying $i to lldb\n"
+ patch -sNp1 -i ${i}
+ done
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
+ esac
+ fi
+
+ # Move clang files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
+ fi
+ # Move clang-tools-extra files into llvm source.
+ if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
+ fi
+ # Move lld files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
+ fi
+ # Move lldb files into the llvm source.
+ if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
+ fi
+ # Move compiler-rt files into the llvm source.
+ if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
+ mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
+ fi
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl)
+ # Disable sanitizers
+ sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
+ ;;
+ esac
+
+}
+
+pre_configure() {
+ # 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
+ ppc|ppc-musl) 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
+ configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
+ configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/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";;
+ esac
+ configure_args+=" -DLLVM_TARGET_ARCH=${_arch}"
+ configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
+}
+
+do_install() {
+ vlicense LICENSE.TXT
+
+ cd build
+ cmake -DCMAKE_INSTALL_PREFIX=${DESTDIR}/usr -P cmake_install.cmake
+
+ # Fix permissions of static libs
+ chmod -x ${DESTDIR}/usr/lib/*.a
+
+ # 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
+}
+
+clang-analyzer_package() {
+ archs=noarch
+ pycompile_dirs="usr/share/scan-view"
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - A source code analysis framework"
+ homepage="https://clang-analyzer.llvm.org/"
+ pkg_install() {
+ vmove usr/share/man/man1/scan-build.1
+ vmove "/usr/bin/scan-*"
+ vmove "/usr/share/scan-*"
+ vmove "/usr/libexec/*analyzer"
+ }
+}
+
+clang-tools-extra_package() {
+ depends="clang-${version}_${revision} python3"
+ short_desc+=" - Extra Clang tools"
+ homepage="https://clang.llvm.org/extra/"
+ pkg_install() {
+ vmove usr/bin/clang-apply-replacements
+ vmove usr/bin/clang-query
+ vmove usr/bin/clang-rename
+ vmove usr/bin/clang-tidy
+ vmove usr/bin/modularize
+ vmove "usr/lib/libclangApplyReplacements*"
+ vmove "usr/lib/libclangQuery*"
+ vmove "usr/lib/libclangTidy*"
+ vmove "usr/share/clang/*tidy*"
+ }
+}
+
+clang_package() {
+ lib32disabled=yes
+ depends="libstdc++-devel libgcc-devel binutils"
+ case "$XBPS_TARGET_MACHINE" in
+ *-musl) depends+=" musl-devel";;
+ *) depends+=" glibc-devel";;
+ esac
+ short_desc+=" - C language family frontend"
+ homepage="https://clang.llvm.org/"
+ pkg_install() {
+ vmove usr/include/clang
+ vmove usr/include/clang-c
+ vmove "usr/bin/*clang*"
+ vmove usr/bin/c-index-test
+ vmove usr/lib/clang
+ vmove usr/lib/cmake/clang
+ vmove "usr/lib/libclang*"
+ vmove "usr/share/clang"
+ }
+}
+
+lld_package() {
+ lib32disabled=yes
+ short_desc+=" - linker"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/bin/lld*
+ vmove usr/bin/wasm-ld
+ vmove usr/bin/ld.lld*
+ }
+}
+
+lld-devel_package() {
+ lib32disabled=yes
+ short_desc+=" - linker - development files"
+ homepage="https://lld.llvm.org"
+ pkg_install() {
+ vmove usr/include/lld
+ vmove "usr/lib/liblld*a"
+ }
+}
+
+lldb_package() {
+ lib32disabled=yes
+ depends+=" python3-six"
+ short_desc+=" - LLDB debugger"
+ homepage="https://lldb.llvm.org/"
+ pkg_install() {
+ vmove usr/bin/*lldb*
+ vmove usr/lib/liblldb*so.*
+ vmove /usr/lib/python*
+ # Depend on python3-six instead of conflicting
+ rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
+ }
+}
+
+lldb-devel_package() {
+ depends="lldb>=${version}_${revision}"
+ short_desc+=" - LLDB debugger - development files"
+ pkg_install() {
+ vmove usr/include/lldb
+ vmove "usr/lib/liblldb*.so"
+ }
+}
+
+libllvm10_package() {
+ short_desc+=" - runtime library"
+ pkg_install() {
+ vmove "usr/lib/libLLVM-*.so*"
+ }
+}
diff --git a/srcpkgs/llvm10/update b/srcpkgs/llvm10/update
new file mode 100644
index 00000000000..3d09eaff373
--- /dev/null
+++ b/srcpkgs/llvm10/update
@@ -0,0 +1,2 @@
+site=https://releases.llvm.org/
+pattern="'\K[\d\.]*(?=')"
diff --git a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch b/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
deleted file mode 100644
index f4d2e341b6c..00000000000
--- a/srcpkgs/llvm9/files/patches/compiler-rt/compiler-rt-armv5.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2019-12-11 20:15:30.000000000 +0100
-+++ compiler-rt-9.0.1.src/lib/builtins/CMakeLists.txt 2020-03-29 07:23:38.172813038 +0200
-@@ -419,8 +419,6 @@
- )
- set(arm_Thumb1_SOURCES
- ${arm_Thumb1_JT_SOURCES}
-- ${arm_Thumb1_SjLj_EH_SOURCES}
-- ${arm_Thumb1_VFPv2_SOURCES}
- ${arm_Thumb1_icache_SOURCES}
- )
-
diff --git a/srcpkgs/llvm9/files/patches/llvm/llvm-007-aarch64-mf_exec.patch b/srcpkgs/llvm9/files/patches/llvm/llvm-007-aarch64-mf_exec.patch
new file mode 100644
index 00000000000..a64a317ee6c
--- /dev/null
+++ b/srcpkgs/llvm9/files/patches/llvm/llvm-007-aarch64-mf_exec.patch
@@ -0,0 +1,25 @@
+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/lib/Support/Unix/Memory.inc
++++ b/lib/Support/Unix/Memory.inc
+@@ -59,7 +59,7 @@
+ 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/llvm9/template b/srcpkgs/llvm9/template
index 350a9d67d16..75d9c8aed7d 100644
--- a/srcpkgs/llvm9/template
+++ b/srcpkgs/llvm9/template
@@ -1,7 +1,7 @@
# Template file for 'llvm9'
pkgname=llvm9
version=9.0.1
-revision=5
+revision=6
wrksrc="llvm-${version}.src"
build_style=cmake
configure_args="
@@ -20,42 +20,14 @@ short_desc="Low Level Virtual Machine"
maintainer="q66 <daniel@octaforge.org>"
license="NCSA"
homepage="https://www.llvm.org"
-distfiles="
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lldb-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/lld-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/clang-tools-extra-${version}.src.tar.xz
- https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/compiler-rt-${version}.src.tar.xz"
-checksum="
- 00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a
- 8a7b9fd795c31a3e3cba6ce1377a2ae5c67376d92888702ce27e26f0971beb09
- 86262bad3e2fd784ba8c5e2158d7aa36f12b85f2515e95bc81d65d75bb9b0c82
- 5778512b2e065c204010f88777d44b95250671103e434f9dc7363ab2e3804253
- b26fd72a78bd7db998a26270ec9ec6a01346651d88fa87b4b323e13049fb6f07
- c2bfab95c9986318318363d7f371a85a95e333bc0b34fbfa52edbd3f5e3a9077"
-disable_parallel_builds=yes
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/llvm-${version}.src.tar.xz"
+checksum="00a1ee1f389f81e9979f3a640a01c431b3021de0d42278f6508391a2f0b81c9a"
lib32disabled=yes
-# necessary to override auto default
python_version=3
-_lldb_enable=yes
+conflicts="llvm10>=0"
-if [ "$CROSS_BUILD" ]; then
- _lldb_enable=no
-fi
-
-case "$XBPS_TARGET_MACHINE" in
- ppc64le*) ;;
- ppc*) _lldb_enable=no ;;
-esac
-
-subpackages="clang-tools-extra clang clang-analyzer libllvm9"
-if [ "$_lldb_enable" = "yes" ]; then
- # XXX fails to cross compile due to python
- subpackages+=" lldb lldb-devel"
-fi
-subpackages+=" lld lld-devel"
+subpackages="libllvm9"
post_patch() {
# patches
@@ -64,61 +36,6 @@ post_patch() {
msg_normal "Applying $i to llvm\n"
patch -sNp1 -i ${i}
done
-
- cd ${XBPS_BUILDDIR}/clang-${version}.src
- for i in ${FILESDIR}/patches/clang/clang-*.patch; do
- msg_normal "Applying $i to clang\n"
- patch -sNp1 -i ${i}
- done
-
- case "$XBPS_TARGET_MACHINE" in
- armv5*)
- cd ${XBPS_BUILDDIR}/compiler-rt-${version}.src
- for i in ${FILESDIR}/patches/compiler-rt/compiler-rt-*.patch; do
- msg_normal "Applying $i to compiler-rt\n"
- patch -sNp1 -i ${i}
- done
- ;;
- esac
-
- if [ "$_lldb_enable" = "yes" ]; then
- cd ${XBPS_BUILDDIR}/lldb-${version}.src
- for i in ${FILESDIR}/patches/lldb/*.patch; do
- msg_normal "Applying $i to lldb\n"
- patch -sNp1 -i ${i}
- done
- case "$XBPS_TARGET_MACHINE" in
- *-musl) sed -i 's|__ptrace_request|int|g' source/Plugins/Process/Linux/NativeProcessLinux.cpp ;;
- esac
- fi
-
- # Move clang files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-${version}.src ${wrksrc}/tools/clang
- fi
- # Move clang-tools-extra files into llvm source.
- if [ -d ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/clang-tools-extra-${version}.src ${wrksrc}/tools/clang/tools/extra
- fi
- # Move lld files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/lld-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lld-${version}.src ${wrksrc}/tools/lld
- fi
- # Move lldb files into the llvm source.
- if [ "$_lldb_enable" = "yes" -a -d ${XBPS_BUILDDIR}/lldb-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/lldb-${version}.src ${wrksrc}/tools/lldb
- fi
- # Move compiler-rt files into the llvm source.
- if [ -d ${XBPS_BUILDDIR}/compiler-rt-${version}.src ]; then
- mv ${XBPS_BUILDDIR}/compiler-rt-${version}.src ${wrksrc}/projects/compiler-rt
- fi
- case "$XBPS_TARGET_MACHINE" in
- *-musl)
- # Disable sanitizers
- sed -i 's/set(COMPILER_RT_HAS_SANITIZER_COMMON TRUE)/set(COMPILER_RT_HAS_SANITIZER_COMMON FALSE)/' ${wrksrc}/projects/compiler-rt/cmake/config-ix.cmake
- ;;
- esac
-
}
pre_configure() {
@@ -141,9 +58,7 @@ pre_configure() {
CXXFLAGS="$BUILD_CXXFLAGS" LDFLAGS="$BUILD_LDFLAGS" \
cmake ../.. -DCMAKE_BUILD_TYPE=Release
make ${makejobs} -C utils/TableGen
- make ${makejobs} -C tools/clang/utils/TableGen
configure_args+=" -DLLVM_TABLEGEN=${wrksrc}/build/HOST/bin/llvm-tblgen"
- configure_args+=" -DCLANG_TABLEGEN=${wrksrc}/build/HOST/bin/clang-tblgen"
cd ../..
fi
@@ -185,103 +100,6 @@ do_install() {
fi
}
-clang-analyzer_package() {
- archs=noarch
- pycompile_dirs="usr/share/scan-view"
- depends="clang-${version}_${revision} python3"
- short_desc+=" - A source code analysis framework"
- homepage="https://clang-analyzer.llvm.org/"
- pkg_install() {
- vmove usr/share/man/man1/scan-build.1
- vmove "/usr/bin/scan-*"
- vmove "/usr/share/scan-*"
- vmove "/usr/libexec/*analyzer"
- }
-}
-
-clang-tools-extra_package() {
- depends="clang-${version}_${revision} python3"
- short_desc+=" - Extra Clang tools"
- homepage="https://clang.llvm.org/extra/"
- pkg_install() {
- vmove usr/bin/clang-apply-replacements
- vmove usr/bin/clang-query
- vmove usr/bin/clang-rename
- vmove usr/bin/clang-tidy
- vmove usr/bin/modularize
- vmove "usr/lib/libclangApplyReplacements*"
- vmove "usr/lib/libclangQuery*"
- vmove "usr/lib/libclangTidy*"
- vmove "usr/share/clang/*tidy*"
- }
-}
-
-clang_package() {
- lib32disabled=yes
- depends="libstdc++-devel libgcc-devel binutils"
- case "$XBPS_TARGET_MACHINE" in
- *-musl) depends+=" musl-devel";;
- *) depends+=" glibc-devel";;
- esac
- short_desc+=" - C language family frontend"
- homepage="https://clang.llvm.org/"
- pkg_install() {
- vmove usr/include/clang
- vmove usr/include/clang-c
- vmove "usr/bin/*clang*"
- vmove usr/bin/c-index-test
- vmove usr/lib/clang
- vmove usr/lib/cmake/clang
- vmove "usr/lib/libclang*"
- vmove "usr/share/clang"
- }
-}
-
-lld_package() {
- lib32disabled=yes
- short_desc+=" - linker"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/bin/lld*
- vmove usr/bin/wasm-ld
- vmove usr/bin/ld.lld*
- }
-}
-
-lld-devel_package() {
- lib32disabled=yes
- short_desc+=" - linker - development files"
- homepage="https://lld.llvm.org"
- pkg_install() {
- vmove usr/include/lld
- vmove "usr/lib/liblld*a"
- }
-}
-
-lldb_package() {
- lib32disabled=yes
- depends+=" python3-six"
- short_desc+=" - LLDB debugger"
- homepage="https://lldb.llvm.org/"
- pkg_install() {
- vmove usr/bin/*lldb*
- vmove usr/lib/liblldb*so.*
- vman tools/lldb/docs/lldb.1
- vmove /usr/lib/python*
- # Depend on python3-six instead of conflicting
- rm ${PKGDESTDIR}/usr/lib/python3*/site-packages/six.py
- }
-}
-
-lldb-devel_package() {
- depends="lldb>=${version}_${revision}"
- short_desc+=" - LLDB debugger - development files"
- pkg_install() {
- vmove usr/include/lldb
- vmove "usr/lib/liblldb*.so"
- }
-}
-
libllvm9_package() {
short_desc+=" - runtime library"
pkg_install() {
From f13338202df73a31e4e42c11464003d39d6b41ba Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:08:58 +0200
Subject: [PATCH 02/24] llvm: update to 10.0.0
---
srcpkgs/llvm/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/llvm/template b/srcpkgs/llvm/template
index fa66bf84444..9878bfcaed2 100644
--- a/srcpkgs/llvm/template
+++ b/srcpkgs/llvm/template
@@ -1,9 +1,9 @@
# Template file for 'llvm'
pkgname=llvm
-version=9.0.1
+version=10.0.0
revision=1
build_style=meta
-depends="llvm9"
+depends="llvm10"
replaces="llvm8>=0 llvm7>=0 llvm6.0>=0 llvm3.9>=0"
short_desc="LLVM meta package"
maintainer="Enno Boland <gottox@voidlinux.org>"
From 67e7aa96a850789f9d0140214b282d1714b933f9 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 05:11:33 +0200
Subject: [PATCH 03/24] rust: switch to llvm9 for now
---
srcpkgs/rust/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rust/template b/srcpkgs/rust/template
index e7421cf4e04..0215eeaf6c5 100644
--- a/srcpkgs/rust/template
+++ b/srcpkgs/rust/template
@@ -12,7 +12,7 @@ _cargo_dist_version=0.41.0
# uploaded to https://alpha.de.repo.voidlinux.org/distfiles/
wrksrc="rustc-${version}-src"
hostmakedepends="cmake curl pkg-config python3 tar"
-makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm"
+makedepends="libffi-devel ncurses-devel libxml2-devel zlib-devel llvm9"
depends="rust-std"
short_desc="Safe, concurrent, practical systems language"
maintainer="Enno Boland <gottox@voidlinux.org>"
@@ -28,7 +28,7 @@ build_options="static_llvm"
_bootstrap_dir="stage0-bootstrap"
if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" cargo llvm"
+ hostmakedepends+=" cargo llvm9"
# These are required for building the buildhost's stage0/1
hostmakedepends+=" libffi-devel libxml2-devel ncurses-devel zlib-devel"
else
From d2023523dd8a6155bd1ff16599c6393ad115c80d Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:13:35 +0200
Subject: [PATCH 04/24] mesa: rebuild against llvm10
---
srcpkgs/mesa/patches/clover-ppc64-cpp14.patch | 13 +++++++++++++
srcpkgs/mesa/template | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
create mode 100644 srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
diff --git a/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
new file mode 100644
index 00000000000..b7eef76959a
--- /dev/null
+++ b/srcpkgs/mesa/patches/clover-ppc64-cpp14.patch
@@ -0,0 +1,13 @@
+LLVM10 headers need C++14, so override the override.
+
+--- meson.build
++++ meson.build
+@@ -730,7 +730,7 @@ if _opencl != 'disabled'
+ #error "AltiVec not enabled"
+ #endif''',
+ name : 'Altivec')
+- clover_cpp_std += ['cpp_std=gnu++11']
++ clover_cpp_std += ['cpp_std=gnu++14']
+ endif
+ else
+ dep_clc = null_dep
diff --git a/srcpkgs/mesa/template b/srcpkgs/mesa/template
index 0d49f2badf4..3f98f454709 100644
--- a/srcpkgs/mesa/template
+++ b/srcpkgs/mesa/template
@@ -1,13 +1,13 @@
# Template file for 'mesa'
pkgname=mesa
version=20.0.6
-revision=1
+revision=2
wrksrc="mesa-${version}"
build_style=meson
configure_args="-Dglvnd=true -Dshared-glapi=true -Dgbm=true -Degl=true
-Dosmesa=gallium -Dgles1=true -Dgles2=true -Dglx=dri -Ddri3=true
-Dlmsensors=true -Dplatforms=x11,drm,$(vopt_if wayland wayland),surfaceless
- -Dllvm=true -Db_lto=false"
+ -Dllvm=true -Db_lto=false -Dcpp_std=gnu++14"
hostmakedepends="gettext flex libxml2-python llvm pkg-config
python3-Mako $(vopt_if wayland 'wayland-protocols wayland-devel')
glslang"
From ffdbf79a468aad348feb187a730c249c3094db6a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:14:15 +0200
Subject: [PATCH 05/24] libclc-git: rebuild with llvm10
---
srcpkgs/libclc-git/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/libclc-git/template b/srcpkgs/libclc-git/template
index 62e010a7128..748ffe98fc8 100644
--- a/srcpkgs/libclc-git/template
+++ b/srcpkgs/libclc-git/template
@@ -1,7 +1,7 @@
# Template file for 'libclc-git'
pkgname=libclc-git
version=20181127
-revision=3
+revision=4
_git_hash=1ecb16dd7d8b8e9151027faab996f27b2ac508e3
wrksrc="libclc-${_git_hash}"
build_style=configure
From 0f298a5deea08f62eebd69b299bf70e62d2b8a02 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:08 +0200
Subject: [PATCH 06/24] qt5: rebuild for llvm10
---
srcpkgs/qt5/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qt5/template b/srcpkgs/qt5/template
index 5f9766ae2f9..5fbeef1f13f 100644
--- a/srcpkgs/qt5/template
+++ b/srcpkgs/qt5/template
@@ -1,7 +1,7 @@
# Template file for 'qt5'
pkgname=qt5
version=5.14.2
-revision=2
+revision=3
wrksrc="qt-everywhere-src-${version}"
build_style=meta
hostmakedepends="cmake clang flex git glib-devel pkg-config
From 0c0571655931bc367569cfef695acb88d145d663 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:33 +0200
Subject: [PATCH 07/24] qtcreator: rebuild for llvm10
---
srcpkgs/qtcreator/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/qtcreator/template b/srcpkgs/qtcreator/template
index fd8ac276547..c7733f69e5a 100644
--- a/srcpkgs/qtcreator/template
+++ b/srcpkgs/qtcreator/template
@@ -1,7 +1,7 @@
# Template file for 'qtcreator'
pkgname=qtcreator
version=4.12.0
-revision=1
+revision=2
wrksrc="qt-creator-opensource-src-${version}"
build_style=qmake
make_install_args="INSTALL_ROOT=\${DESTDIR}/usr"
From 2849b32db5c43e29fd8589dfa5c085f5d1534693 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:49:49 +0200
Subject: [PATCH 08/24] gnome-builder: rebuild for llvm10
---
srcpkgs/gnome-builder/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/gnome-builder/template b/srcpkgs/gnome-builder/template
index 9d715064a19..970d08f3462 100644
--- a/srcpkgs/gnome-builder/template
+++ b/srcpkgs/gnome-builder/template
@@ -1,7 +1,7 @@
# Template file for 'gnome-builder'
pkgname=gnome-builder
version=3.34.1
-revision=3
+revision=4
build_style=meson
configure_args="-Dwith_webkit=true -Dwith_sysprof=true -Dhelp=true"
hostmakedepends="pkg-config appdata-tools desktop-file-utils flex gobject-introspection
From 4a742517c5aeade620c461529229deeea0afdf32 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:08 +0200
Subject: [PATCH 09/24] juCi++: rebuild for llvm10
---
srcpkgs/juCi++/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/juCi++/template b/srcpkgs/juCi++/template
index 73fa7d8b265..2eb45a234b3 100644
--- a/srcpkgs/juCi++/template
+++ b/srcpkgs/juCi++/template
@@ -1,7 +1,7 @@
# Template file for 'juCi++'
pkgname=juCi++
version=1.5.0
-revision=4
+revision=5
_libclangmm_commit="687b9c231d850504ec515acb9ccab73f26c34063"
_tiny_commit="a6773276efdbc322f1abb0159301f5502647eb52"
wrksrc="jucipp-v${version}"
From bdb013d9f3c922d5d2b2899d53e3120722f2acfc Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 06:50:53 +0200
Subject: [PATCH 10/24] kdevelop: rebuild for llvm10
---
srcpkgs/kdevelop/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/kdevelop/template b/srcpkgs/kdevelop/template
index 64dd036e456..198cd546fb1 100644
--- a/srcpkgs/kdevelop/template
+++ b/srcpkgs/kdevelop/template
@@ -1,7 +1,7 @@
# Template file for 'kdevelop'
pkgname=kdevelop
version=5.5.0
-revision=2
+revision=3
build_style=cmake
hostmakedepends="extra-cmake-modules qt5-qmake qt5-host-tools qt5-tools
kcmutils kcoreaddons kdevelop-pg-qt plasma-framework gettext llvm tar which"
From 1e8cac182d2281384221c43dcc75d69ce76813ff Mon Sep 17 00:00:00 2001
From: Renato Aguiar <renato@renatoaguiar.net>
Date: Thu, 7 May 2020 23:43:32 -0700
Subject: [PATCH 11/24] rdedup: orphan, rebuild for llvm10
---
srcpkgs/rdedup/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/rdedup/template b/srcpkgs/rdedup/template
index 14abab6a85a..94cb523fab2 100644
--- a/srcpkgs/rdedup/template
+++ b/srcpkgs/rdedup/template
@@ -1,13 +1,13 @@
# Template file for 'rdedup'
pkgname=rdedup
version=3.1.1
-revision=3
+revision=4
wrksrc=rdedup-rdedup-v${version}
build_style=cargo
hostmakedepends="pkg-config clang"
makedepends="libressl-devel liblzma-devel libsodium-devel"
short_desc="Data deduplication engine"
-maintainer="Renato Aguiar <renato@renag.me>"
+maintainer="Orphaned <orphan@voidlinux.org>"
license="MPL-2.0"
homepage="https://github.com/dpc/rdedup"
distfiles="https://github.com/dpc/rdedup/archive/rdedup-v${version}.tar.gz"
From 81aa08f55c0547a4790a0feb50fb908ffd19c2a1 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:38 +0200
Subject: [PATCH 12/24] bpftrace: rebuild against llvm10
---
srcpkgs/bpftrace/template | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/srcpkgs/bpftrace/template b/srcpkgs/bpftrace/template
index 59693fceddb..9ae175bad8c 100644
--- a/srcpkgs/bpftrace/template
+++ b/srcpkgs/bpftrace/template
@@ -2,6 +2,7 @@
pkgname=bpftrace
version=0.10.0
revision=1
+archs="x86_64* aarch64* ppc64*"
build_style=cmake
configure_args="-DBUILD_TESTING=OFF" # needs root to run
hostmakedepends="pkg-config flex"
@@ -13,10 +14,6 @@ homepage="https://github.com/iovisor/bpftrace/"
distfiles="https://github.com/iovisor/bpftrace/archive/v${version}.tar.gz"
checksum=50ea80c0e337c4aaa260911e013b92ae09bdd5a062b23eb748290409bc2844db
-if [ "$XBPS_TARGET_WORDSIZE" != 64 ]; then
- broken="Only 64 bit targets are supported. ${XBPS_TARGET_MACHINE} is ${XBPS_TARGET_WORDSIZE} bit."
-fi
-
post_install() {
# clashes with bcc-tools
rm -rf ${DESTDIR}/usr/share/man
From 797914f8f23f57e86756c98481e09e7c01584001 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:02:53 +0200
Subject: [PATCH 13/24] rtags: rebuild for llvm10
---
srcpkgs/rtags/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/rtags/template b/srcpkgs/rtags/template
index e1806c3f924..dc7ee5ed9e9 100644
--- a/srcpkgs/rtags/template
+++ b/srcpkgs/rtags/template
@@ -1,7 +1,7 @@
# Template file for 'rtags'
pkgname=rtags
version=2.38
-revision=1
+revision=2
build_style=cmake
# Don't run tests in do_install, please.
configure_args="-DSKIP_CTEST=TRUE"
From a30584b66c7ba14c5d44f134a7039debc4d6f5b4 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:03:08 +0200
Subject: [PATCH 14/24] shiboken2: rebuild for llvm10
---
srcpkgs/shiboken2/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/shiboken2/template b/srcpkgs/shiboken2/template
index a4ce57e01fe..7b2174aa66b 100644
--- a/srcpkgs/shiboken2/template
+++ b/srcpkgs/shiboken2/template
@@ -1,7 +1,7 @@
# Template file for 'shiboken2'
pkgname=shiboken2
version=5.14.1
-revision=1
+revision=2
_pkgname="pyside-setup-opensource-src-${version}"
wrksrc="$_pkgname"
configure_args="-DUSE_PYTHON_VERSION=3 -DCMAKE_INSTALL_PREFIX=/usr
From 43f633ec5e4c641338fde47ce4d5e4d905455464 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 18:12:42 +0200
Subject: [PATCH 15/24] codelite: rebuild for llvm10
---
srcpkgs/codelite/template | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/codelite/template b/srcpkgs/codelite/template
index 0db46a091d9..a2a09d79fa1 100644
--- a/srcpkgs/codelite/template
+++ b/srcpkgs/codelite/template
@@ -1,12 +1,13 @@
# Template file for 'codelite'
pkgname=codelite
version=13.0
-revision=2
+revision=3
+archs="i686* x86_64* ppc64le*"
build_style=cmake
configure_args="-DWITH_PCH=0
$(vopt_if sftp -DENABLE_SFTP=1)
$(vopt_if lldb -DENABLE_LLDB=1)"
-hostmakedepends="pkg-config clang"
+hostmakedepends="pkg-config clang which"
makedepends="gtk+3-devel wxWidgets-gtk3-devel sqlite-devel
$(vopt_if lldb lldb-devel) $(vopt_if hunspell hunspell-devel)
$(vopt_if mysql libmariadbclient-devel) $(vopt_if sftp libssh-devel)"
@@ -16,9 +17,9 @@ license="GPL-2.0-or-later"
homepage="http://www.codelite.org"
distfiles="https://github.com/eranif/${pkgname}/archive/${version}.tar.gz"
checksum=f2653fa42d6214999718236998cb223e6de00a498c0cfde795e901be693fb9ac
+nocross=yes
python_version=2 #unverified
-archs="i686* x86_64* ppc64le*"
build_options="hunspell lldb mysql sftp"
build_options_default="hunspell lldb sftp"
desc_option_hunspell="Enable SpellCheck plugin"
From 61b1e69fbcb3bd0163d41ce5c30a1add501e3c68 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:46:59 +0200
Subject: [PATCH 16/24] ccls: update to 0.20190823.6
---
srcpkgs/bcc/template | 2 +-
srcpkgs/ccls/template | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/bcc/template b/srcpkgs/bcc/template
index c9a1caadfc3..79aecfa43f8 100644
--- a/srcpkgs/bcc/template
+++ b/srcpkgs/bcc/template
@@ -1,7 +1,7 @@
# Template file for 'bcc'
pkgname=bcc
version=0.13.0
-revision=1
+revision=2
wrksrc="bcc"
build_style=cmake
configure_args="-DREVISION=${version}"
diff --git a/srcpkgs/ccls/template b/srcpkgs/ccls/template
index c4bcabfbc65..bebfa0f4c61 100644
--- a/srcpkgs/ccls/template
+++ b/srcpkgs/ccls/template
@@ -1,6 +1,6 @@
# Template file for 'ccls'
pkgname=ccls
-version=0.20190823.5
+version=0.20190823.6
revision=1
build_style=cmake
hostmakedepends="clang-tools-extra"
@@ -10,7 +10,7 @@ maintainer="Nathan Owens <ndowens04@gmail.com>"
license="Apache-2.0"
homepage="https://github.com/MaskRay/ccls"
distfiles="https://github.com/MaskRay/ccls/archive/${version}.tar.gz"
-checksum=6f39fa5ce79c1682973811ce2409718710bfef6008f94f96277393e6846bd76c
+checksum=83dd45120e9674319f91e4379013831e124c0858e050bbc3521e3f8aebe5c95b
nocross="Clang cannot be installed as makedep"
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
From 1aaae096bf38e8c684c6bfb8171dd6f3cd66e685 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 19:53:35 +0200
Subject: [PATCH 17/24] clazy: rebuild against llvm10
---
srcpkgs/clazy/patches/llvm10.patch | 72 ++++++++++++++++++++++++++++++
srcpkgs/clazy/template | 2 +-
2 files changed, 73 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/clazy/patches/llvm10.patch
diff --git a/srcpkgs/clazy/patches/llvm10.patch b/srcpkgs/clazy/patches/llvm10.patch
new file mode 100644
index 00000000000..289deaabbe4
--- /dev/null
+++ b/srcpkgs/clazy/patches/llvm10.patch
@@ -0,0 +1,72 @@
+From df41bd29433937111edca3654a7beb11ec765029 Mon Sep 17 00:00:00 2001
+From: Johannes Ziegenbalg <Johannes.Ziegenbalg@tu-dresden.de>
+Date: Fri, 27 Mar 2020 14:18:32 +0100
+Subject: [PATCH] Fix build issues using llvm 10.0.0
+
+---
+ CMakeLists.txt | 2 +-
+ src/ClazyStandaloneMain.cpp | 10 ++++++++++
+ src/checks/level0/qstring-ref.cpp | 4 ++++
+ 3 files changed, 15 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index f1463cfe..a30813f8 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -53,7 +53,7 @@ if(MSVC)
+ # disable trigger-happy warnings from Clang/LLVM headers
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4267 /wd4244 /wd4291 /wd4800 /wd4141 /wd4146 /wd4251")
+ elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -fno-common -Woverloaded-virtual -Wcast-qual -fno-strict-aliasing -pedantic -Wno-long-long -Wall -W -Wno-unused-parameter -Wwrite-strings -fno-exceptions -fno-rtti")
+ endif()
+
+ set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-flat_namespace -Wl,-undefined -Wl,suppress")
+diff --git a/src/ClazyStandaloneMain.cpp b/src/ClazyStandaloneMain.cpp
+index aada1895..6baae329 100644
+--- src/ClazyStandaloneMain.cpp
++++ src/ClazyStandaloneMain.cpp
+@@ -93,7 +93,11 @@ class ClazyToolActionFactory
+ {
+ }
+
++#if LLVM_VERSION_MAJOR >= 10
++ std::unique_ptr<FrontendAction> create() override
++#else
+ FrontendAction *create() override
++#endif
+ {
+ ClazyContext::ClazyOptions options = ClazyContext::ClazyOption_None;
+
+@@ -116,9 +120,15 @@ class ClazyToolActionFactory
+ options |= ClazyContext::ClazyOption_IgnoreIncludedFiles;
+
+ // TODO: We need to agregate the fixes with previous run
++#if LLVM_VERSION_MAJOR >= 10
++ return std::make_unique<ClazyStandaloneASTAction>(s_checks.getValue(), s_headerFilter.getValue(),
++ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
++ m_paths, options);
++#else
+ return new ClazyStandaloneASTAction(s_checks.getValue(), s_headerFilter.getValue(),
+ s_ignoreDirs.getValue(), s_exportFixes.getValue(),
+ m_paths, options);
++#endif
+ }
+ std::vector<std::string> m_paths;
+ };
+diff --git a/src/checks/level0/qstring-ref.cpp b/src/checks/level0/qstring-ref.cpp
+index d1d8a4ea..ec9e8901 100644
+--- src/checks/level0/qstring-ref.cpp
++++ src/checks/level0/qstring-ref.cpp
+@@ -117,7 +117,11 @@ static bool containsChild(Stmt *s, Stmt *target)
+ return true;
+
+ if (auto mte = dyn_cast<MaterializeTemporaryExpr>(s)) {
++#if LLVM_VERSION_MAJOR >= 10
++ return containsChild(mte->getSubExpr(), target);
++#else
+ return containsChild(mte->getTemporary(), target);
++#endif
+ } else if (auto ice = dyn_cast<ImplicitCastExpr>(s)) {
+ return containsChild(ice->getSubExpr(), target);
+ } else if (auto bte = dyn_cast<CXXBindTemporaryExpr>(s)) {
diff --git a/srcpkgs/clazy/template b/srcpkgs/clazy/template
index f7f790395e6..d9846d5b41e 100644
--- a/srcpkgs/clazy/template
+++ b/srcpkgs/clazy/template
@@ -1,7 +1,7 @@
# Template file for 'clazy'
pkgname=clazy
version=1.6
-revision=1
+revision=2
build_style=cmake
hostmakedepends="python"
makedepends="clang llvm"
From 364d1ae7cb0c134d1e51ae63c34642445e2b5fa6 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:05:22 +0200
Subject: [PATCH 18/24] llvm-libunwind: update to 10.0.0
---
srcpkgs/llvm-libunwind/template | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/llvm-libunwind/template b/srcpkgs/llvm-libunwind/template
index c5dd2da671e..6e20a791e65 100644
--- a/srcpkgs/llvm-libunwind/template
+++ b/srcpkgs/llvm-libunwind/template
@@ -1,18 +1,18 @@
# Template file for 'llvm-libunwind'
pkgname=llvm-libunwind
-version=9.0.0
+version=10.0.0
revision=1
build_style=cmake
wrksrc="libunwind-${version}.src"
-hostmakedepends="llvm9"
-makedepends="llvm9"
+hostmakedepends="llvm10"
+makedepends="llvm10"
make_build_args="VERBOSE=1"
short_desc="LLVM version of libunwind library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/libunwind-${version}.src.tar.xz"
-checksum=976a8d09e1424fb843210eecec00a506b956e6c31adda3b0d199e945be0d0db2
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libunwind-${version}.src.tar.xz"
+checksum=09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626
post_install() {
vmkdir usr/include
From 9cf48621e855cac10dc33dd0f179a6ee2f02c48a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:42 +0200
Subject: [PATCH 19/24] libcxxabi: update to 10.0.0
---
srcpkgs/libcxxabi/template | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/libcxxabi/template b/srcpkgs/libcxxabi/template
index 03b9424deee..97992a79ff8 100644
--- a/srcpkgs/libcxxabi/template
+++ b/srcpkgs/libcxxabi/template
@@ -1,6 +1,6 @@
# Template file for 'libcxxabi'
pkgname=libcxxabi
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
@@ -8,16 +8,16 @@ configure_args="-DLIBCXXABI_LIBCXX_INCLUDES=../libcxx/include
-DLIBCXXABI_USE_LLVM_UNWINDER=1
-DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}"
make_build_args="VERBOSE=1"
-hostmakedepends="llvm9"
-makedepends="llvm9 llvm-libunwind-devel"
+hostmakedepends="llvm10"
+makedepends="llvm10 llvm-libunwind-devel"
short_desc="Low-level support for libc++ standard library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxxabi.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz
- https://www.llvm.org/releases/${version}/libcxx-${version}.src.tar.xz"
-checksum="675041783565c906ac2f7f8b2bc5c40f14d871ecfa8ade34855aa18de95530e9
- 3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c"
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxxabi-${version}.src.tar.xz
+ https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum="e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1
+ 270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7"
case "$XBPS_TARGET_MACHINE" in
armv[67]l)
From eb7485a32f4ba283ea8f830fa1b3eb21cb9a495a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:11:50 +0200
Subject: [PATCH 20/24] libcxx: update to 10.0.0
---
srcpkgs/libcxx/template | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/srcpkgs/libcxx/template b/srcpkgs/libcxx/template
index 58af53e149e..b32e56dfcdf 100644
--- a/srcpkgs/libcxx/template
+++ b/srcpkgs/libcxx/template
@@ -1,21 +1,21 @@
# Template file for 'libcxx'
pkgname=libcxx
-version=9.0.0
+version=10.0.0
revision=1
wrksrc="${pkgname}-${version}.src"
build_style=cmake
configure_args+=" -DLIBCXX_CXX_ABI=libcxxabi -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
-DLIBCXX_CXX_ABI_LIBRARY_PATH=${XBPS_CROSS_BASE}/usr/lib
-DLIBCXXABI_USE_LLVM_UNWINDER=1"
-hostmakedepends="llvm9 python3"
+hostmakedepends="llvm10 python3"
makedepends="libcxxabi-devel llvm llvm-libunwind-devel"
make_build_args="VERBOSE=1"
short_desc="New implementation of the C++ standard library, targeting C++11, C++14 and above"
maintainer="Orphaned <orphan@voidlinux.org>"
license="NCSA, MIT"
homepage="https://libcxx.llvm.org"
-distfiles="https://www.llvm.org/releases/${version}/${pkgname}-${version}.src.tar.xz"
-checksum=3c4162972b5d3204ba47ac384aa456855a17b5e97422723d4758251acf1ed28c
+distfiles="https://github.com/llvm/llvm-project/releases/download/llvmorg-${version}/libcxx-${version}.src.tar.xz"
+checksum=270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7
case "$XBPS_TARGET_MACHINE" in
*-musl) configure_args+=" -DLIBCXX_HAS_MUSL_LIBC=YES"
From 3751edfcd18fe54dcc723d3611a635d2b8d936f6 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:31:20 +0200
Subject: [PATCH 21/24] include-what-you-use: rebuild for llvm10
---
.../include-what-you-use/patches/llvm10.patch | 61 +++++++++++++++++++
srcpkgs/include-what-you-use/template | 2 +-
2 files changed, 62 insertions(+), 1 deletion(-)
create mode 100644 srcpkgs/include-what-you-use/patches/llvm10.patch
diff --git a/srcpkgs/include-what-you-use/patches/llvm10.patch b/srcpkgs/include-what-you-use/patches/llvm10.patch
new file mode 100644
index 00000000000..c6e0a5c1b39
--- /dev/null
+++ b/srcpkgs/include-what-you-use/patches/llvm10.patch
@@ -0,0 +1,61 @@
+--- iwyu_driver.cc
++++ iwyu_driver.cc
+@@ -205,11 +205,8 @@ CompilerInstance* CreateCompilerInstance(int argc, const char **argv) {
+
+ // Initialize a compiler invocation object from the clang (-cc1) arguments.
+ const ArgStringList &cc_arguments = command.getArguments();
+- const char** args_start = const_cast<const char**>(cc_arguments.data());
+- const char** args_end = args_start + cc_arguments.size();
+ std::shared_ptr<CompilerInvocation> invocation(new CompilerInvocation);
+- CompilerInvocation::CreateFromArgs(*invocation,
+- args_start, args_end, diagnostics);
++ CompilerInvocation::CreateFromArgs(*invocation, cc_arguments, diagnostics);
+ invocation->getFrontendOpts().DisableFree = false;
+
+ // Use libc++ headers bundled with Xcode.app on macOS.
+--- iwyu_preprocessor.cc
++++ iwyu_preprocessor.cc
+@@ -34,6 +34,7 @@
+ #include "clang/Lex/MacroInfo.h"
+
+ using clang::FileEntry;
++using clang::FileEntryRef;
+ using clang::FileID;
+ using clang::MacroDefinition;
+ using clang::MacroDirective;
+@@ -694,7 +695,7 @@ void IwyuPreprocessorInfo::FileChanged(SourceLocation loc,
+ // Called when we see an #include, but decide we don't need to
+ // actually read it because it's already been #included (and is
+ // protected by a header guard).
+-void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
++void IwyuPreprocessorInfo::FileSkipped(const FileEntryRef& file,
+ const Token &filename,
+ SrcMgr::CharacteristicKind file_type) {
+ CHECK_(include_filename_loc_.isValid() &&
+@@ -705,11 +706,11 @@ void IwyuPreprocessorInfo::FileSkipped(const FileEntry& file,
+ GetInstantiationLoc(filename.getLocation());
+ ERRSYM(GetFileEntry(include_loc))
+ << "[ (#include) ] " << include_name_as_written
+- << " (" << GetFilePath(&file) << ")\n";
++ << " (" << GetFilePath(&file.getFileEntry()) << ")\n";
+
+- AddDirectInclude(include_loc, &file, include_name_as_written);
+- if (ShouldReportIWYUViolationsFor(&file)) {
+- files_to_report_iwyu_violations_for_.insert(&file);
++ AddDirectInclude(include_loc, &file.getFileEntry(), include_name_as_written);
++ if (ShouldReportIWYUViolationsFor(&file.getFileEntry())) {
++ files_to_report_iwyu_violations_for_.insert(&file.getFileEntry());
+ }
+ }
+
+--- iwyu_preprocessor.h
++++ iwyu_preprocessor.h
+@@ -204,7 +204,7 @@ class IwyuPreprocessorInfo : public clang::PPCallbacks,
+ void FileChanged(clang::SourceLocation loc, FileChangeReason reason,
+ clang::SrcMgr::CharacteristicKind file_type,
+ clang::FileID exiting_from_id) override;
+- void FileSkipped(const clang::FileEntry& file, const clang::Token &filename,
++ void FileSkipped(const clang::FileEntryRef& file, const clang::Token &filename,
+ clang::SrcMgr::CharacteristicKind file_type) override;
+ // FileChanged is actually a multi-plexer for 4 different callbacks.
+ void FileChanged_EnterFile(clang::SourceLocation file_beginning);
diff --git a/srcpkgs/include-what-you-use/template b/srcpkgs/include-what-you-use/template
index a33d07095f4..18ad1b8896d 100644
--- a/srcpkgs/include-what-you-use/template
+++ b/srcpkgs/include-what-you-use/template
@@ -1,7 +1,7 @@
# Template file for 'include-what-you-use'
pkgname=include-what-you-use
version=0.13
-revision=1
+revision=2
wrksrc="${pkgname}"
build_style=cmake
configure_args="-DIWYU_LLVM_ROOT_PATH=${XBPS_CROSS_BASE}/usr "
From f7a7bafa20fe04a8f6cf596c29649067b2b7694b Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:38 +0200
Subject: [PATCH 22/24] afl: rebuild for llvm10
---
srcpkgs/afl/template | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/srcpkgs/afl/template b/srcpkgs/afl/template
index 5dba2562b37..96c35aa144a 100644
--- a/srcpkgs/afl/template
+++ b/srcpkgs/afl/template
@@ -1,7 +1,7 @@
# Template file for 'afl'
pkgname=afl
version=2.56b
-revision=1
+revision=2
# x86 only currently
archs="i686* x86_64*"
wrksrc="AFL-${version}"
From 03c7fce8e0369ce69c315e2c8d8e04fbdd0aa42a Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:32:49 +0200
Subject: [PATCH 23/24] beignet: rebuild for llvm10
---
.../patches/{llvm6.patch => llvm06.patch} | 0
.../patches/{llvm8.patch => llvm08.patch} | 0
.../patches/{llvm9.patch => llvm09.patch} | 0
srcpkgs/beignet/patches/llvm10.patch | 347 ++++++++++++++++++
srcpkgs/beignet/template | 4 +-
5 files changed, 349 insertions(+), 2 deletions(-)
rename srcpkgs/beignet/patches/{llvm6.patch => llvm06.patch} (100%)
rename srcpkgs/beignet/patches/{llvm8.patch => llvm08.patch} (100%)
rename srcpkgs/beignet/patches/{llvm9.patch => llvm09.patch} (100%)
create mode 100644 srcpkgs/beignet/patches/llvm10.patch
diff --git a/srcpkgs/beignet/patches/llvm6.patch b/srcpkgs/beignet/patches/llvm06.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm6.patch
rename to srcpkgs/beignet/patches/llvm06.patch
diff --git a/srcpkgs/beignet/patches/llvm8.patch b/srcpkgs/beignet/patches/llvm08.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm8.patch
rename to srcpkgs/beignet/patches/llvm08.patch
diff --git a/srcpkgs/beignet/patches/llvm9.patch b/srcpkgs/beignet/patches/llvm09.patch
similarity index 100%
rename from srcpkgs/beignet/patches/llvm9.patch
rename to srcpkgs/beignet/patches/llvm09.patch
diff --git a/srcpkgs/beignet/patches/llvm10.patch b/srcpkgs/beignet/patches/llvm10.patch
new file mode 100644
index 00000000000..9a6cc5a8e8f
--- /dev/null
+++ b/srcpkgs/beignet/patches/llvm10.patch
@@ -0,0 +1,347 @@
+diff --git CMake/FindLLVM.cmake CMake/FindLLVM.cmake
+index 0a59e47..6e90923 100644
+--- CMake/FindLLVM.cmake
++++ CMake/FindLLVM.cmake
+@@ -104,28 +104,16 @@ string(REGEX REPLACE " *\n" "" LLVM_SYSTEM_LIBS ${LLVM_SYSTEM_LIBS_ORIG})
+ endif (LLVM_SYSTEM_LIBS_ORIG)
+ endif (LLVM_VERSION_NODOT VERSION_GREATER 34)
+
++#something harmless because whitespace at start is an error
++set(CLANG_LIBRARIES "-ldl")
+ macro(add_one_lib name)
+ FIND_LIBRARY(CLANG_LIB
+ NAMES ${name}
+ PATHS ${LLVM_LIBRARY_DIR} NO_DEFAULT_PATH)
+- set(CLANG_LIBRARIES ${CLANG_LIBRARIES} ${CLANG_LIB})
++ set(CLANG_LIBRARIES "${CLANG_LIBRARIES} ${CLANG_LIB}")
++ message(STATUS "clanglibs name ${name} this ${CLANG_LIB} all ${CLANG_LIBRARIES} ")
+ unset(CLANG_LIB CACHE)
+ endmacro()
+
+ #Assume clang lib path same as llvm lib path
+-add_one_lib("clangCodeGen")
+-add_one_lib("clangFrontend")
+-add_one_lib("clangSerialization")
+-add_one_lib("clangDriver")
+-add_one_lib("clangSema")
+-add_one_lib("clangStaticAnalyzerFrontend")
+-add_one_lib("clangStaticAnalyzerCheckers")
+-add_one_lib("clangStaticAnalyzerCore")
+-add_one_lib("clangAnalysis")
+-add_one_lib("clangEdit")
+-add_one_lib("clangAST")
+-add_one_lib("clangASTMatchers")
+-add_one_lib("clangParse")
+-add_one_lib("clangSema")
+-add_one_lib("clangLex")
+-add_one_lib("clangBasic")
++add_one_lib("clang-cpp")
+diff --git CMakeLists.txt CMakeLists.txt
+index c11acbb..08f427d 100644
+--- CMakeLists.txt
++++ CMakeLists.txt
+@@ -79,7 +79,7 @@ elseif (COMPILER STREQUAL "CLANG")
+ elseif (COMPILER STREQUAL "ICC")
+ set (CMAKE_C_CXX_FLAGS "${CMAKE_C_CXX_FLAGS} -wd2928 -Wall -fPIC -fstrict-aliasing -fp-model fast -msse4.1 -Wl,-E")
+ endif ()
+-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
++set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof")
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+diff --git backend/src/backend/program.cpp backend/src/backend/program.cpp
+index b36f7b4..e666031 100644
+--- backend/src/backend/program.cpp
++++ backend/src/backend/program.cpp
+@@ -694,9 +694,9 @@ namespace gbe {
+ #endif
+ );
+
++ llvm::cl::ResetAllOptionOccurrences();
+ clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ // Create the compiler instance
+ clang::CompilerInstance Clang;
+@@ -1242,8 +1242,7 @@ EXTEND_QUOTE:
+ // Create the compiler invocation
+ std::unique_ptr<clang::CompilerInvocation> CI(new clang::CompilerInvocation);
+ return clang::CompilerInvocation::CreateFromArgs(*CI,
+- &args[0],
+- &args[0] + args.size(),
++ clang::ArrayRef<const char*>(args),
+ Diags);
+ }
+ #endif
+diff --git backend/src/llvm/llvm_gen_backend.cpp backend/src/llvm/llvm_gen_backend.cpp
+index c6fc30d..82441d8 100644
+--- backend/src/llvm/llvm_gen_backend.cpp
++++ backend/src/llvm/llvm_gen_backend.cpp
+@@ -575,10 +575,12 @@ namespace gbe
+ has_errors(false),
+ legacyMode(true)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 37
+ initializeLoopInfoWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeLoopInfoPass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ pass = PASS_EMIT_REGISTERS;
+ }
+diff --git backend/src/llvm/llvm_gen_backend.hpp backend/src/llvm/llvm_gen_backend.hpp
+index b4715b1..8e74f7a 100644
+--- backend/src/llvm/llvm_gen_backend.hpp
++++ backend/src/llvm/llvm_gen_backend.hpp
+@@ -130,10 +130,10 @@ namespace gbe
+ llvm::FunctionPass *createGenPass(ir::Unit &unit);
+
+ /*! Remove the GEP instructions */
+- llvm::BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit);
++ llvm::FunctionPass *createRemoveGEPPass(const ir::Unit &unit);
+
+ /*! Merge load/store if possible */
+- llvm::BasicBlockPass *createLoadStoreOptimizationPass();
++ llvm::FunctionPass *createLoadStoreOptimizationPass();
+
+ /*! Scalarize all vector op instructions */
+ llvm::FunctionPass* createScalarizePass();
+@@ -141,7 +141,7 @@ namespace gbe
+ llvm::ModulePass* createBarrierNodupPass(bool);
+
+ /*! Convert the Intrinsic call to gen function */
+- llvm::BasicBlockPass *createIntrinsicLoweringPass();
++ llvm::FunctionPass *createIntrinsicLoweringPass();
+
+ /*! Passer the printf function call. */
+ llvm::FunctionPass* createPrintfParserPass(ir::Unit &unit);
+diff --git backend/src/llvm/llvm_intrinsic_lowering.cpp backend/src/llvm/llvm_intrinsic_lowering.cpp
+index 94f0ce6..b5539e9 100644
+--- backend/src/llvm/llvm_intrinsic_lowering.cpp
++++ backend/src/llvm/llvm_intrinsic_lowering.cpp
+@@ -29,12 +29,12 @@
+ using namespace llvm;
+
+ namespace gbe {
+- class InstrinsicLowering : public BasicBlockPass
++ class InstrinsicLowering : public FunctionPass
+ {
+ public:
+ static char ID;
+ InstrinsicLowering() :
+- BasicBlockPass(ID) {}
++ FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+
+@@ -93,9 +93,9 @@ namespace gbe {
+ CI->eraseFromParent();
+ return NewCI;
+ }
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ for (BasicBlock &BB : F) {
+ Module *M = BB.getParent()->getParent();
+
+ DataLayout TD(M);
+@@ -159,13 +159,14 @@ namespace gbe {
+ }
+ }
+ }
+- return changedBlock;
++ }
++ return true;
+ }
+ };
+
+ char InstrinsicLowering::ID = 0;
+
+- BasicBlockPass *createIntrinsicLoweringPass() {
++ FunctionPass *createIntrinsicLoweringPass() {
+ return new InstrinsicLowering();
+ }
+ } // end namespace
+diff --git backend/src/llvm/llvm_loadstore_optimization.cpp backend/src/llvm/llvm_loadstore_optimization.cpp
+index 5aa38be..e314302 100644
+--- backend/src/llvm/llvm_loadstore_optimization.cpp
++++ backend/src/llvm/llvm_loadstore_optimization.cpp
+@@ -26,13 +26,13 @@
+
+ using namespace llvm;
+ namespace gbe {
+- class GenLoadStoreOptimization : public BasicBlockPass {
++ class GenLoadStoreOptimization : public FunctionPass {
+
+ public:
+ static char ID;
+ ScalarEvolution *SE;
+ const DataLayout *TD;
+- GenLoadStoreOptimization() : BasicBlockPass(ID) {}
++ GenLoadStoreOptimization() : FunctionPass(ID) {}
+
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+@@ -45,7 +45,9 @@ namespace gbe {
+ AU.setPreservesCFG();
+ }
+
+- virtual bool runOnBasicBlock(BasicBlock &BB) {
++ virtual bool runOnFunction(Function &F) {
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 38
+ SE = &getAnalysis<ScalarEvolutionWrapperPass>().getSE();
+ #else
+@@ -59,7 +61,9 @@ namespace gbe {
+ #else
+ TD = getAnalysisIfAvailable<DataLayout>();
+ #endif
+- return optimizeLoadStore(BB);
++ changedAnyBlock = optimizeLoadStore(BB) | changedAnyBlock;
++ }
++ return changedAnyBlock;
+ }
+ Type *getValueType(Value *insn);
+ Value *getPointerOperand(Value *I);
+@@ -148,7 +152,7 @@ namespace gbe {
+ values.push_back(merged[i]);
+ }
+ LoadInst *ld = cast<LoadInst>(merged[0]);
+- unsigned align = ld->getAlignment();
++ MaybeAlign align = ld->getAlign();
+ unsigned addrSpace = ld->getPointerAddressSpace();
+ // insert before first load
+ Builder.SetInsertPoint(ld);
+@@ -231,7 +235,7 @@ namespace gbe {
+
+ unsigned addrSpace = st->getPointerAddressSpace();
+
+- unsigned align = st->getAlignment();
++ MaybeAlign align = st->getAlign();
+ // insert before the last store
+ Builder.SetInsertPoint(merged[size-1]);
+
+@@ -325,7 +329,7 @@ namespace gbe {
+ return changed;
+ }
+
+- BasicBlockPass *createLoadStoreOptimizationPass() {
++ FunctionPass *createLoadStoreOptimizationPass() {
+ return new GenLoadStoreOptimization();
+ }
+ };
+diff --git backend/src/llvm/llvm_passes.cpp backend/src/llvm/llvm_passes.cpp
+index 10752a3..b8f2282 100644
+--- backend/src/llvm/llvm_passes.cpp
++++ backend/src/llvm/llvm_passes.cpp
+@@ -37,7 +37,7 @@
+ #include "sys/map.hpp"
+
+ using namespace llvm;
+-
++template class cfg::Update<BasicBlock *>;
+ namespace gbe
+ {
+ bool isKernelFunction(const llvm::Function &F) {
+@@ -219,13 +219,13 @@ namespace gbe
+ return offset;
+ }
+
+- class GenRemoveGEPPasss : public BasicBlockPass
++ class GenRemoveGEPPasss : public FunctionPass
+ {
+
+ public:
+ static char ID;
+ GenRemoveGEPPasss(const ir::Unit &unit) :
+- BasicBlockPass(ID),
++ FunctionPass(ID),
+ unit(unit) {}
+ const ir::Unit &unit;
+ void getAnalysisUsage(AnalysisUsage &AU) const {
+@@ -242,16 +242,18 @@ namespace gbe
+
+ bool simplifyGEPInstructions(GetElementPtrInst* GEPInst);
+
+- virtual bool runOnBasicBlock(BasicBlock &BB)
++ virtual bool runOnFunction(Function &F)
+ {
+- bool changedBlock = false;
++ bool changedAnyBlock = false;
++ for (BasicBlock &BB : F) {
+ iplist<Instruction>::iterator I = BB.getInstList().begin();
+ for (auto nextI = I, E = --BB.getInstList().end(); I != E; I = nextI) {
+ iplist<Instruction>::iterator I = nextI++;
+ if(GetElementPtrInst* gep = dyn_cast<GetElementPtrInst>(&*I))
+- changedBlock = (simplifyGEPInstructions(gep) || changedBlock);
++ changedAnyBlock = (simplifyGEPInstructions(gep) | changedAnyBlock);
+ }
+- return changedBlock;
++ }
++ return changedAnyBlock;
+ }
+ };
+
+@@ -367,7 +369,7 @@ namespace gbe
+ return true;
+ }
+
+- BasicBlockPass *createRemoveGEPPass(const ir::Unit &unit) {
++ FunctionPass *createRemoveGEPPass(const ir::Unit &unit) {
+ return new GenRemoveGEPPasss(unit);
+ }
+ } /* namespace gbe */
+diff --git backend/src/llvm/llvm_sampler_fix.cpp backend/src/llvm/llvm_sampler_fix.cpp
+index 2a097c8..863be6d 100644
+--- backend/src/llvm/llvm_sampler_fix.cpp
++++ backend/src/llvm/llvm_sampler_fix.cpp
+@@ -33,10 +33,12 @@ namespace gbe {
+ class SamplerFix : public FunctionPass {
+ public:
+ SamplerFix() : FunctionPass(ID) {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git backend/src/llvm/llvm_scalarize.cpp backend/src/llvm/llvm_scalarize.cpp
+index e9a2a66..e9d2ee4 100644
+--- backend/src/llvm/llvm_scalarize.cpp
++++ backend/src/llvm/llvm_scalarize.cpp
+@@ -96,10 +96,12 @@ namespace gbe {
+
+ Scalarize() : FunctionPass(ID)
+ {
++#if LLVM_VERSION_MAJOR < 10
+ #if LLVM_VERSION_MAJOR * 10 + LLVM_VERSION_MINOR >= 35
+ initializeDominatorTreeWrapperPassPass(*PassRegistry::getPassRegistry());
+ #else
+ initializeDominatorTreePass(*PassRegistry::getPassRegistry());
++#endif
+ #endif
+ }
+
+diff --git utests/CMakeLists.txt utests/CMakeLists.txt
+index 300d87a..64179c7 100644
+--- utests/CMakeLists.txt
++++ utests/CMakeLists.txt
+@@ -26,8 +26,8 @@ if (NOT NOT_BUILD_STAND_ALONE_UTEST)
+ # Threads
+ Find_Package(Threads)
+
+- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -std=c++0x -Wno-invalid-offsetof")
+- set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS}")
++ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_C_CXX_FLAGS} -Wno-invalid-offsetof -ffloat-store -fno-strict-aliasing")
++ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_CXX_FLAGS} -ffloat-store -fno-strict-aliasing") #compiler_{degrees,radians,function_argument2} use equality comparison of floats, compiler_long_bitcast uses aliasing
+ set (CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g -DGBE_DEBUG=1")
+ set (CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG -DGBE_DEBUG=0")
diff --git a/srcpkgs/beignet/template b/srcpkgs/beignet/template
index c132335da37..130aa57d790 100644
--- a/srcpkgs/beignet/template
+++ b/srcpkgs/beignet/template
@@ -1,8 +1,8 @@
# Template file for 'beignet'
pkgname=beignet
version=1.3.2
-revision=6
-archs="i686* x86_64*"
+revision=7
+#archs="i686* x86_64*"
wrksrc="Beignet-${version}-Source"
build_style=cmake
hostmakedepends="clang llvm pkg-config"
From 26532fea4a9492c3e3fb73564b3873df340622b3 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Fri, 8 May 2020 20:33:17 +0200
Subject: [PATCH 24/24] ispc: update to 1.13.0, limit to x86_64
[ci skip]
---
srcpkgs/ispc/template | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/ispc/template b/srcpkgs/ispc/template
index 998d8028cac..b9160d5664a 100644
--- a/srcpkgs/ispc/template
+++ b/srcpkgs/ispc/template
@@ -1,21 +1,31 @@
# Template file for 'ispc'
pkgname=ispc
-version=1.12.0
-revision=2
-archs="i686 x86_64"
+version=1.13.0
+revision=1
+archs="x86_64"
build_style=cmake
+configure_args="-DISPC_NO_DUMPS=ON -DARM_ENABLED=OFF"
hostmakedepends="clang python3 m4 bison flex llvm"
-configure_args="-DISPC_NO_DUMPS=yes"
makedepends="ncurses-devel zlib-devel"
-short_desc="A compiler for high-performance SIMD programming on the CPU"
+short_desc="Compiler for high-performance SIMD programming on the CPU"
maintainer="Andrea Brancaleoni <abc@pompel.me>"
-license="BSD"
+license="BSD-3-Clause"
homepage="https://ispc.github.io"
distfiles="https://github.com/ispc/ispc/archive/v${version}.tar.gz"
+checksum=cc74c4c490ddf4e0a63f01948ec8d6eb575d85ab5932d30ca4ad01c0e8f079ce
patch_args="-p1"
-checksum=9ebc29adcdf477659b45155d0f91e61120a12084e42113d0e9f4ce5cfdfbdcab
+nocross=yes
nopie=yes
+# hack to make -m32 work so it can build 32-bit target
+case "$XBPS_TARGET_MACHINE" in
+ x86_64) hostmakedepends+=" gcc-multilib";;
+esac
+
pre_build() {
sed -i '/tinfo/d' CMakeLists.txt
}
+
+post_install() {
+ vlicense LICENSE.txt
+}
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PR PATCH] [Merged]: LLVM/Clang 10
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
` (13 preceding siblings ...)
2020-05-08 22:51 ` q66
@ 2020-05-08 23:31 ` q66
14 siblings, 0 replies; 16+ messages in thread
From: q66 @ 2020-05-08 23:31 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 798 bytes --]
There's a merged pull request on the void-packages repository
LLVM/Clang 10
https://github.com/void-linux/void-packages/pull/21756
Description:
# needs rebuilding (unticked still needs testing)
- [x] libclc-git
- [x] mesa
- [x] llvm9
- [x] bpftrace
- [x] gnome-builder
- [x] juCi++
- [x] kdevelop
- [x] qt5
- [x] qtcreator
- [x] rtags
- [x] shiboken2
- [x] rdedup
- [x] codelite
- [x] bcc
- [x] ccls
- [x] clazy
- [x] afl (x86 only, need help)
- [x] beignet (x86 only, need hlep)
- [x] ispc (x86 only, need help)
- [x] llvm-libunwind
- [x] libcxx
- [x] libcxxabi
- [x] include-what-you-use
# no bump but test build anyway
- [x] hfsprogs
- [x] godot
- [x] firefox
- [x] firefox-esr
- [x] bat
- [x] blender
- [x] ardour
- [x] pijul
- [x] qv4l2
- [x] yosys
^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2020-05-08 23:31 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-08 19:29 [PR PATCH] LLVM/Clang 10 q66
2020-05-08 19:57 ` [PR PATCH] [Updated] " q66
2020-05-08 20:05 ` q66
2020-05-08 20:32 ` q66
2020-05-08 20:37 ` q66
2020-05-08 20:38 ` q66
2020-05-08 21:27 ` pullmoll
2020-05-08 21:40 ` [PR PATCH] [Updated] " q66
2020-05-08 21:45 ` q66
2020-05-08 21:49 ` [PR PATCH] [Updated] " q66
2020-05-08 21:49 ` q66
2020-05-08 21:57 ` q66
2020-05-08 22:15 ` q66
2020-05-08 22:32 ` q66
2020-05-08 22:51 ` q66
2020-05-08 23:31 ` [PR PATCH] [Merged]: " q66
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).