Commit cfaf5b49 authored by Patrick Storz's avatar Patrick Storz 🦄

CI on Windows using AppVeyor and MSYS2

parent 4a8fe9d4
#!/usr/bin/env bash
cd "$(dirname "$0")"
mkdir build
cd build
# Write an empty fonts.conf to speed up fc-cache
export FONTCONFIG_FILE=/dummy-fonts.conf
cat >"$FONTCONFIG_FILE" <<EOF
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig></fontconfig>
EOF
# update/install dependecies
pacman -Suu --needed --noconfirm --noprogressbar
pacman -S $MINGW_PACKAGE_PREFIX-ccache --needed --noconfirm --noprogressbar
source ../msys2installdeps.sh
# configure
ccache --max-size=200M
cmake .. -G Ninja -DCMAKE_C_COMPILER_LAUNCHER="ccache" -DCMAKE_CXX_COMPILER_LAUNCHER="ccache"
# build
ccache --zero-stats
ninja
ccache --show-stats
ninja install
# test
inkscape/inkscape.exe -V
# package
7z a inkscape.7z inkscape
version: '{branch}-{build}'
branches:
only:
- master
clone_depth: 10
environment:
matrix:
- MSYSTEM: MINGW64
- MSYSTEM: MINGW32
build_script:
- C:\msys64\usr\bin\pacman -Syuu --needed --noconfirm --noprogressbar
- C:\msys64\usr\bin\bash --login -c "$(cygpath ${APPVEYOR_BUILD_FOLDER})/appveyor.sh"
artifacts:
- path: build\inkscape.7z
cache:
- C:\msys64\home\appveyor\.ccache
#!/usr/bin/env bash
# ------------------------------------------------------------------------------
# This script installs all dependecies required for building Inkscape with MSYS2
# -------------------------------------------------------------------------------
# This script installs all dependencies required for building Inkscape with MSYS2
# execute it once on an MSYS shell, i.e.
# - use the "MSYS2 MSYS" shortcut in the start menu or
# - run "msys2.exe" in MSYS2's installation folder
......@@ -8,12 +8,20 @@
# MSYS2 and installed libraries can be updated later by executing
# pacman -Syu --ignore=mingw-w64-*-imagemagick
# in an MSYS shell
# ------------------------------------------------------------------------------
# -------------------------------------------------------------------------------
# select if you want to build 32-bit (i686), 64-bit (x86_64), or both
#ARCH=mingw-w64-i686
#ARCH=mingw-w64-x86_64
ARCH={mingw-w64-i686,mingw-w64-x86_64}
case "$MSYSTEM" in
MINGW32)
ARCH=mingw-w64-i686
;;
MINGW64)
ARCH=mingw-w64-x86_64
;;
*)
ARCH={mingw-w64-i686,mingw-w64-x86_64}
;;
esac
# sync package databases
pacman -Sy
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment