Skip to content
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

CI: Reuse build directory across builds, use ccache #53

Merged
merged 1 commit into from
Feb 5, 2025

Conversation

aperezdc
Copy link
Member

Given that builds use a self-hosted runner, that means it is possible to arrange certain directories to kept between runs: speed up the build by keeping the build directory (per architecture) and use ccache (the cache directory is also kept). Cerbero's cache invalidation handles rebuilding packages as needed when source build recipes change.

@aperezdc aperezdc added the enhancement New feature or request label Jan 24, 2025
@aperezdc aperezdc self-assigned this Jan 24, 2025
@aperezdc aperezdc force-pushed the aperezdc/ci-reuse-builddir branch 4 times, most recently from a7fa102 to 4368f12 Compare January 27, 2025 20:42
@aperezdc aperezdc requested a review from ltilve January 27, 2025 21:36
@aperezdc
Copy link
Member Author

CI run (successful): https://github.com/Igalia/wpe-android-cerbero/actions/runs/12997947975

This makes incremental builds have the chance of being considerably faster.

Note how the arm64 build took ~26 minutes and the x86_64 build took under 2 minutes. This is because I triggered before another run and canceled the arm64 build after the x86_64 one completed. Then after I launched the run linked above, which was able to reuse the intermediate x86_64 build outputs, but the arm64 build was done from scratch.

Given that builds use a self-hosted runner, that means it is possible to
arrange certain directories to kept between runs: speed up the build by
keeping the build directory (per architecture) and use ccache (the cache
directory is also kept). Cerbero's cache invalidation handles rebuilding
packages as needed when source build recipes change.
@aperezdc aperezdc force-pushed the aperezdc/ci-reuse-builddir branch from 4368f12 to 8d78b63 Compare January 28, 2025 09:20
@aperezdc
Copy link
Member Author

aperezdc commented Jan 28, 2025

Rebased and conflicts resolved, PTAL.

CI run (successful) after the rebase: https://github.com/Igalia/wpe-android-cerbero/actions/runs/13010933816/job/36288283204 (only 5 minutes!)

Copy link
Member

@jaragunde jaragunde left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thanks! Sorry for the delay :)

@aperezdc aperezdc merged commit 95b6668 into main Feb 5, 2025
3 checks passed
@aperezdc aperezdc deleted the aperezdc/ci-reuse-builddir branch February 5, 2025 08:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants