Skip to content

Add s390x support #392

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

Merged
merged 1 commit into from
Nov 15, 2019
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
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ matrix:
env: PLATFORM="aarch64"
- arch: ppc64le
env: PLATFORM="ppc64le"
- arch: s390x
env: PLATFORM="s390x"

script:
- PLATFORM=$PLATFORM TRAVIS_COMMIT=$TRAVIS_COMMIT ./build.sh
Expand Down
5 changes: 5 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,11 @@ ppc64le image: ``quay.io/pypa/manylinux2014_ppc64le``
.. image:: https://quay.io/repository/pypa/manylinux2014_ppc64le/status
:target: https://quay.io/repository/pypa/manylinux2014_ppc64le

s390x image: ``quay.io/pypa/manylinux2014_s390x``

.. image:: https://quay.io/repository/pypa/manylinux2014_s390x/status
:target: https://quay.io/repository/pypa/manylinux2014_s390x

These images are rebuilt using Travis-CI on every commit to this
repository; see the
`docker/ <https://github.com/pypa/manylinux/tree/manylinux2014/docker>`_
Expand Down
19 changes: 19 additions & 0 deletions docker/Dockerfile-s390x
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
FROM s390x/clefos:7
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is what was missing to get gh-391 going. For future reference, how did you know what to specify here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For future reference, how did you know what to specify here?

Well, I didn't know. I googled around, found this: http://containerz.blogspot.com/2017/07/an-overview-on-s390x-base-images.html which lead me there https://hub.docker.com/_/clefos to gather the fact that the image was part of docker official images (i.e. good enough to use as a base image without too much further research) and https://www.sinenomine.net/products/linux/clefos (official page, mostly to gather if devtoolset-8 was part of the package list or not).

LABEL maintainer="The ManyLinux project"

ENV AUDITWHEEL_ARCH s390x
ENV AUDITWHEEL_PLAT manylinux2014_$AUDITWHEEL_ARCH
ENV LC_ALL en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US.UTF-8
ENV DEVTOOLSET_ROOTPATH /opt/rh/devtoolset-8/root
ENV PATH $DEVTOOLSET_ROOTPATH/usr/bin:$PATH
ENV LD_LIBRARY_PATH $DEVTOOLSET_ROOTPATH/usr/lib64:$DEVTOOLSET_ROOTPATH/usr/lib:$DEVTOOLSET_ROOTPATH/usr/lib64/dyninst:$DEVTOOLSET_ROOTPATH/usr/lib/dyninst:/usr/local/lib64:/usr/local/lib
ENV PKG_CONFIG_PATH /usr/local/lib/pkgconfig

COPY build_scripts /build_scripts
RUN bash build_scripts/build.sh && rm -r build_scripts

ENV SSL_CERT_FILE=/opt/_internal/certs.pem

CMD ["/bin/bash"]
4 changes: 3 additions & 1 deletion docker/build_scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ sed -i '/^override_install_langs=/d' /etc/yum.conf
# concerns."
# Decided not to clean at this point: https://github.com/pypa/manylinux/pull/129
yum -y update
yum -y install yum-utils
yum-config-manager --enable extras

# upgrading glibc-common can end with removal on en_US.UTF-8 locale
localedef -i en_US -f UTF-8 en_US.UTF-8
Expand All @@ -62,7 +64,7 @@ if [ "${AUDITWHEEL_ARCH}" == "x86_64" ]; then
yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
YASM=yasm
TOOLCHAIN_DEPS=${DEVTOOLSET8_TOOLCHAIN_DEPS}
elif [ "${AUDITWHEEL_ARCH}" == "aarch64" ] || [ "${AUDITWHEEL_ARCH}" == "ppc64le" ]; then
elif [ "${AUDITWHEEL_ARCH}" == "aarch64" ] || [ "${AUDITWHEEL_ARCH}" == "ppc64le" ] || [ "${AUDITWHEEL_ARCH}" == "s390x" ]; then
# Software collection (for devtoolset-8)
yum -y install centos-release-scl-rh
TOOLCHAIN_DEPS=${DEVTOOLSET8_TOOLCHAIN_DEPS}
Expand Down