]> git.proxmox.com Git - llvm-toolchain.git/commitdiff
d/rules: Check for previous version of llvm-spirv as well
authorJordan Justen <jljusten@debian.org>
Sun, 30 Oct 2022 22:16:19 +0000 (15:16 -0700)
committerJordan Justen <jljusten@debian.org>
Mon, 31 Oct 2022 05:07:54 +0000 (22:07 -0700)
Signed-off-by: Jordan Justen <jljusten@debian.org>
debian/changelog
debian/rules

index ae0f070432922f9e9e92d92c6bd1b6e987827c56..73d6f0997e1a9f51c6cd2274c86691d4d0378d23 100644 (file)
@@ -7,6 +7,7 @@ llvm-toolchain-15 (1:15.0.3-3) UNRELEASED; urgency=medium
   * d/rules: Set LLVM_SPIRV with cmake for libclc
   * d/patches: Drop libclc-llvm-spirv.diff now that we are setting LLVM_SPIRV
   * d/rules: Restore building libclc .bc output without spir-v support
+  * d/rules: Check for previous version of llvm-spirv as well
 
  -- Jordan Justen <jljusten@debian.org>  Sun, 30 Oct 2022 00:26:40 -0700
 
index f1179237092e27c254552d77aae402314d778e75..4d8a59c810cc406182e3d09a683a5bae29589432 100755 (executable)
@@ -245,6 +245,10 @@ endif
 
 LLVM_SPIRV_VERSION := $(LLVM_VERSION)
 LLVM_SPIRV := $(shell bash -c "command -v llvm-spirv-$(LLVM_SPIRV_VERSION)" 2>/dev/null)
+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
 
 ifndef LLVM_SPIRV
        LLVM_SPIRV_INSTALLED = no