Skip to content

Commit

Permalink
Update imagick package to 3.7.0
Browse files Browse the repository at this point in the history
Also apply hack patch for preprocessor build failures
  • Loading branch information
tianon committed Mar 11, 2024
1 parent 8b7fb41 commit 509adb5
Show file tree
Hide file tree
Showing 22 changed files with 269 additions and 64 deletions.
18 changes: 17 additions & 1 deletion Dockerfile.template
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,25 @@ RUN set -ex; \
# WARNING: imagick is likely not supported on Alpine: https://github.com/Imagick/imagick/issues/328
{{ ) else "" end -}}
# https://pecl.php.net/package/imagick
pecl install imagick-3.6.0; \
{{ if true then ( -}}
# https://github.com/Imagick/imagick/commit/5ae2ecf20a1157073bad0170106ad0cf74e01cb6 (causes a lot of build failures, but strangely only intermittent ones 🤔)
# see also https://github.com/Imagick/imagick/pull/641
# this is "pecl install imagick-3.7.0", but by hand so we can apply a small hack / part of the above commit
curl -fL -o imagick.tgz 'https://pecl.php.net/get/imagick-3.7.0.tgz'; \
echo '5a364354109029d224bcbb2e82e15b248be9b641227f45e63425c06531792d3e *imagick.tgz' | sha256sum -c -; \
tar --extract --directory /tmp --file imagick.tgz imagick-3.7.0; \
grep '^//#endif$' /tmp/imagick-3.7.0/Imagick.stub.php; \
test "$(grep -c '^//#endif$' /tmp/imagick-3.7.0/Imagick.stub.php)" = '1'; \
sed -i -e 's!^//#endif$!#endif!' /tmp/imagick-3.7.0/Imagick.stub.php; \
grep '^//#endif$' /tmp/imagick-3.7.0/Imagick.stub.php && exit 1 || :; \
docker-php-ext-install /tmp/imagick-3.7.0; \
rm -rf imagick.tgz /tmp/imagick-3.7.0; \
{{ # TODO when imagick has another release, we should ditch this whole block and just update instead -}}
{{ ) else ( -}}
pecl install imagick-3.7.0; \
docker-php-ext-enable imagick; \
rm -r /tmp/pear; \
{{ ) end -}}
\
# some misbehaving extensions end up outputting to stdout 🙈 (https://github.com/docker-library/wordpress/issues/669#issuecomment-993945967)
out="$(php -r 'exit(0);')"; \
Expand Down
15 changes: 12 additions & 3 deletions beta/php8.1/apache/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions beta/php8.1/fpm-alpine/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions beta/php8.1/fpm/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions beta/php8.2/apache/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions beta/php8.2/fpm-alpine/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions beta/php8.2/fpm/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions beta/php8.3/apache/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions beta/php8.3/fpm-alpine/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions beta/php8.3/fpm/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions cli/php8.1/alpine/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions cli/php8.2/alpine/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions cli/php8.3/alpine/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 12 additions & 3 deletions latest/php8.1/apache/Dockerfile

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 509adb5

Please sign in to comment.