-
Notifications
You must be signed in to change notification settings - Fork 0
79 lines (74 loc) · 2.14 KB
/
win-build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: Build on Windows
on:
push:
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- name: Download FFmpeg binaries
uses: robinraju/release-downloader@v1.10
with:
repository: BtbN/FFmpeg-Builds
latest: true
fileName: ffmpeg-n7*-win64-lgpl-shared*.zip
out-file-path: ffmpeg-binary
extract: true
- name: Download sdl2
uses: robinraju/release-downloader@v1.10
with:
repository: libsdl-org/SDL
latest: true
fileName: '*win*x64*.zip'
out-file-path: sdl2-binary
extract: true
- name: Download sdl2-mixer
uses: robinraju/release-downloader@v1.10
with:
repository: libsdl-org/SDL_mixer
latest: true
fileName: '*win*x64*.zip'
out-file-path: sdl2-mixer-binary
extract: true
- name: Download sdl2-ttf
uses: robinraju/release-downloader@v1.10
with:
repository: libsdl-org/SDL_ttf
latest: true
fileName: '*win*x64*.zip'
out-file-path: sdl2-ttf-binary
extract: true
- name: Download sdl2-image
uses: robinraju/release-downloader@v1.10
with:
repository: libsdl-org/SDL_image
latest: true
fileName: '*win*x64*.zip'
out-file-path: sdl2-image-binary
extract: true
- name: Copy sdl2 library files
run: |
copy sdl2-binary/*.dll sdl2-libs
copy sdl2-mixer-binary/*.dll sdl2-libs
copy sdl2-mixer-binary/optional/*.dll sdl2-libs
copy sdl2-image-binary/*.dll sdl2-libs
copy sdl2-image-binary/optional/*.dll sdl2-libs
copy sdl2-ttf-binary/*.dll sdl2-libs
Get-ChildItem -Recurse sdl2-libs
- name: Build
run: |
$env:Path += ";" + $pwd + "\sdl2-libs"
cd ffmpeg-binary\*
$env:FFMPEG_DIR = $pwd
cd ..\..\
cargo build --verbose
cargo build --release --verbose
- name: Upload compiled binaries
uses: actions/upload-artifact@v4
with:
name: windows-release-binary
path: ./target