diff --git a/.azure/ci-linux-job.yml b/.azure/ci-linux-job.yml new file mode 100644 index 00000000..08a2d79c --- /dev/null +++ b/.azure/ci-linux-job.yml @@ -0,0 +1,67 @@ +jobs: +- job: Linux_CI + displayName: 'Linux CI' + pool: + vmImage: 'Ubuntu 16.04' + strategy: + matrix: + Py27: + python: 'python2.7' + make_venv: 'python2.7 -m virtualenv venv' + venv_pkg: 'python-virtualenv' + Py36: + python: 'python3.6' + make_venv: 'python3.6 -m venv venv' + venv_pkg: 'python3.6-venv' + Py37: + python: 'python3.7' + make_venv: 'python3.7 -m venv venv' + venv_pkg: 'python3.7-venv' + maxParallel: 3 + + variables: {'PYTHONUNBUFFERED': '1'} + + steps: + - checkout: self + submodules: recursive + + - script: | + sudo add-apt-repository -y ppa:deadsnakes/ppa + sudo apt-get update + sudo apt-get install -y build-essential + sudo apt-get install -y $PYTHON ${PYTHON}-dev lib${PYTHON}-dev + sudo apt-get install -y libgtk-3-dev libjpeg-dev libtiff-dev \ + libsdl2-dev libgstreamer-plugins-base1.0-dev libnotify-dev \ + libsm-dev libwebkit2gtk-4.0-dev libxtst-dev \ + libgl1-mesa-dev libglu1-mesa-dev $VENV_PKG + displayName: 'Install deb package requirements' + + - script: | + $PYTHON --version + $MAKE_VENV + source venv/bin/activate + python -m pip install -U pip setuptools wheel + python -m pip install -r requirements.txt + displayName: 'Install Python dependencies' + + - script: | + source venv/bin/activate + python build.py --jobs=4 build_wx + displayName: 'build wxWidgets' + + - script: | + source venv/bin/activate + python build.py dox etg --nodoc sip + displayName: 'generate code' + + - script: | + source venv/bin/activate + python build.py --jobs=4 build_py + displayName: 'build wxPython' + + - script: | + source venv/bin/activate + python build.py bdist_wheel + python build.py install + python -c "import wx; print(wx.version());" + displayName: 'build wheel and test install' diff --git a/.azure/ci-macos-job.yml b/.azure/ci-macos-job.yml new file mode 100644 index 00000000..df4447c3 --- /dev/null +++ b/.azure/ci-macos-job.yml @@ -0,0 +1,61 @@ +jobs: +- job: MacOS_CI + displayName: 'MacOS CI' + pool: + vmImage: 'macOS-10.13' + strategy: + matrix: + Py27: + python_version: '2.7.16' + python_pkg: 'python-2.7.16-macosx10.9.pkg' + python: 'python2.7' + Py36: + python_version: '3.6.8' + python_pkg: 'python-3.6.8-macosx10.9.pkg' + python: 'python3.6' + Py37: + python_version: '3.7.3' + python_pkg: 'python-3.7.3-macosx10.9.pkg' + python: 'python3.7' + maxParallel: 3 + + + variables: {'PYTHONUNBUFFERED': '1'} + + steps: + - checkout: self + submodules: recursive + + - script: | + curl -O https://www.python.org/ftp/python/$PYTHON_VERSION/$PYTHON_PKG + sudo installer -pkg $PYTHON_PKG -target / + which $PYTHON + $PYTHON --version + displayName: 'Fetch Python' + + - script: | + curl -O https://bootstrap.pypa.io/get-pip.py + $PYTHON get-pip.py + $PYTHON -m pip install -U setuptools wheel + $PYTHON -m pip install -r requirements.txt + displayName: 'Install Python dependencies' + + - script: | + #sudo xcode-select -s /Applications/Xcode_9.4.1.app/Contents/Developer + xcode-select --print-path + $PYTHON build.py --jobs=4 build_wx + displayName: 'build wxWidgets' + + - script: | + $PYTHON build.py dox etg --nodoc sip + displayName: 'generate code' + + - script: | + $PYTHON build.py --jobs=4 build_py + displayName: 'build wxPython' + + - script: | + $PYTHON build.py bdist_wheel + $PYTHON build.py install + $PYTHON -c "import wx; print(wx.version());" + displayName: 'build wheel and test install' diff --git a/.azure/ci-windows-job.yml b/.azure/ci-windows-job.yml new file mode 100644 index 00000000..1d1edc0a --- /dev/null +++ b/.azure/ci-windows-job.yml @@ -0,0 +1,68 @@ +jobs: +- job: Windows_CI + displayName: 'Windows CI' + pool: + #vmImage: 'vs2015-win2012r2' + vmImage: 'vs2017-win2016' + strategy: + matrix: + Py36_x86: + python.version: '3.6' + python.arch: x86 + addToPath: true + Py37_x86: + python.version: '3.7' + python.arch: x86 + addToPath: true + Py36_x64: + python.version: '3.6' + python.arch: x64 + addToPath: true + Py37_x64: + python.version: '3.7' + python.arch: x64 + addToPath: true + maxParallel: 4 + + + variables: {'PYTHONUNBUFFERED': '1'} + + steps: + - checkout: self + submodules: recursive + + - task: UsePythonVersion@0 + inputs: + versionSpec: '$(python.version)' + architecture: '$(python.arch)' + + - bash: | + which python + python -c "import sys; print(sys.version); print(sys.prefix)" + displayName: 'Check Python' + + - bash: | + curl -O https://bootstrap.pypa.io/get-pip.py + python get-pip.py + python -m pip install -U setuptools wheel + python -m pip install -r requirements.txt + displayName: 'Install Python dependencies' + + - bash: | + which cl.exe + python build.py --jobs=4 build_wx + displayName: 'build wxWidgets' + + - bash: | + python build.py dox etg --nodoc sip + displayName: 'generate code' + + - bash: | + python build.py --jobs=4 build_py + displayName: 'build wxPython' + + - bash: | + python build.py bdist_wheel + python build.py install + python -c "import wx; print(wx.version());" + displayName: 'build wheel and test install' diff --git a/.circleci/config.yml b/.circleci/config.yml deleted file mode 100644 index ff336e97..00000000 --- a/.circleci/config.yml +++ /dev/null @@ -1,100 +0,0 @@ -# Python CircleCI 2.0 configuration file -# -# Check https://circleci.com/docs/2.0/language-python/ for more details -# -version: 2 - -# The configuration in this "shared" section are the things that each job will -# have in common, and are substituted into the jobs config below. It is the -# job definitions that specify the things that are unique to each job (like -# the Python version to use, via the docker image name). -shared: &shared - working_directory: ~/repo - - steps: - - checkout - - run: - name: checkout submodules - command: | - git submodule sync - git submodule update --init --recursive - - - run: - name: install apt packages - command: | - sudo apt-get update - sudo apt-get install -y libgtk-3-dev libjpeg-dev libtiff-dev \ - libsdl2-dev libgstreamer-plugins-base1.0-dev libnotify-dev \ - libsm-dev libwebkit2gtk-4.0-dev libxtst-dev \ - libgl1-mesa-dev libglu1-mesa-dev python-virtualenv - - - run: - name: install python packages - command: | - $MAKE_VENV - source venv/bin/activate - pip install -r requirements.txt - - - run: - name: build wxWidgets - command: | - source venv/bin/activate - python build.py --jobs=4 dox build_wx - - - run: - name: build wxPython - command: | - source venv/bin/activate - python build.py --jobs=4 etg --nodoc sip build_py - - - run: - name: build wheel and test install - command: | - source venv/bin/activate - python build.py bdist_wheel - python build.py install - python -c "import wx; print(wx.version())" - - -# We use one job for each version of Python that we want to build with. Each -# one gets its own copy of the shared config above. -jobs: - "Python-2.7": - <<: *shared - docker: - - image: circleci/python:2.7 - environment: - - MAKE_VENV: "python -m virtualenv venv" - - "Python-3.5": - <<: *shared - docker: - - image: circleci/python:3.5 - environment: - - MAKE_VENV: "python -m venv venv" - - "Python-3.6": - <<: *shared - docker: - - image: circleci/python:3.6 - environment: - - MAKE_VENV: "python -m venv venv" - - "Python-3.7": - <<: *shared - docker: - - image: circleci/python:3.7 - environment: - - MAKE_VENV: "python -m venv venv" - - -# This workflow defines the jobs that comprise the "build" task. The jobs will -# be run in parallel. -workflows: - version: 2 - build: - jobs: - - "Python-2.7" - - "Python-3.5" - - "Python-3.6" - - "Python-3.7" diff --git a/azure-pipelines.yml b/azure-pipelines.yml new file mode 100644 index 00000000..000c9314 --- /dev/null +++ b/azure-pipelines.yml @@ -0,0 +1,24 @@ +# CI for wxPython Phoenix on Azure DevOps + +#pipelines: +#- pipeline: +# + +name: CI.$(Date:yyyyMMdd).$(Rev:.r) + +trigger: +- master + +pr: + autoCancel: true + branches: + include: + - master + +jobs: +- template: .azure/ci-linux-job.yml +- template: .azure/ci-macos-job.yml +- template: .azure/ci-windows-job.yml + + + diff --git a/wscript b/wscript index 062818be..f93c783f 100644 --- a/wscript +++ b/wscript @@ -87,6 +87,11 @@ def configure(conf): # using VS 2017 everywhere for Python 3.7. msvc_version = '14.0' + # In some cases (Azure DevOps at least) we're getting "14.1" for Python + # 3.6 too. Smash it down to '14.0' + if msvc_version == "14.1" and sys.version_info[:2] == (3,6): + msvc_version = '14.0' + conf.env['MSVC_VERSIONS'] = ['msvc ' + msvc_version] conf.env['MSVC_TARGETS'] = [conf.options.msvc_arch] conf.load('msvc')