Skip to content

Commit

Permalink
Auto merge of #86092 - JohnTitor:clang-12-beta, r=Mark-Simulacrum
Browse files Browse the repository at this point in the history
[beta] Backport #84894 to fix beta CI

Currently, beta backports fail with this failure: #86036 (comment)
```
STL1000: Unexpected compiler version, expected Clang 11.0.0 or newer.
```

The previous beta backport was successful because it uses a Visual Studio tool v14.28.29910 but now CI uses v14.29.30037.
#84894 updated clang to 12 so master didn't catch this change, I guess. Hopefully, it fixes CI failures on beta.
  • Loading branch information
bors committed Jun 8, 2021
2 parents 82b8621 + ff4c377 commit e7f4b8b
Showing 1 changed file with 7 additions and 16 deletions.
23 changes: 7 additions & 16 deletions src/ci/scripts/install-clang.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ IFS=$'\n\t'
source "$(cd "$(dirname "$0")" && pwd)/../shared.sh"

# Update both macOS's and Windows's tarballs when bumping the version here.
LLVM_VERSION="10.0.0"
LLVM_VERSION="12.0.0"

if isMacOS; then
# If the job selects a specific Xcode version, use that instead of
Expand Down Expand Up @@ -42,23 +42,14 @@ elif isWindows && [[ ${CUSTOM_MINGW-0} -ne 1 ]]; then
# clang has an output mode compatible with MinGW that we need. If it does we
# should switch to clang for MinGW as well!
#
# Note that the LLVM installer is an NSIS installer
#
# Original downloaded here came from:
#
# https://github.com/llvm/llvm-project/releases/download/llvmorg-10.0.0/LLVM-10.0.0-win64.exe
#
# That installer was run through `wine ./installer.exe /S /NCRC` on Linux
# and then the resulting installation directory (found in
# `$HOME/.wine/drive_c/Program Files/LLVM`) was packaged up into a tarball.
# We've had issues otherwise that the installer will randomly hang, provide
# not a lot of useful information, pollute global state, etc. In general the
# tarball is just more confined and easier to deal with when working with
# various CI environments.
# The LLVM installer is an NSIS installer, which we can extract with 7z. We
# don't want to run the installer directly; extracting it is more reliable
# in CI environments.

mkdir -p citools
mkdir -p citools/clang-rust
cd citools
curl -f "${MIRRORS_BASE}/LLVM-${LLVM_VERSION}-win64.tar.gz" | tar xzf -
curl -f "${MIRRORS_BASE}/LLVM-${LLVM_VERSION}-win64.exe" -o "LLVM-${LLVM_VERSION}-win64.exe"
7z x -oclang-rust/ "LLVM-${LLVM_VERSION}-win64.exe"
ciCommandSetEnv RUST_CONFIGURE_ARGS \
"${RUST_CONFIGURE_ARGS} --set llvm.clang-cl=$(pwd)/clang-rust/bin/clang-cl.exe"
fi

0 comments on commit e7f4b8b

Please sign in to comment.