mirror of
https://git.freebsd.org/ports.git
synced 2025-05-12 23:31:50 -04:00
lang/php8[12]: Fix build on aarch64 with ZTS
- Refresh patches PR: 266175 Reported by: thresh@nginx.com Sponsored by: Bounce Experts
This commit is contained in:
parent
76231c1482
commit
c89b6f2799
18 changed files with 68 additions and 38 deletions
|
@ -400,8 +400,12 @@ CONFIGURE_ARGS+= --enable-odbc \
|
||||||
.if ${PHP_MODNAME} == "opcache"
|
.if ${PHP_MODNAME} == "opcache"
|
||||||
# This is needed by Zend extensions, keep before everything.
|
# This is needed by Zend extensions, keep before everything.
|
||||||
PHP_MOD_PRIO= 10
|
PHP_MOD_PRIO= 10
|
||||||
|
.if ${ARCH} == aarch64
|
||||||
|
CONFIGURE_ARGS+= --disable-opcache-jit
|
||||||
|
.else
|
||||||
CONFIGURE_ARGS+= --enable-opcache
|
CONFIGURE_ARGS+= --enable-opcache
|
||||||
.endif
|
.endif
|
||||||
|
.endif
|
||||||
|
|
||||||
.if ${PHP_MODNAME} == "pcntl"
|
.if ${PHP_MODNAME} == "pcntl"
|
||||||
CONFIGURE_ARGS+= --enable-pcntl
|
CONFIGURE_ARGS+= --enable-pcntl
|
||||||
|
|
11
lang/php81/files/patch-TSRM_TSRM.c
Normal file
11
lang/php81/files/patch-TSRM_TSRM.c
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
--- TSRM/TSRM.c.orig 2023-04-12 03:52:48 UTC
|
||||||
|
+++ TSRM/TSRM.c
|
||||||
|
@@ -750,7 +750,7 @@ TSRM_API size_t tsrm_get_ls_cache_tcb_offset(void)
|
||||||
|
asm ("leal _tsrm_ls_cache@ntpoff,%0"
|
||||||
|
: "=r" (ret));
|
||||||
|
return ret;
|
||||||
|
-#elif defined(__aarch64__)
|
||||||
|
+#elif defined(__aarch64__) && !defined(__FreeBSD__)
|
||||||
|
size_t ret;
|
||||||
|
|
||||||
|
# ifdef __APPLE__
|
|
@ -1,6 +1,6 @@
|
||||||
--- build/Makefile.global.orig 2019-08-06 06:54:07 UTC
|
--- build/Makefile.global.orig 2023-03-14 19:50:20 UTC
|
||||||
+++ build/Makefile.global
|
+++ build/Makefile.global
|
||||||
@@ -89,14 +89,14 @@ test: all
|
@@ -92,14 +92,14 @@ test: all
|
||||||
@if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \
|
@if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \
|
||||||
INI_FILE=`$(PHP_EXECUTABLE) -d 'display_errors=stderr' -r 'echo php_ini_loaded_file();' 2> /dev/null`; \
|
INI_FILE=`$(PHP_EXECUTABLE) -d 'display_errors=stderr' -r 'echo php_ini_loaded_file();' 2> /dev/null`; \
|
||||||
if test "$$INI_FILE"; then \
|
if test "$$INI_FILE"; then \
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
--- configure.ac.orig 2021-12-15 02:00:45 UTC
|
--- configure.ac.orig 2023-03-14 19:50:20 UTC
|
||||||
+++ configure.ac
|
+++ configure.ac
|
||||||
@@ -55,6 +55,7 @@ AH_BOTTOM([
|
@@ -55,6 +55,7 @@ AH_BOTTOM([
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
dnl Haiku does not have network api in libc.
|
dnl Haiku does not have network api in libc.
|
||||||
PHP_CHECK_FUNC_LIB(setsockopt, network)
|
PHP_CHECK_FUNC_LIB(setsockopt, network)
|
||||||
@@ -1360,7 +1360,7 @@ EXPANDED_SYSCONFDIR=`eval echo $sysconfdir`
|
@@ -1372,7 +1372,7 @@ EXPANDED_SYSCONFDIR=`eval echo $sysconfdir`
|
||||||
EXPANDED_DATADIR=$datadir
|
EXPANDED_DATADIR=$datadir
|
||||||
EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
|
EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
|
||||||
EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"`
|
EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"`
|
||||||
|
@ -34,7 +34,7 @@
|
||||||
|
|
||||||
exec_prefix=$old_exec_prefix
|
exec_prefix=$old_exec_prefix
|
||||||
libdir=$old_libdir
|
libdir=$old_libdir
|
||||||
@@ -1579,7 +1579,7 @@ PHP_SUBST(all_targets)
|
@@ -1591,7 +1591,7 @@ PHP_SUBST(all_targets)
|
||||||
PHP_SUBST(install_targets)
|
PHP_SUBST(install_targets)
|
||||||
PHP_SUBST(install_binary_targets)
|
PHP_SUBST(install_binary_targets)
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- ext/mysqli/mysqli_nonapi.c.orig 2020-01-09 11:40:57 UTC
|
--- ext/mysqli/mysqli_nonapi.c.orig 2023-03-14 19:50:20 UTC
|
||||||
+++ ext/mysqli/mysqli_nonapi.c
|
+++ ext/mysqli/mysqli_nonapi.c
|
||||||
@@ -28,7 +28,9 @@
|
@@ -26,7 +26,9 @@
|
||||||
#include "php_ini.h"
|
#include "php_ini.h"
|
||||||
#include "ext/standard/info.h"
|
#include "ext/standard/info.h"
|
||||||
#include "zend_smart_str.h"
|
#include "zend_smart_str.h"
|
||||||
|
@ -8,5 +8,5 @@
|
||||||
#include "php_mysqli_structs.h"
|
#include "php_mysqli_structs.h"
|
||||||
+#endif
|
+#endif
|
||||||
#include "mysqli_priv.h"
|
#include "mysqli_priv.h"
|
||||||
|
#define ERROR_ARG_POS(arg_num) (getThis() ? (arg_num-1) : (arg_num))
|
||||||
|
|
||||||
#define SAFE_STR(a) ((a)?a:"")
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- ext/mysqli/mysqli_prop.c.orig 2020-01-09 11:40:11 UTC
|
--- ext/mysqli/mysqli_prop.c.orig 2023-03-14 19:50:20 UTC
|
||||||
+++ ext/mysqli/mysqli_prop.c
|
+++ ext/mysqli/mysqli_prop.c
|
||||||
@@ -26,7 +26,9 @@
|
@@ -24,7 +24,9 @@
|
||||||
#include "php.h"
|
#include "php.h"
|
||||||
#include "php_ini.h"
|
#include "php_ini.h"
|
||||||
#include "ext/standard/info.h"
|
#include "ext/standard/info.h"
|
||||||
|
@ -9,4 +9,4 @@
|
||||||
+#endif
|
+#endif
|
||||||
#include "mysqli_priv.h"
|
#include "mysqli_priv.h"
|
||||||
|
|
||||||
#define CHECK_STATUS(value) \
|
#define CHECK_STATUS(value, quiet) \
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
--- ext/mysqli/php_mysqli_structs.h.orig 2019-12-17 10:29:23 UTC
|
--- ext/mysqli/php_mysqli_structs.h.orig 2023-03-14 19:50:20 UTC
|
||||||
+++ ext/mysqli/php_mysqli_structs.h
|
+++ ext/mysqli/php_mysqli_structs.h
|
||||||
@@ -36,7 +36,7 @@
|
@@ -26,7 +26,7 @@
|
||||||
#define FALSE 0
|
#undef LIST
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
-#ifdef MYSQLI_USE_MYSQLND
|
-#ifdef MYSQLI_USE_MYSQLND
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- ext/pcre/pcre2lib/sljit/sljitConfigInternal.h.orig 2022-03-25 09:54:56 UTC
|
--- ext/pcre/pcre2lib/sljit/sljitConfigInternal.h.orig 2023-03-14 19:50:20 UTC
|
||||||
+++ ext/pcre/pcre2lib/sljit/sljitConfigInternal.h
|
+++ ext/pcre/pcre2lib/sljit/sljitConfigInternal.h
|
||||||
@@ -283,7 +283,7 @@
|
@@ -319,7 +319,7 @@ extern "C" {
|
||||||
/* Instruction cache flush. */
|
/* Instruction cache flush. */
|
||||||
/****************************/
|
/****************************/
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- sapi/apache2handler/config.m4.orig 2018-08-14 11:39:14 UTC
|
--- sapi/apache2handler/config.m4.orig 2023-03-14 19:50:20 UTC
|
||||||
+++ sapi/apache2handler/config.m4
|
+++ sapi/apache2handler/config.m4
|
||||||
@@ -65,7 +65,7 @@ if test "$PHP_APXS2" != "no"; then
|
@@ -64,7 +64,7 @@ if test "$PHP_APXS2" != "no"; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
APXS_LIBEXECDIR='$(INSTALL_ROOT)'`$APXS -q LIBEXECDIR`
|
APXS_LIBEXECDIR='$(INSTALL_ROOT)'`$APXS -q LIBEXECDIR`
|
||||||
|
@ -8,4 +8,4 @@
|
||||||
+ if true; then
|
+ if true; then
|
||||||
INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
|
INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
|
||||||
$APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
|
$APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
|
||||||
-i -n php7"
|
-i -n php"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- sapi/fpm/config.m4.orig 2018-08-14 11:39:14 UTC
|
--- sapi/fpm/config.m4.orig 2023-03-14 19:50:20 UTC
|
||||||
+++ sapi/fpm/config.m4
|
+++ sapi/fpm/config.m4
|
||||||
@@ -319,7 +319,7 @@ AC_DEFUN([AC_FPM_LQ],
|
@@ -315,7 +315,7 @@ AC_DEFUN([AC_FPM_LQ],
|
||||||
AC_MSG_RESULT([no])
|
AC_MSG_RESULT([no])
|
||||||
])
|
])
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- sapi/fpm/www.conf.in.orig 2019-01-26 15:54:27 UTC
|
--- sapi/fpm/www.conf.in.orig 2023-03-14 19:50:20 UTC
|
||||||
+++ sapi/fpm/www.conf.in
|
+++ sapi/fpm/www.conf.in
|
||||||
@@ -27,10 +27,14 @@ group = @php_fpm_group@
|
@@ -32,10 +32,14 @@ group = @php_fpm_group@
|
||||||
; Valid syntaxes are:
|
; Valid syntaxes are:
|
||||||
; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on
|
; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on
|
||||||
; a specific port;
|
; a specific port;
|
||||||
|
|
|
@ -401,8 +401,12 @@ CONFIGURE_ARGS+= --enable-odbc \
|
||||||
.if ${PHP_MODNAME} == "opcache"
|
.if ${PHP_MODNAME} == "opcache"
|
||||||
# This is needed by Zend extensions, keep before everything.
|
# This is needed by Zend extensions, keep before everything.
|
||||||
PHP_MOD_PRIO= 10
|
PHP_MOD_PRIO= 10
|
||||||
|
.if ${ARCH} == aarch64
|
||||||
|
CONFIGURE_ARGS+= --disable-opcache-jit
|
||||||
|
.else
|
||||||
CONFIGURE_ARGS+= --enable-opcache
|
CONFIGURE_ARGS+= --enable-opcache
|
||||||
.endif
|
.endif
|
||||||
|
.endif
|
||||||
|
|
||||||
.if ${PHP_MODNAME} == "pcntl"
|
.if ${PHP_MODNAME} == "pcntl"
|
||||||
CONFIGURE_ARGS+= --enable-pcntl
|
CONFIGURE_ARGS+= --enable-pcntl
|
||||||
|
|
11
lang/php82/files/patch-TSRM_TSRM.c
Normal file
11
lang/php82/files/patch-TSRM_TSRM.c
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
--- TSRM/TSRM.c.orig 2023-04-12 04:09:40 UTC
|
||||||
|
+++ TSRM/TSRM.c
|
||||||
|
@@ -740,7 +740,7 @@ TSRM_API size_t tsrm_get_ls_cache_tcb_offset(void)
|
||||||
|
asm ("leal _tsrm_ls_cache@ntpoff,%0"
|
||||||
|
: "=r" (ret));
|
||||||
|
return ret;
|
||||||
|
-#elif defined(__aarch64__)
|
||||||
|
+#elif defined(__aarch64__) && !defined(__FreeBSD__)
|
||||||
|
size_t ret;
|
||||||
|
|
||||||
|
# ifdef __APPLE__
|
|
@ -1,4 +1,4 @@
|
||||||
--- configure.ac.orig 2022-08-02 13:57:03 UTC
|
--- configure.ac.orig 2023-03-14 16:11:05 UTC
|
||||||
+++ configure.ac
|
+++ configure.ac
|
||||||
@@ -55,6 +55,7 @@ AH_BOTTOM([
|
@@ -55,6 +55,7 @@ AH_BOTTOM([
|
||||||
|
|
||||||
|
@ -8,7 +8,7 @@
|
||||||
#endif /* PHP_CONFIG_H */
|
#endif /* PHP_CONFIG_H */
|
||||||
])
|
])
|
||||||
|
|
||||||
@@ -279,7 +280,6 @@ dnl --------------------------------------------------
|
@@ -279,7 +280,6 @@ sinclude(Zend/Zend.m4)
|
||||||
|
|
||||||
dnl ----------------------------------------------------------------------------
|
dnl ----------------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
PHP_HELP_SEPARATOR([SAPI modules:])
|
PHP_HELP_SEPARATOR([SAPI modules:])
|
||||||
PHP_SHLIB_SUFFIX_NAMES
|
PHP_SHLIB_SUFFIX_NAMES
|
||||||
PHP_BUILD_PROGRAM
|
PHP_BUILD_PROGRAM
|
||||||
@@ -627,7 +627,7 @@ dnl Some systems (like OpenSolaris) do not have nanosl
|
@@ -626,7 +626,7 @@ memrchr \
|
||||||
AX_FUNC_WHICH_GETHOSTBYNAME_R
|
AX_FUNC_WHICH_GETHOSTBYNAME_R
|
||||||
|
|
||||||
dnl Some systems (like OpenSolaris) do not have nanosleep in libc.
|
dnl Some systems (like OpenSolaris) do not have nanosleep in libc.
|
||||||
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
dnl Haiku does not have network api in libc.
|
dnl Haiku does not have network api in libc.
|
||||||
PHP_CHECK_FUNC_LIB(setsockopt, network)
|
PHP_CHECK_FUNC_LIB(setsockopt, network)
|
||||||
@@ -1375,7 +1375,7 @@ EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CON
|
@@ -1413,7 +1413,7 @@ EXPANDED_SYSCONFDIR=`eval echo $sysconfdir`
|
||||||
EXPANDED_DATADIR=$datadir
|
EXPANDED_DATADIR=$datadir
|
||||||
EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
|
EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
|
||||||
EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"`
|
EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"`
|
||||||
|
@ -34,7 +34,7 @@
|
||||||
|
|
||||||
exec_prefix=$old_exec_prefix
|
exec_prefix=$old_exec_prefix
|
||||||
libdir=$old_libdir
|
libdir=$old_libdir
|
||||||
@@ -1600,7 +1600,7 @@ PHP_SUBST(install_binary_targets)
|
@@ -1638,7 +1638,7 @@ PHP_SUBST(all_targets)
|
||||||
PHP_SUBST(install_targets)
|
PHP_SUBST(install_targets)
|
||||||
PHP_SUBST(install_binary_targets)
|
PHP_SUBST(install_binary_targets)
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- ext/hash/xxhash/xxhash.h.orig 2022-08-02 13:57:03 UTC
|
--- ext/hash/xxhash/xxhash.h.orig 2023-03-14 16:11:05 UTC
|
||||||
+++ ext/hash/xxhash/xxhash.h
|
+++ ext/hash/xxhash/xxhash.h
|
||||||
@@ -3048,22 +3048,32 @@ enum XXH_VECTOR_TYPE /* fake enum */ {
|
@@ -3047,22 +3047,32 @@ enum XXH_VECTOR_TYPE /* fake enum */ {
|
||||||
* inconsistent intrinsics, spotty coverage, and multiple endiannesses.
|
* inconsistent intrinsics, spotty coverage, and multiple endiannesses.
|
||||||
*/
|
*/
|
||||||
#if XXH_VECTOR == XXH_VSX
|
#if XXH_VECTOR == XXH_VSX
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- sapi/apache2handler/config.m4.orig 2018-08-14 11:39:14 UTC
|
--- sapi/apache2handler/config.m4.orig 2023-03-14 16:11:05 UTC
|
||||||
+++ sapi/apache2handler/config.m4
|
+++ sapi/apache2handler/config.m4
|
||||||
@@ -65,7 +65,7 @@ if test "$PHP_APXS2" != "no"; then
|
@@ -64,7 +64,7 @@ if test "$PHP_APXS2" != "no"; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
APXS_LIBEXECDIR='$(INSTALL_ROOT)'`$APXS -q LIBEXECDIR`
|
APXS_LIBEXECDIR='$(INSTALL_ROOT)'`$APXS -q LIBEXECDIR`
|
||||||
|
@ -8,4 +8,4 @@
|
||||||
+ if true; then
|
+ if true; then
|
||||||
INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
|
INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
|
||||||
$APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
|
$APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
|
||||||
-i -n php7"
|
-i -n php"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- sapi/fpm/config.m4.orig 2018-08-14 11:39:14 UTC
|
--- sapi/fpm/config.m4.orig 2023-03-14 16:11:05 UTC
|
||||||
+++ sapi/fpm/config.m4
|
+++ sapi/fpm/config.m4
|
||||||
@@ -319,7 +319,7 @@ AC_DEFUN([AC_FPM_LQ],
|
@@ -339,7 +339,7 @@ AC_DEFUN([AC_FPM_LQ],
|
||||||
AC_MSG_RESULT([no])
|
AC_MSG_RESULT([no])
|
||||||
])
|
])
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
--- sapi/fpm/www.conf.in.orig 2019-01-26 15:54:27 UTC
|
--- sapi/fpm/www.conf.in.orig 2023-03-14 16:11:05 UTC
|
||||||
+++ sapi/fpm/www.conf.in
|
+++ sapi/fpm/www.conf.in
|
||||||
@@ -27,10 +27,14 @@ group = @php_fpm_group@
|
@@ -32,10 +32,14 @@ group = @php_fpm_group@
|
||||||
; Valid syntaxes are:
|
; Valid syntaxes are:
|
||||||
; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on
|
; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on
|
||||||
; a specific port;
|
; a specific port;
|
||||||
|
|
Loading…
Add table
Reference in a new issue