forked from Garux/netradiant-custom
-
Notifications
You must be signed in to change notification settings - Fork 1
105 lines (90 loc) · 2.98 KB
/
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
name: build
on: [workflow_dispatch]
jobs:
windows-msys:
name: ${{ matrix.config }} Windows ${{ matrix.arch }}
runs-on: windows-2019
strategy:
fail-fast: false
matrix:
arch: [x86, x86_64]
cc: [gcc]
include:
- arch: x86
msystem: MINGW32
prefix: mingw-w64-i686
- arch: x86_64
msystem: MINGW64
prefix: mingw-w64-x86_64
defaults:
run:
shell: msys2 {0}
steps:
- uses: msys2/setup-msys2@v2
with:
install: ${{ matrix.prefix }}-qt5-base ${{ matrix.prefix }}-libxml2 git
msystem: ${{ matrix.msystem }}
path-type: minimal
release: false
update: false
- uses: actions/checkout@v3
with:
submodules: recursive
- name: Build
run: |
make DOWNLOAD_GAMEPACKS=no MAKEFILE_CONF=msys2-Makefile.conf BUILD=release -j$(nproc)
wget https://www.dropbox.com/s/b1xpajzfa6yjlzf/netradiant-custom-extra-gamepacks.zip
unzip -o netradiant-custom-extra-gamepacks.zip -d "install"
wget https://www.dropbox.com/s/hcgkwzzmja3m6c0/netradiant-custom-extra-win.zip
unzip -o netradiant-custom-extra-win.zip -d "install"
- uses: actions/upload-artifact@v3
with:
name: Windows-${{ matrix.arch }}
path: install/
if-no-files-found: error
linux:
name: ${{ matrix.config }} Linux ${{ matrix.arch }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
arch: [x86_64]
steps:
- name: Install tools
run: |
sudo apt-get -qq update
sudo apt-get -y install mesa-common-dev qtbase5-dev
- uses: actions/checkout@v3
with:
submodules: recursive
- name: Build
run: |
make -j 4 DOWNLOAD_GAMEPACKS=no CXXFLAGS="-Wno-deprecated-copy"
wget https://www.dropbox.com/s/b1xpajzfa6yjlzf/netradiant-custom-extra-gamepacks.zip
unzip -o netradiant-custom-extra-gamepacks.zip -d "install"
- uses: actions/upload-artifact@v3
with:
name: Linux-${{ matrix.arch }}
path: install/
if-no-files-found: error
create-testing:
if: github.ref == 'refs/heads/master' && github.event_name == 'push' || github.event_name == 'workflow_dispatch'
needs: [windows-msys, linux]
runs-on: windows-latest
steps:
- name: Download Artifacts
uses: actions/download-artifact@v3
- name: Create binary archives
shell: cmd
run: |
"%programfiles%\7-Zip\7z.exe" a -r netradiant-custom-windows-x86_64.zip "%CD%\Windows-x86_64\*"
"%programfiles%\7-Zip\7z.exe" a -r netradiant-custom-linux-x86_64.zip "%CD%\Linux-x86_64\*"
- name: Create latest build
uses: ec-/action-automatic-releases@test
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
automatic_release_tag: "latest"
prerelease: true
title: Development Build
files: |
*.zip