Skip to content
This repository has been archived by the owner on Jan 26, 2025. It is now read-only.

Update build-windows.yml #6

Update build-windows.yml

Update build-windows.yml #6

Workflow file for this run

name: Build [Windows]
on:
push:
branches: [ "main", "test" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- name: Download libzmq from vcpkg
uses: johnwason/vcpkg-action@v5
with:
pkgs: zeromq[draft]
triplet: x64-windows
token: ${{ github.token }}
- name: Move needed libzmq files
run: move "${{ github.workspace }}\vcpkg\packages\zeromq_x64-windows\*" "${{ github.workspace }}\src\nativeInterop"
- name: Download 7-Zip
run: curl https://www.7-zip.org/a/7z2301-x64.exe --output 7z-installer.exe
- name: Extract 7-Zip
run: .\7z-installer.exe /S /D="${{ github.workspace }}\7zip"
- name: Download mpv
run: curl https://kumisystems.dl.sourceforge.net/project/mpv-player-windows/libmpv/mpv-dev-x86_64-20240114-git-bd35dc8.7z --output mpv.7z
- name: Extract mpv
run: 7zip\7z.exe x mpv.7z -osrc\nativeInterop
- name: Move libmpv.dll.a
run: md src\nativeInterop\lib & move src\nativeInterop\libmpv.dll.a src\nativeInterop\lib\libmpv.dll.a
- name: Move libmpv-2.dll
run: md src\nativeInterop\bin & move src\nativeInterop\libmpv-2.dll src\nativeInterop\bin\libmpv-2.dll
- name: Build native binaries
run: .\gradlew.bat nativeBinaries
- name: Upload debug binary
uses: actions/upload-artifact@v3
with:
name: spms-windows-debug.exe
path: build\bin\native\debugExecutable\spmp-server.exe
- name: Upload release binary
uses: actions/upload-artifact@v3
with:
name: spms-windows-release.exe
path: build\bin\native\releaseExecutable\spmp-server.exe