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

pillow-wheels has been incorporated into Pillow #191

Merged
merged 2 commits into from
Oct 28, 2023
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
6 changes: 5 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,11 @@ jobs:
run: |
sudo apt-get update && sudo apt-get install -qyy debootstrap
if [ "${{ matrix.target }}" = "latest" ]; then
git submodule update --remote Pillow
if [[ -n "$matrix.test-image" ]]; then
git submodule update --remote --init --recursive Pillow
else
git submodule update --remote Pillow
fi
(cd Pillow && git checkout main)
fi
sudo chown -R 1000 $(pwd)
Expand Down
14 changes: 5 additions & 9 deletions manylinux2014-wheel-build/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,18 +1,14 @@
FROM quay.io/pypa/manylinux2014_x86_64:latest

run mkdir /src && mkdir /Pillow
RUN mkdir /src
ENV SRC=/src
ENV PATH=/opt/rh/devtoolset-9/root/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

RUN git clone --depth 1 https://github.com/python-pillow/pillow-wheels /src/pillow-wheels

COPY build_depends.sh /src
copy yum_install /usr/local/bin

RUN cd $SRC/pillow-wheels \
&& git submodule update --init multibuild \
&& bash $SRC/build_depends.sh
COPY build_depends.sh $SRC
COPY Pillow $SRC
COPY yum_install /usr/local/bin

RUN cd $SRC && bash build_depends.sh

