fix(renderer): mark the parked artifact LUTs as intentionally unread #14
Workflow file for this run
This file contains hidden or 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: liborender Release | |
| # Triggered by a liborender-v* tag. | |
| # Builds liborender.so (Linux) + orender.dll (Windows), bundles each with the | |
| # cbindgen-generated orender.h header, and creates a draft GitHub release. | |
| # | |
| # Unlike the Studio release workflow, this build needs NO PipeWire / ASIO / | |
| # Tauri toolchains: orender_ffi only pulls orender_engine (audio-free by | |
| # design — see runtime_control::HostControlHandler). | |
| on: | |
| push: | |
| tags: | |
| - 'liborender-v*' | |
| workflow_dispatch: | |
| jobs: | |
| # Release artifacts must originate from the `release` branch: fail fast on a | |
| # tag pushed from main or a feature branch. | |
| guard: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| fetch-depth: 0 | |
| - name: Tag must be on the release branch | |
| if: startsWith(github.ref, 'refs/tags/') | |
| run: | | |
| git fetch --no-tags origin +refs/heads/release:refs/remotes/origin/release | |
| if git merge-base --is-ancestor "$GITHUB_SHA" origin/release; then | |
| echo "OK: $GITHUB_SHA is contained in origin/release" | |
| else | |
| echo "::error::Tag $GITHUB_REF_NAME ($GITHUB_SHA) is not on the 'release' branch. Cut release tags from 'release' (merge main->release, then tag)." | |
| exit 1 | |
| fi | |
| # liborender-v* tags name the crate version (see ABI.md's version table); | |
| # a mismatched tag would publish artifacts whose orender_build_id() | |
| # contradicts the release name. | |
| - name: Tag must match the orender_ffi crate version | |
| if: startsWith(github.ref, 'refs/tags/') | |
| run: | | |
| crate_version=$(sed -n 's/^version = "\(.*\)"$/\1/p' omniphony-renderer/orender_ffi/Cargo.toml | head -1) | |
| tag_version="${GITHUB_REF_NAME#liborender-v}" | |
| if [ "$crate_version" != "$tag_version" ]; then | |
| echo "::error::Tag $GITHUB_REF_NAME does not match orender_ffi version $crate_version. Bump orender_ffi/Cargo.toml (and regenerate the header) before tagging." | |
| exit 1 | |
| fi | |
| echo "OK: tag matches orender_ffi $crate_version" | |
| build-linux: | |
| needs: guard | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Build orender_ffi (release) | |
| run: cargo build --release -p orender_ffi | |
| working-directory: omniphony-renderer | |
| env: | |
| RUSTFLAGS: -D warnings | |
| - name: Package (zip) | |
| run: | | |
| mkdir -p staging | |
| cp omniphony-renderer/target/release/liborender.so staging/ | |
| cp omniphony-renderer/orender_ffi/include/orender.h staging/ | |
| cd staging | |
| zip "../${GITHUB_REF_NAME}-linux-x86_64.zip" liborender.so orender.h | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: liborender-linux-x86_64 | |
| path: ${{ github.ref_name }}-linux-x86_64.zip | |
| build-windows: | |
| needs: guard | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Build orender_ffi (release) | |
| run: cargo build --release -p orender_ffi | |
| working-directory: omniphony-renderer | |
| env: | |
| RUSTFLAGS: -D warnings | |
| - name: Package (zip) | |
| shell: pwsh | |
| run: | | |
| New-Item -ItemType Directory -Force -Path staging | Out-Null | |
| Copy-Item omniphony-renderer/target/release/orender.dll staging/ | |
| Copy-Item omniphony-renderer/orender_ffi/include/orender.h staging/ | |
| Compress-Archive -Path staging/orender.dll, staging/orender.h ` | |
| -DestinationPath "${env:GITHUB_REF_NAME}-windows-x86_64.zip" | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: liborender-windows-x86_64 | |
| path: ${{ github.ref_name }}-windows-x86_64.zip | |
| build-macos: | |
| needs: guard | |
| runs-on: macos-14 | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Build orender_ffi (release) | |
| run: cargo build --release -p orender_ffi | |
| working-directory: omniphony-renderer | |
| env: | |
| RUSTFLAGS: -D warnings | |
| - name: Package (zip) | |
| run: | | |
| mkdir -p staging | |
| cp omniphony-renderer/target/release/liborender.dylib staging/ | |
| cp omniphony-renderer/orender_ffi/include/orender.h staging/ | |
| cd staging | |
| zip "../${GITHUB_REF_NAME}-macos-arm64.zip" liborender.dylib orender.h | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: liborender-macos-arm64 | |
| path: ${{ github.ref_name }}-macos-arm64.zip | |
| release: | |
| needs: [build-linux, build-windows, build-macos] | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Download Linux artifact | |
| uses: actions/download-artifact@v8 | |
| with: | |
| name: liborender-linux-x86_64 | |
| - name: Download Windows artifact | |
| uses: actions/download-artifact@v8 | |
| with: | |
| name: liborender-windows-x86_64 | |
| - name: Download macOS artifact | |
| uses: actions/download-artifact@v8 | |
| with: | |
| name: liborender-macos-arm64 | |
| - name: Create draft release | |
| uses: softprops/action-gh-release@v3 | |
| with: | |
| draft: true | |
| name: ${{ github.ref_name }} | |
| files: | | |
| ${{ github.ref_name }}-linux-x86_64.zip | |
| ${{ github.ref_name }}-windows-x86_64.zip | |
| ${{ github.ref_name }}-macos-arm64.zip |