qBittorrent/.appveyor.yml

94 lines
3.5 KiB
YAML
Raw Normal View History

2016-01-12 11:18:38 +03:00
version: '{branch}-{build}'
# Do not build on tags (GitHub only)
skip_tags: true
image: Visual Studio 2022
2016-01-12 11:18:38 +03:00
branches:
except: # blacklist
- coverity_scan
2016-01-12 11:18:38 +03:00
environment:
REPO_DIR: &REPO_DIR c:\qbittorrent
CACHE_DIR: &CACHE_DIR c:\qbt_cache
QBT_VER_URL: https://builds.shiki.hu/appveyor/version_64
QBT_LIB_URL: https://builds.shiki.hu/appveyor/qbt_libraries_64.7z
2016-01-12 11:18:38 +03:00
# project directory
clone_folder: *REPO_DIR
# cache size should < 100MB (after compressing with fastest option):
# see: https://www.appveyor.com/docs/build-cache#save-update-cache-before-build-finishes
cache:
- *CACHE_DIR
clone_depth: 50
2016-01-12 11:18:38 +03:00
install:
# check if library needs update
- appveyor DownloadFile "%QBT_VER_URL%" -FileName "c:\version_new" && SET /P newVersion=<"c:\version_new"
- IF EXIST "%CACHE_DIR%\version" (SET /P oldVersion=<"%CACHE_DIR%\version")
- IF NOT EXIST "%CACHE_DIR%\version" (SET updateCache=1)
- IF NOT "%oldVersion%" == "%newVersion%" (SET updateCache=1)
# update library
- IF "%updateCache%" == "1" (ECHO "--- Will redownload libraries ---" &&
RMDIR /S /Q "%CACHE_DIR%" & MKDIR "%CACHE_DIR%" &&
appveyor DownloadFile "%QBT_LIB_URL%" -FileName "c:\qbt_lib.7z" && 7z x "c:\qbt_lib.7z" -o"%CACHE_DIR%" > nul &&
COPY "c:\version_new" "%CACHE_DIR%\version")
# Qt stay compressed in cache
- 7z x "%CACHE_DIR%\qt5_64.7z" -o"c:\qbt" > nul
2016-01-12 11:18:38 +03:00
before_build:
# setup env
- CALL "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvarsall.bat" x64
2021-07-14 08:26:19 +03:00
- SET PATH=%PATH%;C:\Qt\5.15.2\msvc2019_64\bin;%CACHE_DIR%\jom
2016-01-12 11:18:38 +03:00
# setup project
2018-08-10 01:16:42 +03:00
- COPY /Y "%CACHE_DIR%\conf.pri" "%REPO_DIR%"
2016-01-12 11:18:38 +03:00
# workarounds
- MKLINK /J "c:\qbt\base" "%CACHE_DIR%\base"
build_script:
- cd "%REPO_DIR%"
2019-11-11 08:24:33 +03:00
# scan only as lupdate is prone to hang
- lupdate -extensions c,cpp,h,hpp,ui .
2016-01-12 11:18:38 +03:00
- qmake qbittorrent.pro && cd src && qmake src.pro
- jom -j2 -f Makefile.Release
2021-11-17 07:02:42 +03:00
after_build:
- cd "%REPO_DIR%"
- MKDIR upload
- COPY dist\windows\qt.conf upload
- COPY src\release\qbittorrent.exe upload
- COPY src\release\qbittorrent.pdb upload
- COPY "%CACHE_DIR%\base\bin\libcrypto-1_1-x64.dll" upload
- COPY "%CACHE_DIR%\base\bin\libssl-1_1-x64.dll" upload
- COPY "%CACHE_DIR%\base\lib\torrent-rasterbar.dll" upload
- COPY "%CACHE_DIR%\base\lib\zlib1.dll" upload
- COPY C:\Qt\5.15.2\msvc2019_64\bin\Qt5Core.dll upload
- COPY C:\Qt\5.15.2\msvc2019_64\bin\Qt5Gui.dll upload
- COPY C:\Qt\5.15.2\msvc2019_64\bin\Qt5Network.dll upload
- COPY C:\Qt\5.15.2\msvc2019_64\bin\Qt5Sql.dll upload
- COPY C:\Qt\5.15.2\msvc2019_64\bin\Qt5Svg.dll upload
- COPY C:\Qt\5.15.2\msvc2019_64\bin\Qt5Widgets.dll upload
- COPY C:\Qt\5.15.2\msvc2019_64\bin\Qt5WinExtras.dll upload
- COPY C:\Qt\5.15.2\msvc2019_64\bin\Qt5Xml.dll upload
- MKDIR upload\plugins\iconengines
- COPY C:\Qt\5.15.2\msvc2019_64\plugins\iconengines\qsvgicon.dll upload\plugins\iconengines
- MKDIR upload\plugins\imageformats
- COPY C:\Qt\5.15.2\msvc2019_64\plugins\imageformats\qico.dll upload\plugins\imageformats
- COPY C:\Qt\5.15.2\msvc2019_64\plugins\imageformats\qsvg.dll upload\plugins\imageformats
- MKDIR upload\plugins\platforms
- COPY C:\Qt\5.15.2\msvc2019_64\plugins\platforms\qwindows.dll upload\plugins\platforms
- MKDIR upload\plugins\sqldrivers
- COPY C:\Qt\5.15.2\msvc2019_64\plugins\sqldrivers\qsqlite.dll upload\plugins\sqldrivers
- MKDIR upload\plugins\styles
- COPY C:\Qt\5.15.2\msvc2019_64\plugins\styles\qwindowsvistastyle.dll upload\plugins\styles
2016-01-12 11:18:38 +03:00
test: off
2021-11-17 07:02:42 +03:00
artifacts:
- path: upload
name: qBittorrent-Appveyor_Windows-x64