-
Notifications
You must be signed in to change notification settings - Fork 405
117 lines (103 loc) · 3.4 KB
/
msbuild.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
106
107
108
109
110
111
112
113
114
115
116
117
# The name of our workflow
name: Build
on: [push, pull_request]
jobs:
checkuncrustify:
name: "Check code style with Uncrustify"
# Ubuntu 22.04 has uncrustify 0.72_f
runs-on: ubuntu-22.04
steps:
- name: Install dependencies
run: sudo apt update && sudo apt install -y uncrustify
- name: Checkout OpenVPN-GUI
uses: actions/checkout@v3
- name: Show uncrustify version
run: uncrustify --version
- name: Run uncrustify
run: ./dev-tools/reformat-all.sh
- name: Check for changes
run: git diff --output=uncrustify-changes.patch
- name: Show changes on standard output
run: git diff
- uses: actions/upload-artifact@v3
with:
name: uncrustify-changes.patch
path: uncrustify-changes.patch
- name: Set job status
run: test ! -s uncrustify-changes.patch
msvc:
strategy:
matrix:
arch: [x86, x64, arm64]
conf:
- name: ""
value: "release"
ovpn3:
- preset: ""
name: ""
upload_name: ""
- preset: -ovpn3
name: "- ovpn3"
upload_name: "_ovpn3"
include:
- conf:
name: " ASAN"
value: "asan"
arch: x64
name: 'msvc - ${{matrix.arch}} ${{ matrix.ovpn3.name }}${{ matrix.conf.name }}'
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- uses: lukka/get-cmake@latest
- name: Restore artifacts, or setup vcpkg (do not install any package)
uses: lukka/run-vcpkg@v11
with:
vcpkgDirectory: '${{ runner.workspace }}/b/vcpkg'
vcpkgGitCommitId: "1ba9a2591f15af5900f2ce2b3e2bf31771e3ac48"
- name: Run CMake consuming CMakePreset.json and vcpkg.json by mean of vcpkg.
uses: lukka/run-cmake@v10
with:
configurePreset: '${{ matrix.arch }}${{ matrix.ovpn3.preset }}'
buildPreset: '${{ matrix.arch }}-${{ matrix.conf.value }}${{ matrix.ovpn3.preset }}'
- uses: actions/upload-artifact@v3
with:
name: openvpn-gui_${{ matrix.arch }}_${{ matrix.conf.value }}${{ matrix.ovpn3.upload_name }}
path: |
out/build/${{ matrix.arch }}${{ matrix.ovpn3.preset }}/${{ matrix.conf.value }}/*.dll
out/build/${{ matrix.arch }}${{ matrix.ovpn3.preset }}/${{ matrix.conf.value }}/*.exe
mingw:
strategy:
fail-fast: false
matrix:
target: [mingw64, mingw]
include:
- target: mingw64
chost: x86_64-w64-mingw32
- target: mingw
chost: i686-w64-mingw32
name: "gcc-mingw - ${{matrix.target}}"
runs-on: ubuntu-20.04
env:
MAKEFLAGS: -j3
steps:
- name: Install dependencies
run: sudo apt update && sudo apt install -y mingw-w64 libtool automake autoconf
- name: Checkout
uses: actions/checkout@v3
with:
path: openvpn-gui
- name: autoconf
run: autoreconf -fvi
working-directory: openvpn-gui
- name: Cache dependencies
id: cache
uses: actions/cache@v3
with:
path: '~/mingw/'
key: mingw-${{ matrix.target }}
- name: configure
run: PKG_CONFIG_PATH=${HOME}/mingw/opt/${LIB}/pkgconfig ./configure --host=${{ matrix.chost }}
working-directory: openvpn-gui
- name: make
run: make
working-directory: openvpn-gui