Some extensions are missing in PHP 7.4.0: zip, gmp, sodium


My tests are failing in 7.4 right now because php’s zip extension isn’t available.

I tried following the instructions for “Enabling preinstalled PHP extensions” but got this:

PHP Warning: PHP Startup: Unable to load dynamic library ‘’ (tried: /home/travis/.phpenv/versions/7.4.0/lib/php/extensions/no-debug-zts-20190902/ (/home/travis/.phpenv/versions/7.4.0/lib/php/extensions/no-debug-zts-20190902/ cannot open shared object file: No such file or directory), /home/travis/.phpenv/versions/7.4.0/lib/php/extensions/no-debug-zts-20190902/ (/home/travis/.phpenv/versions/7.4.0/lib/php/extensions/no-debug-zts-20190902/ cannot open shared object file: No such file or directory)) in Unknown on line 0

When reporting problems, please include relevant build URLs. Thanks.

Sorry, these should be helpful.

I have the same problem with GMP and env 7.x.
Project is here:

I’ve updated the subject of this topic so that we can discuss missing extensions generally.

For zip, we are building for 7.4.0 (this might be a change from PHP itself), not, which something is trying to use. Not sure how best to address this apparent discrepancy.

This doesn’t look like a recent change, so I am not sure what’s going on.

Looks like the option --enable-zip has been changed to --with-zip on PHP 7.4.0.

But the build command line was set to --enable-zip (seen at ./home/travis/.phpenv/versions/7.4.0/bin/php-config)

1 Like

try to install using pecl install zip fails, as seen on:

checking PHP version... 7.4
checking for pkg-config... /usr/bin/pkg-config
checking for libzip... not found
configure: error: Please reinstall the libzip distribution
ERROR: `/tmp/pear/install/zip/configure --with-php-config=/home/travis/.phpenv/versions/7.4.0/bin/php-config' failed

The options from 7.4snapshot were fine, you can see there that ./home/travis/.phpenv/versions/7.4snapshot/bin/php-config contains --with-zip.

This are the significant changes from 7.4snapshot to 7.4.0 on php-config:

--- 7.4snapshot-co	2019-12-06 13:55:21.118460897 -0600
+++ 7.4.0-co	2019-12-06 13:47:47.403134610 -0600
@@ -8,13 +8,15 @@
- '--enable-gd'
- '--with-jpeg'
- '--with-freetype'
+ '--with-gd'
+ '--with-jpeg-dir=/usr'
+ '--with-png-dir=/usr'
+ '--with-freetype-dir=/usr'
- '--with-zip'
+ '--enable-zip'
+ '--with-mcrypt=/usr'
@@ -26,6 +28,7 @@
+ '--with-mysql=mysqlnd'
@@ -51,9 +54,9 @@
- '--with-sodium=/home/travis/.phpenv/versions/7.4.0'
+ '--with-libsodium=/home/travis/.phpenv/versions/7.4.0'
- 'PKG_CONFIG_PATH=/home/travis/.phpenv/versions/7.4.0/lib/pkgconfig:'
+ 'PKG_CONFIG_PATH=/lib/pkgconfig:'

While PHP 7.4 testing is broken on Travis CI we have enabled allowed failures for PHP 7.4. That way we still see how 7.4 is doing during test runs while it does not fail our build.

Let me know once the GD extension is working, then we can run PHP 7.4 for real.

Where do I add the --with-gmp compiler flag in the travis.yml file?

We can’t test Laravel Dusk atm because of the missing zip extension:

As pecl install zip doesn’t works either, there isn’t an alternative way to solve this atm afaik.

I’ve refreshed PHP 7.4 binaries, with a few changes to the configurations. Please test them.

1 Like

Awesome! It’s working

1 Like

Thank you for the report!

How about you? Have you had a chance to test it yet?

Thank you PHP 7.4 seems to be working now and our remaining test fails are due to the fact that Drupal core is not 7.4 compatible yet in :slight_smile:

1 Like

Sweet! Thanks for the report.

1 Like

All builds are now passing. Thanks for the fast action!

1 Like

We’re still experiencing problems with GD in php 7.4