aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows/ubuntu.yml
blob: bc7505c5dbf316956379d05bf7e41f4665b9b0ff (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: 🐧 OpenMP

on: [push, pull_request]

concurrency:
  group: ${{ github.ref }}-${{ github.head_ref }}-ubuntu
  cancel-in-progress: true

jobs:
  build_cxxminimal:
    name: GCC Minimal w/o MPI
    runs-on: ubuntu-20.04
    if: github.event.pull_request.draft == false
    env:
      CXXFLAGS: "-Werror"
    steps:
    - uses: actions/checkout@v2
    - name: install dependencies
      run: |
        .github/workflows/dependencies/gcc.sh
    - name: build WarpX
      run: |
        cmake -S . -B build_3D         \
          -DCMAKE_VERBOSE_MAKEFILE=ON  \
          -DWarpX_EB=OFF               \
          -DWarpX_MPI=OFF              \
          -DWarpX_QED=OFF
        cmake --build build_3D -j 2
        cmake -S . -B build_RZ         \
          -DCMAKE_VERBOSE_MAKEFILE=ON  \
          -DWarpX_DIMS=RZ              \
          -DWarpX_EB=OFF               \
          -DWarpX_MPI=OFF              \
          -DWarpX_QED=OFF
        cmake --build build_RZ -j 2

  build_pyfull:
    name: Clang pywarpx
    runs-on: ubuntu-20.04
    if: github.event.pull_request.draft == false
    # On CI for this test, Ninja is slower than the default:
    #env:
    #  CMAKE_GENERATOR: Ninja
    steps:
    - uses: actions/checkout@v2
    - name: install dependencies
      run: |
        .github/workflows/dependencies/pyfull.sh
    - name: build WarpX
      run: |
        python3 -m pip install --upgrade pip setuptools wheel
        export WARPX_MPI=ON
        export WARPX_OPENPMD=ON
        export WARPX_PSATD=ON
        export WARPX_QED_TABLE_GEN=ON
        export CC=$(which clang)
        export CXX=$(which clang++)
        export CXXFLAGS="-Werror -Wno-error=pass-failed"
        python3 -m pip install -v .

    - name: run pywarpx
      run: |
        export OMP_NUM_THREADS=1
        mpirun -n 2 Examples/Physics_applications/laser_acceleration/PICMI_inputs_laser_acceleration.py