diff options
Diffstat (limited to 'scripts/build')
-rw-r--r-- | scripts/build/v-clang.inc | 15 | ||||
-rw-r--r-- | scripts/build/v-llvm.inc | 4 |
2 files changed, 14 insertions, 5 deletions
diff --git a/scripts/build/v-clang.inc b/scripts/build/v-clang.inc index 29dce9cb..c6a2cf58 100644 --- a/scripts/build/v-clang.inc +++ b/scripts/build/v-clang.inc @@ -5,7 +5,20 @@ required_variables_clang=( artifact_dependency_clang=("") setup_variables_clang() { - LLVM_VERSION_SHORT="${LLVM_VERSION/./}" + local v_a + v_a=(${LLVM_VERSION//./ }) + + LLVM_VERSION_MAJOR="0" + LLVM_VERSION_MINOR="0" + + if [[ "${#v_a[@]}" -ge 1 ]]; then + LLVM_VERSION_MAJOR="${v_a[0]}" + fi + if [[ "${#v_a[@]}" -ge 2 ]]; then + LLVM_VERSION_MINOR="${v_a[1]}" + fi + + LLVM_VERSION_SHORT="${LLVM_VERSION_MAJOR}${LLVM_VERSION_MINOR}" } export_variables_clang=( diff --git a/scripts/build/v-llvm.inc b/scripts/build/v-llvm.inc index 9d84f6c2..7c3ade0a 100644 --- a/scripts/build/v-llvm.inc +++ b/scripts/build/v-llvm.inc @@ -27,7 +27,6 @@ setup_variables_llvm() { LLVM_VERSION_MAJOR="0" LLVM_VERSION_MINOR="0" - LLVM_VERSION_PATCH="0" if [[ "${#v_a[@]}" -ge 1 ]]; then LLVM_VERSION_MAJOR="${v_a[0]}" @@ -35,9 +34,6 @@ setup_variables_llvm() { if [[ "${#v_a[@]}" -ge 2 ]]; then LLVM_VERSION_MINOR="${v_a[1]}" fi - if [[ "${#v_a[@]}" -ge 3 ]]; then - LLVM_VERSION_PATCH="${v_a[2]}" - fi LLVM_VERSION_SHORT="${LLVM_VERSION_MAJOR}${LLVM_VERSION_MINOR}" } |