Skip to content

Adding GCC15 to CI, take 4 #115

Adding GCC15 to CI, take 4

Adding GCC15 to CI, take 4 #115

Workflow file for this run

name: Test
on:
push:
paths-ignore:
- 'README.md'
- '.gitignore'
- 'LICENSE'
- 'CHANGELOG.md'
- 'doc/**'
- 'tools/**'
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- { os: macos-latest }
- { os: windows-latest, module: true }
- { os: ubuntu-latest, compiler: gcc, version: 11 }
- { os: ubuntu-latest, compiler: gcc, version: 12 }
- { os: ubuntu-latest, compiler: gcc, version: 13 }
- { os: ubuntu-24.04, compiler: gcc, version: 14, module: true }
- { os: ubuntu-22.04, compiler: clang, version: 13 }
- { os: ubuntu-22.04, compiler: clang ,version: 14 }
- { os: ubuntu-22.04, compiler: clang, version: 15 }
- { os: ubuntu-22.04, compiler: clang, version: 16 }
- { os: ubuntu-latest, compiler: clang, version: 17 }
- { os: ubuntu-latest, compiler: clang, version: 18, module: true }
- { os: ubuntu-latest, compiler: clang, version: 19, module: true }
- { os: ubuntu-latest, compiler: clang, version: 20, module: true }
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: System Setup
shell: bash
run: |
if [[ '${{ matrix.os }}' == ubuntu-* ]]; then
if [[ '${{ matrix.compiler }}' == 'clang' ]]; then
wget https://apt.llvm.org/llvm.sh
chmod u+x llvm.sh
sudo ./llvm.sh ${{ matrix.version }}
sudo apt-get install -y clang-tools-${{ matrix.version }}
echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV
echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV
fi
if [[ '${{ matrix.compiler }}' == 'gcc' ]]; then
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install -y gcc-${{ matrix.version }} g++-${{ matrix.version }}
echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV
echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV
fi
mkdir bin
wget -qO- https://github.com/ninja-build/ninja/releases/download/v1.12.1/ninja-linux.zip | \
gunzip > bin/ninja
chmod a+x bin/ninja
echo PATH=`pwd`/bin:$PATH >> $GITHUB_ENV
echo "CMAKE_GENERATOR=-GNinja" >> $GITHUB_ENV
fi
if [[ '${{ matrix.module}}' == 'true' ]]; then
echo "CMAKE_ARGS=-DISPTR_ENABLE_MODULE=ON" >> $GITHUB_ENV
fi
- name: Configure
shell: bash
run: |
cmake $CMAKE_GENERATOR -S . -B build $CMAKE_ARGS -DISPTR_ENABLE_PYTHON=ON -DCMAKE_BUILD_TYPE=Release
- name: Build and Test
shell: bash
run: |
cmake --build build --config Release --target run-test
container:
runs-on: ubuntu-latest
container: ${{ matrix.container }}
strategy:
fail-fast: false
matrix:
include:
- {container: gcc:15.1, module: true}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: System Setup
shell: bash
run: |
apt-get update
apt-get install -y ninja-build
apt-get install -y python3-dev
export CMAKE_VERSION=3.28.6
wget https://github.com/Kitware/CMake/releases/download/v${CMAKE_VERSION}/cmake-${CMAKE_VERSION}-Linux-x86_64.sh \
-q -O /tmp/cmake-install.sh \
&& chmod u+x /tmp/cmake-install.sh \
&& /tmp/cmake-install.sh --skip-license --prefix=/usr \
rm -f /tmp/cmake-install.sh
if [[ '${{ matrix.module}}' == 'true' ]]; then
echo "CMAKE_ARGS=-DISPTR_ENABLE_MODULE=ON" >> $GITHUB_ENV
fi
- name: Configure
shell: bash
run: |
cmake $CMAKE_GENERATOR -S . -B build $CMAKE_ARGS -DISPTR_ENABLE_PYTHON=ON -DCMAKE_BUILD_TYPE=Release
- name: Build and Test
shell: bash
run: |
cmake --build build --config Release --target run-test