summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorMatt Mastracci <matthew@mastracci.com>2023-06-08 09:16:24 -0600
committerGitHub <noreply@github.com>2023-06-08 15:16:24 +0000
commitf35161d3c549c46309ddfbe286ed3f9507076ccd (patch)
tree0980221d44b5cf162a6e3bc6eaf0fe5b509cf901 /.github
parentcaad79ef7807bbd8f53b0338e23d281c5c45519b (diff)
chore: Ensure we only end up with the clang version we want & upgrade libffi (#19421)
The number of clang versions installed on the build machines is too dang high.
Diffstat (limited to '.github')
-rwxr-xr-x.github/workflows/ci.generate.ts7
-rw-r--r--.github/workflows/ci.yml7
2 files changed, 12 insertions, 2 deletions
diff --git a/.github/workflows/ci.generate.ts b/.github/workflows/ci.generate.ts
index 616d4653b..f6c94441b 100755
--- a/.github/workflows/ci.generate.ts
+++ b/.github/workflows/ci.generate.ts
@@ -24,12 +24,14 @@ const prCacheKeyPrefix =
`${cacheVersion}-cargo-target-\${{ matrix.os }}-\${{ matrix.profile }}-\${{ matrix.job }}-`;
const installPkgsCommand =
- "sudo apt-get install --no-install-recommends debootstrap clang-15 lld-15";
+ "sudo apt-get install --no-install-recommends debootstrap clang-15 lld-15 clang-tools-15 clang-format-15 clang-tidy-15";
const sysRootStep = {
name: "Set up incremental LTO and sysroot build",
run: `# Avoid running man-db triggers, which sometimes takes several minutes
# to complete.
sudo apt-get remove --purge -y man-db
+# Remove older clang before we install
+sudo apt-get remove 'clang-12*' 'clang-13*' 'clang-14*' 'llvm-12*' 'llvm-13*' 'llvm-14*' 'lld-12*' 'lld-13*' 'lld-14*'
# Install clang-15, lld-15, and debootstrap.
echo "deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-15 main" |
@@ -40,6 +42,8 @@ sudo dd of=/etc/apt/trusted.gpg.d/llvm-snapshot.gpg
sudo apt-get update
# this was unreliable sometimes, so try again if it fails
${installPkgsCommand} || echo 'Failed. Trying again.' && sudo apt-get clean && sudo apt-get update && ${installPkgsCommand}
+# Fix alternatives
+(yes '' | sudo update-alternatives --force --all) || true
# Create ubuntu-16.04 sysroot environment, which is used to avoid
# depending on a very recent version of glibc.
@@ -461,6 +465,7 @@ const ci = {
"python --version",
"rustc --version",
"cargo --version",
+ "which dpkg && dpkg -l",
// Deno is installed when linting.
'if [ "${{ matrix.job }}" == "lint" ]',
"then",
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index a2cfa572c..86411c21c 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -209,6 +209,8 @@ jobs:
# Avoid running man-db triggers, which sometimes takes several minutes
# to complete.
sudo apt-get remove --purge -y man-db
+ # Remove older clang before we install
+ sudo apt-get remove 'clang-12*' 'clang-13*' 'clang-14*' 'llvm-12*' 'llvm-13*' 'llvm-14*' 'lld-12*' 'lld-13*' 'lld-14*'
# Install clang-15, lld-15, and debootstrap.
echo "deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-15 main" |
@@ -218,7 +220,9 @@ jobs:
sudo dd of=/etc/apt/trusted.gpg.d/llvm-snapshot.gpg
sudo apt-get update
# this was unreliable sometimes, so try again if it fails
- sudo apt-get install --no-install-recommends debootstrap clang-15 lld-15 || echo 'Failed. Trying again.' && sudo apt-get clean && sudo apt-get update && sudo apt-get install --no-install-recommends debootstrap clang-15 lld-15
+ sudo apt-get install --no-install-recommends debootstrap clang-15 lld-15 clang-tools-15 clang-format-15 clang-tidy-15 || echo 'Failed. Trying again.' && sudo apt-get clean && sudo apt-get update && sudo apt-get install --no-install-recommends debootstrap clang-15 lld-15 clang-tools-15 clang-format-15 clang-tidy-15
+ # Fix alternatives
+ (yes '' | sudo update-alternatives --force --all) || true
# Create ubuntu-16.04 sysroot environment, which is used to avoid
# depending on a very recent version of glibc.
@@ -277,6 +281,7 @@ jobs:
python --version
rustc --version
cargo --version
+ which dpkg && dpkg -l
if [ "${{ matrix.job }}" == "lint" ]
then
deno --version