-
Notifications
You must be signed in to change notification settings - Fork 5
97 lines (85 loc) · 2.19 KB
/
main.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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
name: CI
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build_native_linux:
name: Build native on linux
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
- name: Build
run: |
mkdir build
cd build
cmake ../libstbi
make install
- uses: actions/upload-artifact@master
with:
name: linux-x64
path: runtimes/linux-x64
build_native_macos:
name: Build native on macOS
runs-on: macos-latest
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
- name: Build
run: |
mkdir build
cd build
cmake -DCMAKE_OSX_DEPLOYMENT_TARGET=10.9 ../libstbi
make install
- uses: actions/upload-artifact@master
with:
name: osx-x64
path: runtimes/osx-x64
build_native_windows:
name: Build native on Windows
runs-on: windows-latest
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
- name: Setup MSBuild.exe
uses: microsoft/setup-msbuild@v1.1
- name: Build
run: |
mkdir build
cd build
cmake ../libstbi
msbuild /v:m /p:Configuration=Release INSTALL.vcxproj
- uses: actions/upload-artifact@master
with:
name: win-x64
path: runtimes/win-x64
build_wrapper:
name: Build C# wrapper
runs-on: ubuntu-latest
needs: [build_native_linux, build_native_macos, build_native_windows]
steps:
- uses: actions/checkout@v1
- name: Grab linux binary
uses: actions/download-artifact@master
with:
name: linux-x64
path: runtimes/linux-x64
- name: Grab macOS binary
uses: actions/download-artifact@master
with:
name: osx-x64
path: runtimes/osx-x64
- name: Grab Windows binary
uses: actions/download-artifact@master
with:
name: win-x64
path: runtimes/win-x64
- name: Build and pack nuget package
run: dotnet pack -c Release