Skip to content

Build

Build #400

Workflow file for this run

name: Build
on:
push:
schedule:
- cron: "0 8 * * 0"
jobs:
GNU:
name: GNU ${{ matrix.gnu_ver }} (${{ matrix.build_type }})
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
gnu_ver: [13, 14]
build_type: [Debug, Release]
steps:
- uses: actions/checkout@v4
- name: Install gfortran
run: |
sudo apt update
sudo apt install --no-install-recommends -y \
gfortran-${{ matrix.gnu_ver }} \
ninja-build \
libflint-dev
- name: Configuring
run: |
mkdir build
cd build
cmake .. \
-GNinja \
-DCMAKE_Fortran_COMPILER=gfortran-${{ matrix.gnu_ver }} \
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
-DBUILD_TESTS=ON
- name: Building
run: cmake --build build
- name: Testing
run: ctest --output-on-failure --test-dir build
- name: Running
run: |
cd build
mv input_example.dat input.dat
./main pw
./main cw
./main dw
./main dwb
MSYS2:
name: MSYS2/UCRT64 (${{ matrix.build_type }})
runs-on: windows-2022
strategy:
fail-fast: false
matrix:
build_type: [Debug, Release]
defaults:
run:
shell: msys2 {0}
steps:
- uses: actions/checkout@v4
- name: Install compiler
uses: msys2/setup-msys2@v2
with:
msystem: UCRT64
release: true
update: true
pacboy: fc:p cmake:p ninja:p flint:p
- name: Configuring
run: |
mkdir build && cd build
cmake .. \
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
-DBUILD_TESTS=ON
- name: Building
run: cmake --build build
- name: Testing
run: ctest --output-on-failure --test-dir build
- name: Running
run: |
cd build
mv input_example.dat input.dat
./main pw
./main cw
./main dw
./main dwb
Intel:
name: Intel (${{ matrix.build_type }})
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
build_type: [Debug, Release]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Intel compilers
run: |
wget -O- https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB \
| gpg --dearmor | sudo tee /usr/share/keyrings/oneapi-archive-keyring.gpg > /dev/null
echo "deb [signed-by=/usr/share/keyrings/oneapi-archive-keyring.gpg] https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list
sudo apt update
sudo apt install --no-install-recommends -y \
intel-oneapi-compiler-fortran \
ninja-build \
libflint-dev
source /opt/intel/oneapi/setvars.sh
printenv >> $GITHUB_ENV
- name: Configuring
run: |
mkdir build
cd build
cmake .. \
-GNinja \
-DCMAKE_Fortran_COMPILER=ifx \
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
-DBUILD_TESTS=ON
- name: Building
run: cmake --build build
- name: Testing
run: ctest --output-on-failure --test-dir build
- name: Running
run: |
cd build
mv input_example.dat input.dat
./main pw
./main cw
./main dw
./main dwb
Nvidia:
name: Nvidia (${{ matrix.build_type }})
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
build_type: [Debug, Release]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Nvidia HPC Compiler
run: |
curl https://developer.download.nvidia.com/hpc-sdk/ubuntu/DEB-GPG-KEY-NVIDIA-HPC-SDK | sudo gpg --dearmor -o /usr/share/keyrings/nvidia-hpcsdk-archive-keyring.gpg
echo 'deb [signed-by=/usr/share/keyrings/nvidia-hpcsdk-archive-keyring.gpg] https://developer.download.nvidia.com/hpc-sdk/ubuntu/amd64 /' | sudo tee /etc/apt/sources.list.d/nvhpc.list
sudo apt-get update
sudo apt install --no-install-recommends -y \
nvhpc-24-9 \
ninja-build \
libflint-dev
echo "/opt/nvidia/hpc_sdk/Linux_x86_64/24.9/compilers/bin" >> $GITHUB_PATH
echo "LD_LIBRARY_PATH=/opt/nvidia/hpc_sdk/Linux_x86_64/24.9/compilers/lib" >> $GITHUB_ENV
- name: Configuring
run: |
mkdir build
cd build
cmake .. \
-GNinja \
-DCMAKE_Fortran_COMPILER=nvfortran \
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
-DBUILD_TESTS=ON
- name: Building
run: cmake --build build
- name: Testing
run: ctest --output-on-failure --test-dir build
- name: Running
run: |
cd build
mv input_example.dat input.dat
./main pw
./main cw
./main dw
./main dwb