This repository has been archived by the owner on Oct 8, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #169 from nulano/gha
- Loading branch information
Showing
4 changed files
with
144 additions
and
196 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
|
||
if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then | ||
if [[ "$MB_PYTHON_VERSION" == "pypy3.6-7.3" ]]; then | ||
# for https://foss.heptapod.net/pypy/pypy/-/issues/3229 | ||
# TODO remove when that is fixed | ||
brew install tcl-tk | ||
fi | ||
# these cause a conflict with built webp and libtiff | ||
brew remove --ignore-dependencies webp zstd xz libtiff | ||
fi | ||
|
||
if [[ "$MB_PYTHON_VERSION" == "pypy3.6-7.3" ]]; then | ||
if [[ "$TRAVIS_OS_NAME" != "macos-latest" ]]; then | ||
MB_ML_VER="2010" | ||
DOCKER_TEST_IMAGE="multibuild/xenial_$PLAT" | ||
else | ||
MB_PYTHON_OSX_VER="10.9" | ||
fi | ||
fi | ||
|
||
echo "::group::Install a virtualenv" | ||
source multibuild/common_utils.sh | ||
source multibuild/travis_steps.sh | ||
# can't use default 7.3.1 on macOS due to https://foss.heptapod.net/pypy/pypy/-/issues/3229 | ||
LATEST_PP_7p3=7.3.2 | ||
pip install virtualenv | ||
before_install | ||
echo "::endgroup::" | ||
|
||
echo "::group::Build wheel" | ||
clean_code $REPO_DIR $BUILD_COMMIT | ||
build_wheel $REPO_DIR $PLAT | ||
ls -l "${GITHUB_WORKSPACE}/${WHEEL_SDIR}/" | ||
echo "::endgroup::" | ||
|
||
echo "::group::Test wheel" | ||
install_run $PLAT | ||
echo "::endgroup::" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
|
||
name: Wheels | ||
|
||
on: [push, pull_request] | ||
|
||
env: | ||
REPO_DIR: Pillow | ||
BUILD_DEPENDS: "" | ||
TEST_DEPENDS: "pytest pytest-cov" | ||
MACOSX_DEPLOYMENT_TARGET: "10.10" | ||
WHEEL_SDIR: wheelhouse | ||
|
||
jobs: | ||
build: | ||
name: ${{ matrix.python }} ${{ matrix.os-name }} ${{ matrix.platform }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ "ubuntu-16.04", "macos-latest" ] | ||
python: [ "pypy3.6-7.3", "3.6", "3.7", "3.8", "3.9" ] | ||
platform: [ "x86_64", "i686" ] | ||
exclude: | ||
- os: "macos-latest" | ||
platform: "i686" | ||
include: | ||
- os: "macos-latest" | ||
os-name: "osx" | ||
- os: "ubuntu-16.04" | ||
os-name: "xenial" | ||
env: | ||
BUILD_COMMIT: HEAD | ||
PLAT: ${{ matrix.platform }} | ||
MB_PYTHON_VERSION: ${{ matrix.python }} | ||
TRAVIS_OS_NAME: ${{ matrix.os-name }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: true | ||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.9 | ||
- name: Build Wheel | ||
run: .github/workflows/build.sh | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: wheels | ||
path: wheelhouse/*.whl | ||
# Uncomment to get SSH access for testing | ||
# - name: Setup tmate session | ||
# if: failure() | ||
# uses: mxschmitt/action-tmate@v3 | ||
|
||
build-latest: | ||
name: ${{ matrix.python }} ${{ matrix.os-name }} ${{ matrix.platform }} latest | ||
runs-on: ${{ matrix.os }} | ||
if: "!startsWith(github.ref, 'refs/tags/')" | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ "ubuntu-16.04", "macos-latest" ] | ||
python: [ "pypy3.6-7.3", "3.6", "3.7", "3.8", "3.9" ] | ||
platform: [ "x86_64", "i686" ] | ||
exclude: | ||
- os: "macos-latest" | ||
platform: "i686" | ||
include: | ||
- os: "macos-latest" | ||
os-name: "osx" | ||
- os: "ubuntu-16.04" | ||
os-name: "xenial" | ||
env: | ||
BUILD_COMMIT: master | ||
PLAT: ${{ matrix.platform }} | ||
MB_PYTHON_VERSION: ${{ matrix.python }} | ||
TRAVIS_OS_NAME: ${{ matrix.os-name }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: true | ||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.9 | ||
- name: Build Wheel | ||
run: .github/workflows/build.sh | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: wheels-latest | ||
path: wheelhouse/*.whl | ||
|
||
release: | ||
name: Create Release | ||
runs-on: ubuntu-latest | ||
if: "startsWith(github.ref, 'refs/tags/')" | ||
needs: build | ||
steps: | ||
- uses: actions/download-artifact@v2 | ||
with: | ||
name: wheels | ||
- name: Upload Release | ||
uses: fnkr/github-action-ghr@v1.3 | ||
env: | ||
GHR_PATH: . | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters