-
Notifications
You must be signed in to change notification settings - Fork 148
ci(refactor): extract build setup logic into setup-build #622
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
022fd5b to
fbe271c
Compare
|
Changed from |
fbe271c to
4bf9299
Compare
|
Rebased. Added features: |
4bf9299 to
a908805
Compare
ae3fef0 to
c859b16
Compare
|
Updated. |
|
This looks to be building and caching flint also on Ubuntu, right? Then #703 will go in easily? The actions setup looks much cleaner with this! |
|
Yes, the action now builds FLINT 3.3.1 also on Ubuntu. It also contains some untested features like |
c859b16 to
237cda5
Compare
| - name: Install dependencies (Ubuntu) | ||
| if: runner.os == 'Linux' && steps.setup.outputs.container == 'false' | ||
| uses: awalsh128/cache-apt-pkgs-action@a605dbde2ac49a823c9c87ad58491b51848bf355 # for empty_packages_behavior |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Once this commit is included in a release, we can simplify the reference to v1.
|
I'm thinking about letting this action optionally run the build step (despite the name |
|
Right, this would speed things up (a bit) if the binaries are cached. At some point it might be worth taking a look at the slowest of the tests under valgrind, and trying to make an easier test which hits the same bug, if we would like the CI to run faster (since in the future, we would like to add a lot more tests for better coverage). |
|
I just meant removing the five |
|
Then I misunderstood. In the context of your changes here it does make sense to remove as much duplicate build code as you can from the various test jobs indeed. |
b564d01 to
5fd2e3d
Compare
Refactor workflows by introducing a new composite action, "setup-build", to encapsulate common setup logic. This action sets up the build environment and runs the configure script based on the "features" input.
5fd2e3d to
ada1f0a
Compare
|
FLINT is now statically linked on macOS. I also committed workflow improvements with more robust checks, and excluded |
This patch extracts the build setup logic into a composite action called
setup-buildto avoid repeating similar steps in different jobs. The setup process includes installing dependencies and libraries, extracting tarballs, runningautoreconf, and executingconfigure.In the future, if we need to elaborate further on setting up libraries (including building and caching), such as MPI or FLINT, we can manage them all in one place.
There are several ways to organize shared logic in GitHub Actions:
setup-buildneeds to modify$LIBRARY_PATHetc.)This patch adopts the last option. To mitigate the drawback, I added lines like
### Initialize setup ###in therun:field, which will appear in the logs.