forked from Sigil-Ebook/Sigil
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.retired_appveyor.yml
247 lines (215 loc) · 8.78 KB
/
.retired_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
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
version: '1.0.0-{build}'
branches:
only:
- master
- /\d+\.\d+\.\d+(-\d+)?/
configuration: Release
platform:
- x64
environment:
global:
GDRIVE_REFRESH_TOKEN:
secure: +J2q/4lkiBXik5Ttvt06vpNiWBjNIXx+jFnYw1rOR9sLkyksyXGj+NeNKQB8kPwE
matrix:
- job_name: "Sigil macOS Mojave"
APPVEYOR_BUILD_WORKER_IMAGE: macOS-Mojave
- job_name: "Sigil Ubuntu 1804 x64"
APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu1804
- job_name: "Sigil VS2019 x64"
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
#matrix:
# exclude:
# - job_name: "Sigil macOS Mojave"
# APPVEYOR_BUILD_WORKER_IMAGE: macOS-Mojave
# - job_name: "Sigil Ubuntu 1804 x64"
# APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu1804
# - job_name: "Sigil VS2019 x64"
# APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
init:
- cmd: echo NUMBER_OF_PROCESSORS=%NUMBER_OF_PROCESSORS%
- sh: echo _NPROCESSORS_ONLN=$(getconf _NPROCESSORS_ONLN)
- cmd: set /p RedistVersion=<"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\Microsoft.VCRedistVersion.default.txt"
- ps: $commit = $env:APPVEYOR_REPO_COMMIT.SubString(0,7)
- ps: $timestamp = $env:APPVEYOR_REPO_COMMIT_TIMESTAMP.SubString(0,10)
- ps: Update-AppveyorBuild -Version ("{0}-{1}-{2}" -f $env:APPVEYOR_REPO_BRANCH, $commit, $timestamp)
# Skip after build stuff unless '[deploy]' is in the commit message
- ps: $deploy = $env:APPVEYOR_REPO_COMMIT_MESSAGE -match '.*?\[deploy\].*?'
- ps: if(($deploy -eq $true) -and (-not $env:APPVEYOR_PULL_REQUEST_NUMBER) ) {$env:DEPLOY_INSTALLERS = $true}
clone_script:
- ps: >-
if(-not $env:APPVEYOR_PULL_REQUEST_NUMBER) {
git clone -q --depth=1 --branch=$env:APPVEYOR_REPO_BRANCH https://github.com/$env:APPVEYOR_REPO_NAME.git $env:APPVEYOR_BUILD_FOLDER
git checkout -qf $env:APPVEYOR_REPO_COMMIT
} else {
git clone -q --depth=1 https://github.com/$env:APPVEYOR_REPO_NAME.git $env:APPVEYOR_BUILD_FOLDER
git fetch -q origin +refs/pull/$env:APPVEYOR_PULL_REQUEST_NUMBER/merge:
git checkout -qf FETCH_HEAD
}
Set-Location $env:APPVEYOR_BUILD_FOLDER
only_commits:
files:
- CMakeLists.txt
- appveyor.yml
- installer/Sigil.iss
- src/
- ci_scripts/
- internal/
- cmake_extras/
- 3rdparty/
for:
# Windows
- matrix:
only:
- job_name: "Sigil VS2019 x64"
cache:
- C:\ProgramData\chocolatey\bin -> appveyor.yml
- C:\ProgramData\chocolatey\lib -> appveyor.yml
- C:\Python38-x64\Lib\site-packages -> appveyor.yml
environment:
GDRIVE_DIR:
secure: e/trZFJnPzo9saqwWWn6+E3ZPoItqflSviT92eeH3Qk76GuEHrPk9DrcG1bh3SNX
INNO: C:\Program Files (x86)\Inno Setup 6
REDIST: C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Redist\MSVC\%RedistVersion%\vcredist_%PLATFORM%.exe
DOWNLOADQT: https://github.com/dougmassay/win-qtwebkit-5.212/releases/download/v5.212-1/MyQt%PLATFORM%_5.12.9_VS2017_WE.7z
GDRIVE: https://github.com/dougmassay/win-qtwebkit-5.212/releases/download/v5.212-1/gdrive-windows-x64.exe
QT: C:\MyQtx64_WE\Qt5.12.9
PYTHON: C:\Python38-x64
CMAKE64BIT: -DWIN_INSTALLER_USE_64BIT_CRT=1
install:
- ps: if($env:DEPLOY_INSTALLERS) {echo 'Deployment= $env:DEPLOY_INSTALLERS'}
- cmd: choco install ninja
- cmd: rmdir c:\cygwin /s /q
- cmd: rmdir c:\Python35 /s /q
- cmd: rmdir c:\Python35-x64 /s /q
- cmd: cp '%REDIST%' installer/
- cmd: cd ..\..
- cmd: curl.exe -L -o webkit.7z %DOWNLOADQT%
- cmd: 7z x webkit.7z -y
- cmd: set PATH=%PYTHON%;%PYTHON%\Scripts;%QT%\bin;%INNO%;%PATH%
- cmd: echo 'PATH = %PATH%'
- cmd: python -m pip install --upgrade pip
- cmd: pip3.8 install six==1.15.0
- cmd: pip3.8 install html5lib==1.1
- cmd: pip3.8 install regex==2020.6.8
- cmd: pip3.8 install css-parser==1.0.4
- cmd: pip3.8 install cssselect==1.1.0
- cmd: pip3.8 install urllib3==1.25.9
- cmd: pip3.8 install certifi==2020.6.20
- cmd: pip3.8 install dulwich==0.20.5 --global-option="--pure"
- cmd: pip3.8 install chardet==3.0.4
- cmd: pip3.8 install pillow==7.1.2
- cmd: pip3.8 install PyQt5==5.12.3 PyQt5-sip==4.19.19
- cmd: pip3.8 install lxml==4.5.1
before_build:
- cmd: mkdir %APPVEYOR_BUILD_FOLDER%\build
- cmd: cd %APPVEYOR_BUILD_FOLDER%\build
- cmd: curl.exe -L -o gdrive.exe %GDRIVE%
- cmd: set PATH=%APPVEYOR_BUILD_FOLDER%\build;%PATH%
- cmd: gdrive.exe version
- cmd: qmake -v
- cmd: python --version
- cmd: call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvarsall.bat" %PLATFORM% -vcvars_ver=14.1
- cmd: cmake .. -G "Ninja" -DCMAKE_BUILD_TYPE=%configuration% -DUSE_ALT_ICONS=1 -DQt5_DIR=%QT%\lib\cmake\Qt5 %CMAKE64BIT%
build_script:
- cmd: ninja -j%NUMBER_OF_PROCESSORS%
after_build:
- ps: >-
if($env:DEPLOY_INSTALLERS) {
echo 'Deploying installer'
ninja -j2 makeinstaller
}else {echo 'No deployment specified'}
deploy_script:
- ps: if($env:DEPLOY_INSTALLERS) {python ../ci_scripts/gddeploy.py}
# Linux
- matrix:
only:
- job_name: "Sigil Ubuntu 1804 x64"
install:
- |
sudo apt-get remove -y --purge man-db
sudo apt-get update -qq
sudo apt-get install -y cmake cmake-data build-essential ninja
sudo apt-get install -y zlib1g-dev libhunspell-dev libminizip-dev libpcre3-dev
sudo apt-get install -y qtbase5-dev qttools5-dev qttools5-dev-tools qtwebengine5-dev qt5-default qtchooser
sudo apt-get install -y python3-dev python3-lxml python3-six
- sh: which qmake
- sh: qmake -v
- sh: python3 --version
- sh: gcc --version
before_build:
- sh: mkdir $APPVEYOR_BUILD_FOLDER/build
- sh: cd $APPVEYOR_BUILD_FOLDER/build
- sh: pwd
- sh: |-
cmake .. -G Ninja \
-DUSE_SYSTEM_LIBS=1 \
-DSYSTEM_LIBS_REQUIRED=1 \
-DCMAKE_C_COMPILER=clang \
-DCMAKE_CXX_COMPILER=clang++ \
-DCMAKE_BUILD_TYPE=Debug
build_script:
- sh: ninja -j$(getconf _NPROCESSORS_ONLN)
# Mac
- matrix:
only:
- job_name: "Sigil macOS Mojave"
environment:
GDRIVE_DIR:
secure: RjmPwHRaOXNx/mAY2gS4P5sLd2zK/RRD1/gtBMj54SPaUDZoSFFnmj4KBj0/wFmv
HOMEBREW_NO_AUTO_UPDATE: 1
HOMEBREW_NO_INSTALL_CLEANUP: 1
MACOSX_DEPLOYMENT_TARGET: 10.12
DOWNLOADQT: https://github.com/kevinhendricks/BuildSigilOnMac/releases/download/for_sigil_1.0.0/Qt5129.tar.xz
DOWNLOADPY: https://github.com/kevinhendricks/BuildSigilOnMac/releases/download/for_sigil_1.0.0/Python.framework.tar.xz
DOWNLOADSDK: https://github.com/phracker/MacOSX-SDKs/releases/download/10.15/MacOSX10.14.sdk.tar.xz
PY_VER: 3.8
stack: python 3.8
install:
- ps: if($env:DEPLOY_INSTALLERS) {echo 'Deployment= $env:DEPLOY_INSTALLERS'}
- sh: brew install gdrive
- sh: brew install wget
- sh: pwd
- sh: cd ~
- sh: wget $DOWNLOADQT
- sh: tar xzf Qt5129.tar.xz
- sh: export MYQTHOME=${HOME}/Qt5129
- sh: export PATH=${PATH}:${MYQTHOME}/bin
- sh: sudo mkdir -p /Users/kbhend/Qt5129
- sh: sudo chown -R appveyor /Users/kbhend/
- sh: cp -R ~/Qt5129/plugins /Users/kbhend/Qt5129
- sh: mkdir Frameworks
- sh: cd ./Frameworks
- sh: wget $DOWNLOADPY
- sh: tar xzf Python.framework.tar.xz
- sh: export MYDEST=${HOME}/Frameworks
- sh: export PATH=${MYDEST}/Python.framework/Versions/${PY_VER}/bin:${PATH}
- sh: cd /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs
- sh: sudo wget $DOWNLOADSDK
- sh: sudo tar xzf MacOSX10.14.sdk.tar.xz
- sh: qmake -v
- sh: python3 --version
before_build:
- sh: mkdir $APPVEYOR_BUILD_FOLDER/build
- sh: cd $APPVEYOR_BUILD_FOLDER/build
- sh: pwd
- sh: |-
cmake -DPKG_SYSTEM_PYTHON=1 \
-DCMAKE_OSX_DEPLOYMENT_TARGET=10.12 \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_CXX_FLAGS=-Wno-inconsistent-missing-override \
-DCMAKE_PREFIX_PATH=${MYQTHOME}/lib/cmake \
-DCMAKE_OSX_SYSROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/ ../
build_script:
- sh: make -j$(getconf _NPROCESSORS_ONLN)
after_build:
- ps: >-
if($env:DEPLOY_INSTALLERS) {
echo 'Deploying App'
make addframeworks
bash ../ci_scripts/rpath_adjust.sh
cd ./bin
tar -cJf Sigil.tar.xz Sigil.app
cd ../
} else {echo 'No deployment specified'}
deploy_script:
- ps: if($env:DEPLOY_INSTALLERS) {python3 ../ci_scripts/gddeploy.py}