-
Notifications
You must be signed in to change notification settings - Fork 6
/
appveyor.yml
186 lines (151 loc) · 5.26 KB
/
appveyor.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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
shallow_clone: true
clone_depth: 1
branches:
only:
- master
image:
- Visual Studio 2019
- Ubuntu2004 # 20.04 LTS (Focal Fossa)
- macos-bigsur
for:
- # Windows
matrix:
only:
- image: Visual Studio 2019
environment:
# Set Qt toolkit path
QTOOLS: C:\Qt\Tools\mingw1120_64\bin
QTDIR: C:\Qt\6.4\mingw_64 # required as is
before_build:
- set PATH=%QTOOLS%;%QTDIR%\bin;%PATH%
- cmd /c ver
- gcc --version
- qmake --version
- cmake --version
- python --version
build_script:
# Build Leviathan version file
- python appveyor_generateversion.py
- cd src
- mkdir deploy64
#- mingw32-make clean
#- del Makefile*
#- del .qmake.stash
- qmake Leviathan.pro CONFIG+=release
- mingw32-make -j%NUMBER_OF_PROCESSORS%
after_build:
- copy /Y release\Leviathan.exe deploy64
# Prepare the libraries and the other files to deploy
- call %QTDIR%\bin\windeployqt.exe --force --compiler-runtime --no-translations --no-opengl-sw --no-system-d3d-compiler --no-quick-import --no-virtualkeyboard deploy64
# windeployqt only copies the required Qt dlls, not the c++ ones, even adding --compiler-runtime
- copy /Y "%QTOOLS%\libstdc++-6.dll" deploy64
- copy /Y "%QTOOLS%\libgcc_s_seh-1.dll" deploy64
- copy /Y "%QTOOLS%\libwinpthread-1.dll" deploy64
- copy /Y "%QTOOLS%\libgomp*.dll" deploy64 # we need the OpenMP libraries
# Copy extra required libs
- copy /Y ..\winlibs\64\zlib.dll deploy64
# Pack everything in a zip
- 7z a ..\Leviathan-Windows-x86_64-automated-%APPVEYOR_REPO_TAG_NAME%.zip .\deploy64\*
artifacts:
- path: Leviathan-Windows-x86_64-automated-$(APPVEYOR_REPO_TAG_NAME).zip
name: binpkg-x86_64
deploy:
tag: $(APPVEYOR_REPO_TAG_NAME)
release: $(APPVEYOR_REPO_TAG_NAME)
description: 'Release for version $(APPVEYOR_REPO_TAG_NAME)'
provider: GitHub
auth_token:
secure: J8jjMGdO2zbAS725FDct4WZwi9jxYf2J1lCZC6zFStF4afJhL0QiQh08eGV3KT00
artifact: binpkg-x86_64
force_update: true
draft: false
prerelease: false
on:
branch: master # release from master branch only.
APPVEYOR_REPO_TAG: true # deploy on tag push only
- # Linux build
matrix:
only:
- image: Ubuntu2004
install:
- sudo add-apt-repository ppa:ubuntu-toolchain-r/test
- sudo apt-get -y update
- sudo apt-get -y install gcc-11 g++-11
- sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 110 --slave /usr/bin/g++ g++ /usr/bin/g++-11
- sudo update-alternatives --set gcc /usr/bin/gcc-11
before_build:
# Set Qt toolkit path
- export QTDIR=${HOME}/Qt/6.2/gcc_64
- export PATH=${QTDIR}/bin:$PATH
- lsb_release -d
- gcc --version
- qmake --version
- cmake --version
- python --version
build_script:
# Build Leviathan version file
- python appveyor_generateversion.py
- cd src
- qmake Leviathan.pro CONFIG+=release
- make -j"$(nproc)"
after_build:
# Pack everything in a zip
- tar -czf ../Leviathan-Linux-x86_64-automated-${APPVEYOR_REPO_TAG_NAME}.zip Leviathan
artifacts:
- path: Leviathan-Linux-x86_64-automated-$(APPVEYOR_REPO_TAG_NAME).zip
name: binpkg-x86_64
deploy:
tag: $(APPVEYOR_REPO_TAG_NAME)
release: $(APPVEYOR_REPO_TAG_NAME)
description: 'Release for version $(APPVEYOR_REPO_TAG_NAME)'
provider: GitHub
auth_token:
secure: J8jjMGdO2zbAS725FDct4WZwi9jxYf2J1lCZC6zFStF4afJhL0QiQh08eGV3KT00
artifact: binpkg-x86_64
force_update: true
draft: false
prerelease: false
on:
branch: master # release from master branch only.
APPVEYOR_REPO_TAG: true # deploy on tag push only
- # MacOS
matrix:
only:
- image: macos-bigsur
before_build:
# Set Qt toolkit path
- export QTDIR=${HOME}/Qt/6.2/macos
- export PATH=${QTDIR}/bin:$PATH
- sw_vers
- gcc --version
- qmake --version
- cmake --version
- python --version
build_script:
# Build Leviathan version file
- python appveyor_generateversion.py
- cd src
- qmake Leviathan.pro CONFIG+=release
- make -j"$(nproc)"
after_build:
# Pack everything in a zip
#- zip -r ../LeviathanMacOSx86_64-automated-${APPVEYOR_REPO_TAG_NAME}.zip Leviathan.app
- macdeployqt Leviathan.app -dmg
- mv Leviathan.dmg ../Leviathan-MacOS-x86_64-automated-${APPVEYOR_REPO_TAG_NAME}.dmg
artifacts:
- path: Leviathan-MacOS-x86_64-automated-$(APPVEYOR_REPO_TAG_NAME).dmg
name: binpkg-x86_64
deploy:
tag: $(APPVEYOR_REPO_TAG_NAME)
release: $(APPVEYOR_REPO_TAG_NAME)
description: 'Release for version $(APPVEYOR_REPO_TAG_NAME)'
provider: GitHub
auth_token:
secure: J8jjMGdO2zbAS725FDct4WZwi9jxYf2J1lCZC6zFStF4afJhL0QiQh08eGV3KT00
artifact: binpkg-x86_64
force_update: true
draft: false
prerelease: false
on:
branch: master # release from master branch only.
APPVEYOR_REPO_TAG: true # deploy on tag push only