Skip to content

Commit 67ec375

Browse files
committed
Backport changes for macos 14
1 parent 3aaa8d3 commit 67ec375

File tree

3 files changed

+28
-37
lines changed

3 files changed

+28
-37
lines changed

.github/actions/brew/action.yml

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -5,31 +5,25 @@ runs:
55
- shell: bash
66
run: |
77
set -x
8+
9+
# Patch brew to overwrite always
10+
formula_installer="$(brew --repo)"/Library/Homebrew/formula_installer.rb
11+
code=" keg.link\(verbose: verbose\?"
12+
sudo sed -Ei '' "s/$code.*/$code, overwrite: true\)/" "$formula_installer"
13+
14+
# Some packages exist on x86 but not arm, or vice versa.
15+
# Install them with reinstall to avoid warnings.
16+
brew reinstall autoconf webp tidy-html5 libzip libsodium icu4c
817
brew install \
9-
pkg-config \
10-
autoconf \
1118
bison \
1219
re2c
1320
brew install \
14-
15-
curl \
16-
krb5 \
1721
bzip2 \
1822
enchant \
1923
libffi \
20-
libpng \
21-
webp \
22-
freetype \
2324
intltool \
2425
libiconv \
25-
zlib \
2626
t1lib \
27-
gd \
28-
libzip \
29-
gmp \
30-
tidy-html5 \
3127
libxml2 \
3228
libjpeg \
33-
libxslt \
34-
postgresql
35-
brew link gettext --force
29+
libxslt

.github/actions/configure-macos/action.yml

Lines changed: 17 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -10,26 +10,24 @@ runs:
1010
run: |
1111
set -x
1212
BREW_OPT="$(brew --prefix)"/opt
13-
export PATH="/usr/local/opt/bison/bin:$PATH"
14-
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/opt/[email protected]/lib/pkgconfig"
15-
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/opt/curl/lib/pkgconfig"
16-
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/opt/krb5/lib/pkgconfig"
17-
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/opt/libffi/lib/pkgconfig"
18-
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/opt/libxml2/lib/pkgconfig"
19-
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/opt/libxslt/lib/pkgconfig"
20-
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/opt/zlib/lib/pkgconfig"
21-
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/opt/icu4c@74/lib/pkgconfig"
13+
export PATH="$BREW_OPT/bison/bin:$PATH"
14+
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:$BREW_OPT/[email protected]/lib/pkgconfig"
15+
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:$BREW_OPT/curl/lib/pkgconfig"
16+
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:$BREW_OPT/libffi/lib/pkgconfig"
17+
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:$BREW_OPT/libxml2/lib/pkgconfig"
18+
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:$BREW_OPT/libxslt/lib/pkgconfig"
19+
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:$BREW_OPT/zlib/lib/pkgconfig"
20+
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:$BREW_OPT/icu4c/lib/pkgconfig"
2221
sed -i -e 's/Requires.private:.*//g' "$BREW_OPT/curl/lib/pkgconfig/libcurl.pc"
2322
./buildconf --force
2423
./configure \
25-
CFLAGS="-Wno-strict-prototypes -Wno-unused-but-set-variable -Wno-single-bit-bitfield-constant-conversion" \
2624
--enable-option-checking=fatal \
2725
--prefix=/usr/local \
2826
--enable-fpm \
2927
--with-pdo-mysql=mysqlnd \
3028
--with-mysqli=mysqlnd \
31-
--with-pgsql=/usr/local/opt/libpq \
32-
--with-pdo-pgsql=/usr/local/opt/libpq \
29+
--with-pgsql="$BREW_OPT"/libpq \
30+
--with-pdo-pgsql="$BREW_OPT"/libpq \
3331
--with-pdo-sqlite \
3432
--without-pear \
3533
--enable-gd \
@@ -42,30 +40,29 @@ runs:
4240
--enable-soap \
4341
--enable-xmlreader \
4442
--with-xsl \
45-
--with-tidy=/usr/local/opt/tidy-html5 \
43+
--with-tidy="$BREW_OPT"/tidy-html5 \
4644
--with-libxml \
4745
--enable-sysvsem \
4846
--enable-sysvshm \
4947
--enable-shmop \
5048
--enable-pcntl \
51-
--with-readline=/usr/local/opt/readline \
49+
--with-readline="$BREW_OPT"/readline \
5250
--enable-mbstring \
5351
--with-curl \
54-
--with-gettext=/usr/local/opt/gettext \
52+
--with-gettext="$BREW_OPT"/gettext \
5553
--enable-sockets \
56-
--with-bz2=/usr/local/opt/bzip2 \
54+
--with-bz2="$BREW_OPT"/bzip2 \
5755
--with-openssl \
58-
--with-gmp=/usr/local/opt/gmp \
59-
--with-iconv=/usr/local/opt/libiconv \
56+
--with-gmp="$BREW_OPT"/gmp \
57+
--with-iconv="$BREW_OPT"/libiconv \
6058
--enable-bcmath \
6159
--enable-calendar \
6260
--enable-ftp \
63-
--with-pspell=/usr/local/opt/aspell \
64-
--with-kerberos \
6561
--enable-sysvmsg \
6662
--with-ffi \
6763
--enable-zend-test \
6864
--enable-dl-test=shared \
65+
--enable-intl \
6966
--with-mhash \
7067
--with-sodium \
7168
--enable-dba \

.github/workflows/push.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ jobs:
113113
uses: ./.github/actions/verify-generated-files
114114
MACOS_DEBUG_NTS:
115115
if: github.repository == 'php/php-src' || github.event_name == 'pull_request'
116-
runs-on: macos-13
116+
runs-on: macos-14
117117
steps:
118118
- name: git checkout
119119
uses: actions/checkout@v4

0 commit comments

Comments
 (0)