Patch macOS CI #115
This file contains 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: GitHub Actions CI | ||
on: | ||
push: | ||
branches: | ||
- develop | ||
- main | ||
pull_request: | ||
branches: | ||
- develop | ||
- main | ||
jobs: | ||
linux: | ||
runs-on: ubuntu-latest | ||
container: ${{ matrix.container }} | ||
env: | ||
GH_JOBNAME: ${{ matrix.jobname }} | ||
GH_OS: Linux | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
jobname: | ||
[ | ||
GCC9-NoMPI-Debug-Real, | ||
GCC9-NoMPI-NoOMP-Real, | ||
GCC9-NoMPI-NoOMP-Complex, | ||
GCC9-NoMPI-Sandbox-Real, | ||
GCC9-MPI-Gcov-Real, | ||
GCC9-MPI-Gcov-Complex, | ||
GCC12-NoMPI-Werror-Real, | ||
GCC12-NoMPI-Werror-Complex, | ||
GCC12-NoMPI-Werror-Real-Mixed, | ||
GCC12-NoMPI-Werror-Complex-Mixed, | ||
Clang14-NoMPI-ASan-Real, | ||
Clang14-NoMPI-ASan-Complex, | ||
Clang14-NoMPI-UBSan-Real, | ||
Clang16-NoMPI-Offload-Real, | ||
Clang16-NoMPI-Offload-Complex, | ||
] | ||
include: | ||
- jobname: GCC9-NoMPI-Debug-Real | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-openmpi:latest | ||
options: -u 1001 | ||
- jobname: GCC9-NoMPI-NoOMP-Real | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-openmpi:latest | ||
options: -u 1001 | ||
- jobname: GCC9-NoMPI-NoOMP-Complex | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-openmpi:latest | ||
options: -u 1001 | ||
- jobname: GCC9-NoMPI-Sandbox-Real | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-openmpi:latest | ||
options: -u 1001 | ||
- jobname: GCC9-MPI-Gcov-Real | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-openmpi:latest | ||
options: -u 1001 | ||
- jobname: GCC9-MPI-Gcov-Complex | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-openmpi:latest | ||
options: -u 1001 | ||
- jobname: GCC12-NoMPI-Werror-Real | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-serial:latest | ||
options: -u 1001 | ||
- jobname: GCC12-NoMPI-Werror-Complex | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-serial:latest | ||
options: -u 1001 | ||
- jobname: GCC12-NoMPI-Werror-Real-Mixed | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-serial:latest | ||
options: -u 1001 | ||
- jobname: GCC12-NoMPI-Werror-Complex-Mixed | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-serial:latest | ||
options: -u 1001 | ||
- jobname: Clang14-NoMPI-ASan-Real | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-openmpi:latest | ||
options: -u 1001 | ||
- jobname: Clang14-NoMPI-ASan-Complex | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-openmpi:latest | ||
options: -u 1001 | ||
- jobname: Clang14-NoMPI-UBSan-Real | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-openmpi:latest | ||
options: -u 1001 | ||
- jobname: Clang16-NoMPI-Offload-Real | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-clang:latest | ||
options: -u 1001 | ||
- jobname: Clang16-NoMPI-Offload-Complex | ||
container: | ||
image: ghcr.io/qmcpack/ubuntu22-clang:latest | ||
options: -u 1001 | ||
steps: | ||
- name: Checkout Action | ||
uses: actions/checkout@v4 | ||
- name: Configure | ||
run: tests/test_automation/github-actions/ci/run_step.sh configure | ||
- name: Build | ||
run: tests/test_automation/github-actions/ci/run_step.sh build | ||
- name: Test | ||
run: tests/test_automation/github-actions/ci/run_step.sh test | ||
- name: Coverage | ||
if: contains(matrix.jobname, 'Gcov') | ||
run: tests/test_automation/github-actions/ci/run_step.sh coverage | ||
- name: Upload Coverage | ||
if: contains(matrix.jobname, 'Gcov') && github.repository_owner == 'QMCPACK' | ||
uses: codecov/codecov-action@v3 | ||
with: | ||
files: ../qmcpack-build/coverage.xml | ||
flags: tests-deterministic # optional | ||
name: codecov-QMCPACK # optional | ||
fail_ci_if_error: true # optional (default = false) | ||
macos: | ||
runs-on: macos-13 | ||
env: | ||
GH_JOBNAME: ${{ matrix.jobname }} | ||
GH_OS: macOS | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
jobname: [macOS-GCC12-NoMPI-Real] | ||
steps: | ||
- name: Checkout Action | ||
uses: actions/checkout@v4 | ||
- run: brew update | ||
# github actions overwrites brew's python. Force it to reassert itself, by running in a separate step. | ||
# From https://github.com/mesonbuild/meson/blob/master/.github/workflows/macos.yml#L87-L92 | ||
- name: Install Homebrew Python | ||
run: | | ||
find /usr/local/bin -lname '*/Library/Frameworks/Python.framework/*' -delete | ||
sudo rm -rf /Library/Frameworks/Python.framework/ | ||
brew install --force python3 && brew unlink python3 && brew unlink python3 && brew link --overwrite python3 | ||
find /usr/local/Cellar/python* -name EXTERNALLY-MANAGED -print0 | xargs -0 rm -vf | ||
- name: Setup Dependencies | ||
run: | | ||
brew install ninja hdf5 fftw boost | ||
python3 -m pip install numpy h5py pandas | ||
- name: Configure | ||
run: tests/test_automation/github-actions/ci/run_step.sh configure | ||
- name: Build | ||
run: tests/test_automation/github-actions/ci/run_step.sh build | ||
- name: Test | ||
run: tests/test_automation/github-actions/ci/run_step.sh test | ||
- name: Install | ||
run: tests/test_automation/github-actions/ci/run_step.sh install | ||
spack-centos-stream: | ||
runs-on: ubuntu-latest | ||
container: ${{ matrix.container }} | ||
env: | ||
GH_JOBNAME: ${{ matrix.jobname }} | ||
GH_OS: Linux | ||
CONTAINER_OS: spack-centos-stream | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
jobname: | ||
[ | ||
GCC11-NoMPI-Debug-Real, | ||
GCC11-NoMPI-NoOMP-Real, | ||
GCC11-NoMPI-NoOMP-Complex, | ||
GCC11-NoMPI-Sandbox-Real, | ||
] | ||
include: | ||
- jobname: GCC11-NoMPI-Debug-Real | ||
container: | ||
image: ghcr.io/qmcpack/centos-stream-gcc11:latest | ||
options: -u 1001 | ||
- jobname: GCC11-NoMPI-NoOMP-Real | ||
container: | ||
image: ghcr.io/qmcpack/centos-stream-gcc11:latest | ||
options: -u 1001 | ||
- jobname: GCC11-NoMPI-NoOMP-Complex | ||
container: | ||
image: ghcr.io/qmcpack/centos-stream-gcc11:latest | ||
options: -u 1001 | ||
- jobname: GCC11-NoMPI-Sandbox-Real | ||
container: | ||
image: ghcr.io/qmcpack/centos-stream-gcc11:latest | ||
options: -u 1001 | ||
steps: | ||
- name: Checkout Action | ||
uses: actions/checkout@v4 | ||
- name: Echo Debug | ||
run: | | ||
echo $PATH | ||
echo $LD_LIBRARY_PATH | ||
- name: Configure | ||
run: tests/test_automation/github-actions/ci/run_step.sh configure | ||
- name: Build | ||
run: tests/test_automation/github-actions/ci/run_step.sh build | ||
- name: Test | ||
run: tests/test_automation/github-actions/ci/run_step.sh test |