mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-09-25 19:40:35 -09:00
package/bcc: bump version to 0.37.0
Changelog: https://github.com/iovisor/bcc/blob/v0.37.0/debian/changelog This commit removes the package patch which is included in this new version. It also adds another upstream patch to fix the build with the upcoming LLVM 23. Cc: Bernd Kuhls <bernd@kuhls.net> Signed-off-by: Julien Olivain <ju.o@free.fr>
This commit is contained in:
@@ -1,64 +0,0 @@
|
||||
From 4c7be1ec6ab74e973f8d18a9011fa349c3d9dd58 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Holger=20Hoffst=C3=A4tte?= <holger@applied-asynchrony.com>
|
||||
Date: Mon, 2 Mar 2026 10:03:15 +0100
|
||||
Subject: [PATCH] Fix build with LLVM-22
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
LLVM-22 changed the signatures of various createDiagnostics() calls [1].
|
||||
Introduce a new version macro guard and adapt the code to the changed API.
|
||||
|
||||
Fixes #5483
|
||||
|
||||
[1] https://github.com/llvm/llvm-project/commit/30633f30894129919050f24fdd1f8f6bc46beae0
|
||||
|
||||
Signed-off-by: Holger Hoffstätte <holger@applied-asynchrony.com>
|
||||
|
||||
Upstream: https://github.com/iovisor/bcc/commit/4c7be1ec6ab74e973f8d18a9011fa349c3d9dd58
|
||||
|
||||
Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
|
||||
---
|
||||
src/cc/frontends/clang/loader.cc | 15 ++++++++++++---
|
||||
1 file changed, 12 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/src/cc/frontends/clang/loader.cc b/src/cc/frontends/clang/loader.cc
|
||||
index 6f8387aaf017..1f706344724d 100644
|
||||
--- a/src/cc/frontends/clang/loader.cc
|
||||
+++ b/src/cc/frontends/clang/loader.cc
|
||||
@@ -464,7 +464,10 @@ int ClangLoader::do_compile(
|
||||
}
|
||||
invocation0.getFrontendOpts().DisableFree = false;
|
||||
|
||||
-#if LLVM_VERSION_MAJOR >= 20
|
||||
+#if LLVM_VERSION_MAJOR >= 22
|
||||
+ compiler0.setVirtualFileSystem(llvm::vfs::getRealFileSystem());
|
||||
+ compiler0.createDiagnostics(new IgnoringDiagConsumer());
|
||||
+#elif LLVM_VERSION_MAJOR >= 20
|
||||
compiler0.createDiagnostics(*llvm::vfs::getRealFileSystem(), new IgnoringDiagConsumer());
|
||||
#else
|
||||
compiler0.createDiagnostics(new IgnoringDiagConsumer());
|
||||
@@ -487,7 +490,10 @@ int ClangLoader::do_compile(
|
||||
add_main_input(invocation1, main_path, &*out_buf);
|
||||
invocation1.getFrontendOpts().DisableFree = false;
|
||||
|
||||
-#if LLVM_VERSION_MAJOR >= 20
|
||||
+#if LLVM_VERSION_MAJOR >= 22
|
||||
+ compiler1.setVirtualFileSystem(llvm::vfs::getRealFileSystem());
|
||||
+ compiler1.createDiagnostics();
|
||||
+#elif LLVM_VERSION_MAJOR >= 20
|
||||
compiler1.createDiagnostics(*llvm::vfs::getRealFileSystem());
|
||||
#else
|
||||
compiler1.createDiagnostics();
|
||||
@@ -517,7 +523,10 @@ int ClangLoader::do_compile(
|
||||
invocation2.getCodeGenOpts().setInlining(CodeGenOptions::NormalInlining);
|
||||
// suppress warnings in the 2nd pass, but bail out on errors (our fault)
|
||||
invocation2.getDiagnosticOpts().IgnoreWarnings = true;
|
||||
-#if LLVM_VERSION_MAJOR >= 20
|
||||
+#if LLVM_VERSION_MAJOR >= 22
|
||||
+ compiler2.setVirtualFileSystem(llvm::vfs::getRealFileSystem());
|
||||
+ compiler2.createDiagnostics();
|
||||
+#elif LLVM_VERSION_MAJOR >= 20
|
||||
compiler2.createDiagnostics(*llvm::vfs::getRealFileSystem());
|
||||
#else
|
||||
compiler2.createDiagnostics();
|
||||
@@ -0,0 +1,38 @@
|
||||
From e5418ece42eb5bb322d220a2ff94f545d72a6f8a Mon Sep 17 00:00:00 2001
|
||||
From: Viktor Malik <viktor.malik@gmail.com>
|
||||
Date: Thu, 13 Aug 2026 08:22:00 +0200
|
||||
Subject: [PATCH] src/cc: Fix MCContext constructor for LLVM 23
|
||||
|
||||
Two LLVM 23 patches [1,2] changed the MCContext constructor to take
|
||||
MCAsmInfo, MCRegisterInfo, and MCSubtargetInfo by a reference rather
|
||||
than by a pointer. Reflect the change in call of the constructor.
|
||||
|
||||
[1] https://github.com/llvm/llvm-project/commit/13e98d834101efd1794cdd026377c508293ee21b
|
||||
[2] https://github.com/llvm/llvm-project/commit/d50631faad3003e73589528c83d3bbbad7ba72f1
|
||||
|
||||
Upstream: https://github.com/iovisor/bcc/commit/dad0db93fd0f443b2a4f43bc2f23c621c9202516
|
||||
Signed-off-by: Viktor Malik <viktor.malik@gmail.com>
|
||||
Signed-off-by: Julien Olivain <ju.o@free.fr>
|
||||
---
|
||||
src/cc/bcc_debug.cc | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/src/cc/bcc_debug.cc b/src/cc/bcc_debug.cc
|
||||
index 2e53c44d..0812c4ab 100644
|
||||
--- a/src/cc/bcc_debug.cc
|
||||
+++ b/src/cc/bcc_debug.cc
|
||||
@@ -148,7 +148,11 @@ void SourceDebugger::dump() {
|
||||
T->createMCSubtargetInfo(TripleArg, "", ""));
|
||||
MCObjectFileInfo MOFI;
|
||||
#if LLVM_VERSION_MAJOR >= 13
|
||||
+#if LLVM_VERSION_MAJOR >= 23
|
||||
+ MCContext Ctx(TheTriple, *MAI, *MRI, *STI, nullptr);
|
||||
+#else
|
||||
MCContext Ctx(TheTriple, MAI.get(), MRI.get(), STI.get(), nullptr);
|
||||
+#endif
|
||||
Ctx.setObjectFileInfo(&MOFI);
|
||||
MOFI.initMCObjectFileInfo(Ctx, false, false);
|
||||
#else
|
||||
--
|
||||
2.55.0
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
# locally calculated
|
||||
sha256 ea8562246801c52a9c21c47076dae9ff1d3719bb86b96d7a6222b3724461f52c bcc-v0.36.1-git4.tar.gz
|
||||
sha256 fa4302ee54d8638ca08fa7f2d1dfe7f39d4bd1bd02ccd2b298b0148369f3a680 bcc-v0.37.0-git4.tar.gz
|
||||
sha256 b40930bbcf80744c86c46a12bc9da056641d722716c378f5659b9e555ef833e1 LICENSE.txt
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
#
|
||||
################################################################################
|
||||
|
||||
BCC_VERSION = v0.36.1
|
||||
BCC_VERSION = v0.37.0
|
||||
BCC_SITE = https://github.com/iovisor/bcc
|
||||
BCC_SITE_METHOD = git
|
||||
BCC_GIT_SUBMODULES = YES
|
||||
|
||||
Reference in New Issue
Block a user