Files

20 lines
747 B
Docker

FROM balenalib/raspberry-pi-python:3.11-bullseye
ARG PILLOW_VERSION=10.3.0
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential python3-dev \
libjpeg-dev zlib1g-dev libtiff5-dev libwebp-dev libopenjp2-7-dev libfreetype6-dev \
&& apt-get clean && rm -rf /var/lib/apt/lists/*
RUN python3 -m pip install --upgrade pip wheel setuptools
RUN mkdir -p /out
RUN set -eux; \
echo "Building wheel for Pillow version ${PILLOW_VERSION}..."; \
python3 -m pip wheel --no-cache-dir --no-binary :all: -w /out pillow==${PILLOW_VERSION}; \
\
echo "--- Content of /out after build ---"; \
ls -lR /out; \
\
test -f /out/pillow-*.whl || (echo "FATAL: Pillow wheel file was not created!" && exit 1)