2
0

appveyor.yml 2.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. environment:
  2. matrix:
  3. - PYTHON: "C:\\Python27"
  4. PYTHON_VERSION: "2.7.x"
  5. PYTHON_ARCH: "32"
  6. - PYTHON: "C:\\Python27-x64"
  7. PYTHON_VERSION: "2.7.x"
  8. PYTHON_ARCH: "64"
  9. - PYTHON: "C:\\Python34"
  10. PYTHON_VERSION: "3.4.x"
  11. PYTHON_ARCH: "32"
  12. - PYTHON: "C:\\Python34-x64"
  13. PYTHON_VERSION: "3.4.x"
  14. PYTHON_ARCH: "64"
  15. DISTUTILS_USE_SDK: "1"
  16. - PYTHON: "C:\\Python35"
  17. PYTHON_VERSION: "3.5.x"
  18. PYTHON_ARCH: "32"
  19. - PYTHON: "C:\\Python35-x64"
  20. PYTHON_VERSION: "3.5.x"
  21. PYTHON_ARCH: "64"
  22. - PYTHON: "C:\\Python36"
  23. PYTHON_VERSION: "3.6.x"
  24. PYTHON_ARCH: "32"
  25. - PYTHON: "C:\\Python36-x64"
  26. PYTHON_VERSION: "3.6.x"
  27. PYTHON_ARCH: "64"
  28. install:
  29. # If there is a newer build queued for the same PR, cancel this one.
  30. # The AppVeyor 'rollout builds' option is supposed to serve the same
  31. # purpose but it is problematic because it tends to cancel builds pushed
  32. # directly to master instead of just PR builds (or the converse).
  33. # credits: JuliaLang developers.
  34. - ps: if ($env:APPVEYOR_PULL_REQUEST_NUMBER -and $env:APPVEYOR_BUILD_NUMBER -ne ((Invoke-RestMethod `
  35. https://ci.appveyor.com/api/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG/history?recordsNumber=50).builds | `
  36. Where-Object pullRequestId -eq $env:APPVEYOR_PULL_REQUEST_NUMBER)[0].buildNumber) { `
  37. throw "There are newer queued builds for this pull request, failing early." }
  38. - ECHO "Filesystem root:"
  39. - ps: "ls \"C:/\""
  40. - ECHO "Installed SDKs:"
  41. - ps: "ls \"C:/Program Files/Microsoft SDKs/Windows\""
  42. # Install Python (from the official .msi of http://python.org) and pip when
  43. # not already installed.
  44. - ps: if (-not(Test-Path($env:PYTHON))) { & appveyor\install.ps1 }
  45. # Prepend newly installed Python to the PATH of this build (this cannot be
  46. # done from inside the powershell script as it would require to restart
  47. # the parent CMD process).
  48. - "SET PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%"
  49. # Check that we have the expected version and architecture for Python
  50. - "build.cmd %PYTHON%\\python.exe --version"
  51. - "build.cmd %PYTHON%\\python.exe -c \"import struct; print(struct.calcsize('P') * 8)\""
  52. # Install setuptools/wheel so that we can e.g. use bdist_wheel
  53. - "pip install setuptools wheel"
  54. - "build.cmd %PYTHON%\\python.exe setup.py develop"
  55. build_script:
  56. # Build the compiled extension
  57. - "build.cmd %PYTHON%\\python.exe setup.py build"
  58. test_script:
  59. - "build.cmd %PYTHON%\\python.exe setup.py test"
  60. - "build.cmd %PYTHON%\\pythonw.exe setup.py test"
  61. after_test:
  62. - "build.cmd %PYTHON%\\python.exe setup.py bdist_wheel"
  63. # http://stackoverflow.com/questions/43255455/unicode-character-causing-error-with-bdist-wininst-on-python-3-but-not-python-2
  64. # - "python setup.py bdist_wininst"
  65. - "build.cmd %PYTHON%\\python.exe setup.py bdist_msi"
  66. - ps: "ls dist"
  67. artifacts:
  68. - path: dist\*