Skip to content

prog; implement binv4 spec #16

prog; implement binv4 spec

prog; implement binv4 spec #16

Workflow file for this run

name: CI Builds
on:
push:
branches: ["main"]
paths:
- 'crates/**'
- '.github/workflows/**'
# pull_request:
# branches: ["main"]
# paths:
# - 'crates/**'
# - '.github/workflows/**'
defaults:
run:
shell: bash
jobs:
package:
strategy:
matrix:
include:
- { name: windows, os: windows-latest, cross-target: "" }
name: Package plugin binaries
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Fetch all git history
run: git fetch --force --prune --tags --unshallow
- name: Install dependencies
if: startsWith(matrix.os, 'ubuntu')
run: |
sudo apt-get update
sudo apt-get install -y libasound2-dev libgl-dev libjack-dev libx11-xcb-dev libxcb1-dev libxcb-dri2-0-dev libxcb-icccm4-dev libxcursor-dev libxkbcommon-dev libxcb-shape0-dev libxcb-xfixes0-dev
- uses: actions/cache@v3
# FIXME: Caching `target/` causes the Windows runner to blow up after some time
if: startsWith(matrix.os, 'windows')
with:
path: |
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
key: ${{ matrix.name }}-${{ matrix.cross-target }}
- uses: actions/cache@v3
if: "!startsWith(matrix.os, 'windows')"
with:
path: |
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ matrix.name }}-${{ matrix.cross-target }}
- name: Set up Rust toolchain
uses: dtolnay/rust-toolchain@nightly
with:
targets: ${{ matrix.cross-target }}
# - name: Download ToyboxC artifacts
# if: startsWith(matrix.os, 'windows')
# run: ./download-binv3.bat
- name: Package all targets from bundler.toml
run: |
# Building can be sped up by specifying all packages in one go
package_args=()
for package in $(cargo xtask known-packages); do
package_args+=("-p" "$package")
done
runner_name=${{ matrix.name }}
if [[ $runner_name = 'macos-universal' ]]; then
export MACOSX_DEPLOYMENT_TARGET=10.13
cargo xtask bundle-universal "${package_args[@]}" --release
else
cross_target=${{ matrix.cross-target }}
if [[ -n $cross_target ]]; then
package_args+=("--target" "$cross_target")
fi
cargo xtask bundle "${package_args[@]}" --release
fi