Skip to content

Instantly share code, notes, and snippets.

@ppolxda
Last active November 27, 2019 16:35
Show Gist options
  • Save ppolxda/1ebc6bdd2053984bc5ff7a799647bf75 to your computer and use it in GitHub Desktop.
Save ppolxda/1ebc6bdd2053984bc5ff7a799647bf75 to your computer and use it in GitHub Desktop.
plyvel appveyor windows build
version: 1.1.0.build v{build}
skip_tags: true
init:
- cmd: ECHO Python %PYTHON_VERSION% (%PYTHON_ARCH%bit) from %PYTHON%
environment:
VCPKG_PATH: C:/tools/vcpkg/installed
matrix:
- platform: x86
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
PYTHON: C:\\Python35
PYTHON_VERSION: 3.5.x
PYTHON_ARCH: 32
MSVC_VERSION: Visual Studio 15
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
PYTHON: C:\\Python35-x64
PYTHON_VERSION: 3.5.x
PYTHON_ARCH: 64
MSVC_VERSION: Visual Studio 15 Win64
- platform: x86
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
PYTHON: C:\\Python36
PYTHON_VERSION: 3.6.x
PYTHON_ARCH: 32
MSVC_VERSION: Visual Studio 15
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
PYTHON: C:\\Python36-x64
PYTHON_VERSION: 3.6.x
PYTHON_ARCH: 64
MSVC_VERSION: Visual Studio 15 Win64
- platform: x86
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
PYTHON: C:\\Python37
PYTHON_VERSION: 3.7.x
PYTHON_ARCH: 32
MSVC_VERSION: Visual Studio 15
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
PYTHON: C:\\Python37-x64
PYTHON_VERSION: 3.7.x
PYTHON_ARCH: 64
MSVC_VERSION: Visual Studio 15 Win64
- platform: x86
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
PYTHON: C:\\Python38
PYTHON_VERSION: 3.8.x
PYTHON_ARCH: 32
MSVC_VERSION: Visual Studio 15
- platform: x64
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
PYTHON: C:\\Python38-x64
PYTHON_VERSION: 3.8.x
PYTHON_ARCH: 64
MSVC_VERSION: Visual Studio 15
install:
- cmd: >-
REM ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
ECHO "Filesystem root:"
REM stdint for vc9
REM https://github.com/tango-controls/zmq-windows-ci/blob/master/appveyor.yml
REM appveyor DownloadFile https://raw.githubusercontent.com/mattn/gntp-send/master/include/msinttypes/stdint.h
REM cmd: copy stdint.h "C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include"
REM Update Python PATH of this build (so pip is available, this cannot be
REM done from inside the powershell script as it would require to restart
REM the parent CMD process).
SET PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%
python --version
REM for /f %%i in ('which vcpkg') do set VCPKG_PATH=%%i/installed
if "%PLATFORM%" == "x64" set LEVELDB="vcpkg install leveldb:x64-windows"
if "%PLATFORM%" == "x64" set VCPKG_SYS_PATH=x64-windows
if "%PLATFORM%" == "x86" set LEVELDB="vcpkg install leveldb:x86-windows"
if "%PLATFORM%" == "x86" set VCPKG_SYS_PATH=x86-windows
echo "%LEVELDB%"
echo "%VCPKG_PATH%/%VCPKG_SYS_PATH%/include"
echo "%VCPKG_PATH%/%VCPKG_SYS_PATH%/lib"
call "%LEVELDB%"
REM Upgrade to the latest version of pip to avoid it displaying warnings
REM about it being out of date.
pip install --disable-pip-version-check --user --upgrade pip
REM Install twine, support for 'bdist_wheel' and update setuptools.
pip install --upgrade wheel setuptools twine pytest
pip install -r requirements-dev.txt
build_script:
- cmd: >-
cython --cplus --fast-fail --annotate plyvel/_plyvel.pyx
echo "%VCPKG_PATH%/%VCPKG_SYS_PATH%/include"
echo "%VCPKG_PATH%/%VCPKG_SYS_PATH%/lib"
python setup.py build_ext --include-dirs=%VCPKG_PATH%/%VCPKG_SYS_PATH%/include --library-dirs=%VCPKG_PATH%/%VCPKG_SYS_PATH%/lib --libraries=shlwapi
python setup.py install
after_test:
- cmd: python setup.py bdist_wheel
artifacts:
- path: dist\*.whl
deploy:
- provider: GitHub
release: $(appveyor_build_version)-win
description: $(appveyor_build_version)-win
auth_token:
secure: UawhdM4kwf9nrfIvRPtPISwEe262kUVl+b+7C+mHNfowkxwDcysuWb1pOSPboHdA
prerelease: true
force_update: true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment