diff --git a/debian/changelog b/debian/changelog index 5fa1d8a8..34398fd6 100644 --- a/debian/changelog +++ b/debian/changelog @@ -61,6 +61,16 @@ llvm-toolchain-snapshot (1:18~++20230725115106+b6847edfc235-1~exp1) experimental -- Sylvestre Ledru Tue, 25 Jul 2023 23:52:42 +0200 +llvm-toolchain-17 (1:17.0.4-2) UNRELEASED; urgency=medium + + [ John Paul Adrian Glaubitz ] + * Don't run chrpath for libclang on sparc and sparc64 + + [ Matthias Klose ] + * Build-depend on llvm-spirv-17. + + -- John Paul Adrian Glaubitz Thu, 09 Nov 2023 10:07:49 +0100 + llvm-toolchain-17 (1:17.0.2-1~exp1) experimental; urgency=medium * New upstream release @@ -84,7 +94,6 @@ llvm-toolchain-17 (1:17.0.0~+rc4-1~exp6) experimental; urgency=medium * Enable again python3-lldb on bionic (apt.llvm.org) -- Sylvestre Ledru Mon, 18 Sep 2023 11:22:37 +0200 ->>>>>>> 17 llvm-toolchain-17 (1:17.0.0~+rc4-1~exp5) experimental; urgency=medium @@ -215,13 +224,30 @@ llvm-toolchain-snapshot (1:17~++20230128060150+75153adeda1a-1~exp1) experimental -- Sylvestre Ledru Sat, 28 Jan 2023 18:07:40 +0100 -llvm-toolchain-16 (1:16.0.6-18) UNRELEASED; urgency=medium +llvm-toolchain-16 (1:16.0.6-18) unstable; urgency=medium + [ Gianfranco Costamagna ] * Upload to sid + + [ Sylvestre Ledru ] + * Change the logic to disable SPIRV. Disable it on most of the versions because + it needs llvm-spirv-16. + Enabled on trixie/sid, Ubuntu Mantic + FAILED: spirv-mesa3d-.spv /build/source/libclc/build/spirv-mesa3d-.spv + cd /build/source/libclc/build && /usr/bin/llvm-spirv-15 + --spirv-max-version=1.1 -o spirv-mesa3d-.spv builtins.link.spirv-mesa3d-.bc + Unknown attribute kind (86) (Producer: 'LLVM16.0.6' Reader: 'LLVM 15.0.6') + * For Ubuntu bionic, improve the deactivation of lldb python + [ Steve Langasek ] * Add noble as supported Ubuntu release - -- Gianfranco Costamagna Wed, 25 Oct 2023 08:10:35 +0200 + [ John Paul Adrian Glaubitz ] + * Don't run chrpath for libclang on sparc and sparc64 + + [ Sylvestre Ledru ] + + -- Sylvestre Ledru Sat, 11 Nov 2023 09:57:35 +0100 llvm-toolchain-16 (1:16.0.6-17exp1) experimental; urgency=medium diff --git a/debian/control b/debian/control index 6c8d9ca9..682f9796 100644 --- a/debian/control +++ b/debian/control @@ -23,7 +23,7 @@ Build-Depends: debhelper (>= 10.0), cmake, ninja-build, libctypes-ocaml-dev [amd64 arm64 armhf ppc64el riscv64 s390x], dh-exec, dh-ocaml [amd64 arm64 armhf ppc64el riscv64 s390x], libpfm4-dev [linux-any], python3-setuptools, libz3-dev, -# llvm-spirv-17 [ amd64 arm64 armel armhf i386 mips64el ppc64el riscv64 s390x ] | hello [!i386], + llvm-spirv-17 [ amd64 arm64 armel armhf i386 mips64el ppc64el riscv64 s390x ] | hello [!i386], spirv-tools [ linux-any ] | hello [ !i386], wasi-libc | hello [ !any-i386], libcurl4-openssl-dev | libcurl-dev, diff --git a/debian/control.in b/debian/control.in index 22783d62..7242e09b 100644 --- a/debian/control.in +++ b/debian/control.in @@ -23,7 +23,7 @@ Build-Depends: debhelper (>= 10.0), cmake, ninja-build, libctypes-ocaml-dev [amd64 arm64 armhf ppc64el riscv64 s390x], dh-exec, dh-ocaml [amd64 arm64 armhf ppc64el riscv64 s390x], libpfm4-dev [linux-any], python3-setuptools, libz3-dev, -# llvm-spirv-17 [ amd64 arm64 armel armhf i386 mips64el ppc64el riscv64 s390x ] | hello [!i386], + llvm-spirv-17 [ amd64 arm64 armel armhf i386 mips64el ppc64el riscv64 s390x ] | hello [!i386], spirv-tools [ linux-any ] | hello [ !i386], wasi-libc | hello [ !any-i386], libcurl4-openssl-dev | libcurl-dev, diff --git a/debian/rules b/debian/rules index db969bc9..d7d87501 100755 --- a/debian/rules +++ b/debian/rules @@ -272,22 +272,27 @@ ifndef LLVM_SPIRV LLVM_SPIRV_VERSION := $(shell expr $(LLVM_VERSION) - 1) LLVM_SPIRV := $(shell bash -c "command -v llvm-spirv-$(LLVM_SPIRV_VERSION)" 2>/dev/null) endif + +# Disable spirv support for most of the distro versions +# It needs llvm-spirv-16 and it is rarely available +# Be prescritive +SPIRV_DISABLE_DISTRO := bionic buster lunar jammy focal buster bullseye bookworm ifndef LLVM_SPIRV LLVM_SPIRV_INSTALLED = no else - ifeq ($(shell dpkg --compare-versions $(shell dpkg-query -W -f '$${Version}' llvm-spirv-$(LLVM_SPIRV_VERSION)) gt 17.0.0 ; echo $$?),0) + ifeq (,$(filter-out $(SPIRV_DISABLE_DISTRO), $(DISTRO))) # Too old llvm-spirv version are failing. See #52200 - LLVM_SPIRV_INSTALLED = yes - else LLVM_SPIRV_INSTALLED = no + else + LLVM_SPIRV_INSTALLED = yes endif endif -LIBCLC_TARGETS_TO_BUILD="amdgcn--;amdgcn--amdhsa;amdgcn-mesa-mesa3d;r600--;nvptx--;nvptx64--;nvptx--nvidiacl;nvptx64--nvidiacl" +LIBCLC_TARGETS_TO_BUILD=amdgcn--;amdgcn--amdhsa;amdgcn-mesa-mesa3d;r600--;nvptx--;nvptx64--;nvptx--nvidiacl;nvptx64--nvidiacl LIBCLC_LLVM_SPIRV = ifeq ($(LLVM_SPIRV_INSTALLED),yes) - LIBCLC_TARGETS_TO_BUILD := $(LIBCLC_TARGETS_TO_BUILD)";spirv-mesa3d-;spirv64-mesa3d-" - LIBCLC_LLVM_SPIRV = "-DLLVM_SPIRV=$(LLVM_SPIRV)" + LIBCLC_TARGETS_TO_BUILD := $(LIBCLC_TARGETS_TO_BUILD);spirv-mesa3d-;spirv64-mesa3d- + LIBCLC_LLVM_SPIRV = -DLLVM_SPIRV=$(LLVM_SPIRV) endif BINUTILS_GOLD_ARCHS := amd64 arm64 armhf i386 ppc64 ppc64el x32 s390x hurd-i386 kfreebsd-amd64 kfreebsd-i386 @@ -414,9 +419,13 @@ else PROJECTS+=;lldb endif -ifneq (,$(filter $(DISTRO),buster)) +LLDB_PYTHON_DISABLE_DISTRO := bionic buster +LLDB_PYTHON_ENABLE=yes +# Disable zstd on old distro, fails on lld +ifeq (,$(filter-out $(LLDB_PYTHON_DISABLE_DISTRO), $(DISTRO))) # Don't enable lld python for old distros STAGE_ALL_CMAKE_EXTRA += -DLLDB_ENABLE_PYTHON=OFF + LLDB_PYTHON_ENABLE=no endif LIBCXX_WASM_ENABLE=yes @@ -589,6 +598,7 @@ stamps/preconfigure: @echo "COMPILER_RT_WASM_ENABLE=$(COMPILER_RT_WASM_ENABLE)" @echo "LIBCXX_WASM_ENABLE=$(LIBCXX_WASM_ENABLE)" @echo "SCCACHE_ENABLE=$(SCCACHE_ENABLE)" + @echo "LLVM_SPIRV=$(LLVM_SPIRV)" @echo "LLVM_SPIRV_INSTALLED=$(LLVM_SPIRV_INSTALLED)" @echo "DOC_GENERATION=$(DOC_GENERATION)" @@ -615,12 +625,12 @@ stamps/preconfigure: debian/llvm-$(LLVM_VERSION)-linker-tools.links \ debian/libbolt-$(LLVM_VERSION)-dev.install -ifdef LLVM_SPIRV # llvm-spirv was found, so we can enable *.spv files. Debian # buster and Ubuntu 18.04 don't have llvm-spirv to create the # *.spv files. - sed -i -e "s|#spv\ ||g" debian/libclc-$(LLVM_VERSION).install -endif + if test "$(LLVM_SPIRV_INSTALLED)" = "yes"; then \ + sed -i -e "s|#spv\ ||g" debian/libclc-$(LLVM_VERSION).install; \ + fi # disable libc++-X.Y-dev-wasm32.install.in on old distro if test "$(LIBCXX_WASM_ENABLE)" = "no"; then \ @@ -851,7 +861,7 @@ stamps/debian-libclc-build: -DCMAKE_INSTALL_INCLUDEDIR=include \ -DLLVM_CMAKE_DIR=$(STAGE_2_BIN_DIR)/../ \ $(LIBCLC_LLVM_SPIRV) \ - -DLIBCLC_TARGETS_TO_BUILD=$(LIBCLC_TARGETS_TO_BUILD); \ + -DLIBCLC_TARGETS_TO_BUILD="$(LIBCLC_TARGETS_TO_BUILD)"; \ LD_LIBRARY_PATH=$$LD_LIBRARY_PATH:$(STAGE_2_LIB_DIR) ninja -j $(NJOBS) $(VERBOSE) ifndef LLVM_SPIRV echo "libclc built without SPIRV (.spv) outputs because llvm-spirv wasn't found" @@ -1094,7 +1104,7 @@ override_dh_auto_install: # Only run on executable, not script chrpath -d `find $(DEB_INST)/usr/lib/llvm-$(LLVM_VERSION)/bin/ -type f -executable -exec file -i '{}' \; | grep 'x-executable; charset=binary'|cut -d: -f1` -ifeq (,$(filter $(DEB_HOST_ARCH), powerpc powerpcspe)) +ifeq (,$(filter $(DEB_HOST_ARCH), powerpc powerpcspe sparc sparc64)) ifneq (,$(filter $(DEB_HOST_ARCH_OS),linux)) # To fix custom-library-search-path chrpath -d $(DEB_INST)/usr/lib/llvm-$(LLVM_VERSION)/lib/clang/$(LLVM_VERSION)*/lib/linux/*.so @@ -1280,6 +1290,8 @@ endif if test "$(DISTRO)" = "buster" -o "$(DEB_HOST_ARCH)" = "mips64el"; then \ mkdir -p $(DEB_INST)/usr/lib/llvm-$(LLVM_VERSION)/share/gdb/python/ompd/; \ touch $(DEB_INST)/usr/lib/llvm-$(LLVM_VERSION)/share/gdb/python/ompd/empty; \ + fi + if test "$(LLDB_PYTHON_ENABLE)" = no; then \ echo "" > debian/python3-lldb-$(LLVM_VERSION).install; \ fi