⚗️ try official GCC containers

This commit is contained in:
Niels Lohmann 2022-08-14 14:04:45 +02:00
parent 8fcdbf2e77
commit a17298480d
No known key found for this signature in database
GPG Key ID: 7F3CEA63AE251B69
2 changed files with 26 additions and 0 deletions

View File

@ -90,6 +90,21 @@ jobs:
github-token: ${{ secrets.GITHUB_TOKEN }} github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: ${{ github.workspace }}/build/json.info.filtered.noexcept path-to-lcov: ${{ github.workspace }}/build/json.info.filtered.noexcept
ci_test_compilers_gcc:
runs-on: ubuntu-latest
strategy:
matrix:
compiler: ['7.5.0', '8.5.0']
container: gcc:${{ matrix.compiler }}
steps:
- uses: actions/checkout@v3
- name: Install CMake
run: sudo apt-get update ; sudo apt-get install -y cmake
- name: Run CMake
run: cmake -S . -B build -DJSON_CI=On
- name: Build
run: cmake --build build --target ci_test_compiler_default
ci_test_compilers: ci_test_compilers:
runs-on: ubuntu-latest runs-on: ubuntu-latest
container: ghcr.io/nlohmann/json-ci:v2.4.0 container: ghcr.io/nlohmann/json-ci:v2.4.0

View File

@ -929,6 +929,17 @@ foreach(COMPILER g++-4.8 g++-4.9 g++-5 g++-6 g++-7 g++-8 g++-9 g++-10 g++-11 cla
unset(COMPILER_TOOL CACHE) unset(COMPILER_TOOL CACHE)
endforeach() endforeach()
add_custom_target(ci_test_compiler_default
COMMAND ${CMAKE_COMMAND}
-DCMAKE_BUILD_TYPE=Debug
-DJSON_BuildTests=ON -DJSON_FastTests=ON
-S${PROJECT_SOURCE_DIR} -B${PROJECT_BINARY_DIR}/build_compiler_default
${ADDITIONAL_FLAGS}
COMMAND ${CMAKE_COMMAND} --build ${PROJECT_BINARY_DIR}/build_compiler_default --parallel ${N}
COMMAND cd ${PROJECT_BINARY_DIR}/build_compiler_default && ${CMAKE_CTEST_COMMAND} --parallel ${N} --exclude-regex "test-unicode" --output-on-failure
COMMENT "Compile and test with default C++ compiler"
)
############################################################################### ###############################################################################
# CUDA example # CUDA example
############################################################################### ###############################################################################