position dependent photon field for EM interactions (optimised) #285
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: crpropa-testing_ubuntu22 | |
| on: [push, pull_request] | |
| jobs: | |
| linux: | |
| runs-on: ${{ matrix.config.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| config: | |
| - name: "ubuntu-22" | |
| os: ubuntu-22.04 | |
| cxx: "g++-11" | |
| cc: "gcc-11" | |
| fc: "gfortran-11" | |
| swig_builtin: "On" #uses swig 4.0.2 | |
| py: "/usr/bin/python3" #python 3.10 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Preinstall | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install libmuparser-dev python3 python3-setuptools libhdf5-serial-dev libomp5 libomp-dev libfftw3-dev libcfitsio-dev lcov | |
| pip install --upgrade pip | |
| pip install numpy | |
| pip show numpy | |
| - name: Set up the build | |
| env: | |
| CXX: ${{ matrix.config.cxx }} | |
| CC: ${{ matrix.config.cc }} | |
| FC: ${{ matrix.config.fc }} | |
| run: | | |
| mkdir build | |
| cd build | |
| cmake .. -DENABLE_PYTHON=True \ | |
| -DENABLE_TESTING=On \ | |
| -DPython_EXECUTABLE=${{ matrix.config.py }} \ | |
| -DENABLE_SWIG_BUILTIN=${{ matrix.config.swig_builtin }} \ | |
| -DSIMD_EXTENSIONS=native \ | |
| -DCMAKE_CXX_STANDARD=17 \ | |
| -DCMAKE_CXX_FLAGS="-std=c++17 -Wall -Wextra -I${{ github.workspace }}/libs/nanoflann/include" | |
| - name: Build CRPropa | |
| run: | | |
| cd build | |
| make | |
| - name: Run tests | |
| run: | | |
| cd build | |
| make test ARGS="--output-on-failure" | |
| - name: Archive test results | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: "test-report_${{matrix.config.name}}" | |
| path: build/Testing/Temporary/LastTest.log | |