From a1dce0f830220d390f3603b0e3d0d8a3899ab6d8 Mon Sep 17 00:00:00 2001 From: Jesper Noordsij Date: Sat, 6 Jul 2024 19:25:48 +0200 Subject: [PATCH] Add pdo build batch for 8.4.0alpha1 --- 8.4-rc/alpine3.19/cli/Dockerfile | 16 ++++++++++++++++ 8.4-rc/alpine3.19/fpm/Dockerfile | 16 ++++++++++++++++ 8.4-rc/alpine3.19/zts/Dockerfile | 16 ++++++++++++++++ 8.4-rc/alpine3.20/cli/Dockerfile | 16 ++++++++++++++++ 8.4-rc/alpine3.20/fpm/Dockerfile | 16 ++++++++++++++++ 8.4-rc/alpine3.20/zts/Dockerfile | 16 ++++++++++++++++ 8.4-rc/bookworm/apache/Dockerfile | 14 ++++++++++++++ 8.4-rc/bookworm/cli/Dockerfile | 14 ++++++++++++++ 8.4-rc/bookworm/fpm/Dockerfile | 14 ++++++++++++++ 8.4-rc/bookworm/zts/Dockerfile | 14 ++++++++++++++ 8.4-rc/bullseye/apache/Dockerfile | 14 ++++++++++++++ 8.4-rc/bullseye/cli/Dockerfile | 14 ++++++++++++++ 8.4-rc/bullseye/fpm/Dockerfile | 14 ++++++++++++++ 8.4-rc/bullseye/zts/Dockerfile | 14 ++++++++++++++ Dockerfile-linux.template | 30 ++++++++++++++++++++++++++++++ 15 files changed, 238 insertions(+) diff --git a/8.4-rc/alpine3.19/cli/Dockerfile b/8.4-rc/alpine3.19/cli/Dockerfile index 05b78dab3..5987797a1 100644 --- a/8.4-rc/alpine3.19/cli/Dockerfile +++ b/8.4-rc/alpine3.19/cli/Dockerfile @@ -59,10 +59,14 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ apk add --no-cache --virtual .fetch-deps gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apk add --no-cache --virtual .patch-deps patchutils; \ \ mkdir -p /usr/src; \ cd /usr/src; \ @@ -84,6 +88,14 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ + apk del --no-network .patch-deps; \ apk del --no-network .fetch-deps COPY docker-php-source /usr/local/bin/ @@ -100,6 +112,7 @@ RUN set -eux; \ linux-headers \ oniguruma-dev \ openssl-dev \ + patch \ readline-dev \ sqlite-dev \ ; \ @@ -117,6 +130,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ ./configure \ --build="$gnuArch" \ diff --git a/8.4-rc/alpine3.19/fpm/Dockerfile b/8.4-rc/alpine3.19/fpm/Dockerfile index cec4af123..ea2a7c4ac 100644 --- a/8.4-rc/alpine3.19/fpm/Dockerfile +++ b/8.4-rc/alpine3.19/fpm/Dockerfile @@ -59,10 +59,14 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ apk add --no-cache --virtual .fetch-deps gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apk add --no-cache --virtual .patch-deps patchutils; \ \ mkdir -p /usr/src; \ cd /usr/src; \ @@ -84,6 +88,14 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ + apk del --no-network .patch-deps; \ apk del --no-network .fetch-deps COPY docker-php-source /usr/local/bin/ @@ -100,6 +112,7 @@ RUN set -eux; \ linux-headers \ oniguruma-dev \ openssl-dev \ + patch \ readline-dev \ sqlite-dev \ ; \ @@ -117,6 +130,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ ./configure \ --build="$gnuArch" \ diff --git a/8.4-rc/alpine3.19/zts/Dockerfile b/8.4-rc/alpine3.19/zts/Dockerfile index bc5ad2df3..cd14f6619 100644 --- a/8.4-rc/alpine3.19/zts/Dockerfile +++ b/8.4-rc/alpine3.19/zts/Dockerfile @@ -59,10 +59,14 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ apk add --no-cache --virtual .fetch-deps gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apk add --no-cache --virtual .patch-deps patchutils; \ \ mkdir -p /usr/src; \ cd /usr/src; \ @@ -84,6 +88,14 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ + apk del --no-network .patch-deps; \ apk del --no-network .fetch-deps COPY docker-php-source /usr/local/bin/ @@ -100,6 +112,7 @@ RUN set -eux; \ linux-headers \ oniguruma-dev \ openssl-dev \ + patch \ readline-dev \ sqlite-dev \ ; \ @@ -117,6 +130,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ ./configure \ --build="$gnuArch" \ diff --git a/8.4-rc/alpine3.20/cli/Dockerfile b/8.4-rc/alpine3.20/cli/Dockerfile index e197d7156..fba42d2ad 100644 --- a/8.4-rc/alpine3.20/cli/Dockerfile +++ b/8.4-rc/alpine3.20/cli/Dockerfile @@ -59,10 +59,14 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ apk add --no-cache --virtual .fetch-deps gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apk add --no-cache --virtual .patch-deps patchutils; \ \ mkdir -p /usr/src; \ cd /usr/src; \ @@ -84,6 +88,14 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ + apk del --no-network .patch-deps; \ apk del --no-network .fetch-deps COPY docker-php-source /usr/local/bin/ @@ -100,6 +112,7 @@ RUN set -eux; \ linux-headers \ oniguruma-dev \ openssl-dev \ + patch \ readline-dev \ sqlite-dev \ ; \ @@ -117,6 +130,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ ./configure \ --build="$gnuArch" \ diff --git a/8.4-rc/alpine3.20/fpm/Dockerfile b/8.4-rc/alpine3.20/fpm/Dockerfile index dfced2dc0..a69f72458 100644 --- a/8.4-rc/alpine3.20/fpm/Dockerfile +++ b/8.4-rc/alpine3.20/fpm/Dockerfile @@ -59,10 +59,14 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ apk add --no-cache --virtual .fetch-deps gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apk add --no-cache --virtual .patch-deps patchutils; \ \ mkdir -p /usr/src; \ cd /usr/src; \ @@ -84,6 +88,14 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ + apk del --no-network .patch-deps; \ apk del --no-network .fetch-deps COPY docker-php-source /usr/local/bin/ @@ -100,6 +112,7 @@ RUN set -eux; \ linux-headers \ oniguruma-dev \ openssl-dev \ + patch \ readline-dev \ sqlite-dev \ ; \ @@ -117,6 +130,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ ./configure \ --build="$gnuArch" \ diff --git a/8.4-rc/alpine3.20/zts/Dockerfile b/8.4-rc/alpine3.20/zts/Dockerfile index 16a1b8585..29deab843 100644 --- a/8.4-rc/alpine3.20/zts/Dockerfile +++ b/8.4-rc/alpine3.20/zts/Dockerfile @@ -59,10 +59,14 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ apk add --no-cache --virtual .fetch-deps gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apk add --no-cache --virtual .patch-deps patchutils; \ \ mkdir -p /usr/src; \ cd /usr/src; \ @@ -84,6 +88,14 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ + apk del --no-network .patch-deps; \ apk del --no-network .fetch-deps COPY docker-php-source /usr/local/bin/ @@ -100,6 +112,7 @@ RUN set -eux; \ linux-headers \ oniguruma-dev \ openssl-dev \ + patch \ readline-dev \ sqlite-dev \ ; \ @@ -117,6 +130,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ ./configure \ --build="$gnuArch" \ diff --git a/8.4-rc/bookworm/apache/Dockerfile b/8.4-rc/bookworm/apache/Dockerfile index 70340e014..3597959b6 100644 --- a/8.4-rc/bookworm/apache/Dockerfile +++ b/8.4-rc/bookworm/apache/Dockerfile @@ -123,12 +123,16 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ savedAptMark="$(apt-mark showmanual)"; \ apt-get update; \ apt-get install -y --no-install-recommends gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apt-get install -y --no-install-recommends patchutils; \ rm -rf /var/lib/apt/lists/*; \ \ mkdir -p /usr/src; \ @@ -151,6 +155,13 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ apt-mark auto '.*' > /dev/null; \ apt-mark manual $savedAptMark > /dev/null; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false @@ -184,6 +195,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ # https://bugs.php.net/bug.php?id=74125 diff --git a/8.4-rc/bookworm/cli/Dockerfile b/8.4-rc/bookworm/cli/Dockerfile index 993baaa05..69aeb0657 100644 --- a/8.4-rc/bookworm/cli/Dockerfile +++ b/8.4-rc/bookworm/cli/Dockerfile @@ -63,12 +63,16 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ savedAptMark="$(apt-mark showmanual)"; \ apt-get update; \ apt-get install -y --no-install-recommends gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apt-get install -y --no-install-recommends patchutils; \ rm -rf /var/lib/apt/lists/*; \ \ mkdir -p /usr/src; \ @@ -91,6 +95,13 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ apt-mark auto '.*' > /dev/null; \ apt-mark manual $savedAptMark > /dev/null; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false @@ -123,6 +134,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ # https://bugs.php.net/bug.php?id=74125 diff --git a/8.4-rc/bookworm/fpm/Dockerfile b/8.4-rc/bookworm/fpm/Dockerfile index 23477e357..acabf1c8d 100644 --- a/8.4-rc/bookworm/fpm/Dockerfile +++ b/8.4-rc/bookworm/fpm/Dockerfile @@ -63,12 +63,16 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ savedAptMark="$(apt-mark showmanual)"; \ apt-get update; \ apt-get install -y --no-install-recommends gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apt-get install -y --no-install-recommends patchutils; \ rm -rf /var/lib/apt/lists/*; \ \ mkdir -p /usr/src; \ @@ -91,6 +95,13 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ apt-mark auto '.*' > /dev/null; \ apt-mark manual $savedAptMark > /dev/null; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false @@ -123,6 +134,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ # https://bugs.php.net/bug.php?id=74125 diff --git a/8.4-rc/bookworm/zts/Dockerfile b/8.4-rc/bookworm/zts/Dockerfile index 575203b03..749063f88 100644 --- a/8.4-rc/bookworm/zts/Dockerfile +++ b/8.4-rc/bookworm/zts/Dockerfile @@ -63,12 +63,16 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ savedAptMark="$(apt-mark showmanual)"; \ apt-get update; \ apt-get install -y --no-install-recommends gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apt-get install -y --no-install-recommends patchutils; \ rm -rf /var/lib/apt/lists/*; \ \ mkdir -p /usr/src; \ @@ -91,6 +95,13 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ apt-mark auto '.*' > /dev/null; \ apt-mark manual $savedAptMark > /dev/null; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false @@ -123,6 +134,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ # https://bugs.php.net/bug.php?id=74125 diff --git a/8.4-rc/bullseye/apache/Dockerfile b/8.4-rc/bullseye/apache/Dockerfile index 5b6854468..b0c593743 100644 --- a/8.4-rc/bullseye/apache/Dockerfile +++ b/8.4-rc/bullseye/apache/Dockerfile @@ -121,12 +121,16 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ savedAptMark="$(apt-mark showmanual)"; \ apt-get update; \ apt-get install -y --no-install-recommends gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apt-get install -y --no-install-recommends patchutils; \ rm -rf /var/lib/apt/lists/*; \ \ mkdir -p /usr/src; \ @@ -149,6 +153,13 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ apt-mark auto '.*' > /dev/null; \ apt-mark manual $savedAptMark > /dev/null; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false @@ -182,6 +193,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ # https://bugs.php.net/bug.php?id=74125 diff --git a/8.4-rc/bullseye/cli/Dockerfile b/8.4-rc/bullseye/cli/Dockerfile index 7da6b0e4a..0f11fdd9e 100644 --- a/8.4-rc/bullseye/cli/Dockerfile +++ b/8.4-rc/bullseye/cli/Dockerfile @@ -63,12 +63,16 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ savedAptMark="$(apt-mark showmanual)"; \ apt-get update; \ apt-get install -y --no-install-recommends gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apt-get install -y --no-install-recommends patchutils; \ rm -rf /var/lib/apt/lists/*; \ \ mkdir -p /usr/src; \ @@ -91,6 +95,13 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ apt-mark auto '.*' > /dev/null; \ apt-mark manual $savedAptMark > /dev/null; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false @@ -123,6 +134,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ # https://bugs.php.net/bug.php?id=74125 diff --git a/8.4-rc/bullseye/fpm/Dockerfile b/8.4-rc/bullseye/fpm/Dockerfile index d193396cc..e24c6675b 100644 --- a/8.4-rc/bullseye/fpm/Dockerfile +++ b/8.4-rc/bullseye/fpm/Dockerfile @@ -63,12 +63,16 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ savedAptMark="$(apt-mark showmanual)"; \ apt-get update; \ apt-get install -y --no-install-recommends gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apt-get install -y --no-install-recommends patchutils; \ rm -rf /var/lib/apt/lists/*; \ \ mkdir -p /usr/src; \ @@ -91,6 +95,13 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ apt-mark auto '.*' > /dev/null; \ apt-mark manual $savedAptMark > /dev/null; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false @@ -123,6 +134,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ # https://bugs.php.net/bug.php?id=74125 diff --git a/8.4-rc/bullseye/zts/Dockerfile b/8.4-rc/bullseye/zts/Dockerfile index 2bca02ad9..f7bd29726 100644 --- a/8.4-rc/bullseye/zts/Dockerfile +++ b/8.4-rc/bullseye/zts/Dockerfile @@ -63,12 +63,16 @@ ENV GPG_KEYS AFD8691FDAEDF03BDF6E460563F15A9B715376CA 9D7F99A0CB8F05C8A6958D6256 ENV PHP_VERSION 8.4.0alpha1 ENV PHP_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz" PHP_ASC_URL="https://downloads.php.net/~saki/php-8.4.0alpha1.tar.xz.asc" ENV PHP_SHA256="65903a7add51350540b567f8cd2d964ac11366bf33e1b287489765feac45278e" +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" RUN set -eux; \ \ savedAptMark="$(apt-mark showmanual)"; \ apt-get update; \ apt-get install -y --no-install-recommends gnupg; \ + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apt-get install -y --no-install-recommends patchutils; \ rm -rf /var/lib/apt/lists/*; \ \ mkdir -p /usr/src; \ @@ -91,6 +95,13 @@ RUN set -eux; \ rm -rf "$GNUPGHOME"; \ fi; \ \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ + \ apt-mark auto '.*' > /dev/null; \ apt-mark manual $savedAptMark > /dev/null; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false @@ -123,6 +134,9 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ # https://bugs.php.net/bug.php?id=74125 diff --git a/Dockerfile-linux.template b/Dockerfile-linux.template index 8d3b56b9f..5d60eebd8 100644 --- a/Dockerfile-linux.template +++ b/Dockerfile-linux.template @@ -198,15 +198,27 @@ ENV GPG_KEYS {{ ENV PHP_VERSION {{ .version }} ENV PHP_URL="{{ .url }}" PHP_ASC_URL="{{ .ascUrl // "" }}" ENV PHP_SHA256="{{ .sha256 // "" }}" +{{ if .version == "8.4.0alpha1" then ( -}} +ENV PHP_PDO_PATCH_URL="https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch" +ENV PHP_PDO_PATCH_SHA256="d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e" +{{ ) else "" end -}} RUN set -eux; \ \ {{ if is_alpine then ( -}} apk add --no-cache --virtual .fetch-deps gnupg; \ +{{ if .version == "8.4.0alpha1" then ( -}} + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apk add --no-cache --virtual .patch-deps patchutils; \ +{{ ) else "" end -}} {{ ) else ( -}} savedAptMark="$(apt-mark showmanual)"; \ apt-get update; \ apt-get install -y --no-install-recommends gnupg; \ +{{ if .version == "8.4.0alpha1" then ( -}} + # Add patchutils; see https://github.com/docker-library/php/pull/1526 + apt-get install -y --no-install-recommends patchutils; \ +{{ ) else "" end -}} rm -rf /var/lib/apt/lists/*; \ {{ ) end -}} \ @@ -229,8 +241,20 @@ RUN set -eux; \ gpgconf --kill all; \ rm -rf "$GNUPGHOME"; \ fi; \ +{{ if .version == "8.4.0alpha1" then ( -}} + \ + # Add patch; see https://github.com/docker-library/php/pull/1526 + curl -fsSL -o php-pdo.patch https://patch-diff.githubusercontent.com/raw/php/php-src/pull/14797.patch; \ + echo "d9f33beda1ffffc66299377a0946b1fe2916382e320084568ae6ee2a6d1fb19e php-pdo.patch" | sha256sum -c -; \ + TEMPFILE=$(mktemp); \ + filterdiff -p1 -x 'NEWS' < php-pdo.patch >$TEMPFILE; \ + mv $TEMPFILE php-pdo.patch; \ +{{ ) else "" end -}} \ {{ if is_alpine then ( -}} +{{ if .version == "8.4.0alpha1" then ( -}} + apk del --no-network .patch-deps; \ +{{ ) else "" end -}} apk del --no-network .fetch-deps {{ ) else ( -}} apt-mark auto '.*' > /dev/null; \ @@ -261,6 +285,7 @@ RUN set -eux; \ "libsodium-dev", "libxml2-dev", "openssl-dev", + if .version == "8.4.0alpha1" then "patch" else empty end, "readline-dev", "sqlite-dev", # https://github.com/docker-library/php/issues/888 @@ -304,6 +329,11 @@ RUN set -eux; \ ; \ docker-php-source extract; \ cd /usr/src/php; \ +{{ if .version == "8.4.0alpha1" then ( -}} +# Apply patch; see https://github.com/docker-library/php/pull/1526 + patch -p1 < ../php-pdo.patch; \ + ./buildconf -f; \ +{{ ) else "" end -}} gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \ {{ if is_alpine then "" else ( -}} debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \