kiwix-build/appveyor.yml

70 lines
2.7 KiB
YAML

image: Visual Studio 2019
version: '0.1.{build}'
environment:
EXTRA_DIR: 'C:\extra'
MINGW64_EXTRA_DIR: '/c/extra'
PATH: 'C:\\Python312\\Scripts;%PATH%;%EXTRA_DIR%\bin;C:\\Program Files (x86)\\Windows Kits\\10\\bin\\%platform%'
PKG_CONFIG_PATH: '%EXTRA_DIR%\lib\pkgconfig'
MSYS2_PATH_TYPE: 'inherit'
MSYS2_ARG_CONV_EXCL: '-Tp'
MINGW64_RUN: 'C:\msys64\usr\bin\bash.exe --login -c'
MSYSTEM: 'MINGW64'
KIWIX_DESKTOP_VERSION: '2.3.1-3'
KIWIX_DESKTOP_RELEASE: 0
init:
- cmd: |
echo %TEST_VAR%
REM Set VC 2019
"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvars64.bat"
mkdir C:\extra\bin
install:
- cmd: |
cd C:\projects
REM Install meson
C:\Python312\Scripts\pip install meson
REM Install ninja
curl -o ninja-win.zip -L https://github.com/ninja-build/ninja/releases/download/v1.8.2/ninja-win.zip
7z e ninja-win.zip -o%EXTRA_DIR%\bin
REM Install pkg-config-lite
curl -o pkg-config-lite-0.28-1.zip -L https://deac-fra.dl.sourceforge.net/project/pkgconfiglite/0.28-1/pkg-config-lite-0.28-1_bin-win32.zip
7z e pkg-config-lite-0.28-1.zip -o%EXTRA_DIR%\bin pkg-config-lite-0.28-1/bin/pkg-config.exe
cd kiwix-build
REM Install openssh (scp) for deployement
choco install openssh openssl.light
- cmd: openssl enc -d -aes-256-cbc -md sha256 -pass pass:%ENC_PASSWD% -in appveyor\nightlybot_id_key.enc -out appveyor\nightlybot_id_key
build_script:
- IF "%USE_CACHE%" EQU "1" appveyor\setup_from_cache.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_zlib.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_lzma.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_zstd.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_libcurl.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_pthread.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_dirent.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_xapian.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_icu.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_pugixml.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_aria2.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_mustache.cmd
- IF "%USE_CACHE%" NEQ "1" appveyor\install_libmicrohttpd.cmd
- IF "%USE_CACHE%" NEQ "1" %MINGW64_RUN% "cd /c/projects/kiwix-build && appveyor/create_cache.sh"
- appveyor\install_libzim.cmd
- appveyor\install_libkiwix.cmd
- appveyor\install_kiwix-desktop.cmd
before_deploy:
- cmd: openssl enc -d -pbkdf2 -aes-256-cbc -md sha256 -pass pass:%win_certificate_secret% -in appveyor\kiwix.pfx.enc -out appveyor\kiwix.pfx
- cmd: '%MINGW64_RUN% "cd /c/projects/kiwix-build && appveyor/package_kiwix-desktop.sh"'
deploy_script:
- cmd: '%MINGW64_RUN% "cd /c/projects/kiwix-build && appveyor/deploy.sh"'