mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-09-24 20:50:13 +01:00
Move to clang 21 as mininum version and use it in CI (#7779)
Clang 21 is now the latest version available in Ubuntu LTS, so we can move to it.
This commit is contained in:
@@ -23,7 +23,7 @@ runs:
|
||||
xcrun simctl delete all
|
||||
sudo rm -rf ~/Library/Developer/CoreSimulator/Caches/*
|
||||
|
||||
# Install and cache LLVM 19 from Homebrew. Some runners may have LLVM 19,
|
||||
# Install and cache LLVM 21 from Homebrew. Some runners may have LLVM 21,
|
||||
# but this is reliable (including with libc++), and gives us testing at the
|
||||
# minimum supported LLVM version.
|
||||
- name: Cache Homebrew
|
||||
@@ -46,7 +46,7 @@ runs:
|
||||
}}
|
||||
# Note the key needs to include all the packages we're adding.
|
||||
key:
|
||||
Homebrew-Cache-${{ inputs.matrix_runner }}-${{ runner.arch }}-llvm@19
|
||||
Homebrew-Cache-${{ inputs.matrix_runner }}-${{ runner.arch }}-llvm@21
|
||||
|
||||
- name: Install LLVM and Clang with Homebrew
|
||||
if: steps.cache-homebrew-macos.outputs.cache-hit != 'true'
|
||||
@@ -60,11 +60,11 @@ runs:
|
||||
LEAVES=$(brew leaves | egrep -v '^(bazelisk|gh|git|git-lfs|gnu-tar|go@.*|jq|pipx|node@.*|openssl@.*|wget|yq|zlib)$')
|
||||
brew uninstall -f --ignore-dependencies $LEAVES
|
||||
echo '*** Installing LLVM deps'
|
||||
brew install --force-bottle --only-dependencies llvm@19
|
||||
brew install --force-bottle --only-dependencies llvm@21
|
||||
echo '*** Installing LLVM itself'
|
||||
brew install --force-bottle --force --verbose llvm@19
|
||||
echo '*** brew info llvm@19'
|
||||
brew info llvm@19
|
||||
brew install --force-bottle --force --verbose llvm@21
|
||||
echo '*** brew info llvm@21'
|
||||
brew info llvm@21
|
||||
echo '*** brew autoremove'
|
||||
brew autoremove
|
||||
echo '*** brew info'
|
||||
@@ -77,7 +77,7 @@ runs:
|
||||
- name: Setup LLVM and Clang
|
||||
shell: bash
|
||||
run: |
|
||||
LLVM_PATH="$(brew --prefix llvm@19)"
|
||||
LLVM_PATH="$(brew --prefix llvm@21)"
|
||||
echo "Using ${LLVM_PATH}"
|
||||
echo "${LLVM_PATH}/bin" >> $GITHUB_PATH
|
||||
echo '*** ls "${LLVM_PATH}"'
|
||||
|
||||
@@ -23,17 +23,13 @@ runs:
|
||||
large-packages: false
|
||||
|
||||
# Select the LLVM release - by the cache key and the download.
|
||||
#
|
||||
# x86-64 uses the LLVM 19 monolithic package. That release only
|
||||
# published a smaller community build for Linux AArch64, so AArch64 uses
|
||||
# the official monolithic package, first available in LLVM 20.
|
||||
- name: Select LLVM release
|
||||
shell: bash
|
||||
run: |
|
||||
if [[ "${{ runner.arch }}" == "ARM64" ]]; then
|
||||
echo "LLVM_RELEASE=20.1.8" >> "$GITHUB_ENV"
|
||||
echo "LLVM_RELEASE=21.1.8" >> "$GITHUB_ENV"
|
||||
else
|
||||
echo "LLVM_RELEASE=19.1.7" >> "$GITHUB_ENV"
|
||||
echo "LLVM_RELEASE=21.1.8" >> "$GITHUB_ENV"
|
||||
fi
|
||||
|
||||
# Cache and install a recent version of LLVM. This uses the GitHub action
|
||||
|
||||
Reference in New Issue
Block a user