Skip to content

Read the Docs Documentation #484

Read the Docs Documentation

Read the Docs Documentation #484

name: Linux Build/Test for PR and collaborator push
on:
# allows us to run workflows manually
workflow_dispatch:
pull_request:
branches:
- develop
paths-ignore:
- '.github/workflows/docker_publish.yml'
- '.github/workflows/mac_build_test.yml'
- '.github/workflows/windows_build_test.yml'
- '.github/workflows/linux_upstream_test_*'
- '.github/workflows/housekeeping.yml'
- '.github/workflows/changelog_test.yml'
- '.github/actions/**'
- 'CI/**'
- 'doc/**'
push:
branches:
- develop
paths-ignore:
- '.github/workflows/docker_publish.yml'
- '.github/workflows/mac_build_test.yml'
- '.github/workflows/windows_build_test.yml'
- '.github/workflows/linux_upstream_test_*'
- '.github/workflows/housekeeping.yml'
- '.github/workflows/changelog_test.yml'
- '.github/actions/**'
- 'CI/**'
- 'doc/**'
jobs:
BuildTest:
runs-on: ubuntu-latest
strategy:
matrix:
ubuntu_versions : [
20.04,
22.04,
]
compiler : [
gcc,
clang,
]
hdf5_versions : [
1.14.3,
]
moab_versions : [
5.4.1,
5.5.1,
]
double_down : [
OFF,
]
geant_version : [
10.7.4,
11.1.2
]
container:
image: ghcr.io/svalinn/dagmc-ci-ubuntu-${{ matrix.ubuntu_versions }}-${{ matrix.compiler}}-geant4_${{ matrix.geant_version }}-hdf5_${{ matrix.hdf5_versions}}-moab_${{ matrix.moab_versions }}/moab:latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
submodules: recursive
- name: Building DAGMC
run: |
ln -s $GITHUB_WORKSPACE /root/build_dir/DAGMC
mkdir -p ./build
cd ./build
git config --global --add safe.directory $GITHUB_WORKSPACE
cmake ../ -DMOAB_DIR=${moab_install_dir} \
-DBUILD_GEANT4=ON \
-DGEANT4_DIR=${geant4_install_dir} \
-DBUILD_CI_TESTS=ON \
-DBUILD_MW_REG_TESTS=OFF \
-DBUILD_STATIC_EXE=OFF \
-DBUILD_STATIC_LIBS=OFF \
-DCMAKE_C_COMPILER=${CC} \
-DCMAKE_CXX_COMPILER=${CXX} \
-DCMAKE_Fortran_COMPILER=gfortran \
-DCMAKE_INSTALL_PREFIX=${install_dir}/dagmc \
-DDOUBLE_DOWN=${double_down} \
-DCMAKE_CXX_FLAGS="-Werror=reorder" \
-Ddd_ROOT=${double_down_install_dir} && \
make -j2 && \
make install
- name: Testing DAGMC
run: |
cd $GITHUB_WORKSPACE/build
PATH=${install_dir}/dagmc/bin:${PATH} CTEST_OUTPUT_ON_FAILURE=1 make test