From ca9dbba24d5170e0454c0678f37003eb2cf08482 Mon Sep 17 00:00:00 2001 From: Sylvestre Ledru Date: Mon, 10 Oct 2022 13:47:36 +0200 Subject: [PATCH] Don't build wasm target on arm64 armel mips64el mipsel ppc64el armhf for now --- debian/changelog | 6 ++++-- debian/rules | 13 ++++++++++++- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/debian/changelog b/debian/changelog index 0723ec17..a4e992ef 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,10 @@ -llvm-toolchain-14 (1:14.0.6-4) UNRELEASED; urgency=medium +llvm-toolchain-14 (1:14.0.6-4) unstable; urgency=medium * fix the cmake detection with libmlir + * Don't build wasm target on arm64 armel mips64el mipsel ppc64el armhf + for now - -- Sylvestre Ledru Sun, 09 Oct 2022 20:33:54 +0200 + -- Sylvestre Ledru Mon, 10 Oct 2022 13:47:25 +0200 llvm-toolchain-14 (1:14.0.6-3) unstable; urgency=medium diff --git a/debian/rules b/debian/rules index 41ff3c5b..4ebc5495 100755 --- a/debian/rules +++ b/debian/rules @@ -291,6 +291,12 @@ ifeq ($(LIBUNWIND_ENABLE),yes) endif endif +COMPILER_RT_WASM_ENABLE=yes + +ifneq (,$(filter $(DEB_HOST_ARCH), arm64 armel mips64el mipsel ppc64el armhf)) + COMPILER_RT_WASM_ENABLE=no +endif + # Do not install objects STAGE_ALL_CMAKE_EXTRA += -DMLIR_INSTALL_AGGREGATE_OBJECTS=OFF @@ -680,6 +686,7 @@ debian-libclc-build: touch $@ debian-rtlib-wasm-build: +ifeq (${COMPILER_RT_WASM_ENABLE},yes) echo "Using cmake: $(CMAKE_BIN)" for build in wasm32 wasm64; do \ mkdir -p build-compiler-rt-$$build; \ @@ -708,6 +715,9 @@ debian-rtlib-wasm-build: -DCOMPILER_RT_OS_DIR=wasi; \ ninja -C build-compiler-rt-$$build $(NJOBS) $(VERBOSE); \ done +else + echo "Skip on this arch" +endif touch $@ override_dh_auto_build: debian-full-build debian-libfuzzer-build debian-libclc-build debian-rtlib-wasm-build @@ -849,9 +859,10 @@ endif $(DEB_INST)/usr/lib/llvm-$(LLVM_VERSION)/build/utils/lit/lit/*/__pycache__/ DESTDIR=$(DEB_INST) ninja $(VERBOSE) -C libclc/build install - +ifeq (${COMPILER_RT_WASM_ENABLE},yes) DESTDIR=$(DEB_INST) ninja $(VERBOSE) -C build-compiler-rt-wasm32 install DESTDIR=$(DEB_INST) ninja $(VERBOSE) -C build-compiler-rt-wasm64 install +endif # Rename binaries mkdir -p $(DEB_INST)/usr/bin/