diff --git a/Dockerfiles/mods/Dockerfile-7.4 b/Dockerfiles/mods/Dockerfile-7.4 index cda3816c..89ac6a29 100644 --- a/Dockerfiles/mods/Dockerfile-7.4 +++ b/Dockerfiles/mods/Dockerfile-7.4 @@ -29,6 +29,7 @@ ENV BUILD_DEPS \ libenchant-dev \ libevent-dev \ libfbclient2 \ + libffi-dev \ libfreetype6-dev \ libgmp-dev \ libhiredis-dev \ @@ -65,6 +66,7 @@ ENV RUN_DEPS \ libc-client2007e \ libenchant1c2a \ libfbclient2 \ + libffi6 \ libfreetype6 \ libhiredis0.13 \ libicu57 \ @@ -126,6 +128,20 @@ RUN set -x \ && (rm -rf /usr/local/lib/php/test/exif || true) \ && (rm -rf /usr/local/lib/php/doc/exif || true) \ \ +# ---- Installing PHP Extension: ffi ---- + && git clone https://github.com/dstogov/php-ffi /tmp/ffi \ + && cd /tmp/ffi \ + && curl -sS -O https://github.com/fpoirotte/php-ffi/commit/734630fe3d2e3efd343d3f3636b58446abd9c941.diff \ +&& git apply 734630fe3d2e3efd343d3f3636b58446abd9c941.diff \ +&& phpize \ +&& ./configure --with-ffi \ +&& make -j$(getconf _NPROCESSORS_ONLN) \ +&& make install \ + \ + && docker-php-ext-enable ffi \ + && (rm -rf /usr/local/lib/php/test/ffi || true) \ + && (rm -rf /usr/local/lib/php/doc/ffi || true) \ + \ # ---- Installing PHP Extension: gd ---- && ln -s /usr/lib/x86_64-linux-gnu/libXpm.* /usr/lib/ \ && /usr/local/bin/docker-php-ext-configure gd --with-gd --with-webp-dir=/usr --with-jpeg-dir=/usr --with-png-dir=/usr --with-zlib-dir=/usr --with-xpm-dir=/usr --with-freetype-dir=/usr --enable-gd-jis-conv \ @@ -444,6 +460,8 @@ RUN set -x \ && php-fpm -m | grep -oiE '^enchant$' \ && php -m | grep -oiE '^exif$' \ && php-fpm -m | grep -oiE '^exif$' \ + && php -m | grep -oiE '^ffi$' \ + && php-fpm -m | grep -oiE '^ffi$' \ && php -m | grep -oiE '^fileinfo$' \ && php-fpm -m | grep -oiE '^fileinfo$' \ && php -m | grep -oiE '^filter$' \ diff --git a/README.md b/README.md index f8743a60..d9f765c0 100644 --- a/README.md +++ b/README.md @@ -571,7 +571,7 @@ Check out this table to see which Docker image provides what PHP modules. 7.4 Core, ctype, curl, date, dom, fileinfo, filter, ftp, hash, iconv, json, libxml, mbstring, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, Reflection, session, SimpleXML, sodium, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib - bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imap, interbase, intl, json, ldap, libxml, mbstring, memcached, mongodb, mysqli, mysqlnd, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, PDO_OCI, pdo_pgsql, pdo_sqlite, pgsql, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, sodium, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib + bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, exif, FFI, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imap, interbase, intl, json, ldap, libxml, mbstring, memcached, mongodb, mysqli, mysqlnd, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, PDO_OCI, pdo_pgsql, pdo_sqlite, pgsql, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, sodium, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib diff --git a/build/ansible/group_vars/all.yml b/build/ansible/group_vars/all.yml index 167ed34e..2aecb523 100644 --- a/build/ansible/group_vars/all.yml +++ b/build/ansible/group_vars/all.yml @@ -710,6 +710,7 @@ extensions_enabled: - dom - enchant - exif + - ffi - fileinfo - filter - ftp @@ -896,6 +897,20 @@ extensions_available: exif: all: type: builtin + ffi: + disabled: [5.2, 5.3, 5.4, 5.5, 5.6, 7.0, 7.1, 7.2, 7.3] + all: + type: git + git_url: https://github.com/dstogov/php-ffi + command: | + curl -sS -O https://github.com/fpoirotte/php-ffi/commit/734630fe3d2e3efd343d3f3636b58446abd9c941.diff \ + && git apply 734630fe3d2e3efd343d3f3636b58446abd9c941.diff \ + && phpize \ + && ./configure --with-ffi \ + && make -j$(getconf _NPROCESSORS_ONLN) \ + && make install \ + build_dep: [libffi-dev] + run_dep: [libffi6] fileinfo: already_avail: [5.3, 5.4, 5.5, 5.6, 7.0, 7.1, 7.2, 7.3, 7.4] 5.2: