Skip to content

Add missing pcre dependency definition to zip extension #14404

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions ext/zip/config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ if test "$PHP_ZIP" != "no"; then

PHP_ZIP_SOURCES="php_zip.c zip_stream.c"
PHP_NEW_EXTENSION(zip, $PHP_ZIP_SOURCES, $ext_shared)
PHP_ADD_EXTENSION_DEP(zip, pcre)

PHP_SUBST(ZIP_SHARED_LIBADD)
fi
1 change: 1 addition & 0 deletions ext/zip/config.w32
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ if (PHP_ZIP != "no") {
CHECK_LIB("libzip_a.lib", "zip", PHP_ZIP) && CHECK_LIB("libbz2_a.lib", "zip", PHP_ZIP) && CHECK_LIB("zlib_a.lib", "zip", PHP_ZIP) && CHECK_LIB("liblzma_a.lib", "zip", PHP_ZIP))
) {
EXTENSION('zip', 'php_zip.c zip_stream.c');
ADD_EXTENSION_DEP('zip', 'pcre');

if (get_define("LIBS_ZIP").match("libzip_a(?:_debug)?\.lib")) {
/* Using static dependency lib. */
Expand Down
8 changes: 7 additions & 1 deletion ext/zip/php_zip.c
Original file line number Diff line number Diff line change
Expand Up @@ -1146,9 +1146,15 @@ static PHP_MSHUTDOWN_FUNCTION(zip);
static PHP_MINFO_FUNCTION(zip);
/* }}} */

static const zend_module_dep zip_deps[] = {
ZEND_MOD_REQUIRED("pcre")
ZEND_MOD_END
};

/* {{{ zip_module_entry */
zend_module_entry zip_module_entry = {
STANDARD_MODULE_HEADER,
STANDARD_MODULE_HEADER_EX, NULL,
zip_deps,
"zip",
ext_functions,
PHP_MINIT(zip),
Expand Down
Loading