FROM quay.io/pypa/manylinux2014_x86_64:latest
COPY --from=0 /usr/local/lib /usr/local/lib
Expand Down
3 changes: 3 additions & 0 deletions manylinux2014-wheel-build/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ TEST_IMAGE := $(if $(DOCKER_USERNAME), $(DOCKER_USERNAME)/$(TEST_TARGET):$(BRANC

.PHONY: build
build:
cp -r ../Pillow .
docker build -t $(IMAGENAME):$(BRANCH) .

.PHONY: update
Expand All @@ -27,6 +28,8 @@ wheel:
_PYVER=310 $(MAKE) wheel
311:
_PYVER=311 $(MAKE) wheel
312:
_PYVER=312 $(MAKE) wheel

.PHONY: test
test: 310
Expand Down
2 changes: 1 addition & 1 deletion manylinux2014-wheel-build/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ The Makefile has several new commands:

* make wheel: Makes a Python 3.10 manylinux2014 wheel, and puts it in the
./out directory.
* make 38|39|310|311: These are specific commands to make
* make 38|39|310|311|312: These are specific commands to make
the corresponding 3.x version in the ./out directory.

The test target here is mainly to validate the image build, it is
Expand Down
4 changes: 2 additions & 2 deletions manylinux2014-wheel-build/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ fi
# not strictly necessary, unless running multiple versions from the shell
rm -f /tmp/*.whl || true

# Python version, as 38,39,310,311. Defaults to 310.
# Python version, as 38,39,310,311,312. Defaults to 310.
# Matches the naming in /opt/python/
PYVER=${1:-310}
PYBIN=$(echo /opt/python/cp${PYVER}*/bin)
Expand All @@ -29,4 +29,4 @@ PATH=$PYBIN:$PATH make clean
# Build and repair
$PYBIN/pip --verbose wheel ${OPTS} -w /tmp /Pillow
$PYBIN/pip install auditwheel
$PYBIN/python3 -m auditwheel repair /tmp/Pillow*whl -w /output
$PYBIN/python3 -m auditwheel repair /tmp/pillow*whl -w /output
6 changes: 3 additions & 3 deletions manylinux2014-wheel-build/build_depends.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@
# limitations under the License.


. multibuild/common_utils.sh
. wheels/multibuild/common_utils.sh

export CONFIGURE_BUILD_SOURCED=1
BUILD_PREFIX="${BUILD_PREFIX:-/usr/local}"
export CPPFLAGS="-I$BUILD_PREFIX/include $CPPFLAGS"
export LIBRARY_PATH="$BUILD_PREFIX/lib:$LIBRARY_PATH"
export PKG_CONFIG_PATH="$BUILD_PREFIX/lib/pkgconfig/:$PKG_CONFIG_PATH"

. multibuild/library_builders.sh
. config.sh
. wheels/multibuild/library_builders.sh
. wheels/config.sh

yum install -y devtoolset-9-gcc devtoolset-9-gcc-c++
pre_build
14 changes: 5 additions & 9 deletions manylinux_2_28-wheel-build/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,18 +1,14 @@
FROM quay.io/pypa/manylinux_2_28_x86_64:latest

run mkdir /src && mkdir /Pillow
RUN mkdir /src
ENV SRC=/src
ENV PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

RUN git clone --depth 1 https://github.com/python-pillow/pillow-wheels /src/pillow-wheels

COPY build_depends.sh /src
copy yum_install /usr/local/bin

RUN cd $SRC/pillow-wheels \
&& git submodule update --init multibuild \
&& bash $SRC/build_depends.sh
COPY build_depends.sh $SRC
COPY Pillow $SRC
COPY yum_install /usr/local/bin

RUN cd $SRC && bash build_depends.sh

FROM quay.io/pypa/manylinux_2_28_x86_64:latest
COPY --from=0 /usr/local/lib /usr/local/lib
Expand Down
3 changes: 3 additions & 0 deletions manylinux_2_28-wheel-build/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ TEST_IMAGE := $(if $(DOCKER_USERNAME), $(DOCKER_USERNAME)/$(TEST_TARGET):$(BRANC

.PHONY: build
build:
cp -r ../Pillow .
docker build -t $(IMAGENAME):$(BRANCH) .

.PHONY: update
Expand All @@ -27,6 +28,8 @@ wheel:
_PYVER=310 $(MAKE) wheel
311:
_PYVER=311 $(MAKE) wheel
312:
_PYVER=312 $(MAKE) wheel

.PHONY: test
test: 310
Expand Down
2 changes: 1 addition & 1 deletion manylinux_2_28-wheel-build/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ The Makefile has several new commands:

* make wheel: Makes a Python 3.10 manylinux_2_28 wheel, and puts it in the
./out directory.
* make 38|39|310|311: These are specific commands to make
* make 38|39|310|311|312: These are specific commands to make
the corresponding 3.x version in the ./out directory.

The test target here is mainly to validate the image build, it is
Expand Down
4 changes: 2 additions & 2 deletions manylinux_2_28-wheel-build/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ fi
# not strictly necessary, unless running multiple versions from the shell
rm -f /tmp/*.whl || true

# Python version, as 38,39,310,311. Defaults to 310.
# Python version, as 38,39,310,311,312. Defaults to 310.
# Matches the naming in /opt/python/
PYVER=${1:-310}
PYBIN=$(echo /opt/python/cp${PYVER}*/bin)
Expand All @@ -29,4 +29,4 @@ PATH=$PYBIN:$PATH make clean
# Build and repair
$PYBIN/pip --verbose wheel ${OPTS} -w /tmp /Pillow
$PYBIN/pip install auditwheel
$PYBIN/python3 -m auditwheel repair /tmp/Pillow*whl -w /output
$PYBIN/python3 -m auditwheel repair /tmp/pillow*whl -w /output
6 changes: 3 additions & 3 deletions manylinux_2_28-wheel-build/build_depends.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@
# limitations under the License.


. multibuild/common_utils.sh
. wheels/multibuild/common_utils.sh

export CONFIGURE_BUILD_SOURCED=1
BUILD_PREFIX="${BUILD_PREFIX:-/usr/local}"
export CPPFLAGS="-I$BUILD_PREFIX/include $CPPFLAGS"
export LIBRARY_PATH="$BUILD_PREFIX/lib:$LIBRARY_PATH"
export PKG_CONFIG_PATH="$BUILD_PREFIX/lib/pkgconfig/:$PKG_CONFIG_PATH"

. multibuild/library_builders.sh
. config.sh
. wheels/multibuild/library_builders.sh
. wheels/config.sh

dnf group install -y "Development Tools"
pre_build