1 # Buildsheet autogenerated by ravenadm tool -- Do not edit.
7 SDESC[standard]= PHP Hypertext Preprocessor version 8.2
8 HOMEPAGE= https://php.net/
12 SITES[main]= PHP/distributions
13 DISTFILE[1]= php-8.2.15.tar.xz:main
15 SPKGS[standard]= complete
20 OPTIONS_AVAILABLE= CLI CGI FPM EMBED DEBUGGER
21 OPTIONS_STANDARD= CLI CGI FPM EMBED DEBUGGER
22 OPTGROUP_RESTRICTED= SAPI
23 OPTDESCR[SAPI]= Server Application Programming Interface
24 OPTGROUP[SAPI]= CLI CGI FPM DEBUGGER
25 OPT_ON[all]= CLI CGI FPM EMBED DEBUGGER
27 BUILD_DEPENDS= autoconf:single:standard
29 USES= cpe gmake pkgconfig zlib pcre2 mbsdfix
30 C_USES[darwin]= iconv:build
31 GNOME_COMPONENTS= libxml2
35 LICENSE= CUSTOM1:primary
36 LICENSE_NAME= CUSTOM1:"PHP License v3.01"
37 LICENSE_FILE= CUSTOM1:{{WRKSRC}}/LICENSE
41 FPC_EQUIVALENT= lang/php82
44 CONFIGURE_ARGS= --with-layout=GNU
47 --with-config-file-scan-dir={{PREFIX}}/etc/php82
48 --sysconfdir={{PREFIX}}/etc/php82
49 --libdir={{PREFIX}}/lib/php82
50 --datadir={{PREFIX}}/share/php82
53 --enable-maintainer-zts
55 CONFIGURE_ENV= ac_cv_decimal_fp_supported="no"
58 DESTDIRNAME= INSTALL_ROOT
62 RC_SUBR= php82-fpm:primary
65 [CLI].DESCRIPTION= Enable Command Line Interface SAPI
66 [CLI].CONFIGURE_ARGS_OFF= --disable-cli
67 [CLI].MAKEFILE_ON= PHP_SAPI+=cli
69 [FPM].DESCRIPTION= Enable FastCGI Process Manager SAPI
70 [FPM].CONFIGURE_ARGS_ON= --enable-fpm
71 --with-fpm-user={{WWWOWN}}
72 --with-fpm-group={{WWWGRP}}
73 [FPM].MAKEFILE_ON= PHP_SAPI+=fpm
75 [DEBUGGER].DESCRIPTION= Enable interactive debugger SAPI module support
76 [DEBUGGER].CONFIGURE_ENABLE_BOTH= phpdbg
77 [DEBUGGER].MAKEFILE_ON= PHP_SAPI+=phpdbg
79 [CGI].DESCRIPTION= Enable Common Gateway Interface SAPI
80 [CGI].CONFIGURE_ARGS_OFF= --disable-cgi
81 [CGI].MAKEFILE_ON= PHP_SAPI+=cgi
83 [EMBED].DESCRIPTION= Build embedded SAPI library
84 [EMBED].CONFIGURE_ARGS_ON= --enable-embed
85 [EMBED].MAKEFILE_ON= PHP_SAPI+=embed
88 ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/php82
91 ${TOUCH} ${WRKSRC}/ext/php_config.h
92 ${REINPLACE_CMD} "s|^\(extension_dir\)|; \1|" ${WRKSRC}/php.ini-*
93 ${REINPLACE_CMD} -e "/phpincludedir =/ s|/php|/php82|" \
94 ${WRKSRC}/scripts/Makefile.frag
95 ${REINPLACE_CMD} -e "/includedir=/ s|php|php82|" \
96 ${WRKSRC}/scripts/phpize.in
97 ${REINPLACE_CMD} -e "/include_dir=/ s|php|php82|" \
98 -e "/^ldflags=/ s|@PHP|-L${PREFIX}/lib/php82 @PHP|" \
99 ${WRKSRC}/scripts/php-config.in
100 ${REINPLACE_CMD} -e "s|darwin|darwin-disable|" \
101 ${WRKSRC}/sapi/cgi/config9.m4 \
102 ${WRKSRC}/sapi/cli/config.m4 \
103 ${WRKSRC}/sapi/fpm/config.m4
105 post-install-DEBUGGER-ON:
106 ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/phpdbg82
109 ${REINPLACE_CMD} -e "s|^;\(pid\)|\1|;s|^;\(pm\.[a-z_]*_servers\)|\1|" \
110 ${WRKSRC}/sapi/fpm/php-fpm.conf.in
113 @${MKDIR} ${STAGEDIR}${PREFIX}/etc/php82
114 ${RM} -r ${STAGEDIR}/var
115 ${RM} -r ${STAGEDIR}${PREFIX}/include/php82/include
116 ${INSTALL_DATA} ${WRKSRC}/php.ini-development \
117 ${WRKSRC}/php.ini-production \
118 ${WRKDIR}/php.conf ${STAGEDIR}${PREFIX}/etc/php82
121 ${ECHO_CMD} "PHP_VER=82" > ${WRKDIR}/php.conf
122 ${ECHO_CMD} "PHP_VERSION=8.2.15" >> ${WRKDIR}/php.conf
123 ${ECHO_CMD} "PHP_SAPI=${PHP_SAPI}" >> ${WRKDIR}/php.conf
124 ${ECHO_CMD} "PHP_EXT_INC=hash json pcre spl" >> ${WRKDIR}/php.conf
125 ${SH} ${WRKSRC}/scripts/php-config --extension-dir | \
126 ${SED} -ne 's,^${PREFIX}/lib/php82/,PHP_EXT_DIR=,p'\
127 >> ${WRKDIR}/php.conf
129 post-install-EMBED-ON:
130 ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libphp.so
131 ${MV} ${STAGEDIR}${PREFIX}/lib/libphp.so \
132 ${STAGEDIR}${PREFIX}/lib/php82/
135 (cd ${WRKSRC} && ${SETENV} MAKE=${MAKE_CMD} ./buildconf --force)
138 ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/php-cgi82
141 ${STRIP_CMD} ${STAGEDIR}${PREFIX}/sbin/php-fpm82
143 [FILE:679:descriptions/desc.primary]
144 PHP is a widely-used open source general-purpose scripting language
145 that is especially suited for web development and can be embedded
146 into HTML. It is modular, and object-oriented. Much of its syntax
147 is borrowed from C, Java and Perl with a couple of unique PHP-specific
148 features thrown in. The language is designed to allow web developers
149 to write dynamically generated pages quickly.
151 This package provides PHP version 7.3.x. New feature added over
152 version 7.2.x include:
154 * Flexible Heredoc and Nowdoc Syntax
156 * Multiple MBString Improvements
157 * LDAP Controls Support
158 * Improved FPM Logging
159 * Windows File Deletion Improvements
160 * Several Deprecations
164 eca5deac02d77d806838275f8a3024b38b35ac0a5d9853dcc71c6cbe3f1f8765 12075384 php-8.2.15.tar.xz
167 [FILE:473:manifests/plist.primary]
168 %%CGI-ON%%bin/php-cgi%%SUFFIX%%
169 %%CLI-ON%%bin/php%%SUFFIX%%
170 %%DEBUGGER-ON%%bin/phpdbg%%SUFFIX%%
171 %%EMBED-ON%%lib/php%%SUFFIX%%/libphp.so
172 %%FPM-ON%%@sample etc/php%%SUFFIX%%/php-fpm.conf.default etc/php%%SUFFIX%%/php-fpm.conf
173 %%FPM-ON%%@sample etc/php%%SUFFIX%%/php-fpm.d/www.conf.default etc/php%%SUFFIX%%/php-fpm.d/www.conf
174 %%FPM-ON%%sbin/php-fpm%%SUFFIX%%
175 %%FPM-ON%%share/php%%SUFFIX%%/fpm/status.html
182 [FILE:5725:manifests/plist.dev]
183 %%CLI-ON%%include/php%%SUFFIX%%/sapi/cli/cli.h
184 %%EMBED-ON%%include/php%%SUFFIX%%/sapi/embed/php_embed.h
188 include/php%%SUFFIX%%/TSRM/
191 include/php%%SUFFIX%%/Zend/
200 zend_attributes_arginfo.h
203 zend_builtin_functions.h
204 zend_builtin_functions_arginfo.h
206 zend_closures_arginfo.h
211 zend_constants_arginfo.h
218 zend_exceptions_arginfo.h
222 zend_fibers_arginfo.h
227 zend_generators_arginfo.h
229 zend_globals_macros.h
236 zend_ini_scanner_defs.h
238 zend_interfaces_arginfo.h
241 zend_language_parser.h
242 zend_language_scanner.h
243 zend_language_scanner_defs.h
248 zend_max_execution_timer.h
253 zend_object_handlers.h
263 zend_smart_str_public.h
265 zend_smart_string_public.h
282 zend_vm_trace_handlers.h
283 zend_vm_trace_lines.h
286 zend_weakrefs_arginfo.h
287 include/php%%SUFFIX%%/Zend/Optimizer/
296 include/php%%SUFFIX%%/ext/date/php_date.h
297 include/php%%SUFFIX%%/ext/date/lib/
300 include/php%%SUFFIX%%/ext/hash/
317 include/php%%SUFFIX%%/ext/json/
321 include/php%%SUFFIX%%/ext/libxml/php_libxml.h
322 include/php%%SUFFIX%%/ext/mysqlnd/
324 mysql_float_to_double.h
328 mysqlnd_block_alloc.h
335 mysqlnd_libmysql_compat.h
337 mysqlnd_portability.h
339 mysqlnd_protocol_frame_codec.h
341 mysqlnd_read_buffer.h
343 mysqlnd_result_meta.h
344 mysqlnd_reverse_api.h
348 mysqlnd_wireprotocol.h
350 include/php%%SUFFIX%%/ext/pcre/php_pcre.h
351 include/php%%SUFFIX%%/ext/pcre/pcre2lib/
359 include/php%%SUFFIX%%/ext/random/php_random.h
360 include/php%%SUFFIX%%/ext/spl/
372 include/php%%SUFFIX%%/ext/standard/
375 basic_functions_arginfo.h
413 php_incomplete_class.h
423 php_smart_string_public.h
436 user_filters_arginfo.h
438 include/php%%SUFFIX%%/main/
456 php_open_temporary_file.h
468 include/php%%SUFFIX%%/main/streams/
470 php_stream_filter_api.h
471 php_stream_glob_wrapper.h
473 php_stream_plain_wrapper.h
474 php_stream_transport.h
475 php_stream_userspace.h
477 lib/php%%SUFFIX%%/build/
479 ax_check_compile_flag.m4
480 ax_gcc_func_attribute.m4
487 php_cxx_compile_stdcxx.m4
492 @postexec touch %D/include/php%%SUFFIX%%/ext/php_config.h
493 @postunexec [ -s %D/include/php%%SUFFIX%%/ext/php_config.h ] || rm %D/include/php%%SUFFIX%%/ext/php_config.h
496 [FILE:258:manifests/plist.man]
497 %%CGI-ON%%share/man/man1/php-cgi%%SUFFIX%%.1.gz
498 %%CLI-ON%%share/man/man1/php%%SUFFIX%%.1.gz
499 %%DEBUGGER-ON%%share/man/man1/phpdbg%%SUFFIX%%.1.gz
500 %%FPM-ON%%share/man/man8/php-fpm%%SUFFIX%%.8.gz
502 php-config%%SUFFIX%%.1.gz
503 phpize%%SUFFIX%%.1.gz
506 [FILE:357:patches/patch-Zend_zend__gdb.c]
507 --- Zend/zend_gdb.c.orig 2023-12-20 06:28:06 UTC
513 -#if defined(__FreeBSD__) && __FreeBSD_version >= 1100000
514 +#if defined(__MidnightBSD__)
515 +# include <sys/user.h>
516 +#elif defined(__FreeBSD__) && __FreeBSD_version >= 1100000
517 # include <sys/user.h>
518 # include <libutil.h>
522 [FILE:1188:patches/patch-build_Makefile.global]
523 --- build/Makefile.global.orig 2023-12-20 06:28:06 UTC
524 +++ build/Makefile.global
525 @@ -92,14 +92,14 @@ test: all
526 @if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \
527 INI_FILE=`$(PHP_EXECUTABLE) -d 'display_errors=stderr' -r 'echo php_ini_loaded_file();' 2> /dev/null`; \
528 if test "$$INI_FILE"; then \
529 - $(EGREP) -h -v $(PHP_DEPRECATED_DIRECTIVES_REGEX) "$$INI_FILE" > $(top_builddir)/tmp-php.ini; \
530 + $(EGREP) -h -v $(PHP_DEPRECATED_DIRECTIVES_REGEX) "$$INI_FILE" > $(top_builddir)/tmp-php.ini || :; \
532 echo > $(top_builddir)/tmp-php.ini; \
534 INI_SCANNED_PATH=`$(PHP_EXECUTABLE) -d 'display_errors=stderr' -r '$$a = explode(",\n", trim(php_ini_scanned_files())); echo $$a[0];' 2> /dev/null`; \
535 if test "$$INI_SCANNED_PATH"; then \
536 INI_SCANNED_PATH=`$(top_srcdir)/build/shtool path -d $$INI_SCANNED_PATH`; \
537 - $(EGREP) -h -v $(PHP_DEPRECATED_DIRECTIVES_REGEX) "$$INI_SCANNED_PATH"/*.ini >> $(top_builddir)/tmp-php.ini; \
538 + $(EGREP) -h -v $(PHP_DEPRECATED_DIRECTIVES_REGEX) "$$INI_SCANNED_PATH"/*.ini >> $(top_builddir)/tmp-php.ini || :; \
540 TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
541 TEST_PHP_SRCDIR=$(top_srcdir) \
544 [FILE:1155:patches/patch-configure.ac]
545 --- configure.ac.orig 2023-12-20 06:28:06 UTC
547 @@ -55,6 +55,7 @@ AH_BOTTOM([
551 +#include <ext/php_config.h>
552 #endif /* PHP_CONFIG_H */
555 @@ -637,7 +638,7 @@ AC_FUNC_STRERROR_R
556 AX_FUNC_WHICH_GETHOSTBYNAME_R
558 dnl Some systems (like OpenSolaris) do not have nanosleep in libc.
559 -PHP_CHECK_FUNC_LIB(nanosleep, rt)
560 +PHP_CHECK_FUNC(nanosleep, rt)
562 dnl Haiku does not have network api in libc.
563 PHP_CHECK_FUNC_LIB(setsockopt, network)
564 @@ -1424,7 +1425,7 @@ EXPANDED_SYSCONFDIR=`eval echo $sysconfd
565 EXPANDED_DATADIR=$datadir
566 EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
567 EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"`
568 -INCLUDE_PATH=.:$EXPANDED_PEAR_INSTALLDIR
569 +INCLUDE_PATH=.:${prefix}/share/pear
571 exec_prefix=$old_exec_prefix
573 @@ -1666,7 +1667,7 @@ PHP_SUBST(all_targets)
574 PHP_SUBST(install_targets)
575 PHP_SUBST(install_binary_targets)
577 -PHP_INSTALL_HEADERS([Zend/ TSRM/ include/ main/ main/streams/])
578 +PHP_INSTALL_HEADERS([Zend/ TSRM/ main/ main/streams/])
579 PHP_INSTALL_HEADERS([Zend/Optimizer], [ \
584 [FILE:628:patches/patch-ext_standard_proc__open.c]
585 --- ext/standard/proc_open.c.orig 2023-12-20 06:28:06 UTC
586 +++ ext/standard/proc_open.c
591 -# elif defined(__FreeBSD__)
592 +# elif defined(__FreeBSD__) && !defined(__MidnightBSD__)
593 /* FreeBSD defines `openpty` in <libutil.h> */
594 # include <libutil.h>
595 -# elif defined(__NetBSD__) || defined(__DragonFly__)
596 +# elif defined(__NetBSD__) || defined(__DragonFly__) || defined(__MidnightBSD__)
597 /* On recent NetBSD/DragonFlyBSD releases the emalloc, estrdup ... calls had been introduced in libutil */
598 # if defined(__NetBSD__)
599 # include <sys/termios.h>
602 [FILE:428:patches/patch-sapi_apache2handler_config.m4]
603 --- sapi/apache2handler/config.m4.orig 2023-12-20 06:28:06 UTC
604 +++ sapi/apache2handler/config.m4
605 @@ -64,7 +64,7 @@ if test "$PHP_APXS2" != "no"; then
608 APXS_LIBEXECDIR='$(INSTALL_ROOT)'`$APXS -q LIBEXECDIR`
609 - if test -z `$APXS -q SYSCONFDIR`; then
611 INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
612 $APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
616 [FILE:304:patches/patch-sapi_fpm_config.m4]
617 --- sapi/fpm/config.m4.orig 2023-12-20 06:28:06 UTC
618 +++ sapi/fpm/config.m4
619 @@ -339,7 +339,7 @@ AC_DEFUN([AC_FPM_LQ],
623 - if test "$have_lq" = "tcp_info"; then
624 + if test "$have_lq" = "so_listenq"; then
625 AC_DEFINE([HAVE_LQ_TCP_INFO], 1, [do we have TCP_INFO?])
630 [FILE:470:patches/patch-sapi_fpm_fpm_fpm__unix.c]
631 --- sapi/fpm/fpm/fpm_unix.c.orig 2023-12-20 06:28:06 UTC
632 +++ sapi/fpm/fpm/fpm_unix.c
633 @@ -478,7 +478,7 @@ int fpm_unix_init_child(struct fpm_worke
638 +#if defined(HAVE_PROCCTL) && defined(PROC_TRACE_CTL_ENABLE)
639 int dumpable = PROC_TRACE_CTL_ENABLE;
640 if (wp->config->process_dumpable && -1 == procctl(P_PID, getpid(), PROC_TRACE_CTL, &dumpable)) {
641 zlog(ZLOG_SYSERROR, "[pool %s] failed to procctl(PROC_TRACE_CTL)", wp->config->name);
644 [FILE:954:patches/patch-sapi_fpm_www.conf.in]
645 --- sapi/fpm/www.conf.in.orig 2023-12-20 06:28:06 UTC
646 +++ sapi/fpm/www.conf.in
647 @@ -32,10 +32,14 @@ group = @php_fpm_group@
648 ; Valid syntaxes are:
649 ; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on
651 +; '0.0.0.0:port' - to listen on a TCP socket to all IPv4 addresses on
653 ; '[ip:6:addr:ess]:port' - to listen on a TCP socket to a specific IPv6 address on
655 ; 'port' - to listen on a TCP socket to all addresses
656 ; (IPv6 and IPv4-mapped) on a specific port;
657 +; Note: IPv4-mapped addresses are disabled by-default in
658 +; FreeBSD for security reasons;
659 ; '/path/to/unix/socket' - to listen on a unix socket.
660 ; Note: This value is mandatory.
661 listen = 127.0.0.1:9000
664 [FILE:1394:files/php82-fpm.in]
668 # PROVIDE: php%%SUFFIX%%-fpm
673 # Add the following line to /etc/rc.conf to enable php-fpm:
674 # php%%SUFFIX%%_fpm_enable="YES"
679 name="php%%SUFFIX%%_fpm"
680 rcvar=php%%SUFFIX%%_fpm_enable
682 start_precmd="php%%SUFFIX%%_fpm_prestart"
683 restart_precmd="php%%SUFFIX%%_fpm_checkconfig"
684 reload_precmd="php%%SUFFIX%%_fpm_checkconfig"
685 configtest_cmd="php%%SUFFIX%%_fpm_checkconfig"
687 load_rc_config "$name"
689 : ${php%%SUFFIX%%_fpm_enable="NO"}
690 : ${php%%SUFFIX%%_fpm_umask=""}
692 extra_commands="reload configtest logrotate"
694 command="%%PREFIX%%/sbin/php-fpm"
695 pidfile="/var/run/php-fpm.pid"
698 logrotate_cmd="php%%SUFFIX%%_fpm_logrotate"
700 required_files="%%PREFIX%%/etc/php-fpm.conf"
702 php%%SUFFIX%%_fpm_logrotate() {
703 if [ -z "$rc_pid" ]; then
707 echo "Rotating logs $name."
711 php%%SUFFIX%%_fpm_checkconfig()
713 echo "Performing sanity check on php-fpm configuration:"
717 php%%SUFFIX%%_fpm_prestart()
719 php%%SUFFIX%%_fpm_checkconfig
721 if [ $checkconfig -ne 0 ]; then
725 if [ ! -z "$php%%SUFFIX%%_fpm_umask" ]; then
726 echo "Setting umask to: ${php%%SUFFIX%%_fpm_umask}"
727 umask $php%%SUFFIX%%_fpm_umask