Skip to content

Update release-build.yml #13

Update release-build.yml

Update release-build.yml #13

Workflow file for this run

name: Build DSU Server

Check failure on line 1 in .github/workflows/release-build.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/release-build.yml

Invalid workflow file

`on.workflow_run` does not reference any workflows. See https://docs.github.com/actions/learn-github-actions/events-that-trigger-workflows#workflow_run for more information
on:
release:
types: [published]
workflow_run:
jobs:
build-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: sudo apt-get update && sudo apt-get install -y libbluetooth-dev pkg-config cmake make g++
- name: Download psmoveapi
run: |
mkdir -p psmoveapi_install
curl -L https://github.com/thp/psmoveapi/releases/download/4.0.12/psmoveapi-4.0.12-linux.tar.gz -o psmoveapi.tar.gz
tar -xzf psmoveapi.tar.gz -C psmoveapi_install --strip-components=1
- name: Build
run: |
cmake -S . -B build -DPSMOVE_ROOT=$PWD/psmoveapi_install
cmake --build build --config Release
- name: Upload release asset
uses: softprops/action-gh-release@v1
with:
files: build/dsu_server_psmove
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
build-macos:
runs-on: macos-13 # Intel runner to match x86_64 binaries
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: brew install cmake pkg-config
- name: Download psmoveapi
run: |
mkdir -p psmoveapi_install
curl -L https://github.com/thp/psmoveapi/releases/download/4.0.12/psmoveapi-4.0.12-macos.tar.gz -o psmoveapi.tar.gz
tar -xzf psmoveapi.tar.gz -C psmoveapi_install --strip-components=1
- name: Build
run: |
cmake -S . -B build -DPSMOVE_ROOT=$PWD/psmoveapi_install
cmake --build build --config Release
- name: Upload release asset
uses: softprops/action-gh-release@v1
with:
files: build/dsu_server_psmove
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
build-windows-msvc:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- name: Download psmoveapi
run: |
mkdir psmoveapi_install
curl -L https://github.com/thp/psmoveapi/releases/download/4.0.12/psmoveapi-4.0.12-windows-msvc2017-x64.zip -o psmoveapi.zip
tar -xf psmoveapi.zip -C psmoveapi_install --strip-components=1
- name: Build (MSVC)
run: |
cmake -S . -B build -G "Visual Studio 17 2022" -A x64 -DPSMOVE_ROOT=%cd%/psmoveapi_install
cmake --build build --config Release
- name: Upload release asset
uses: softprops/action-gh-release@v1
with:
files: build/Release/dsu_server_psmove.exe
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
build-windows-mingw:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- name: Install unzip
run: choco install unzip -y
- name: Download psmoveapi
run: |
mkdir psmoveapi_install
curl -L https://github.com/thp/psmoveapi/releases/download/4.0.12/psmoveapi-4.0.12-mingw64.zip -o psmoveapi.zip
unzip psmoveapi.zip -d psmoveapi_install
- name: Build (MinGW)
run: |
cmake -S . -B build -G "MinGW Makefiles" -DPSMOVE_ROOT=%cd%/psmoveapi_install
cmake --build build --config Release
- name: Upload release asset
uses: softprops/action-gh-release@v1
with:
files: build/dsu_server_psmove.exe
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}