More work on the GP integration #401
Workflow file for this run
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: CMake | |
on: | |
push: | |
pull_request: | |
branches: [ main ] | |
release: | |
types: [ created ] | |
permissions: | |
contents: read | |
pages: write | |
id-token: write | |
jobs: | |
build: | |
name: "${{ matrix.configurations.name }} | ${{ matrix.cmake-build-type }}" | |
environment: configure coverage | |
runs-on: ${{ matrix.configurations.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
configurations: | |
- name: Ubuntu Latest gcc | |
os: ubuntu-22.04 | |
compiler: gcc | |
# - name: Ubuntu Latest clang | |
# os: ubuntu-22.04 # pre-release, ubuntu-latest still points to ubuntu-2004 | |
# compiler: clang | |
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) | |
cmake-build-type: [ Release ] #, Debug ] | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 100 | |
- name: Cache | |
uses: actions/cache@v3 | |
env: | |
cache-name: cache-fetchContent-cache | |
with: | |
path: ${{runner.workspace}}/build/_deps | |
key: ${{ runner.os }}-${{ matrix.configurations.compiler }}-${{ matrix.cmake-build-type }}-${{ hashFiles('CMakeLists.txt') }}-${{ hashFiles('cmake/Dependencies.cmake') }} | |
- name: Setup emsdk | |
uses: mymindstorm/setup-emsdk@v12 | |
with: | |
version: 3.1.41 | |
actions-cache-folder: 'emsdk-cache' | |
- name: Install gcc-12 | |
if: matrix.configurations.compiler == 'gcc' | |
run: | | |
sudo apt update | |
sudo apt install -y gcc-12 g++-12 | |
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 110 --slave /usr/bin/g++ g++ /usr/bin/g++-12 --slave /usr/bin/gcov gcov /usr/bin/gcov-12 | |
- name: Install openGL | |
run: | | |
sudo apt update | |
sudo apt install -y libx11-dev libgl1-mesa-dev libsdl2-dev | |
- name: Configure CMake | |
shell: bash | |
run: cmake -S . -B ../build -DCMAKE_BUILD_TYPE=${{ matrix.cmake-build-type }} -DEMCMAKE_COMMAND=`which emcmake` | |
- name: Build | |
shell: bash | |
run: cmake --build ../build | |
- name: Setup Pages | |
uses: actions/configure-pages@v3 | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v1 | |
with: | |
path: '../build/CMakeExternals/Build/ui-wasm/web/' | |
deploy_pages: | |
name: Deploy to GitHub Pages | |
if: ${{ github.ref_name == 'main' && github.event_name == 'push' }} | |
environment: github-pages | |
runs-on: ubuntu-22.04 | |
needs: build | |
steps: | |
- name: "Setup Pages" | |
uses: actions/configure-pages@v3 | |
- name: "Deploy to pages" | |
id: deployment | |
uses: actions/deploy-pages@v2 |