Explicit build-time features #680
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI (Distro) | ||
| ## This GitHub Actions workflow builds and tests sage-the-distro on various platforms | ||
| ## whenever a tag is pushed or a pull request changes relevant build files. | ||
| ## | ||
| ## It builds and checks some sage spkgs as defined in TARGETS. | ||
| ## | ||
| ## A job succeeds if there is no error. | ||
| ## | ||
| ## The build is run with "make V=0", so the build logs of individual packages are suppressed. | ||
| ## | ||
| ## At the end, all package build logs that contain an error are printed out. | ||
| ## | ||
| ## After all jobs have finished (or are canceled) and a short delay, | ||
| ## tar files of all logs are made available as "build artifacts". | ||
| on: | ||
| pull_request: | ||
| paths: | ||
| - '.github/workflows/ci-distro.yml' | ||
| - 'build/pkgs/**' | ||
| - 'build/make/**' | ||
| - 'configure.ac' | ||
| push: | ||
| tags: | ||
| - '*' | ||
| workflow_dispatch: | ||
| # Allow to run manually | ||
| env: | ||
| TARGETS_PRE: all-sage-local | ||
| TARGETS: build | ||
| TARGETS_OPTIONAL: ptestlong | ||
| permissions: | ||
| packages: write | ||
| concurrency: | ||
| # Cancel previous runs of this workflow for the same branch | ||
| group: ${{ github.workflow }}-${{ github.ref }} | ||
| cancel-in-progress: true | ||
| jobs: | ||
| linux-minimal: | ||
| if: ${{ success() || failure() }} | ||
| uses: ./.github/workflows/docker.yml | ||
|
Check warning on line 46 in .github/workflows/ci-distro.yml
|
||
| with: | ||
| # Build from scratch | ||
| free_disk_space: true | ||
| docker_targets: "with-system-packages configured with-targets-pre with-targets with-targets-optional" | ||
| # FIXME: duplicated from env.TARGETS | ||
| targets_pre: all-sage-local | ||
| targets: build | ||
| targets_optional: ptestlong | ||
| tox_system_factors: >- | ||
| ["ubuntu-jammy"] | ||
| tox_packages_factors: >- | ||
| ["minimal"] | ||
| docker_push_repository: ghcr.io/${{ github.repository }}/ | ||
| linux: | ||
| uses: ./.github/workflows/docker.yml | ||
|
Check warning on line 62 in .github/workflows/ci-distro.yml
|
||
| with: | ||
| free_disk_space: true | ||
| # Build from scratch | ||
| docker_targets: "with-system-packages configured with-targets-pre with-targets with-targets-optional" | ||
| targets_pre: all-sage-local | ||
| targets: build | ||
| targets_optional: ptestlong | ||
| tox_packages_factors: >- | ||
| ["standard"] | ||
| docker_push_repository: ghcr.io/${{ github.repository }}/ | ||
| macos: | ||
| name: Build and Test (macos-${{ matrix.version }}) | ||
| runs-on: macos-${{ matrix.version }} | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| version: | ||
| - '14' | ||
| - '15' | ||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
| - uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: "3.13" | ||
| - name: Install dependencies | ||
| run: | | ||
| eval $(build/bin/sage-print-system-package-command homebrew update) | ||
| eval $(build/bin/sage-print-system-package-command homebrew --yes --ignore-missing install $(build/bin/sage-get-system-packages homebrew _bootstrap _prereq $(build/bin/sage-package list :standard:))) | ||
| - name: Build | ||
| run: | | ||
| source ./.homebrew-build-env | ||
| ./bootstrap | ||
| ./configure --enable-download-from-upstream-url | ||
| make build V=0 | ||
| env: | ||
| MAKE: 'make -j6' | ||
| - name: Test | ||
| run: | | ||
| source ./.homebrew-build-env # Needed so that runtime cython can find the dependencies | ||
| ./sage -t --all -p4 | ||