Skip to content

Commit b94f5ad

Browse files
authored
Merge pull request #19 from mattip/manylinux2010
ENH: add multilinux2010
2 parents a615d78 + 83d84e1 commit b94f5ad

File tree

3 files changed

+27
-18
lines changed

3 files changed

+27
-18
lines changed

.travis.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,22 @@ matrix:
77
services:
88
- docker
99
env: DOCKER_IMAGE=quay.io/pypa/manylinux1_x86_64
10+
PLAT=manylinux1_x86_64
1011
- sudo: required
1112
services:
1213
- docker
1314
env: DOCKER_IMAGE=quay.io/pypa/manylinux1_i686
1415
PRE_CMD=linux32
16+
PLAT=manylinux1_i686
17+
- sudo: required
18+
services:
19+
- docker
20+
env: DOCKER_IMAGE=quay.io/pypa/manylinux2010_x86_64
21+
PLAT=manylinux2010_x86_64
1522

1623
install:
1724
- docker pull $DOCKER_IMAGE
1825

1926
script:
20-
- docker run --rm -v `pwd`:/io $DOCKER_IMAGE $PRE_CMD /io/travis/build-wheels.sh
27+
- docker run --rm -e PLAT=$PLAT -v `pwd`:/io $DOCKER_IMAGE $PRE_CMD /io/travis/build-wheels.sh
2128
- ls wheelhouse/

README.md

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,20 @@ Demo project for building Python wheels for Linux with Travis-CI
66

77

88
This is an example of how to use Travis-CI to build
9-
[PEP 513](https://www.python.org/dev/peps/pep-0513/)-compatible manylinux1
10-
wheels for Python. It supports both Python 2 and 3 on 32 and 64 bit linux
11-
architectures.
9+
[PEP 513](https://www.python.org/dev/peps/pep-0513/)-compatible
10+
wheels for Python. It supports
1211

13-
Because these wheels need to be compiled on CentOS 5, this example uses Docker
14-
running on Travis-CI to compile (you don't need to use docker at all to _use_
15-
these wheels, it's just to compile them). The docker-based build environment
16-
images are:
12+
- manylinux1 for both Python 2 and 3 on 32 and 64 bit linux architectures.
13+
- manylinux2010 for Python 2 and 3 on 64 bit linux architectures.
1714

18-
- 64-bit image (x86-64): ``quay.io/pypa/manylinux1_x86_64`` [![Docker Repository on Quay](https://quay.io/repository/pypa/manylinux1_x86_64/status "Docker Repository on Quay")](https://quay.io/repository/pypa/manylinux1_x86_64)
19-
- 32-bit image (i686): ``quay.io/pypa/manylinux1_i686`` [![Docker Repository on Quay](https://quay.io/repository/pypa/manylinux1_i686/status "Docker Repository on Quay")](https://quay.io/repository/pypa/manylinux1_i686)
15+
Because these wheels need to be compiled with a specific toolchain and support
16+
libraries , this example uses Docker running on Travis-CI to compile (you don't
17+
need to use docker at all to _use_ these wheels, it's just to compile them).
18+
The docker-based build environment images are:
19+
20+
- 64-bit image for manylinux1 (x86-64): ``quay.io/pypa/manylinux1_x86_64`` [![Docker Repository on Quay](https://quay.io/repository/pypa/manylinux1_x86_64/status "Docker Repository on Quay")](https://quay.io/repository/pypa/manylinux1_x86_64)
21+
- 32-bit image for manylinux1 (i686): ``quay.io/pypa/manylinux1_i686`` [![Docker Repository on Quay](https://quay.io/repository/pypa/manylinux1_i686/status "Docker Repository on Quay")](https://quay.io/repository/pypa/manylinux1_i686)
22+
- 64-bit image for manylinux2010 (x86-64): ``quay.io/pypa/manylinux2010_x86_64`` [![Docker Repository on Quay](https://quay.io/repository/pypa/manylinux2010_x86_64/status "Docker Repository on Quay")](https://quay.io/repository/pypa/manylinux2010_x86_64)
2023

2124
This sample project contains a very simple C compile extension module that links
2225
to an external library (ATLAS, a linear algebra library). The build is
@@ -31,13 +34,12 @@ resulting build logs can be found at
3134
https://travis-ci.org/pypa/python-manylinux-demo
3235

3336
The `.travis.yml` file instructs Travis to run the script
34-
`travis/build-wheels.sh` inside of the 32-bit and 64-bit manylinux1 docker
35-
build environments. This script builds the package using `pip`. But these
36-
wheels link against an external library. So to create self-contained wheels,
37-
the build script runs the wheels through
38-
[`auditwheel`](https://pypi.python.org/pypi/auditwheel), which copies the external
39-
library into the wheel itself, so that users won't need to install any extra non-PyPI
40-
dependencies.
37+
`travis/build-wheels.sh` inside of the various docker build environments. This
38+
script builds the package using `pip`. But these wheels link against an
39+
external library. So to create self-contained wheels, the build script runs the
40+
wheels through [`auditwheel`](https://pypi.python.org/pypi/auditwheel), which
41+
copies the external library into the wheel itself, so that users won't need to
42+
install any extra non-PyPI dependencies.
4143

4244
Code of Conduct
4345
---------------

travis/build-wheels.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ done
1212

1313
# Bundle external shared libraries into the wheels
1414
for whl in wheelhouse/*.whl; do
15-
auditwheel repair "$whl" -w /io/wheelhouse/
15+
auditwheel repair "$whl" --plat $PLAT -w /io/wheelhouse/
1616
done
1717

1818
# Install packages and test

0 commit comments

Comments
 (0)