Skip to content

[CI][Github] Use newer sccache version in CI container #149196

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

boomanaiden154
Copy link
Contributor

I was having trouble with the version that ships in the ubuntu apt repository
and GCS based caching. The newer version works, so reintroduce the infra that
we had in 2c1d4b0 to download it.

@llvmbot
Copy link
Member

llvmbot commented Jul 16, 2025

@llvm/pr-subscribers-github-workflow

Author: Aiden Grossman (boomanaiden154)

Changes

I was having trouble with the version that ships in the ubuntu apt repository
and GCS based caching. The newer version works, so reintroduce the infra that
we had in 2c1d4b0 to download it.


Full diff: https://github.com/llvm/llvm-project/pull/149196.diff

1 Files Affected:

  • (modified) .github/workflows/containers/github-action-ci/Dockerfile (+10-2)
diff --git a/.github/workflows/containers/github-action-ci/Dockerfile b/.github/workflows/containers/github-action-ci/Dockerfile
index efe08ebc221c5..a8a3428a4471a 100644
--- a/.github/workflows/containers/github-action-ci/Dockerfile
+++ b/.github/workflows/containers/github-action-ci/Dockerfile
@@ -63,11 +63,19 @@ RUN apt-get update && \
     python3-pip \
     ccache \
     file \
-    tzdata \
-    sccache && \
+    tzdata && \
     apt-get clean && \
     rm -rf /var/lib/apt/lists/*
 
+# We need sccache for caching. We cannot use the apt repository version because
+# it is too old and has bugs related to features we require (particularly GCS
+# caching), so we manually install it here.
+RUN curl -L 'https://github.com/mozilla/sccache/releases/download/v0.10.0/sccache-v0.10.0-x86_64-unknown-linux-musl.tar.gz' > /tmp/sccache.tar.gz && \
+    echo "1fbb35e135660d04a2d5e42b59c7874d39b3deb17de56330b25b713ec59f849b /tmp/sccache.tar.gz" | sha256sum -c && \
+    tar xzf /tmp/sccache.tar.gz -O --wildcards '*/sccache' > '/usr/local/bin/sccache' && \
+    rm /tmp/sccache.tar.gz && \
+    chmod +x /usr/local/bin/sccache
+
 ENV LLVM_SYSROOT=$LLVM_SYSROOT
 ENV PATH=${LLVM_SYSROOT}/bin:${PATH}
 

boomanaiden154 added a commit to boomanaiden154/llvm-project that referenced this pull request Jul 16, 2025
I was having trouble with the version that ships in the ubuntu apt repository
and GCS based caching. The newer version works, so reintroduce the infra that
we had in 2c1d4b0 to download it.

Pull Request: llvm#149196
Created using spr 1.3.4
Created using spr 1.3.4

[skip ci]
boomanaiden154 added a commit to boomanaiden154/llvm-project that referenced this pull request Jul 17, 2025
I was having trouble with the version that ships in the ubuntu apt repository
and GCS based caching. The newer version works, so reintroduce the infra that
we had in 2c1d4b0 to download it.

Pull Request: llvm#149196
Created using spr 1.3.4
boomanaiden154 added a commit to boomanaiden154/llvm-project that referenced this pull request Jul 17, 2025
I was having trouble with the version that ships in the ubuntu apt repository
and GCS based caching. The newer version works, so reintroduce the infra that
we had in 2c1d4b0 to download it.

Pull Request: llvm#149196
Created using spr 1.3.4

[skip ci]
Created using spr 1.3.4
Created using spr 1.3.4

[skip ci]
Created using spr 1.3.4
@boomanaiden154 boomanaiden154 changed the base branch from users/boomanaiden154/main.cigithub-use-newer-sccache-version-in-ci-container to main July 17, 2025 17:14
@boomanaiden154 boomanaiden154 merged commit fcb7ed6 into main Jul 17, 2025
8 of 9 checks passed
@boomanaiden154 boomanaiden154 deleted the users/boomanaiden154/cigithub-use-newer-sccache-version-in-ci-container branch July 17, 2025 17:15
llvm-sync bot pushed a commit to arm/arm-toolchain that referenced this pull request Jul 17, 2025
I was having trouble with the version that ships in the ubuntu apt repository
and GCS based caching. The newer version works, so reintroduce the infra that
we had in 2c1d4b0 to download it.

Reviewers: tstellar, lnihlen, gburgessiv, dschuff, cmtice, Keenuts

Reviewed By: cmtice, Keenuts

Pull Request: llvm/llvm-project#149196
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants