This repository has been archived by the owner on Oct 20, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
appveyor.yml
81 lines (64 loc) · 2.39 KB
/
appveyor.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
os: Visual Studio 2019
image: Visual Studio 2019
platform:
- x64
environment:
global:
REPO_DIR: zgy2sgz
ZFP_DIR: zfp
PACKAGE_NAME: zgy2sgz
BUILD_DEPENDS: "cython numpy"
TWINE_USERNAME: "__token__"
TWINE_PASSWORD:
secure: yNYS7xZ1Cx+oINGqVDiiZhVtDGJR7eK1irisAGXUjEzw0zzcRQ7X+5Z2QMNjOe7viPmMAkhyd82FeeiYbvQkDSgW0AJY3RF9CKwUJAwsX7OEgcl6Z4gmwGNp93HwucdX3vDHD+qawXmWdzPjfZbAZxr5E0OTQuVD1v+CpET7JluUh2pFEf8wZvA623JnnK9SXyQvz986nM8mT7JV/yFDaeCsPQTAqUFYD4mCYROTybA=
matrix:
- PYTHON: C:\Python36
PYTHON_VERSION: 36
- PYTHON: C:\Python37
PYTHON_VERSION: 37
- PYTHON: C:\Python38
PYTHON_VERSION: 38
- PYTHON: C:\Python39
PYTHON_VERSION: 39
install:
- IF "%platform%" == "x64" SET PYTHON=%PYTHON%-x64
- git submodule init
- git submodule update
# Check that we have the expected version and architecture for Python
- SET PATH=%PYTHON%;%PYTHON%\Lib;%PYTHON%\Libs;%PYTHON%\Scripts;%PYTHON%\Library\bin;%PATH%
- python --version
- python -m pip install pip
- python -m pip install --upgrade pip
- python -m pip install twine wheel cython numpy scikit-build
- python -m pip install --upgrade setuptools
- IF %PYTHON_VERSION% == "36" python -m pip install "cmake<3.14"
- IF %PYTHON_VERSION% == "37" python -m pip install "cmake<3.14"
- IF %PYTHON_VERSION% == "38" python -m pip install cmake
- IF %PYTHON_VERSION% == "39" python -m pip install cmake
- echo %PATH%
- echo %PYTHON%
before_build:
- set generator="Visual Studio 16 2019"
build_script:
- cd %ZFP_DIR%
- mkdir build
- cd build
- cmake .. -G %generator% -DBUILD_TESTING=OFF
- cmake --build . --config Release
- cd ../../%REPO_DIR%
- mkdir build
- cd build
- cmake .. -G %generator%
- cmake --build . --config Release
- cd ../..
- cp zgy2sgz/build/convert/Release/zgy2sgz.dll .
- cp zfp/build/bin/Release/zfp.dll .
- cp zgy2sgz/open-zgy/zgy/Slb.Salmon.ZgyPublic/x64_vs140/Salmon/Main/Release/Slb.Salmon.Zgy.dll .
- python setup.py bdist_wheel
deploy_script:
- ps: |
Write-Host "TAG: $env:APPVEYOR_REPO_TAG"
If ($env:APPVEYOR_REPO_TAG -eq "false") { return }
Write-Host "Uploading wheels to pypi"
Invoke-Expression "python -m twine upload --skip-existing dist/*"
If ($LastExitCode -ne 0) { $host.SetShouldExit($LastExitCode) }