Skip to content

Remove vgem check

Remove vgem check #460

Workflow file for this run

name: CMake Build
'on':
push:
branches:
- master
- testing
- feature**
tags: '*'
jobs:
Release:
name: "Create release"
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- name: Printing some info
run: echo "Received ref $GITHUB_REF"
- name: Create release
if: startsWith(github.ref, 'refs/tags/')
run: gh release create ${GITHUB_REF:10} -R ${{ github.repository }} -p -t "Automatic
Release ${GITHUB_REF:10}" -n "Automatically generated by Actions" --target
${{ github.sha }}
Linux_HostTools:
runs-on: ubuntu-latest
needs: Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
name: Linux host tools
steps:
- uses: actions/checkout@v6
with:
submodules: true
path: source
- uses: ./source/.github/actions/cmake-setup
- name: Installing build-essential
run: |
sudo rm /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get update
sudo apt install build-essential nasm
- uses: ./source/.github/actions/build-host-tools
with:
cache_path: source/multi_build/host-x64-linux-native
Linux:
runs-on: ubuntu-latest
needs: Linux_HostTools
strategy:
fail-fast: false
matrix:
include:
- variant: android:arm-neon:19:rel
artifact: android-arm-neon-19
- variant: android:arm-neon:24:rel
artifact: android-arm-neon-24
- variant: android:arm64:30-gl:rel
artifact: android-arm64-30-gl
- variant: android:arm64:32:rel
artifact: android-arm64-32
- variant: beaglebone:arm-buildroot-linux-gnueabihf:ti-sgx:rel
artifact: beaglebone-arm-buildroot-linux-gnueabihf-ti-sgx
- variant: desktop:aarch64-buildroot-linux-gnu:multi:rel
artifact: desktop-aarch64-buildroot-linux-gnu-multi
- variant: desktop:arm-buildroot-linux-gnueabihf:sdl2:rel
artifact: desktop-arm-buildroot-linux-gnueabihf-sdl2
- variant: desktop:x86_64-buildroot-linux-gnu:multi:rel
artifact: desktop-x86_64-buildroot-linux-gnu-multi
- variant: desktop:x86_64-w64-mingw32:posix:rel
artifact: desktop-x86_64-w64-mingw32-posix
- variant: web:wasm32-emscripten:webgl2:rel
artifact: web-wasm32-emscripten-webgl2
- variant: web:wasm32-emscripten:webgl2-custom:rel
artifact: web-wasm32-emscripten-webgl2-custom
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MAP_ACCESS_TOKEN: ${{ secrets.MAP_ACCESS_TOKEN }}
name: ${{ matrix.variant }}
steps:
- uses: actions/checkout@v6
with:
submodules: true
path: source
- uses: ./source/.github/actions/cmake-setup
- uses: actions/setup-java@v5
if: startsWith(matrix.variant, 'android:')
with:
distribution: 'adopt'
java-version: '17'
- name: Installing build-essential
run: |
sudo rm /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get update
sudo apt install build-essential inkscape flatpak nasm squashfs-tools
- name: Host tools cache
uses: actions/cache@v5
with:
path: source/multi_build/host-x64-linux-native
key: host-tools-${{ runner.os }}-${{ hashFiles('source/tools','toolchain/building.py','vcpkg.json','vcpkg-configuration.json') }}
fail-on-cache-miss: true
- name: Space summary
run: |
echo "::info::Total disk usage"
df -h
echo "::info::Source dir space usage"
df -h source/
echo "::info::du in source/"
du -hd2 source/
echo "::info::du in ."
du -hd2 .
- uses: ./source/.github/actions/build-project
with:
variant: ${{ matrix.variant }}
artifact: ${{ matrix.artifact }}
embedded_report_url: "https://reports.speen.dev"
- name: Summarize binary sizes
run: du -h source/multi_build/${{matrix.artifact}}/bin/* source/multi_build/${{matrix.artifact}}/lib/*.so* source/multi_build/${{matrix.artifact}}/packaged/*/* || true
- name: Uploading artifacts
uses: actions/upload-artifact@v7
with:
name: ${{matrix.artifact}}
path: |
source/multi_build/${{matrix.artifact}}/install/bin
source/multi_build/${{matrix.artifact}}/install/lib
!source/multi_build/${{matrix.artifact}}/install/lib/*.a
source/multi_build/${{matrix.artifact}}/install/packaged
if-no-files-found: error
macOS_HostTools:
runs-on: macos-latest
needs: Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
name: macOS host tools
steps:
- uses: actions/checkout@v6
with:
submodules: true
path: source
- uses: ./source/.github/actions/cmake-setup
- name: List sysctl
run: sysctl -a
- name: Installing Inkscape + other stuff
run: |
brew install --cask inkscape
brew install automake libtool
- uses: ./source/.github/actions/build-host-tools
with:
cache_path: source/multi_build/host-arm64-osx
build_args: dbg
- name: List files
run: |
du -hd4 source/multi_build/host-arm64-osx/
find source/multi_build/host-arm64-osx/vcpkg_installed/arm64-osx/tools -type f
macOS:
runs-on: macos-latest
needs: macOS_HostTools
strategy:
fail-fast: false
matrix:
include:
- variant: desktop:x86_64-darwin:macos:rel
artifact: desktop-x86_64-darwin-macos
mode: rel
- variant: desktop:universal-darwin:macos:dbg
artifact: desktop-universal-darwin-macos
- variant: ios:x86_64-darwin:simulator:dbg
artifact: ios-x86_64-darwin-simulator
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
name: ${{ matrix.variant }}
steps:
- uses: actions/checkout@v6
with:
submodules: true
path: source
- uses: ./source/.github/actions/cmake-setup
- name: Installing Inkscape + other stuff
run: |
brew install --cask inkscape
brew install automake autoconf libtool
# git cmake ninja pkg-config wget
- name: Host tools cache
uses: actions/cache@v5
with:
path: source/multi_build/host-arm64-osx
key: host-tools-${{ runner.os }}-${{ hashFiles('source/tools','toolchain/building.py','vcpkg.json','vcpkg-configuration.json') }}
fail-on-cache-miss: true
- uses: ./source/.github/actions/build-project
with:
variant: ${{ matrix.variant }}
artifact: ${{ matrix.artifact }}
- name: Creating archive of artifacts
run: tar cvf apps.tar source/multi_build/${{matrix.artifact}}/install/bin
- name: Uploading artifacts
uses: actions/upload-artifact@v7
with:
name: ${{matrix.artifact}}
path: apps.tar
if-no-files-found: error
Test_x86_64_mesa:
if: ${{ always() }}
name: "Software render test (MESA, ${{ matrix.variant }})"
needs: Linux
runs-on: ubuntu-latest
permissions:
actions: read
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MAP_ACCESS_TOKEN: ${{ secrets.MAP_ACCESS_TOKEN }}
strategy:
fail-fast: false
matrix:
include:
- variant: core_33
dummy_plug: dummy_plug_core_33.json
- variant: core_43
dummy_plug: dummy_plug_core_43.json
- variant: core_45
dummy_plug: dummy_plug_core_45.json
- variant: es_20
dummy_plug: dummy_plug_es_20.json
- variant: es_30
dummy_plug: dummy_plug_es_30.json
- variant: es_32
dummy_plug: dummy_plug_es_32.json
steps:
- uses: actions/checkout@v6
with:
path: source
- name: Installing AppImage/media dependencies
run: |
sudo apt update
sudo apt install libfuse2 ffmpeg
- name: Downloading desktop-x86_64-buildroot-linux-gnu-multi artifacts
uses: actions/download-artifact@v8
with:
name: desktop-x86_64-buildroot-linux-gnu-multi
path: artifacts/
- name: Relocating artifacts
run: |
mkdir -p source/multi_build/desktop-x86_64-buildroot-linux-gnu-multi
mv artifacts/* source/multi_build/desktop-x86_64-buildroot-linux-gnu-multi/
chmod +x source/multi_build/desktop-x86_64-buildroot-linux-gnu-multi/packaged/*/*
- name: Apply VGEM driver
run: sudo modprobe vgem
- name: Run dummy plug tests
run: |
DUMMY_PLUG=${{ matrix.dummy_plug }} source/.github/tests/test_blam_graphics.sh
- name: Convert audio samples to .wav
run: |
ffmpeg -f f32le -ar 48k -ac 2 -i "/tmp/Blam Graphics/rendered_audio" -c:a copy "/tmp/Blam Graphics/rendered_audio.wav"
rm "/tmp/Blam Graphics/rendered_audio"
- name: Uploading test artifacts
uses: actions/upload-artifact@v7
with:
name: dummy_plug_test_${{ matrix.variant }}
path: "/tmp/Blam Graphics"
if-no-files-found: error
Test_x86_64_mesa_gather:
if: ${{ always() }}
name: "Gather test results"
needs: Test_x86_64_mesa
runs-on: ubuntu-latest
permissions:
actions: read
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v6
with:
path: source
- name: Downloading test artifacts
uses: actions/download-artifact@v8
with:
pattern: dummy_plug_test_*
path: artifacts/
- name: Gathering test results into HTML page
run: |
ls -R artifacts/
source/.github/tests/generate_test_page.sh artifacts/
- name: Upload generated page
uses: actions/upload-artifact@v7
with:
name: dummy_plug_results
path: "artifacts/generated/"
if-no-files-found: error
Deploy:
if: ${{ always() }}
needs:
- Linux
- macOS
permissions:
actions: read
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
runs-on: ubuntu-latest
steps:
- name: Gathering artifacts
uses: actions/download-artifact@v8
with:
path: artifacts/
- name: Generating GitHub Pages archive
run: |
mkdir -p _site/downloads/ _site/custom/
curl -L -H "Accept: application/vnd.github+json" -H "Authorization: Bearer ${GITHUB_TOKEN}" -H "X-GitHub-Api-Version: 2022-11-28" https://api.github.com/repos/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}/artifacts -o _site/artifacts.json
cp artifacts/web-wasm32-emscripten-webgl2/bin/BlamGraphics.bundle/favicon.ico _site/
cp -r artifacts/web-wasm32-emscripten-webgl2/bin _site/
cp -r artifacts/web-wasm32-emscripten-webgl2-custom/bin _site/custom/
for f in $(find artifacts/ -mindepth 1 -maxdepth 1); do pushd $f; [[ -f apps.tar ]] && (tar xvf apps.tar && rm apps.tar); tar Jcvf ../../_site/downloads/$(basename $f).tar.xz .; popd; done
- name: Uploading GitHub Pages examples
uses: actions/upload-pages-artifact@v4
- name: Deploy examples to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4