Added containers implementation #94
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
push: | |
branches: [ "master" ] | |
pull_request: | |
branches: [ "master" ] | |
jobs: | |
linux: | |
timeout-minutes: 15 | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest] | |
build_type: [Debug, Release] | |
compiler: | |
- { cc: clang, cxx: 'clang++' } | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set Environment Variables | |
uses: ./.github/actions/setvars | |
with: | |
envFilePath: ./.github/variables/versions.env | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.x' | |
- run: pip install -U Jinja2 | |
- name: Get CMake and Ninja | |
uses: lukka/get-cmake@latest | |
with: | |
cmakeVersion: ${{ env.CMAKE_VERSION }} | |
ninjaVersion: ${{ env.NINJA_VERSION }} | |
- name: Install Clang | |
run: | | |
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - | |
sudo apt-add-repository "deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-${{ env.COMPILER_VERSION }} main" | |
sudo apt update | |
sudo apt install -y ${{ matrix.compiler.cc }}-${{ env.COMPILER_VERSION }} libc++-${{ env.COMPILER_VERSION }}-dev libc++abi-${{ env.COMPILER_VERSION }}-dev | |
- name: Install dependencies | |
run: | | |
sudo apt update | |
sudo apt install libxrandr-dev libxinerama-dev libxcursor-dev libxi-dev libxext-dev wayland-protocols libwayland-dev libxkbcommon-dev | |
sudo apt install libgl-dev | |
- name: Configure | |
env: | |
CC: ${{ matrix.compiler.cc }}-${{ env.COMPILER_VERSION }} | |
CXX: ${{ matrix.compiler.cxx }}-${{ env.COMPILER_VERSION }} | |
run: cmake -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DFLUX_GRAPHICS_API=OpenGL -DFLUX_FORCE_USE_LIBCXX=YES -B ${{ github.workspace }}/build/${{ matrix.os }}-${{ matrix.build_type }} -G Ninja | |
- name: Build | |
# Build your program with the given configuration | |
run: cmake --build ${{ github.workspace }}/build/${{ matrix.os }}-${{ matrix.build_type }} --config ${{ matrix.build_type }} | |
# Conditional test step for Debug builds only | |
- name: Run tests | |
if: ${{ matrix.build_type == 'Debug' }} | |
working-directory: ${{ github.workspace }}/build/${{ matrix.os }}-${{ matrix.build_type }} | |
env: | |
CTEST_OUTPUT_ON_FAILURE: 1 | |
run: ctest --timeout 30 -C Debug -j4 | |
windows: | |
timeout-minutes: 15 | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [windows-latest] | |
build_type: [Debug, Release] | |
compiler: | |
- { cc: clang, cxx: 'clang++' } | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set Environment Variables | |
uses: ./.github/actions/setvars | |
with: | |
envFilePath: ./.github/variables/versions.env | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.x' | |
- run: pip install -U Jinja2 | |
- name: Get CMake and Ninja | |
uses: lukka/get-cmake@latest | |
with: | |
cmakeVersion: ${{ env.CMAKE_VERSION }} | |
ninjaVersion: ${{ env.NINJA_VERSION }} | |
- name: Install LLVM and Clang | |
uses: KyleMayes/install-llvm-action@v2 | |
with: | |
version: ${{ env.COMPILER_VERSION }} | |
- name: Configure | |
env: | |
CC: ${{ matrix.compiler.cc }} | |
CXX: ${{ matrix.compiler.cxx }} | |
run: cmake -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DFLUX_GRAPHICS_API=OpenGL -B ${{ github.workspace }}/build/${{ matrix.os }}-${{ matrix.build_type }} -G Ninja | |
- name: Build | |
# Build your program with the given configuration | |
run: cmake --build ${{ github.workspace }}/build/${{ matrix.os }}-${{ matrix.build_type }} --config ${{ matrix.build_type }} | |
# Conditional test step for Debug builds only | |
- name: Run tests | |
if: ${{ matrix.build_type == 'Debug' }} | |
working-directory: ${{ github.workspace }}/build/${{ matrix.os }}-${{ matrix.build_type }} | |
env: | |
CTEST_OUTPUT_ON_FAILURE: 1 | |
run: ctest --timeout 30 -C Debug -j4 |