Include cstdint for uint64_t #290
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: Build and Test | |
on: | |
push: | |
tags: | |
- '**' | |
branches: | |
- '**' | |
env: | |
VCPKG_OVERLAY_TRIPLETS: cmake/triplets | |
VCPKG_OVERLAY_PORTS: cmake/ports | |
AWS_ACCESS_KEY_ID: ${{secrets.GHBIN_ACCESS_KEY}} | |
AWS_SECRET_ACCESS_KEY: ${{secrets.GHBIN_SECRET_KEY}} | |
AWS_DEFAULT_REGION: fra1 | |
AWS_ENDPOINT_URL: https://fra1.digitaloceanspaces.com | |
AWS_ENDPOINT_URL_S3: https://fra1.digitaloceanspaces.com | |
VCPKG_FEATURE_FLAGS: binarycaching | |
VCPKG_BINARY_SOURCES: "clear;x-aws,s3://gh-bin/bincache/,readwrite" | |
jobs: | |
deps-linux: | |
strategy: | |
fail-fast: false | |
matrix: | |
triplet: ["x64-linux"] | |
runs-on: ubuntu-24.04 | |
env: | |
VCPKG_DEFAULT_TRIPLET: ${{matrix.triplet}} | |
VCPKG_DEFAULT_HOST_TRIPLET: ${{matrix.triplet}} | |
steps: | |
- name: Install prerequisites | |
run: | | |
sudo apt-get update && sudo apt-get install -y ninja-build mesa-vulkan-drivers vulkan-tools wget xorg-dev libgl-dev libgl1-mesa-dev libvulkan-dev autoconf autoconf-archive libxrandr-dev libxinerama-dev libxcursor-dev mesa-common-dev libx11-xcb-dev libwayland-dev libxkbcommon-dev | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Vcpkg | |
shell: bash | |
env: | |
TMPDIR: ${{runner.temp}} | |
run: | | |
cmake -P upload-deps.cmake | |
- name: Upload buildtrees | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: vcpkg-buildtrees-${{matrix.triplet}} | |
retention-days: 10 | |
path: | | |
/usr/local/share/vcpkg/buildtrees | |
deps-windows: | |
strategy: | |
fail-fast: false | |
matrix: | |
triplet: | |
- x64-windows-static-md | |
- x86-windows-static-md | |
- arm64-windows-static-md | |
- x64-windows-static | |
- x86-windows-static | |
- arm64-windows-static | |
runs-on: windows-latest | |
env: | |
VCPKG_DEFAULT_TRIPLET: ${{matrix.triplet}} | |
VCPKG_DEFAULT_HOST_TRIPLET: ${{startsWith(matrix.triplet, 'arm64-') && 'x64-windows-static-md' || matrix.triplet}} | |
LLVM_DIR: "C:/Program Files/LLVM" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Vcpkg | |
run: | | |
cmake -P upload-deps.cmake | |
- name: Upload buildtrees | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: vcpkg-buildtrees-${{matrix.triplet}} | |
retention-days: 10 | |
path: | | |
C:/vcpkg/buildtrees | |
deps-macos: | |
strategy: | |
fail-fast: false | |
matrix: | |
triplet: ["x64-osx", "arm64-osx"] | |
runs-on: macos-latest | |
env: | |
VCPKG_DEFAULT_TRIPLET: ${{matrix.triplet}} | |
VCPKG_DEFAULT_HOST_TRIPLET: ${{matrix.triplet}} | |
VCPKG_ROOT: "$HOME/vcpkg" | |
steps: | |
- name: Install prerequisites | |
run: | | |
brew install ninja autoconf automake autoconf-archive | |
git clone /~https://github.com/microsoft/vcpkg "$HOME/vcpkg" | |
$HOME/vcpkg/bootstrap-vcpkg.sh -disableMetrics | |
echo "$HOME/vcpkg" >> "$GITHUB_PATH" | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Vcpkg | |
run: | | |
cmake -P upload-deps.cmake | |
- name: Upload buildtrees | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: vcpkg-buildtrees-${{matrix.triplet}} | |
retention-days: 10 | |
path: | | |
/Users/runner/vcpkg/buildtrees | |
build-macos: | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- triplet: "x64-osx" | |
arch: x86_64 | |
- triplet: "arm64-osx" | |
arch: arm64 | |
runs-on: macos-latest | |
needs: deps-macos | |
env: | |
VCPKG_DEFAULT_TRIPLET: ${{matrix.triplet}} | |
VCPKG_DEFAULT_HOST_TRIPLET: ${{matrix.triplet}} | |
VCPKG_ROOT: "$HOME/vcpkg" | |
steps: | |
- name: Install prerequisites | |
run: | | |
brew install ninja autoconf automake autoconf-archive | |
git clone /~https://github.com/microsoft/vcpkg "$HOME/vcpkg" | |
$HOME/vcpkg/bootstrap-vcpkg.sh -disableMetrics | |
echo "VCPKG_INSTALLATION_ROOT=$HOME/vcpkg" >> $GITHUB_ENV | |
echo "$HOME/vcpkg" >> "$GITHUB_PATH" | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Build | |
run: | | |
cmake -GNinja -S . -B build-release -DBRISK_TESTS=OFF -DBRISK_EXAMPLES=OFF -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DCMAKE_OSX_ARCHITECTURES=${{matrix.arch}} -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=$VCPKG_INSTALLATION_ROOT/scripts/buildsystems/vcpkg.cmake -DCMAKE_BUILD_TYPE=Release | |
cmake --build build-release --target install | |
cmake -GNinja -S . -B build-debug -DBRISK_TESTS=OFF -DBRISK_EXAMPLES=OFF -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DCMAKE_OSX_ARCHITECTURES=${{matrix.arch}} -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=$VCPKG_INSTALLATION_ROOT/scripts/buildsystems/vcpkg.cmake -DCMAKE_BUILD_TYPE=Debug | |
cmake --build build-debug --target install | |
cd dist | |
cmake -E tar cJ "${{github.workspace}}/Brisk-Prebuilt-${{github.ref_type == 'tag' && github.ref_name || github.sha}}-${{matrix.triplet}}.tar.xz" . | |
- name: Binaries | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{matrix.triplet}} | |
retention-days: 90 | |
path: | | |
Brisk-*.tar.xz | |
build-linux: | |
strategy: | |
fail-fast: false | |
matrix: | |
triplet: ["x64-linux"] | |
runs-on: ubuntu-24.04 | |
needs: deps-linux | |
env: | |
VCPKG_DEFAULT_TRIPLET: ${{matrix.triplet}} | |
VCPKG_DEFAULT_HOST_TRIPLET: ${{matrix.triplet}} | |
steps: | |
- name: Install prerequisites | |
run: | | |
sudo apt-get update && sudo apt-get install -y ninja-build mesa-vulkan-drivers vulkan-tools wget xorg-dev libgl-dev libgl1-mesa-dev libvulkan-dev autoconf autoconf-archive libxrandr-dev libxinerama-dev libxcursor-dev mesa-common-dev libx11-xcb-dev libwayland-dev libxkbcommon-dev | |
wget -O - https://apt.llvm.org/llvm.sh | sudo bash -s - 19 | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Build | |
run: | | |
cmake -GNinja -S . -B build-release -DBRISK_TESTS=OFF -DBRISK_EXAMPLES=OFF -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=$VCPKG_INSTALLATION_ROOT/scripts/buildsystems/vcpkg.cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_COMPILER=clang++-19 -DCMAKE_C_COMPILER=clang-19 | |
cmake --build build-release --target install | |
cmake -GNinja -S . -B build-debug -DBRISK_TESTS=OFF -DBRISK_EXAMPLES=OFF -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=$VCPKG_INSTALLATION_ROOT/scripts/buildsystems/vcpkg.cmake -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_COMPILER=clang++-19 -DCMAKE_C_COMPILER=clang-19 | |
cmake --build build-debug --target install | |
cd dist | |
cmake -E tar cJ "${{github.workspace}}/Brisk-Prebuilt-${{github.ref_type == 'tag' && github.ref_name || github.sha}}-${{matrix.triplet}}.tar.xz" . | |
- name: Binaries | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{matrix.triplet}} | |
retention-days: 90 | |
path: | | |
Brisk-*.tar.xz | |
build-windows: | |
strategy: | |
fail-fast: false | |
matrix: | |
triplet: | |
- x64-windows-static-md | |
- x86-windows-static-md | |
- arm64-windows-static-md | |
- x64-windows-static | |
- x86-windows-static | |
- arm64-windows-static | |
runs-on: windows-latest | |
needs: deps-windows | |
env: | |
VCPKG_DEFAULT_TRIPLET: ${{matrix.triplet}} | |
VCPKG_DEFAULT_HOST_TRIPLET: ${{startsWith(matrix.triplet, 'arm64-') && 'x64-windows-static-md' || matrix.triplet}} | |
CXXFLAGS: ${{startsWith(matrix.triplet, 'arm64-') && '-target arm64-pc-windows-msvc' || (startsWith(matrix.triplet, 'x86-') && '-m32' || '')}} | |
CFLAGS: ${{startsWith(matrix.triplet, 'arm64-') && '-target arm64-pc-windows-msvc' || (startsWith(matrix.triplet, 'x86-') && '-m32' || '')}} | |
LLVM_DIR: "C:/Program Files/LLVM" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Build | |
shell: cmd | |
run: | | |
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{startsWith(matrix.triplet, 'arm64-') && 'x64_arm64' || (startsWith(matrix.triplet, 'x64-') && 'x64' || 'x64_x86')}} | |
cmake -GNinja -S . -B build-release -DBRISK_TESTS=OFF -DBRISK_EXAMPLES=OFF -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DVCPKG_TARGET_TRIPLET=%VCPKG_DEFAULT_TRIPLET% -DVCPKG_HOST_TRIPLET=%VCPKG_DEFAULT_HOST_TRIPLET% -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=%VCPKG_INSTALLATION_ROOT%/scripts/buildsystems/vcpkg.cmake -DBRISK_WEBGPU=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_COMPILER="%LLVM_DIR%/bin/clang-cl.exe" -DCMAKE_C_COMPILER="%LLVM_DIR%/bin/clang-cl.exe" -DCMAKE_LINKER="%LLVM_DIR%/bin/lld-link.exe" | |
cmake --build build-release --target install | |
cmake -GNinja -S . -B build-debug -DBRISK_TESTS=OFF -DBRISK_EXAMPLES=OFF -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DVCPKG_TARGET_TRIPLET=%VCPKG_DEFAULT_TRIPLET% -DVCPKG_HOST_TRIPLET=%VCPKG_DEFAULT_HOST_TRIPLET% -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=%VCPKG_INSTALLATION_ROOT%/scripts/buildsystems/vcpkg.cmake -DBRISK_WEBGPU=ON -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_COMPILER="%LLVM_DIR%/bin/clang-cl.exe" -DCMAKE_C_COMPILER="%LLVM_DIR%/bin/clang-cl.exe" -DCMAKE_LINKER="%LLVM_DIR%/bin/lld-link.exe" | |
cmake --build build-debug --target install | |
cd dist | |
cmake -E tar cJ "${{github.workspace}}/Brisk-Prebuilt-${{github.ref_type == 'tag' && github.ref_name || github.sha}}-${{matrix.triplet}}.tar.xz" . | |
- name: Binaries | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{matrix.triplet}} | |
retention-days: 90 | |
path: | | |
Brisk-*.tar.xz | |
ubuntu-ninja-clang-x86_64: | |
runs-on: ubuntu-24.04 | |
needs: deps-linux | |
env: | |
VCPKG_DEFAULT_TRIPLET: x64-linux | |
VCPKG_DEFAULT_HOST_TRIPLET: x64-linux | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install prerequisites | |
run: | | |
sudo apt-get update && sudo apt-get install -y ninja-build mesa-vulkan-drivers vulkan-tools wget xorg-dev libgl-dev libgl1-mesa-dev libvulkan-dev autoconf autoconf-archive libxrandr-dev libxinerama-dev libxcursor-dev mesa-common-dev libx11-xcb-dev libwayland-dev libxkbcommon-dev | |
wget -O - https://apt.llvm.org/llvm.sh | sudo bash -s - 19 | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Configure | |
run: | | |
cmake -GNinja -S . -B build -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=$VCPKG_INSTALLATION_ROOT/scripts/buildsystems/vcpkg.cmake -DBRISK_LOG_TO_STDERR=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_CXX_COMPILER=clang++-19 -DCMAKE_C_COMPILER=clang-19 | |
- name: Build | |
run: | | |
cmake --build build | |
- name: Test | |
run: | | |
WGPU_LONG_TIMEOUT=1 ctest --test-dir build --output-on-failure -E "window_autotests" | |
- name: Upload test artifacts | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: test-artifacts-${{github.job}} | |
retention-days: 10 | |
path: | | |
build/*.png | |
build/*.log | |
ubuntu-make-gcc-x86_64: | |
runs-on: ubuntu-24.04 | |
needs: deps-linux | |
env: | |
VCPKG_DEFAULT_TRIPLET: x64-linux | |
VCPKG_DEFAULT_HOST_TRIPLET: x64-linux | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install prerequisites | |
run: | | |
sudo apt-get update && sudo apt-get install -y gcc-14 g++-14 ninja-build mesa-vulkan-drivers vulkan-tools wget xorg-dev libgl-dev libgl1-mesa-dev libvulkan-dev autoconf autoconf-archive libxrandr-dev libxinerama-dev libxcursor-dev mesa-common-dev libx11-xcb-dev libwayland-dev libxkbcommon-dev | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Configure | |
run: | | |
cmake -G"Unix Makefiles" -S . -B build -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=$VCPKG_INSTALLATION_ROOT/scripts/buildsystems/vcpkg.cmake -DBRISK_LOG_TO_STDERR=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_CXX_COMPILER=g++-14 -DCMAKE_C_COMPILER=gcc-14 | |
- name: Build | |
run: | | |
cmake --build build | |
- name: Test | |
run: | | |
WGPU_LONG_TIMEOUT=1 ctest --test-dir build --output-on-failure -E "window_autotests" | |
- name: Upload test artifacts | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: test-artifacts-${{github.job}} | |
retention-days: 10 | |
path: | | |
build/*.png | |
build/*.log | |
windows-ninja-clang-x86-64: | |
runs-on: windows-latest | |
needs: deps-windows | |
env: | |
VCPKG_DEFAULT_TRIPLET: x64-windows-static-md | |
VCPKG_DEFAULT_HOST_TRIPLET: x64-windows-static-md | |
LLVM_DIR: C:/Program Files/LLVM | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install prerequisites | |
run: | | |
choco install ninja --no-progress -y | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Configure | |
shell: cmd | |
run: | | |
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvars64.bat" | |
cmake -GNinja -S . -B build -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DVCPKG_TARGET_TRIPLET=%VCPKG_DEFAULT_TRIPLET% -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=%VCPKG_INSTALLATION_ROOT%/scripts/buildsystems/vcpkg.cmake -DBRISK_WEBGPU=ON -DBRISK_LOG_TO_STDERR=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_CXX_COMPILER="C:/Program Files/LLVM/bin/clang-cl.exe" -DCMAKE_C_COMPILER="C:/Program Files/LLVM/bin/clang-cl.exe" -DCMAKE_LINKER="C:/Program Files/LLVM/bin/lld-link.exe" | |
- name: Build | |
run: | | |
cmake --build build | |
- name: Test | |
run: | | |
ctest --test-dir build --output-on-failure | |
- name: Upload test artifacts | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: test-artifacts-${{github.job}} | |
retention-days: 10 | |
path: | | |
build/*.png | |
build/*.log | |
windows-vs-x86: | |
runs-on: windows-latest | |
needs: deps-windows | |
env: | |
VCPKG_DEFAULT_TRIPLET: x86-windows-static-md | |
VCPKG_DEFAULT_HOST_TRIPLET: x86-windows-static-md | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Configure | |
shell: cmd | |
run: | | |
cmake -G"Visual Studio 17 2022" -A Win32 -S . -B build -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DVCPKG_TARGET_TRIPLET=%VCPKG_DEFAULT_TRIPLET% -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=%VCPKG_INSTALLATION_ROOT%/scripts/buildsystems/vcpkg.cmake -DBRISK_WEBGPU=ON -DBRISK_LOG_TO_STDERR=ON | |
- name: Build | |
run: | | |
cmake --build build --config RelWithDebInfo | |
- name: Test | |
run: | | |
ctest --test-dir build --build-config RelWithDebInfo --output-on-failure | |
- name: Upload test artifacts | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: test-artifacts-${{github.job}} | |
retention-days: 10 | |
path: | | |
build/*.png | |
build/*.log | |
windows-vs-clangcl-x86_64: | |
runs-on: windows-latest | |
needs: deps-windows | |
env: | |
VCPKG_DEFAULT_TRIPLET: x64-windows-static | |
VCPKG_DEFAULT_HOST_TRIPLET: x64-windows-static | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Configure | |
shell: cmd | |
run: | | |
cmake -G"Visual Studio 17 2022" -A x64 -T ClangCL -S . -B build -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DVCPKG_TARGET_TRIPLET=%VCPKG_DEFAULT_TRIPLET% -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=%VCPKG_INSTALLATION_ROOT%/scripts/buildsystems/vcpkg.cmake -DBRISK_WEBGPU=ON -DBRISK_LOG_TO_STDERR=ON | |
- name: Build | |
run: | | |
cmake --build build --config RelWithDebInfo | |
- name: Test | |
run: | | |
ctest --test-dir build --build-config RelWithDebInfo --output-on-failure | |
- name: Upload test artifacts | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: test-artifacts-${{github.job}} | |
retention-days: 10 | |
path: | | |
build/*.png | |
build/*.log | |
macos-ninja-clang-arm64: | |
runs-on: macos-latest | |
needs: deps-macos | |
env: | |
VCPKG_DEFAULT_TRIPLET: arm64-osx | |
VCPKG_DEFAULT_HOST_TRIPLET: arm64-osx | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install prerequisites | |
run: | | |
brew install ninja autoconf automake autoconf-archive | |
git clone /~https://github.com/microsoft/vcpkg "$HOME/vcpkg" | |
$HOME/vcpkg/bootstrap-vcpkg.sh -disableMetrics | |
echo "VCPKG_INSTALLATION_ROOT=$HOME/vcpkg" >> $GITHUB_ENV | |
echo "$HOME/vcpkg" >> "$GITHUB_PATH" | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Configure | |
run: | | |
cmake -GNinja -S . -B build -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DCMAKE_OSX_ARCHITECTURES=arm64 -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=$VCPKG_INSTALLATION_ROOT/scripts/buildsystems/vcpkg.cmake -DBRISK_LOG_TO_STDERR=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo | |
- name: Build | |
run: | | |
cmake --build build | |
- name: Test | |
run: | | |
ctest --test-dir build --output-on-failure | |
- name: Upload test artifacts | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: test-artifacts-${{github.job}} | |
retention-days: 10 | |
path: | | |
build/*.png | |
build/*.log | |
macos-ninja-clang-x86_64: | |
runs-on: macos-13 | |
needs: deps-macos | |
env: | |
VCPKG_DEFAULT_TRIPLET: x64-osx | |
VCPKG_DEFAULT_HOST_TRIPLET: x64-osx | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install prerequisites | |
run: | | |
brew install ninja automake autoconf-archive | |
- name: Acquire dependencies | |
run: | | |
cmake -DDEP_BUILD=OFF -P acquire-deps.cmake | |
- name: Configure | |
run: | | |
cmake -GNinja -S . -B build -DCMAKE_INSTALL_PREFIX=dist -DVCPKG_MANIFEST_MODE=OFF -DCMAKE_OSX_ARCHITECTURES=x86_64 -DVCPKG_INSTALLED_DIR=vcpkg_installed -DCMAKE_TOOLCHAIN_FILE=$VCPKG_INSTALLATION_ROOT/scripts/buildsystems/vcpkg.cmake -DBRISK_LOG_TO_STDERR=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo | |
- name: Build | |
run: | | |
cmake --build build | |
- name: Test | |
run: | | |
ctest --test-dir build --output-on-failure | |
- name: Upload test artifacts | |
if: failure() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: test-artifacts-${{github.job}} | |
retention-days: 10 | |
path: | | |
build/*.png | |
build/*.log | |
usage-linux: | |
strategy: | |
fail-fast: false | |
matrix: | |
triplet: ["x64-linux"] | |
runs-on: ubuntu-24.04 | |
needs: build-linux | |
steps: | |
- name: Install prerequisites | |
run: > | |
sudo apt-get update && sudo apt-get install -y ninja-build wget xorg-dev | |
libgl-dev libgl1-mesa-dev libvulkan-dev autoconf autoconf-archive libxrandr-dev | |
libxinerama-dev libxcursor-dev mesa-common-dev libx11-xcb-dev libwayland-dev libxkbcommon-dev | |
- name: Download artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
name: ${{matrix.triplet}} | |
- name: Extract Brisk | |
run: | | |
mkdir brisk-dist && cd brisk-dist | |
cmake -E tar xvf ../Brisk-Prebuilt-*.tar.xz | |
- name: Extract dependencies | |
run: | | |
mkdir vcpkg_exported && cd vcpkg_exported | |
cmake -E tar xvf ../Brisk-Dependencies-*.tar.xz | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
path: repo | |
- name: Configure | |
run: > | |
cmake -G"Unix Makefiles" | |
-S repo/examples/showcase | |
-B build | |
-DCMAKE_BUILD_TYPE=Release | |
-DVCPKG_TARGET_TRIPLET=${{matrix.triplet}} | |
-DCMAKE_PREFIX_PATH=${{github.workspace}}/brisk-dist/lib/cmake | |
-DVCPKG_INSTALLED_DIR=${{github.workspace}}/vcpkg_exported/installed | |
-DCMAKE_TOOLCHAIN_FILE=${{github.workspace}}/vcpkg_exported/scripts/buildsystems/vcpkg.cmake | |
- name: Build | |
run: | | |
cmake --build build | |
- name: Upload usage artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: showcase-${{matrix.triplet}} | |
retention-days: 30 | |
path: | | |
build/showcase | |
usage-macos: | |
strategy: | |
fail-fast: false | |
matrix: | |
triplet: ["x64-osx", "arm64-osx"] | |
runs-on: macos-latest | |
needs: build-macos | |
steps: | |
- name: Download artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
name: ${{matrix.triplet}} | |
- name: Extract Brisk | |
run: | | |
mkdir brisk-dist && cd brisk-dist | |
cmake -E tar xvf ../Brisk-Prebuilt-*.tar.xz | |
- name: Extract dependencies | |
run: | | |
mkdir vcpkg_exported && cd vcpkg_exported | |
cmake -E tar xvf ../Brisk-Dependencies-*.tar.xz | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
path: repo | |
- name: Configure | |
run: > | |
cmake -GXcode | |
-S repo/examples/showcase | |
-DCMAKE_OSX_ARCHITECTURES=${{ startsWith(matrix.triplet, 'x64-') && 'x86_64' || 'arm64' }} | |
-B build | |
-DVCPKG_TARGET_TRIPLET=${{matrix.triplet}} | |
-DCMAKE_PREFIX_PATH=${{github.workspace}}/brisk-dist/lib/cmake | |
-DVCPKG_INSTALLED_DIR=${{github.workspace}}/vcpkg_exported/installed | |
-DCMAKE_TOOLCHAIN_FILE=${{github.workspace}}/vcpkg_exported/scripts/buildsystems/vcpkg.cmake | |
- name: Build | |
run: | | |
cmake --build build --config Release | |
- name: Upload usage artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: showcase-${{matrix.triplet}} | |
retention-days: 30 | |
path: | | |
build/Release/showcase.app | |
usage-windows: | |
strategy: | |
fail-fast: false | |
matrix: | |
triplet: | |
- x64-windows-static-md | |
- x86-windows-static-md | |
- arm64-windows-static-md | |
- x64-windows-static | |
- x86-windows-static | |
- arm64-windows-static | |
runs-on: windows-latest | |
needs: build-windows | |
steps: | |
- name: Download artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
name: ${{matrix.triplet}} | |
- name: Extract Brisk | |
run: | | |
mkdir brisk-dist && cd brisk-dist | |
cmake -E tar xvf (Get-ChildItem ../Brisk-Prebuilt-*.tar.xz).FullName | |
- name: Extract dependencies | |
run: | | |
mkdir vcpkg_exported && cd vcpkg_exported | |
cmake -E tar xvf (Get-ChildItem ../Brisk-Dependencies-*.tar.xz).FullName | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
path: repo | |
- name: Configure | |
run: > | |
cmake -G"Visual Studio 17 2022" | |
-A ${{ startsWith(matrix.triplet, 'x86-') && 'Win32' || (startsWith(matrix.triplet, 'arm64-') && 'ARM64' || 'x64') }} | |
-S repo/examples/showcase | |
-B build | |
-DVCPKG_TARGET_TRIPLET=${{matrix.triplet}} | |
-DVCPKG_HOST_TRIPLET=${{startsWith(matrix.triplet, 'arm64-') && 'x64-windows-static-md' || matrix.triplet}} | |
-DCMAKE_PREFIX_PATH=${{github.workspace}}/brisk-dist/lib/cmake | |
-DVCPKG_INSTALLED_DIR=${{github.workspace}}/vcpkg_exported/installed | |
-DCMAKE_TOOLCHAIN_FILE=${{github.workspace}}/vcpkg_exported/scripts/buildsystems/vcpkg.cmake | |
"-DCMAKE_MSVC_RUNTIME_LIBRARY=MultiThreaded$<$<CONFIG:Debug>:Debug>${{ endsWith(matrix.triplet, '-md') && 'DLL' || '' }}" | |
- name: Build | |
run: | | |
cmake --build build --config Release | |
- name: Upload usage artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: showcase-${{matrix.triplet}} | |
retention-days: 30 | |
path: | | |
build/Release/showcase.exe | |
upload-release: | |
if: startsWith(github.ref, 'refs/tags/') | |
runs-on: ubuntu-24.04 | |
permissions: | |
contents: write | |
needs: [build-windows, build-linux, build-macos] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Download artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
merge-multiple: true | |
- name: Release | |
env: | |
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} | |
run: >- | |
gh release create --draft --notes "Draft Release" --title "Brisk ${{github.ref_name}}" | |
${{github.ref_name}} | |
Brisk-* |