Skip to content

Try to fix libzip on macos #5737

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

Closed
wants to merge 1 commit into from
Closed
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
5 changes: 4 additions & 1 deletion azure/macos/brew.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ parameters:
packages: ''

steps:
- script: brew update
displayName: 'Update Homebrew'
- script: |
brew install pkg-config \
autoconf \
Expand All @@ -23,11 +25,12 @@ steps:
zlib \
t1lib \
gd \
libzip \
gmp \
tidyp \
libxml2 \
libxslt \
postgresql
# Make sure we don't get broken libzip 1.7.0
brew upgrade libzip
brew link icu4c gettext --force
displayName: 'Install Build Dependencies'
4 changes: 4 additions & 0 deletions ext/zip/php_zip.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@
#include "zend_interfaces.h"
#include "php_zip.h"

#ifndef LIBZIP_VERSION_MAJOR
# error You are likely using libzip 1.7.0, which is badly broken. Update to libzip 1.7.1
#endif

/* zip_open is a macro for renaming libzip zipopen, so we need to use PHP_NAMED_FUNCTION */
static PHP_NAMED_FUNCTION(zif_zip_open);
static PHP_NAMED_FUNCTION(zif_zip_read);
Expand Down