Commit 333996f7 authored by Vasily Galkin's avatar Vasily Galkin

Build win32 installers with gnome gitlab win32 runners

appveyor.yml is removed since it is based on pygobject-win32 which
is to old for meld 3.19+

Currently pacman invocation isn't perfect since
it doesn't cache used package versions,
so build can't be reproduced with same msys2 package versions.
parent 15b8ff31
image: fedora:rawhide
stages:
- check
- build
......@@ -8,9 +7,11 @@ variables:
python3-gobject gtk3 gtksourceview3
python3-pytest intltool
before_script:
- dnf update -y
- dnf install -y $DEPENDENCIES
.linux-common: &linux-common
image: fedora:rawhide
before_script:
- dnf update -y
- dnf install -y $DEPENDENCIES
flake8:
stage: check
......@@ -18,13 +19,46 @@ flake8:
- pip3 install -r dev-requirements.txt
- flake8 bin/meld meld/
allow_failure: true
<<: *linux-common
pytest:
linux-pytest:
stage: check
script:
- py.test-3 test/
<<: *linux-common
build:
linux-build:
stage: build
script:
- python3 setup.py build
<<: *linux-common
.mingw-common: &mingw-common
stage: build
tags: # select gitlab runners with specific tag (unrelated to git repo tags)
- win32
artifacts:
name: "%CI_JOB_STAGE%-%CI_COMMIT_REF_NAME%"
paths:
- dist/
before_script:
- path C:\msys64\%MSYSTEM%\bin;C:\msys64\usr\bin;%PATH%
- pacman --noconfirm -S --refresh --sysupgrade --needed mingw-w64-%MSYS2_ARCH%-python3-cx_Freeze mingw-w64-%MSYS2_ARCH%-python3-gobject mingw-w64-%MSYS2_ARCH%-python3-pytest mingw-w64-%MSYS2_ARCH%-gtksourceview3 mingw-w64-%MSYS2_ARCH%-gsettings-desktop-schemas glib2-devel intltool
script:
- glib-compile-schemas data
- python3 setup_win32.py bdist_dumb --bdist-dir build\bdist.mingw\msi --keep-temp bdist_msi --keep-temp
# main purpose of this job is creating installers and not checking for breakage by changes in code
# so allow failures since the status of the build may depend on updates of rolling-release msys2 packages
allow_failure: true
mingw64-dist:
variables:
MSYS2_ARCH: x86_64
MSYSTEM: MINGW64
<<: *mingw-common
mingw32-dist:
variables:
MSYS2_ARCH: i686
MSYSTEM: "MINGW32"
<<: *mingw-common
version: tag-or-branch-set-dynamically.{build}
# Limit builds to release branches
branches:
only:
- master
- meld-3-18
# Only build tags automatically
# TODO: Disabled due to https://github.com/appveyor/ci/issues/1887
# skip_non_tags: true
environment:
PYTHON_PREFIX: C:\Python34
PATH: $(PYTHON_PREFIX);$(PYTHON_PREFIX)\Lib\site-packages\gnome;$(PATH)
install:
- ps: |
if ($env:APPVEYOR_REPO_TAG -eq "true") {
Update-AppveyorBuild -Version $env:APPVEYOR_REPO_TAG_NAME.$env:APPVEYOR_BUILD_NUMBER
} else {
Update-AppveyorBuild -Version $env:APPVEYOR_REPO_BRANCH-$($env:APPVEYOR_REPO_COMMIT.substring(0,7)).$env:APPVEYOR_BUILD_NUMBER
}
# Install cxFreeze
- cmd: |
python -m pip install pypiwin32==219
python -m pip install cx_Freeze==5.0.2
# Download and extract the PyGI all-in-one installer
- cmd: |
curl "https://sourceforge.net/projects/pygobjectwin32/files/pygi-aio-3.24.1_rev1-setup_049a323fe25432b10f7e9f543b74598d4be74a39.exe/download" --location --output pygi-aio-setup.exe
set SOURCEPATH=%cd%\pygi-aio-source
mkdir %SOURCEPATH%
7z.exe x -o%SOURCEPATH% pygi-aio-setup.exe
mkdir pygi-aio-setup
7z.exe x -opygi-aio-setup %SOURCEPATH%\setup.exe
set GIR=True
# %PYTHON_PREFIX% is used because it is the last supported by
# pygi-aio, GTK is installed as a dependency of GTKSourceView
- cmd: |
pygi-aio-setup\rcmd.exe /c "cd pygi-aio-setup && setup.bat %PYTHON_PREFIX% GTKSourceView >pygi-aio-setup.log"
build_script:
- cmd: |
%PYTHON_PREFIX%\Lib\site-packages\gnome\glib-compile-schemas data
%PYTHON_PREFIX%\python setup_win32.py bdist_dumb --bdist-dir build\bdist.mingw\msi --keep-temp bdist_msi --keep-temp
artifacts:
- path: dist/*.msi
name: Meld installer
- path: dist/*.zip
name: Meld freezed binaries archive
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