From d7ecbb69b3a22f47499e7bf1b30eda3ad50171cb Mon Sep 17 00:00:00 2001 From: Sylvestre Ledru Date: Mon, 23 Sep 2024 14:22:41 +0200 Subject: [PATCH] Disable LLVM libc on bionic --- debian/changelog | 1 + debian/rules | 17 +++++++++++------ 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/debian/changelog b/debian/changelog index c02755ef..1600ca65 100644 --- a/debian/changelog +++ b/debian/changelog @@ -2,6 +2,7 @@ llvm-toolchain-19 (1:19.1.0-5) unstable; urgency=medium * Don't enable intel-pt on Ubuntu Bionic * Add disabled info in the build log + * Disable LLVM libc on bionic -- Sylvestre Ledru Mon, 23 Sep 2024 13:20:42 +0200 diff --git a/debian/rules b/debian/rules index 36d2f5fc..47eb3d2a 100755 --- a/debian/rules +++ b/debian/rules @@ -373,12 +373,13 @@ ifneq (,$(filter bolt-$(LLVM_VERSION), $(packages))) endif ifneq (,$(filter libllvmlibc-$(LLVM_VERSION)-dev, $(packages))) - RUNTIMES += ;libc - LLVM_LIBC_FULL_DISTRO := bionic -# Workaround on bionic -# See https://github.com/llvm/llvm-project/issues/82467#issuecomment-2033193448 - ifeq (,$(filter-out $(LLVM_LIBC_FULL_DISTRO), $(DISTRO))) - STAGE_ALL_CMAKE_EXTRA += -DLLVM_LIBC_FULL_BUILD=ON + LLVM_LIBC_ENABLE=yes + LLVM_LIBC_DISABLE_DISTRO := bionic + ifeq (,$(filter $(DISTRO), $(LLVM_LIBC_DISABLE_DISTRO))) + RUNTIMES += ;libc + else + LLVM_LIBC_ENABLE=no + $(info LLVM libc disabled for $(DISTRO)) endif endif @@ -760,6 +761,10 @@ stamps/preconfigure: fi; \ fi + if test "$(LLVM_LIBC_ENABLE)" = "no"; then \ + echo "" > debian/libllvmlibc-$(LLVM_VERSION)-dev.install; \ + fi + # Conditionally enable install clangd grpc files if test "$(CLANGD_GRPC_INSTALLED)" = "yes"; then \ sed -i -e "s|#grpc\ ||g" debian/libclang-$(LLVM_VERSION)-dev.install; \