Article View: linux.debian.bugs.dist
Article #4587Bug#1154059: apache-arrow: FTBFS with LLVM 23 as default: Gandiva rejects LLVM 23
From: Sylvestre Ledru
Date: Sun, 15 Nov 2026 13:40
Date: Sun, 15 Nov 2026 13:40
115 lines
5897 bytes
5897 bytes
--1804289383-1794740520=:2281320
Content-Type: text/plain; charset=UTF-8
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
Content-ID: <20261115120200.2281320@pulau.ecranbleu.org>
Source: apache-arrow
Version: 25.0.0-2
Severity: important
Tags: ftbfs patch
User: pkg-llvm-team@lists.alioth.debian.org
Usertags: llvm-23-default
Control: affects -1 + src:llvm-defaults
Control: block 1154024 by -1
Hello,
We are going to switch the default LLVM version to 23 (transition bug
#1154024). llvm-defaults 0.75~exp1, in experimental, already points to
23.
apache-arrow fails to build in unstable with it, and builds without it:
CMake Warning at cmake_modules/FindLLVMAlt.cmake:58 (find_package):
Could not find a configuration file for package "LLVM" that is compatible
with requested version [...]
/usr/lib/llvm-23/lib/cmake/llvm/LLVMConfig.cmake, version: 23.1.3
Gandiva has a fixed list of supported LLVM versions, ARROW_LLVM_VERSIONS
in cpp/CMakeLists.txt:181, which stops at 22.1. With "23.1" added, the
build goes further and fails in cpp/src/gandiva/engine.cc:213: since
LLVM 23, the ObjectLinkingLayerCreator callback also gets the
JITLinkMemoryManager.
The attached debdiff fixes both. apache-arrow builds with it, tests included.
To reproduce, with sbuild:
sbuild -d unstable \
--extra-repository='deb http://deb.debian.org/debian experimental main' \
--build-dep-resolver=aptitude \
--add-depends='clang (>= 1:23~), llvm-dev (>= 1:23~), libclang-dev (>= 1:23~)' \
<package>
The --add-depends forces the llvm-defaults packages from experimental
(the default apt resolver won't pick them, aptitude does), everything
else comes from unstable.
The severity will be raised to serious once llvm-defaults 23 is in
unstable.
Cheers,
Sylvestre
--1804289383-1794740520=:2281320
Content-Type: text/x-diff; charset=UTF-8; name="apache-arrow.debdiff"
Content-Disposition: attachment; filename="apache-arrow.debdiff"
Content-Transfer-Encoding: 8bit
Content-ID: <20261115120200.2281320.1@pulau.ecranbleu.org>
diff --git a/debian/patches/llvm-23.patch b/debian/patches/llvm-23.patch
new file mode 100644
index 0000000..56bcfae
--- /dev/null
+++ b/debian/patches/llvm-23.patch
@@ -0,0 +1,38 @@
+Description: Build Gandiva with LLVM 23
+ * Add 23.1 to the supported LLVM versions.
+ * The ObjectLinkingLayerCreator callback gets the JITLinkMemoryManager
+ since LLVM 23.
+Author: Sylvestre Ledru <sylvestre@debian.org>
+Forwarded: no
+Last-Update: 2026-11-15
+---
+Index: apache-arrow-25.0.0/cpp/CMakeLists.txt
+===================================================================
+--- apache-arrow-25.0.0.orig/cpp/CMakeLists.txt
++++ apache-arrow-25.0.0/cpp/CMakeLists.txt
+@@ -179,6 +179,7 @@ set(ARROW_DOC_DIR "${CMAKE_INSTALL_DOCDI
+ set(BUILD_SUPPORT_DIR "${CMAKE_SOURCE_DIR}/build-support")
+
+ set(ARROW_LLVM_VERSIONS
++ "23.1"
+ "22.1"
+ "21.1"
+ "20.1"
+Index: apache-arrow-25.0.0/cpp/src/gandiva/engine.cc
+===================================================================
+--- apache-arrow-25.0.0.orig/cpp/src/gandiva/engine.cc
++++ apache-arrow-25.0.0/cpp/src/gandiva/engine.cc
+@@ -209,7 +209,12 @@ Status UseJITLinkIfEnabled(llvm::orc::LL
+ static auto maybe_use_jit_link = ::arrow::internal::GetEnvVar("GANDIVA_USE_JIT_LINK");
+ if (maybe_use_jit_link.ok()) {
+ ARROW_ASSIGN_OR_RAISE(static auto memory_manager, CreateMemmoryManager());
+-# if LLVM_VERSION_MAJOR >= 21
++# if LLVM_VERSION_MAJOR >= 23
++ jit_builder.setObjectLinkingLayerCreator(
++ [&](llvm::orc::ExecutionSession& ES, llvm::jitlink::JITLinkMemoryManager&) {
++ return std::make_unique<llvm::orc::ObjectLinkingLayer>(ES, *memory_manager);
++ });
++# elif LLVM_VERSION_MAJOR >= 21
+ jit_builder.setObjectLinkingLayerCreator([&](llvm::orc::ExecutionSession& ES) {
+ return std::make_unique<llvm::orc::ObjectLinkingLayer>(ES, *memory_manager);
+ });
diff --git a/debian/patches/series b/debian/patches/series
index 0968955..1712f76 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,3 +1,4 @@
use-debian-mimalloc.patch
build-sse4.2-kernels.patch
gandiva-riscv64-pic-jit.patch
+llvm-23.patch
--1804289383-1794740520=:2281320--
Technical Details
Message-ID:
<NZICB-c2ZC-5@gated-at.bofh.it>Path:
mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.samoylyk.net!gothmog.csi.it!news.servidellagleba.it!bofh.it!news.nic.it!robomodShow Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.samoylyk.net!gothmog.csi.it!news.servidellagleba.it!bofh.it!news.nic.it!robomod From: Sylvestre Ledru <sylvestre@debian.org> Newsgroups: linux.debian.bugs.dist Subject: Bug#1154059: apache-arrow: FTBFS with LLVM 23 as default: Gandiva rejects LLVM 23 Date: Sun, 15 Nov 2026 14:40:02 +0100 Message-ID: <NZICB-c2ZC-5@gated-at.bofh.it> X-Mailbox-Line: From debian-bugs-dist-request@lists.debian.org Sun Nov 15 13:31:14 2026 Old-Return-Path: <debbugs@buxtehude.debian.org> X-Spam-Flag: NO X-Spam-Score: -1.9 Reply-To: Sylvestre Ledru <sylvestre@debian.org>, 1154059@bugs.debian.org Resent-To: debian-bugs-dist@lists.debian.org Resent-Cc: debian-science-maintainers@lists.alioth.debian.org X-Debian-Pr-Message: report 1154059 X-Debian-Pr-Package: src:apache-arrow X-Debian-Pr-Keywords: ftbfs patch X-Debian-Pr-Source: apache-arrow MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="1804289383-1794740520=:2281320" User-Agent: mail (GNU Mailutils 3.21) X-Debian-Message: from BTS X-Mailing-List: <debian-bugs-dist@lists.debian.org> archive/latest/2002739 List-ID: <debian-bugs-dist.lists.debian.org> List-URL: <https://lists.debian.org/debian-bugs-dist/> Approved: robomod@news.nic.it Lines: 115 Organization: linux.* mail to news gateway Sender: robomod@news.nic.it X-Original-Date: Sun, 15 Nov 2026 12:02:00 +0100 X-Original-Message-ID: <20261115110200.724D619CDAC9@pulau.ecranbleu.org>