CI: Only add LLVM repository if it is missing

For our js-benchmarks and libjs-test262 workflow runs, we already know
that they're provisioned with these repositories and can skip adding the
key and repo altogether.
This commit is contained in:
Jelle Raaijmakers 2025-05-15 14:39:06 +02:00 committed by Jelle Raaijmakers
commit 9f044cb547
Notes: github-actions[bot] 2025-05-15 13:14:58 +00:00
3 changed files with 4 additions and 8 deletions

View file

@ -33,8 +33,10 @@ runs:
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
curl -f -o /usr/share/keyrings/llvm-snapshot.gpg.key https://apt.llvm.org/llvm-snapshot.gpg.key
echo "deb [signed-by=/usr/share/keyrings/llvm-snapshot.gpg.key] http://apt.llvm.org/noble/ llvm-toolchain-noble-20 main" | sudo tee -a /etc/apt/sources.list.d/llvm.list
if [ ! -f /etc/apt/sources.list.d/llvm.list ]; then
curl -f -o /usr/share/keyrings/llvm-snapshot.gpg.key https://apt.llvm.org/llvm-snapshot.gpg.key
echo "deb [signed-by=/usr/share/keyrings/llvm-snapshot.gpg.key] http://apt.llvm.org/noble/ llvm-toolchain-noble-20 main" | sudo tee -a /etc/apt/sources.list.d/llvm.list
fi
sudo apt-get update -y
sudo apt-get install -y autoconf autoconf-archive automake build-essential ccache cmake curl fonts-liberation2 \

View file

@ -36,9 +36,6 @@ jobs:
if: ${{ matrix.os_name == 'Linux' }}
shell: bash
run: |
curl -f -o /usr/share/keyrings/llvm-snapshot.gpg.key https://apt.llvm.org/llvm-snapshot.gpg.key
echo "deb [signed-by=/usr/share/keyrings/llvm-snapshot.gpg.key] http://apt.llvm.org/noble/ llvm-toolchain-noble-20 main" | sudo tee -a /etc/apt/sources.list.d/llvm.list
sudo apt-get update
sudo apt-get install -y clang++-20 python3-venv
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-20 100

View file

@ -50,9 +50,6 @@ jobs:
- name: Install dependencies
run: |
curl -f -o /usr/share/keyrings/llvm-snapshot.gpg.key https://apt.llvm.org/llvm-snapshot.gpg.key
echo "deb [signed-by=/usr/share/keyrings/llvm-snapshot.gpg.key] http://apt.llvm.org/noble/ llvm-toolchain-noble-20 main" | sudo tee -a /etc/apt/sources.list.d/llvm.list
sudo apt-get update -y
sudo apt-get install -y ninja-build unzip clang-20 clang++-20 jq curl zip tar autoconf autoconf-archive automake nasm pkg-config libgl1-mesa-dev rsync