Skip to content

Commit b203a29

Browse files
committed
Try running in ubuntu-18.04 container under ubuntu-latest (to get GCC 7)
1 parent b339dc4 commit b203a29

File tree

1 file changed

+50
-0
lines changed

1 file changed

+50
-0
lines changed

.github/workflows/ci.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -368,6 +368,56 @@ jobs:
368368
run: cmake --build build --target test_cmake_build
369369

370370

371+
gcc7:
372+
runs-on: ubuntu-latest
373+
strategy:
374+
fail-fast: false
375+
matrix:
376+
std:
377+
- 11
378+
python:
379+
- '3.8'
380+
381+
name: "🐍 ${{ matrix.python }} • GCC 7 • C++${{ matrix.std }} • x64"
382+
container: ubuntu-18.04
383+
384+
steps:
385+
- uses: actions/checkout@v4
386+
387+
- name: Add GCC
388+
run: apt-get update && apt-get install -y gcc
389+
390+
- name: Setup Python ${{ matrix.python }}
391+
uses: actions/setup-python@v5
392+
with:
393+
python-version: ${{ matrix.python }}
394+
395+
- name: Prepare env
396+
run: |
397+
python -m pip install -r tests/requirements.txt
398+
399+
- name: Configure
400+
shell: bash
401+
run: >
402+
cmake -S . -B build
403+
-DPYBIND11_WERROR=ON
404+
-DDOWNLOAD_CATCH=ON
405+
-DCMAKE_CXX_STANDARD=${{ matrix.std }}
406+
-DPYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)")
407+
408+
- name: Build
409+
run: cmake --build build -j 2
410+
411+
- name: Python tests
412+
run: cmake --build build --target pytest
413+
414+
- name: C++ tests
415+
run: cmake --build build --target cpptest
416+
417+
- name: Interface test
418+
run: cmake --build build --target test_cmake_build
419+
420+
371421
# Testing NVCC; forces sources to behave like .cu files
372422
cuda:
373423
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)