@@ -45,12 +45,12 @@ platform:
45
45
build : false
46
46
47
47
init :
48
- - " ECHO %PYTHON_VERSION% %CONDA_INSTALL_LOCN%"
48
+ - cmd : " ECHO %PYTHON_VERSION% %CONDA_INSTALL_LOCN%"
49
49
50
50
install :
51
51
- appveyor DownloadFile "https://raw.githubusercontent.com/pelson/Obvious-CI/master/bootstrap-obvious-ci-and-miniconda.py"
52
52
- cmd : python bootstrap-obvious-ci-and-miniconda.py %CONDA_INSTALL_LOCN% %TARGET_ARCH% %CONDA_PY:~0,1% --without-obvci
53
- - cmd : set PATH=%PATH%;% CONDA_INSTALL_LOCN%;%CONDA_INSTALL_LOCN%\scripts
53
+ - cmd : set PATH=%CONDA_INSTALL_LOCN%;%CONDA_INSTALL_LOCN%\scripts;%PATH%;
54
54
- cmd : set PYTHONUNBUFFERED=1
55
55
- cmd : conda install -c http://conda.anaconda.org/pelson/channel/development --yes --quiet obvious-ci
56
56
- cmd : obvci_install_conda_build_tools.py
@@ -59,12 +59,21 @@ install:
59
59
- cmd : conda config --add channels conda-forge
60
60
# this is now the downloaded conda...
61
61
- conda info -a
62
+
63
+ # Fix the appveyor build environment to work with conda build
64
+ # workaround for missing vcvars64.bat in py34 64bit
65
+ - cmd : copy ci\appveyor\vcvars64.bat "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64"
66
+ # workaround for conda build on py27 prefering the normal installed
67
+ # VS tools instead of the also installed Py27 VS compiler (which wouldn't need this workarounds...)
68
+ - cmd : copy "C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\vcvars64.bat" "C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\amd64\vcvarsamd64.bat"
69
+
62
70
# same things as the requirements in ci/conda_recipe/meta.yaml
63
71
- cmd : conda create -y -q -n test-environment python=%PYTHON_VERSION% pip setuptools numpy python-dateutil freetype msinttypes tk pyparsing pytz tornado libpng zlib pyqt cycler nose mock
64
72
- activate test-environment
65
73
- cmd : echo %PYTHON_VERSION% %TARGET_ARCH%
66
74
- cmd : IF %PYTHON_VERSION% == 2.7 conda install -y functools32
67
- # This is needed for the installer to find the dlls...
75
+
76
+ # Let the install prefer the static builds of the libs
68
77
- set LIBRARY_LIB=%CONDA_DEFAULT_ENV%\Library\lib
69
78
- cmd : ' mkdir lib || cmd /c "exit /b 0"'
70
79
- copy %LIBRARY_LIB%\zlibstatic.lib lib\z.lib
@@ -87,21 +96,28 @@ test_script:
87
96
after_test :
88
97
# After the tests were a success, build packages (wheels and conda)
89
98
90
- # There is a bug in wheels which prevents building wheels when the package uses namespaces
91
- - cmd : ' %CMD_IN_ENV% python setup.py bdist_wheel'
92
- # Note also that our setup.py script, which is called by conda-build, writes
93
- # a __conda_version__.txt file, so the version number on the binary package
94
- # is set dynamically. This unfortunately means that conda build --output
95
- # doesn't really work.
96
- - cmd : ' %CMD_IN_ENV% conda config --get channels'
99
+ # Build the wheel
100
+ # Hide the output, the copied files really clutter the build log...
101
+ - cmd : ' %CMD_IN_ENV% python setup.py bdist_wheel > NUL:'
102
+
103
+ # And now the conda build after a cleanup...
97
104
# cleanup build files so that they don't pollute the conda build but keep the wheel in dist...
98
105
- cmd : git clean -d -x -f -e dist/
106
+ # cleanup the environment so that the test-environment does not leak into the conda build...
107
+ - cmd : set MPLBASEDIRLIST=
108
+ - cmd : set LIBRARY_LIB=
109
+ - cmd : deactivate
110
+ - cmd : path
111
+ - cmd : where python
112
+ - cmd : ' %CMD_IN_ENV% conda config --get channels'
99
113
- cmd : ' %CMD_IN_ENV% conda build .\ci\conda_recipe'
114
+
100
115
# Move the conda package into the dist directory, to register it
101
116
# as an "artifact" for Appveyor.
102
117
- cmd : ' copy /Y %CONDA_INSTALL_LOCN%\conda-bld\win-32\*.bz2 dist || cmd /c "exit /b 0"'
103
118
- cmd : ' copy /Y %CONDA_INSTALL_LOCN%\conda-bld\win-64\*.bz2 dist || cmd /c "exit /b 0"'
104
- - cmd : dir .\dist\
119
+ - cmd : dir dist\
120
+ - cmd : echo finished...
105
121
106
122
artifacts :
107
123
- path : dist\*
@@ -112,5 +128,6 @@ artifacts:
112
128
type : zip
113
129
114
130
on_failure :
131
+ - echo zipping images after a failure...
115
132
- 7z a result_images.zip result_images\ >NUL :
116
133
- appveyor PushArtifact result_images.zip
0 commit comments