Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix python build #407

Merged
merged 7 commits into from
Aug 11, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 11 additions & 3 deletions .travis.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
#!/bin/bash

case "$1" in
"install")
Expand Down Expand Up @@ -36,14 +36,22 @@ case "$1" in
ctest -V
;;
"python")
python setup.py build_ext test
if [ "${TRAVIS_OS_NAME}" = "osx" ]; then
source venv/bin/activate
fi
python setup.py build_ext test
;;
esac
;;
"after_success")
case "${BUILD_SYSTEM}" in
"python")
pip wheel -w dist .
case "${TRAVIS_OS_NAME}" in
"osx")
source venv/bin/activate
pip wheel -w dist .
;;
esac
;;
esac
;;
Expand Down
18 changes: 5 additions & 13 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -159,19 +159,11 @@ matrix:
## Python OS X builds
###
- os: osx
env: BUILD_SYSTEM=python INSTALL_TYPE=system PYTHON_VERSION=2.7
env: BUILD_SYSTEM=python INSTALL_TYPE=macpython PYTHON_VERSION=2.7.12
- os: osx
env: BUILD_SYSTEM=python INSTALL_TYPE=macpython PYTHON_VERSION=2.7.10
env: BUILD_SYSTEM=python INSTALL_TYPE=macpython PYTHON_VERSION=3.4.4
- os: osx
env: BUILD_SYSTEM=python INSTALL_TYPE=homebrew PYTHON_VERSION=2.7.10
- os: osx
env: BUILD_SYSTEM=python INSTALL_TYPE=macpython PYTHON_VERSION=3.4.3
- os: osx
env: BUILD_SYSTEM=python INSTALL_TYPE=homebrew PYTHON_VERSION=3.4.3
- os: osx
env: BUILD_SYSTEM=python INSTALL_TYPE=macpython PYTHON_VERSION=3.5.0
- os: osx
env: BUILD_SYSTEM=python INSTALL_TYPE=homebrew PYTHON_VERSION=3.5.0
env: BUILD_SYSTEM=python INSTALL_TYPE=macpython PYTHON_VERSION=3.5.2

###
## Sanitizers
Expand Down Expand Up @@ -240,7 +232,7 @@ after_success:
- ./.travis.sh after_success

before_deploy:
- if [ "${BUILD_SYSTEM}" = "python" ]; then export WHEELS=$(ls ./dist/*.whl); fi
- if [ "${BUILD_SYSTEM}" = "python" ] && [ "${TRAVIS_OS_NAME}" = "osx" ]; then export WHEELS=$(ls ./dist/*.whl); fi

deploy:
provider: releases
Expand All @@ -251,4 +243,4 @@ deploy:
on:
repo: "google/brotli"
tags: true
condition: "${BUILD_SYSTEM} = python"
condition: "${BUILD_SYSTEM} = python && ${TRAVIS_OS_NAME} = osx"