Skip to content

Commit

Permalink
C++20 Compatibility: GCC 10.1 (#949)
Browse files Browse the repository at this point in the history
  • Loading branch information
ax3l authored May 29, 2020
1 parent 4e051cd commit 1b30da6
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 12 deletions.
8 changes: 2 additions & 6 deletions .github/workflows/dependencies/dependencies.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
#!/usr/bin/env bash
#
# Copyright 2020 Axel Huebl
# Copyright 2020 The AMReX Community
#
# License: BSD-3-Clause-LBNL

# search recursive inside a folder if a file contains tabs
#
# @result 0 if no files are found, else 1
#
# Authors: Axel Huebl

set -eu -o pipefail

Expand Down
17 changes: 17 additions & 0 deletions .github/workflows/dependencies/dependencies_gcc10.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/usr/bin/env bash
#
# Copyright 2020 The AMReX Community
#
# License: BSD-3-Clause-LBNL
# Authors: Axel Huebl

set -eu -o pipefail

sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update

sudo apt-get install -y --no-install-recommends \
build-essential \
g++-10 gfortran-10 \
libopenmpi-dev \
openmpi-bin
8 changes: 2 additions & 6 deletions .github/workflows/dependencies/dependencies_mac.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
#!/usr/bin/env bash
#
# Copyright 2020 Axel Huebl
# Copyright 2020 The AMReX Community
#
# License: BSD-3-Clause-LBNL

# search recursive inside a folder if a file contains tabs
#
# @result 0 if no files are found, else 1
#
# Authors: Axel Huebl

set -eu -o pipefail

Expand Down
20 changes: 20 additions & 0 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,26 @@ jobs:
cmake .. -DENABLE_TUTORIALS=ON
make -j 2 tutorials
# Build libamrex and all tutorials
tutorials_cxx20:
name: [email protected] C++20 [tutorials]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Dependencies
run: .github/workflows/dependencies/dependencies_gcc10.sh
- name: Build & Install
run: |
mkdir build
cd build
cmake .. \
-DENABLE_TUTORIALS=ON \
-DCMAKE_CXX_STANDARD=20 \
-DCMAKE_C_COMPILER=$(which gcc-10) \
-DCMAKE_CXX_COMPILER=$(which g++-10) \
-DCMAKE_Fortran_COMPILER=$(which gfortran-10)
make -j 2 tutorials
# Build libamrex and all tutorials w/o MPI
tutorials-nonmpi:
name: [email protected] C++14 non-MPI [tutorials]
Expand Down

0 comments on commit 1b30da6

Please sign in to comment.