From 685c3626090b1ffd07a4d57636f3bb410fd11431 Mon Sep 17 00:00:00 2001 From: Mike Hommey Date: Tue, 12 Mar 2024 22:08:41 +0000 Subject: [PATCH] Bug 1884838 - Support getting LLVM version from its new location. r=firefox-build-system-reviewers,ahochheiden Patch sent upstream: https://github.com/WebAssembly/wasi-sdk/pull/399 Differential Revision: https://phabricator.services.mozilla.com/D204328 --- taskcluster/scripts/misc/wasi-sdk.patch | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/taskcluster/scripts/misc/wasi-sdk.patch b/taskcluster/scripts/misc/wasi-sdk.patch index 9f7b6ad908fc9..b9e26074d18f1 100644 --- a/taskcluster/scripts/misc/wasi-sdk.patch +++ b/taskcluster/scripts/misc/wasi-sdk.patch @@ -1,3 +1,13 @@ +diff --git a/llvm_version_major.sh b/llvm_version_major.sh +index 2e5d973..93fe9b0 100755 +--- a/llvm_version_major.sh ++++ b/llvm_version_major.sh +@@ -1,4 +1,4 @@ + #/bin/bash + LLVM_PROJ_DIR=${1:-./src/llvm-project} +-MAJOR=`grep "set(LLVM_VERSION_MAJOR" $LLVM_PROJ_DIR/llvm/CMakeLists.txt | awk '{print substr($2, 1, length($2) - 1)}'` ++MAJOR=`(grep "set(LLVM_VERSION_MAJOR" $LLVM_PROJ_DIR/llvm/CMakeLists.txt || grep "set(LLVM_VERSION_MAJOR" $LLVM_PROJ_DIR/cmake/Modules/LLVMVersion.cmake) | awk '{print substr($2, 1, length($2) - 1)}'` + echo $MAJOR diff --git a/Makefile b/Makefile index d2ccff6..95f395b 100644 --- a/Makefile