From f1ca9e49987252938624fcd295777c8de67e04b3 Mon Sep 17 00:00:00 2001 From: Thomas Nabord Date: Thu, 11 Apr 2024 17:55:08 +0100 Subject: [PATCH] Fix configuration of gd in base images below PHP 7.4 --- base/images/7.1-apache/Dockerfile | 3 ++- base/images/7.1-fpm/Dockerfile | 3 ++- base/images/7.2-apache/Dockerfile | 3 ++- base/images/7.2-fpm/Dockerfile | 3 ++- base/images/7.3-apache/Dockerfile | 3 ++- base/images/7.3-fpm/Dockerfile | 4 +++- 6 files changed, 13 insertions(+), 6 deletions(-) diff --git a/base/images/7.1-apache/Dockerfile b/base/images/7.1-apache/Dockerfile index ca61fc4d..c4eb0a87 100644 --- a/base/images/7.1-apache/Dockerfile +++ b/base/images/7.1-apache/Dockerfile @@ -40,7 +40,8 @@ RUN apt-get update \ libonig-dev RUN rm -rf /var/lib/apt/lists/* -RUN docker-php-ext-configure gd --with-freetype=/usr/include/ --with-jpeg=/usr/include/ --with-webp=/usr/include +# PHP < 7.4 have an old syntax to install GD. See https://github.com/docker-library/php/issues/912 +RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ --with-webp-dir=/usr/include RUN docker-php-ext-install iconv intl pdo_mysql mbstring soap gd zip bcmath RUN docker-php-source extract \ diff --git a/base/images/7.1-fpm/Dockerfile b/base/images/7.1-fpm/Dockerfile index cd4c5ee5..edeff118 100644 --- a/base/images/7.1-fpm/Dockerfile +++ b/base/images/7.1-fpm/Dockerfile @@ -40,7 +40,8 @@ RUN apt-get update \ libonig-dev RUN rm -rf /var/lib/apt/lists/* -RUN docker-php-ext-configure gd --with-freetype=/usr/include/ --with-jpeg=/usr/include/ --with-webp=/usr/include +# PHP < 7.4 have an old syntax to install GD. See https://github.com/docker-library/php/issues/912 +RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ --with-webp-dir=/usr/include RUN docker-php-ext-install iconv intl pdo_mysql mbstring soap gd zip bcmath RUN docker-php-source extract \ diff --git a/base/images/7.2-apache/Dockerfile b/base/images/7.2-apache/Dockerfile index 301d2e66..dc141315 100644 --- a/base/images/7.2-apache/Dockerfile +++ b/base/images/7.2-apache/Dockerfile @@ -40,7 +40,8 @@ RUN apt-get update \ libonig-dev RUN rm -rf /var/lib/apt/lists/* -RUN docker-php-ext-configure gd --with-freetype=/usr/include/ --with-jpeg=/usr/include/ --with-webp=/usr/include +# PHP < 7.4 have an old syntax to install GD. See https://github.com/docker-library/php/issues/912 +RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ --with-webp-dir=/usr/include RUN docker-php-ext-install iconv intl pdo_mysql mbstring soap gd zip bcmath RUN docker-php-source extract \ diff --git a/base/images/7.2-fpm/Dockerfile b/base/images/7.2-fpm/Dockerfile index d40f9fe2..89192d33 100644 --- a/base/images/7.2-fpm/Dockerfile +++ b/base/images/7.2-fpm/Dockerfile @@ -40,7 +40,8 @@ RUN apt-get update \ libonig-dev RUN rm -rf /var/lib/apt/lists/* -RUN docker-php-ext-configure gd --with-freetype=/usr/include/ --with-jpeg=/usr/include/ --with-webp=/usr/include +# PHP < 7.4 have an old syntax to install GD. See https://github.com/docker-library/php/issues/912 +RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ --with-webp-dir=/usr/include RUN docker-php-ext-install iconv intl pdo_mysql mbstring soap gd zip bcmath RUN docker-php-source extract \ diff --git a/base/images/7.3-apache/Dockerfile b/base/images/7.3-apache/Dockerfile index 93b17035..7dd9c10d 100644 --- a/base/images/7.3-apache/Dockerfile +++ b/base/images/7.3-apache/Dockerfile @@ -40,7 +40,8 @@ RUN apt-get update \ libonig-dev RUN rm -rf /var/lib/apt/lists/* -RUN docker-php-ext-configure gd --with-freetype=/usr/include/ --with-jpeg=/usr/include/ --with-webp=/usr/include +# PHP < 7.4 have an old syntax to install GD. See https://github.com/docker-library/php/issues/912 +RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ --with-webp-dir=/usr/include RUN docker-php-ext-install iconv intl pdo_mysql mbstring soap gd zip bcmath RUN docker-php-source extract \ diff --git a/base/images/7.3-fpm/Dockerfile b/base/images/7.3-fpm/Dockerfile index a1555d19..b643e2a8 100644 --- a/base/images/7.3-fpm/Dockerfile +++ b/base/images/7.3-fpm/Dockerfile @@ -40,7 +40,9 @@ RUN apt-get update \ libonig-dev RUN rm -rf /var/lib/apt/lists/* -RUN docker-php-ext-configure gd --with-freetype=/usr/include/ --with-jpeg=/usr/include/ --with-webp=/usr/include + +# PHP < 7.4 have an old syntax to install GD. See https://github.com/docker-library/php/issues/912 +RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ --with-webp-dir=/usr/include RUN docker-php-ext-install iconv intl pdo_mysql mbstring soap gd zip bcmath RUN docker-php-source extract \