remove php 5.6 and infrastructure, it is nearly out of security support

This commit is contained in:
sthen 2018-12-11 12:10:19 +00:00
parent 305fd3d250
commit eae4c81565
75 changed files with 9 additions and 1703 deletions

View File

@ -1,28 +0,0 @@
# $OpenBSD: Makefile,v 1.92 2018/12/09 21:01:03 ajacoutot Exp $
# XXX fix build with icu >=5.9.1 (remove at next update?)
CXXFLAGS += -DU_USING_ICU_NAMESPACE=1
PV= 5.6
V= ${PV}.38
REVISION= 5
MASTER_SITES0= https://download.suhosin.org/
FLAVORS= no_suhosin
FLAVOR?=
SUHOSIN_V= 0.9.38
SUPDISTFILES= suhosin-${SUHOSIN_V}.tar.gz:0
.if !${FLAVOR:Mno_suhosin}
DISTFILES+= suhosin-${SUHOSIN_V}.tar.gz:0
PATCH_LIST= patch-* suhosin-*
CONFIGURE_ARGS+= --enable-suhosin
pre-patch:
@mv ${WRKDIR}/suhosin-${SUHOSIN_V} ${WRKSRC}/ext/suhosin
.endif
.include <bsd.port.mk>

View File

@ -1,4 +0,0 @@
SHA256 (php-5.6.38.tar.bz2) = 1lsjG73WO+RDnvXO2WXP1j5imDQp29Tfz7SZgVk+vAM=
SHA256 (suhosin-0.9.38.tar.gz) = wC12xOfOd3kQo3wYGBy2f9npDv4BB/6rPeMTG1+JvOo=
SIZE (php-5.6.38.tar.bz2) = 15058534
SIZE (suhosin-0.9.38.tar.gz) = 122800

View File

@ -1,18 +0,0 @@
$OpenBSD: patch-Zend_zend_compile_h,v 1.1 2018/04/24 15:26:58 sthen Exp $
clang6
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=227723
Index: Zend/zend_compile.h
--- Zend/zend_compile.h.orig
+++ Zend/zend_compile.h
@@ -414,9 +414,6 @@ struct _zend_execute_data {
#define EX(element) execute_data.element
-#define EX_TMP_VAR(ex, n) ((temp_variable*)(((char*)(ex)) + ((int)(n))))
-#define EX_TMP_VAR_NUM(ex, n) (EX_TMP_VAR(ex, 0) - (1 + (n)))
-
#define EX_CV_NUM(ex, n) (((zval***)(((char*)(ex))+ZEND_MM_ALIGNED_SIZE(sizeof(zend_execute_data))))+(n))

View File

@ -1,24 +0,0 @@
$OpenBSD: patch-Zend_zend_execute_h,v 1.1 2018/04/24 15:26:58 sthen Exp $
clang6
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=227723
Index: Zend/zend_execute.h
--- Zend/zend_execute.h.orig
+++ Zend/zend_execute.h
@@ -71,6 +71,15 @@ ZEND_API int zend_eval_stringl_ex(char *str, int str_l
ZEND_API char * zend_verify_arg_class_kind(const zend_arg_info *cur_arg_info, ulong fetch_type, const char **class_name, zend_class_entry **pce TSRMLS_DC);
ZEND_API int zend_verify_arg_error(int error_type, const zend_function *zf, zend_uint arg_num, const char *need_msg, const char *need_kind, const char *given_msg, const char *given_kind TSRMLS_DC);
+static zend_always_inline temp_variable *EX_TMP_VAR(void *ex, int n)
+{
+ return (temp_variable *)((zend_uintptr_t)ex + n);
+}
+static inline temp_variable *EX_TMP_VAR_NUM(void *ex, int n)
+{
+ return (temp_variable *)((zend_uintptr_t)ex - (1 + n) * sizeof(temp_variable));
+}
+
static zend_always_inline void i_zval_ptr_dtor(zval *zval_ptr ZEND_FILE_LINE_DC TSRMLS_DC)
{
if (!Z_DELREF_P(zval_ptr)) {

View File

@ -1,46 +0,0 @@
$OpenBSD: patch-acinclude_m4,v 1.1 2014/11/15 13:43:01 robert Exp $
--- acinclude.m4.orig.port Sun Jul 28 10:54:23 2013
+++ acinclude.m4 Sun Jul 28 10:55:00 2013
@@ -984,15 +984,9 @@ dnl ---------------------------------------------- Sha
if test "$3" != "shared" && test "$3" != "yes" && test "$4" = "cli"; then
dnl ---------------------------------------------- CLI static module
[PHP_]translit($1,a-z_-,A-Z__)[_SHARED]=no
- case "$PHP_SAPI" in
- cgi|embed[)]
- PHP_ADD_SOURCES(PHP_EXT_DIR($1),$2,$ac_extra,)
- EXT_STATIC="$EXT_STATIC $1"
- ;;
- *[)]
PHP_ADD_SOURCES(PHP_EXT_DIR($1),$2,$ac_extra,cli)
- ;;
- esac
+ PHP_ADD_SOURCES(PHP_EXT_DIR($1),$2,$ac_extra,cgi)
+ PHP_ADD_SOURCES(PHP_EXT_DIR($1),$2,$ac_extra,fpm)
EXT_CLI_STATIC="$EXT_CLI_STATIC $1"
fi
PHP_ADD_BUILD_DIR($ext_builddir)
@@ -1042,12 +1036,6 @@ You either need to build $1 shared or build $2 statica
build to be successful.
])
fi
- if test "x$is_it_enabled" = "xno" && test "x$3" != "xtrue"; then
- AC_MSG_ERROR([
-You've configured extension $1, which depends on extension $2,
-but you've either not enabled $2, or have disabled it.
-])
- fi
dnl Some systems require that we link $2 to $1 when building
])
@@ -2320,9 +2308,9 @@ AC_DEFUN([PHP_SETUP_OPENSSL],[
test -z "$PHP_IMAP_SSL" && PHP_IMAP_SSL=no
dnl Fallbacks for different configure options
- if test "$PHP_OPENSSL" != "no"; then
+ if test -n "$PHP_OPENSSL" && test "$PHP_OPENSSL" != "no"; then
PHP_OPENSSL_DIR=$PHP_OPENSSL
- elif test "$PHP_IMAP_SSL" != "no"; then
+ elif test -n "$PHP_IMAP_SSL" && test "$PHP_IMAP_SSL" != "no"; then
PHP_OPENSSL_DIR=$PHP_IMAP_SSL
fi

View File

@ -1,14 +0,0 @@
$OpenBSD: patch-aclocal_m4,v 1.1 2017/04/26 08:15:05 sthen Exp $
--- aclocal.m4.orig.port Tue Apr 25 00:33:44 2017
+++ aclocal.m4 Tue Apr 25 00:35:00 2017
@@ -762,7 +762,9 @@ AC_DEFUN([PHP_REQUIRE_CXX],[
if test -z "$php_cxx_done"; then
AC_PROG_CXX
AC_PROG_CXXCPP
- PHP_ADD_LIBRARY(stdc++)
+ for i in $LIBCXX; do
+ PHP_ADD_LIBRARY($i)
+ done
php_cxx_done=yes
fi
])

View File

@ -1,32 +0,0 @@
$OpenBSD: patch-configure_in,v 1.1 2014/11/15 13:43:01 robert Exp $
--- configure.in.orig.port Wed Nov 12 14:52:21 2014
+++ configure.in Sat Nov 15 10:45:17 2014
@@ -1042,16 +1042,16 @@ case $php_sapi_module in
enable_static=no
case $with_pic in
yes)
- standard_libtool_flag='-prefer-pic'
+ standard_libtool_flag=''
;;
no)
- standard_libtool_flag='-prefer-non-pic'
+ standard_libtool_flag=''
;;
esac
EXTRA_LDFLAGS="$EXTRA_LDFLAGS -avoid-version -module"
;;
*[)]
- standard_libtool_flag='-prefer-non-pic -static'
+ standard_libtool_flag=''
if test -z "$PHP_MODULES" && test -z "$PHP_ZEND_EX"; then
enable_shared=no
fi
@@ -1242,7 +1242,7 @@ EXPANDED_SYSCONFDIR=`eval echo $sysconfdir`
EXPANDED_DATADIR=$datadir
EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"`
-INCLUDE_PATH=.:$EXPANDED_PEAR_INSTALLDIR
+INCLUDE_PATH=.:$libdir
exec_prefix=$old_exec_prefix
libdir=$old_libdir

View File

@ -1,28 +0,0 @@
$OpenBSD: patch-ext_gd_config_m4,v 1.1 2014/11/15 13:43:01 robert Exp $
revert https://github.com/php/php-src/commit/5e9c6c3b644b290255fb10c8eb34778665c2f8a3.patch
which breaks things for finding /usr/X11R6/include/X11/xpm.h
--- ext/gd/config.m4.orig.port Wed Mar 5 10:18:00 2014
+++ ext/gd/config.m4 Thu Mar 27 13:43:18 2014
@@ -158,11 +158,18 @@ AC_DEFUN([PHP_GD_XPM],[
if test "$PHP_XPM_DIR" != "no"; then
for i in $PHP_XPM_DIR /usr/local /usr/X11R6 /usr; do
- test -f $i/include/xpm.h && GD_XPM_DIR=$i && GD_XPM_INC=$i && break
- test -f $i/include/X11/xpm.h && GD_XPM_DIR=$i && GD_XPM_INC=$i/X11 && break
+ test -f $i/$PHP_LIBDIR/libXpm.$SHLIB_SUFFIX_NAME || test -f $i/$PHP_LIBDIR/libXpm.a && GD_XPM_DIR=$i && break
done
if test -z "$GD_XPM_DIR"; then
+ AC_MSG_ERROR([libXpm.(a|so) not found.])
+ fi
+
+ for i in include include/X11; do
+ test -f $GD_XPM_DIR/$i/xpm.h && GD_XPM_INC=$GD_XPM_DIR/include
+ done
+
+ if test -z "$GD_XPM_INC"; then
AC_MSG_ERROR([xpm.h not found.])
fi

View File

@ -1,12 +0,0 @@
$OpenBSD: patch-ext_gd_libgd_gdkanji_c,v 1.1 2014/11/15 13:43:01 robert Exp $
--- ext/gd/libgd/gdkanji.c.orig.port Wed Sep 26 16:44:16 2007
+++ ext/gd/libgd/gdkanji.c Sat Jun 18 12:14:49 2011
@@ -362,7 +362,7 @@ do_convert (unsigned char *to, unsigned char *from, co
from_len = strlen ((const char *) from) + 1;
to_len = BUFSIZ;
- if ((int) iconv(cd, (char **) &from, &from_len, (char **) &to, &to_len) == -1)
+ if ((int) iconv(cd, (const char **) &from, &from_len, (char **) &to, &to_len) == -1)
{
#ifdef HAVE_ERRNO_H
if (errno == EINVAL)

View File

@ -1,75 +0,0 @@
$OpenBSD: patch-ext_iconv_iconv_c,v 1.2 2015/07/12 14:06:23 robert Exp $
--- ext/iconv/iconv.c.orig.port Fri Jul 10 02:33:32 2015
+++ ext/iconv/iconv.c Sun Jul 12 16:05:11 2015
@@ -463,7 +463,7 @@ static php_iconv_err_t _php_iconv_appendl(smart_str *d
out_p = (d)->c + (d)->len;
- if (iconv(cd, (char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
+ if (iconv(cd, (const char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
#if ICONV_SUPPORTS_ERRNO
switch (errno) {
case EINVAL:
@@ -650,7 +650,7 @@ PHP_ICONV_API php_iconv_err_t php_iconv_string(const c
out_p = out_buf;
while (in_left > 0) {
- result = iconv(cd, (char **) &in_p, &in_left, (char **) &out_p, &out_left);
+ result = iconv(cd, (const char **) &in_p, &in_left, (char **) &out_p, &out_left);
out_size = bsz - out_left;
if (result == (size_t)(-1)) {
if (ignore_ilseq && errno == EILSEQ) {
@@ -775,7 +775,7 @@ static php_iconv_err_t _php_iconv_strlen(unsigned int
prev_in_left = in_left;
- if (iconv(cd, (char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
+ if (iconv(cd, (const char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
if (prev_in_left == in_left) {
break;
}
@@ -896,7 +896,7 @@ static php_iconv_err_t _php_iconv_substr(smart_str *pr
prev_in_left = in_left;
- if (iconv(cd1, (char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
+ if (iconv(cd1, (const char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
if (prev_in_left == in_left) {
break;
}
@@ -1028,7 +1028,7 @@ static php_iconv_err_t _php_iconv_strpos(unsigned int
prev_in_left = in_left;
- if (iconv(cd, (char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
+ if (iconv(cd, (const char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
if (prev_in_left == in_left) {
#if ICONV_SUPPORTS_ERRNO
switch (errno) {
@@ -1277,7 +1277,7 @@ static php_iconv_err_t _php_iconv_mime_encode(smart_st
out_left = out_size - out_reserved;
- if (iconv(cd, (char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
+ if (iconv(cd, (const char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
#if ICONV_SUPPORTS_ERRNO
switch (errno) {
case EINVAL:
@@ -1377,7 +1377,7 @@ static php_iconv_err_t _php_iconv_mime_encode(smart_st
out_p = buf;
out_left = out_size;
- if (iconv(cd, (char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
+ if (iconv(cd, (const char **)&in_p, &in_left, (char **) &out_p, &out_left) == (size_t)-1) {
#if ICONV_SUPPORTS_ERRNO
switch (errno) {
case EINVAL:
@@ -2650,7 +2650,7 @@ static int php_iconv_stream_filter_append_bucket(
tcnt = self->stub_len;
while (tcnt > 0) {
- if (iconv(self->cd, &pt, &tcnt, &pd, &ocnt) == (size_t)-1) {
+ if (iconv(self->cd, (const char **)&pt, &tcnt, &pd, &ocnt) == (size_t)-1) {
#if ICONV_SUPPORTS_ERRNO
switch (errno) {
case EILSEQ:

View File

@ -1,25 +0,0 @@
$OpenBSD: patch-ext_mbstring_php_mbregex_c,v 1.1 2018/05/27 20:23:19 martijn Exp $
From 4072b2787074ee8e247a6639585b49e10c5a55fe Mon Sep 17 00:00:00 2001
From: "Christoph M. Becker" <cmbecker69@gmx.de>
Date: Tue, 20 Mar 2018 16:35:39 +0100
Subject: [PATCH] Fix #76113: mbstring does not build with Oniguruma 6.8.1
As of Oniguruma 6.8.1, the regex structure has been moved from the
public `oniguruma.h` to the private `regint.h`. Thus, it is no longer
possible to directly access the struct's members, and actually, there
is no need to, since there are respective accessor functions available
at least of 2.3.1.
Index: ext/mbstring/php_mbregex.c
--- ext/mbstring/php_mbregex.c.orig
+++ ext/mbstring/php_mbregex.c
@@ -454,7 +454,7 @@ static php_mb_regex_t *php_mbregex_compile_pattern(con
OnigUChar err_str[ONIG_MAX_ERROR_MESSAGE_LEN];
found = zend_hash_find(&MBREX(ht_rc), (char *)pattern, patlen+1, (void **) &rc);
- if (found == FAILURE || (*rc)->options != options || (*rc)->enc != enc || (*rc)->syntax != syntax) {
+ if (found == FAILURE || onig_get_options(rc) != options || onig_get_encoding(rc) != enc || onig_get_syntax(rc) != syntax) {
if ((err_code = onig_new(&retval, (OnigUChar *)pattern, (OnigUChar *)(pattern + patlen), options, enc, syntax, &err_info)) != ONIG_NORMAL) {
onig_error_code_to_str(err_str, err_code, &err_info);
php_error_docref(NULL TSRMLS_CC, E_WARNING, "mbregex compile err: %s", err_str);

View File

@ -1,26 +0,0 @@
$OpenBSD: patch-ext_mcrypt_mcrypt_c,v 1.3 2016/12/19 20:35:09 martijn Exp $
mcrypt IV creation. no /dev/{u,}random? yes, it is using the last hunk.
--- ext/mcrypt/mcrypt.c.orig.port Wed Nov 9 02:22:57 2016
+++ ext/mcrypt/mcrypt.c Thu Dec 8 10:55:26 2016
@@ -1445,7 +1445,10 @@ PHP_FUNCTION(mcrypt_create_iv)
}
iv = ecalloc(size + 1, 1);
-
+#if defined(__OpenBSD__)
+ arc4random_buf(iv, (size_t) size);
+ n = size;
+#else
if (source == RANDOM || source == URANDOM) {
#if PHP_WIN32
/* random/urandom equivalent on Windows */
@@ -1490,6 +1493,7 @@ PHP_FUNCTION(mcrypt_create_iv)
iv[--size] = (char) (255.0 * php_rand(TSRMLS_C) / RAND_MAX);
}
}
+#endif /* openbsd */
RETURN_STRINGL(iv, n, 0);
}
/* }}} */

View File

@ -1,11 +0,0 @@
$OpenBSD: patch-ext_mysqlnd_config9_m4,v 1.1 2014/11/15 13:43:01 robert Exp $
--- ext/mysqlnd/config9.m4.orig.port Wed Jul 3 08:10:53 2013
+++ ext/mysqlnd/config9.m4 Sat Jul 27 18:39:50 2013
@@ -16,6 +16,7 @@ if test -z "$PHP_ZLIB_DIR"; then
fi
dnl If some extension uses mysqlnd it will get compiled in PHP core
+PHP_MYSQLND_ENABLED="yes"
if test "$PHP_MYSQLND" != "no" || test "$PHP_MYSQLND_ENABLED" = "yes"; then
mysqlnd_ps_sources="mysqlnd_ps.c mysqlnd_ps_codec.c"
mysqlnd_base_sources="mysqlnd.c mysqlnd_alloc.c mysqlnd_bt.c mysqlnd_charset.c mysqlnd_wireprotocol.c \

View File

@ -1,14 +0,0 @@
$OpenBSD: patch-ext_odbc_config_m4,v 1.3 2015/04/25 16:20:29 robert Exp $
don't link php binary with iodbc
--- ext/odbc/config.m4.orig.port Wed Apr 15 20:05:57 2015
+++ ext/odbc/config.m4 Sat Apr 25 18:10:11 2015
@@ -396,7 +396,6 @@ PHP_ARG_WITH(iodbc,,
AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
fi
if test -x "$PKG_CONFIG" && $PKG_CONFIG --exists libiodbc ; then
- PHP_ADD_LIBRARY_WITH_PATH(iodbc, $PHP_IODBC/$PHP_LIBDIR)
ODBC_TYPE=iodbc
ODBC_INCLUDE=`$PKG_CONFIG --cflags-only-I libiodbc`
ODBC_LFLAGS=`$PKG_CONFIG --libs-only-L libiodbc`

View File

@ -1,12 +0,0 @@
$OpenBSD: patch-ext_openssl_config0_m4,v 1.3 2018/05/25 13:59:19 sthen Exp $
--- ext/openssl/config0.m4.orig.port Wed Apr 15 20:05:57 2015
+++ ext/openssl/config0.m4 Sat Apr 25 18:10:11 2015
@@ -19,7 +19,7 @@ if test "$PHP_OPENSSL" != "no"; then
PHP_SETUP_KERBEROS(OPENSSL_SHARED_LIBADD)
fi
- AC_CHECK_LIB(ssl, DSA_get_default_method, AC_DEFINE(HAVE_DSA_DEFAULT_METHOD, 1, [OpenSSL 0.9.7 or later]))
+ AC_CHECK_LIB(ssl, DSA_get_default_method, AC_DEFINE(HAVE_DSA_DEFAULT_METHOD, 1, [OpenSSL 0.9.7 or later]),, [-lcrypto])
AC_CHECK_LIB(crypto, X509_free, AC_DEFINE(HAVE_DSA_DEFAULT_METHOD, 1, [OpenSSL 0.9.7 or later]))
AC_CHECK_FUNCS([RAND_egd])

View File

@ -1,33 +0,0 @@
$OpenBSD: patch-ext_session_session_c,v 1.2 2018/09/13 14:15:12 sthen Exp $
use arc4random_buf rather than /dev/urandom to add entropy to session ids
Index: ext/session/session.c
--- ext/session/session.c.orig
+++ ext/session/session.c
@@ -346,7 +346,24 @@ PHPAPI char *php_session_create_id(PS_CREATE_SID_ARGS)
efree(buf);
if (PS(entropy_length) > 0) {
-#ifdef PHP_WIN32
+#if defined(__OpenBSD__)
+ unsigned char rbuf[2048];
+ size_t toread = PS(entropy_length);
+ arc4random_buf(rbuf, MIN(toread, sizeof(rbuf)));
+ switch (PS(hash_func)) {
+ case PS_HASH_FUNC_MD5:
+ PHP_MD5Update(&md5_context, rbuf, toread);
+ break;
+ case PS_HASH_FUNC_SHA1:
+ PHP_SHA1Update(&sha1_context, rbuf, toread);
+ break;
+# if defined(HAVE_HASH_EXT) && !defined(COMPILE_DL_HASH)
+ case PS_HASH_FUNC_OTHER:
+ PS(hash_ops)->hash_update(hash_context, rbuf, toread);
+ break;
+# endif /* HAVE_HASH_EXT */
+ }
+#elif defined(PHP_WIN32)
unsigned char rbuf[2048];
size_t toread = PS(entropy_length);

View File

@ -1,30 +0,0 @@
$OpenBSD: patch-ext_spl_php_spl_c,v 1.2 2016/05/06 19:59:32 sthen Exp $
--- ext/spl/php_spl.c.orig.port Thu Apr 28 01:33:49 2016
+++ ext/spl/php_spl.c Fri Apr 29 14:02:27 2016
@@ -788,7 +788,7 @@ PHP_FUNCTION(spl_object_hash)
PHPAPI void php_spl_object_hash(zval *obj, char *result TSRMLS_DC) /* {{{*/
{
- intptr_t hash_handle, hash_handlers;
+ zend_intptr_t hash_handle, hash_handlers;
char *hex;
if (!SPL_G(hash_mask_init)) {
@@ -796,13 +796,13 @@ PHPAPI void php_spl_object_hash(zval *obj, char *resul
php_mt_srand(GENERATE_SEED() TSRMLS_CC);
}
- SPL_G(hash_mask_handle) = (intptr_t)(php_mt_rand(TSRMLS_C) >> 1);
- SPL_G(hash_mask_handlers) = (intptr_t)(php_mt_rand(TSRMLS_C) >> 1);
+ SPL_G(hash_mask_handle) = (zend_intptr_t)(php_mt_rand(TSRMLS_C) >> 1);
+ SPL_G(hash_mask_handlers) = (zend_intptr_t)(php_mt_rand(TSRMLS_C) >> 1);
SPL_G(hash_mask_init) = 1;
}
- hash_handle = SPL_G(hash_mask_handle)^(intptr_t)Z_OBJ_HANDLE_P(obj);
- hash_handlers = SPL_G(hash_mask_handlers)^(intptr_t)Z_OBJ_HT_P(obj);
+ hash_handle = SPL_G(hash_mask_handle)^(zend_intptr_t)Z_OBJ_HANDLE_P(obj);
+ hash_handlers = SPL_G(hash_mask_handlers)^(zend_intptr_t)Z_OBJ_HT_P(obj);
spprintf(&hex, 32, "%016lx%016lx", hash_handle, hash_handlers);

View File

@ -1,14 +0,0 @@
$OpenBSD: patch-ext_spl_php_spl_h,v 1.1 2014/11/15 13:43:01 robert Exp $
--- ext/spl/php_spl.h.orig.port Wed Nov 12 14:52:21 2014
+++ ext/spl/php_spl.h Sat Nov 15 10:45:12 2014
@@ -62,8 +62,8 @@ ZEND_BEGIN_MODULE_GLOBALS(spl)
HashTable * autoload_functions;
int autoload_running;
int autoload_extensions_len;
- intptr_t hash_mask_handle;
- intptr_t hash_mask_handlers;
+ zend_intptr_t hash_mask_handle;
+ zend_intptr_t hash_mask_handlers;
int hash_mask_init;
ZEND_END_MODULE_GLOBALS(spl)

View File

@ -1,21 +0,0 @@
$OpenBSD: patch-ext_standard_password_c,v 1.1 2016/02/06 23:30:25 sthen Exp $
--- ext/standard/password.c.orig.port Mon Feb 1 23:04:02 2016
+++ ext/standard/password.c Mon Feb 1 23:51:51 2016
@@ -124,6 +124,9 @@ static int php_password_make_salt(size_t length, char
buffer = (char *) safe_emalloc(raw_length, 1, 1);
+#if defined(__OpenBSD__)
+ arc4random_buf(buffer, raw_length);
+#else
#if PHP_WIN32
{
BYTE *iv_b = (BYTE *) buffer;
@@ -156,6 +159,7 @@ static int php_password_make_salt(size_t length, char
buffer[i] ^= (char) (255.0 * php_rand(TSRMLS_C) / RAND_MAX);
}
}
+#endif /* openbsd */
result = safe_emalloc(length, 1, 1);
if (php_password_salt_to64(buffer, raw_length, length, result) == FAILURE) {

View File

@ -1,33 +0,0 @@
$OpenBSD: patch-ext_tidy_config_m4,v 1.1 2014/11/15 13:43:01 robert Exp $
--- ext/tidy/config.m4.orig.port Wed Sep 26 16:44:16 2007
+++ ext/tidy/config.m4 Sat Jun 18 12:14:51 2011
@@ -14,12 +14,12 @@ if test "$PHP_TIDY" != "no"; then
fi
for i in $TIDY_SEARCH_DIRS; do
- if test -f $i/include/tidy/tidy.h; then
+ if test -f $i/include/tidyp/tidyp.h; then
TIDY_DIR=$i
- TIDY_INCDIR=$i/include/tidy
- elif test -f $i/include/tidy.h; then
+ TIDY_INCDIR=$i/include/tidyp
+ elif test -f $i/include/tidyp.h; then
TIDY_DIR=$i
- TIDY_INCDIR=$i/include
+ TIDY_INCDIR=$i/include/tidyp
fi
done
@@ -29,10 +29,10 @@ if test "$PHP_TIDY" != "no"; then
TIDY_LIBDIR=$TIDY_DIR/$PHP_LIBDIR
- PHP_ADD_LIBRARY_WITH_PATH(tidy, $TIDY_LIBDIR, TIDY_SHARED_LIBADD)
+ PHP_ADD_LIBRARY_WITH_PATH(tidyp, $TIDY_LIBDIR, TIDY_SHARED_LIBADD)
PHP_ADD_INCLUDE($TIDY_INCDIR)
- PHP_CHECK_LIBRARY(tidy,tidyOptGetDoc,
+ PHP_CHECK_LIBRARY(tidyp,tidyOptGetDoc,
[
AC_DEFINE(HAVE_TIDYOPTGETDOC,1,[ ])
],[],[])

View File

@ -1,12 +0,0 @@
$OpenBSD: patch-ext_tidy_tidy_c,v 1.1 2014/11/15 13:43:01 robert Exp $
--- ext/tidy/tidy.c.orig.port Wed Jul 3 08:10:53 2013
+++ ext/tidy/tidy.c Sat Jul 27 18:39:50 2013
@@ -30,7 +30,7 @@
#include "php_ini.h"
#include "ext/standard/info.h"
-#include "tidy.h"
+#include "tidyp.h"
#include "buffio.h"
/* compatibility with older versions of libtidy */

View File

@ -1,12 +0,0 @@
$OpenBSD: patch-ext_xmlrpc_libxmlrpc_encodings_c,v 1.1 2014/11/15 13:43:01 robert Exp $
--- ext/xmlrpc/libxmlrpc/encodings.c.orig.port Wed Sep 26 16:44:16 2007
+++ ext/xmlrpc/libxmlrpc/encodings.c Sat Jun 18 12:14:51 2011
@@ -78,7 +78,7 @@ static char* convert(const char* src, int src_len, int
if(outbuf) {
out_ptr = (char*)outbuf;
while(inlenleft) {
- st = iconv(ic, (char**)&src, &inlenleft, &out_ptr, &outlenleft);
+ st = iconv(ic, (const char**)&src, &inlenleft, &out_ptr, &outlenleft);
if(st == -1) {
if(errno == E2BIG) {
int diff = out_ptr - outbuf;

View File

@ -1,13 +0,0 @@
$OpenBSD: patch-main_php_h,v 1.1 2014/11/15 13:43:01 robert Exp $
--- main/php.h.orig.port Wed Nov 12 14:52:21 2014
+++ main/php.h Sat Nov 15 10:45:12 2014
@@ -146,7 +146,9 @@ END_EXTERN_C()
# if PHP_WIN32
typedef int socklen_t;
# else
+# if !defined(__OpenBSD__)
typedef unsigned int socklen_t;
+# endif
# endif
#endif

View File

@ -1,12 +0,0 @@
$OpenBSD: patch-main_php_ini_c,v 1.4 2017/01/22 17:00:33 martijn Exp $
--- main/php_ini.c.orig.port Thu Jan 19 01:17:47 2017
+++ main/php_ini.c Fri Jan 20 07:35:15 2017
@@ -576,7 +576,7 @@ int php_init_config(TSRMLS_D)
/* If still no ini file found, search for php.ini file in search path */
if (!fh.handle.fp) {
- fh.handle.fp = php_fopen_with_path("php.ini", "r", php_ini_search_path, &php_ini_opened_path TSRMLS_CC);
+ fh.handle.fp = php_fopen_with_path("php-${PV}.ini", "r", php_ini_search_path, &php_ini_opened_path TSRMLS_CC);
if (fh.handle.fp) {
fh.filename = php_ini_opened_path;
}

View File

@ -1,33 +0,0 @@
$OpenBSD: patch-main_streams_php_stream_transport_h,v 1.1 2015/10/22 13:04:56 sthen Exp $
Real world apps and PHP source code (e.g. SOAP, mysqlnd) just use
STREAM_CRYPTO_METHOD_TLS_CLIENT expecting this to give them "the best
TLS version". Allow this to do what they expect.
Remove useless STREAM_CRYPTO_METHOD_TLS_ANY_* which aren't used anywhere
or exported to the parser.
--- main/streams/php_stream_transport.h.orig.port Wed Oct 21 18:00:04 2015
+++ main/streams/php_stream_transport.h Wed Oct 21 19:40:01 2015
@@ -174,9 +174,7 @@ typedef enum {
STREAM_CRYPTO_METHOD_TLSv1_0_CLIENT = (1 << 3 | 1),
STREAM_CRYPTO_METHOD_TLSv1_1_CLIENT = (1 << 4 | 1),
STREAM_CRYPTO_METHOD_TLSv1_2_CLIENT = (1 << 5 | 1),
- /* tls now equates only to the specific TLSv1 method for BC with pre-5.6 */
- STREAM_CRYPTO_METHOD_TLS_CLIENT = (1 << 3 | 1),
- STREAM_CRYPTO_METHOD_TLS_ANY_CLIENT = ((1 << 3) | (1 << 4) | (1 << 5) | 1),
+ STREAM_CRYPTO_METHOD_TLS_CLIENT = ((1 << 3) | (1 << 4) | (1 << 5) | 1),
STREAM_CRYPTO_METHOD_ANY_CLIENT = ((1 << 1) | (1 << 2) | (1 << 3) | (1 << 4) | (1 << 5) | 1),
STREAM_CRYPTO_METHOD_SSLv2_SERVER = (1 << 1),
STREAM_CRYPTO_METHOD_SSLv3_SERVER = (1 << 2),
@@ -185,9 +183,7 @@ typedef enum {
STREAM_CRYPTO_METHOD_TLSv1_0_SERVER = (1 << 3),
STREAM_CRYPTO_METHOD_TLSv1_1_SERVER = (1 << 4),
STREAM_CRYPTO_METHOD_TLSv1_2_SERVER = (1 << 5),
- /* tls equates only to the specific TLSv1 method for BC with pre-5.6 */
- STREAM_CRYPTO_METHOD_TLS_SERVER = (1 << 3),
- STREAM_CRYPTO_METHOD_TLS_ANY_SERVER = ((1 << 3) | (1 << 4) | (1 << 5)),
+ STREAM_CRYPTO_METHOD_TLS_SERVER = ((1 << 3) | (1 << 4) | (1 << 5)),
STREAM_CRYPTO_METHOD_ANY_SERVER = ((1 << 1) | (1 << 2) | (1 << 3) | (1 << 4) | (1 << 5))
} php_stream_xport_crypt_method_t;

View File

@ -1,59 +0,0 @@
$OpenBSD: patch-php_ini-development,v 1.7 2016/12/19 20:35:09 martijn Exp $
--- php.ini-development.orig.port Wed Nov 9 02:22:57 2016
+++ php.ini-development Thu Dec 8 10:55:27 2016
@@ -706,11 +706,8 @@ default_charset = "UTF-8"
;;;;;;;;;;;;;;;;;;;;;;;;;
; UNIX: "/path1:/path2"
-;include_path = ".:/php/includes"
+include_path = ".:OPENBSD_INCLUDE_PATH"
;
-; Windows: "\path1;\path2"
-;include_path = ".;c:\php\includes"
-;
; PHP's default setting for include_path is ".;/path/to/php/pear"
; http://php.net/include-path
@@ -732,6 +729,7 @@ user_dir =
; extension_dir = "./"
; On windows:
; extension_dir = "ext"
+extension_dir = "MODULES_DIR"
; Directory where the temporary files should be placed.
; Defaults to the system default (see sys_get_temp_dir)
@@ -828,7 +826,7 @@ max_file_uploads = 20
; Whether to allow the treatment of URLs (like http:// or ftp://) as files.
; http://php.net/allow-url-fopen
-allow_url_fopen = On
+allow_url_fopen = Off
; Whether to allow include/require to open URLs (like http:// or ftp://) as files.
; http://php.net/allow-url-include
@@ -933,7 +931,7 @@ cli_server.color = On
[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
-;date.timezone =
+date.timezone = UTC
; http://php.net/date.default-latitude
;date.default_latitude = 31.7667
@@ -1022,16 +1020,6 @@ pdo_mysql.default_socket=
;phar.cache_list =
[mail function]
-; For Win32 only.
-; http://php.net/smtp
-SMTP = localhost
-; http://php.net/smtp-port
-smtp_port = 25
-
-; For Win32 only.
-; http://php.net/sendmail-from
-;sendmail_from = me@example.com
-
; For Unix only. You may supply arguments as well (default: "sendmail -t -i").
; http://php.net/sendmail-path
;sendmail_path =

View File

@ -1,42 +0,0 @@
$OpenBSD: patch-php_ini-production,v 1.6 2016/12/19 20:35:09 martijn Exp $
--- php.ini-production.orig.port Wed Nov 9 02:22:57 2016
+++ php.ini-production Thu Dec 8 10:55:27 2016
@@ -706,11 +706,8 @@ default_charset = "UTF-8"
;;;;;;;;;;;;;;;;;;;;;;;;;
; UNIX: "/path1:/path2"
-;include_path = ".:/php/includes"
+include_path = ".:OPENBSD_INCLUDE_PATH"
;
-; Windows: "\path1;\path2"
-;include_path = ".;c:\php\includes"
-;
; PHP's default setting for include_path is ".;/path/to/php/pear"
; http://php.net/include-path
@@ -732,6 +729,7 @@ user_dir =
; extension_dir = "./"
; On windows:
; extension_dir = "ext"
+extension_dir = "MODULES_DIR"
; Directory where the temporary files should be placed.
; Defaults to the system default (see sys_get_temp_dir)
@@ -828,7 +826,7 @@ max_file_uploads = 20
; Whether to allow the treatment of URLs (like http:// or ftp://) as files.
; http://php.net/allow-url-fopen
-allow_url_fopen = On
+allow_url_fopen = Off
; Whether to allow include/require to open URLs (like http:// or ftp://) as files.
; http://php.net/allow-url-include
@@ -933,7 +931,7 @@ cli_server.color = On
[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
-;date.timezone =
+date.timezone = UTC
; http://php.net/date.default-latitude
;date.default_latitude = 31.7667

View File

@ -1,23 +0,0 @@
$OpenBSD: patch-sapi_apache_mod_php5_c,v 1.1 2014/11/15 13:43:01 robert Exp $
--- sapi/apache/mod_php5.c.orig.port Wed Jul 3 08:10:53 2013
+++ sapi/apache/mod_php5.c Sat Jul 27 18:39:50 2013
@@ -952,12 +952,19 @@ static void php_child_exit_handler(server_rec *s, pool
*/
static void php_init_handler(server_rec *s, pool *p)
{
+ char *ini;
+
register_cleanup(p, NULL, (void (*)(void *))apache_php_module_shutdown_wrapper, (void (*)(void *))php_module_shutdown_for_exec);
if (!apache_php_initialized) {
apache_php_initialized = 1;
#ifdef ZTS
tsrm_startup(1, 1, 0, NULL);
#endif
+
+ if ((ini = getenv("PHP_INI_PATH"))) {
+ apache_sapi_module.php_ini_path_override = ini;
+ }
+
sapi_startup(&apache_sapi_module);
php_apache_startup(&apache_sapi_module);
}

View File

@ -1,25 +0,0 @@
$OpenBSD: patch-sapi_cgi_cgi_main_c,v 1.6 2016/12/19 20:35:09 martijn Exp $
--- sapi/cgi/cgi_main.c.orig.port Wed Nov 9 02:22:57 2016
+++ sapi/cgi/cgi_main.c Thu Dec 8 10:55:27 2016
@@ -1749,6 +1749,7 @@ int main(int argc, char *argv[])
char *orig_optarg = php_optarg;
char *script_file = NULL;
int ini_entries_len = 0;
+ char *ini;
/* end of temporary locals */
#ifdef ZTS
@@ -1809,7 +1810,12 @@ int main(int argc, char *argv[])
sapi_startup(&cgi_sapi_module);
fastcgi = fcgi_is_fastcgi();
- cgi_sapi_module.php_ini_path_override = NULL;
+
+ if ((ini = getenv("PHP_INI_PATH"))) {
+ cgi_sapi_module.php_ini_path_override = ini;
+ } else {
+ cgi_sapi_module.php_ini_path_override = NULL;
+ }
#ifdef PHP_WIN32
_fmode = _O_BINARY; /* sets default for file streams to binary */

View File

@ -1,11 +0,0 @@
$OpenBSD: patch-sapi_cli_php_cli_c,v 1.2 2016/12/19 20:35:09 martijn Exp $
--- sapi/cli/php_cli.c.orig.port Wed Nov 9 02:22:57 2016
+++ sapi/cli/php_cli.c Thu Dec 8 10:55:27 2016
@@ -677,6 +677,7 @@ static int do_cli(int argc, char **argv TSRMLS_DC) /*
int lineno = 0;
const char *param_error=NULL;
int hide_argv = 0;
+ char *ini;
zend_try {

View File

@ -1,103 +0,0 @@
$OpenBSD: patch-sapi_fpm_fpm_fpm_atomic_h,v 1.1 2014/11/15 13:43:01 robert Exp $
Add support for mips
Fix types for sparc64
--- sapi/fpm/fpm/fpm_atomic.h.orig.port Wed Nov 21 20:07:23 2012
+++ sapi/fpm/fpm/fpm_atomic.h Fri Nov 23 15:40:43 2012
@@ -77,10 +77,10 @@ static inline atomic_uint_t atomic_cmp_set(atomic_t *l
}
/* }}} */
-#if (__GNUC__) && (__GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 2))
-
#elif ( __arm__ || __arm ) /* W-Mark Kubacki */
+#if (__GNUC__) && (__GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 2))
+
#if (__arch64__ || __arch64)
typedef int64_t atomic_int_t;
typedef uint64_t atomic_uint_t;
@@ -101,7 +101,7 @@ typedef uint32_t atomic_uint_t;
typedef uint64_t atomic_uint_t;
typedef volatile atomic_uint_t atomic_t;
-static inline int atomic_cas_64(atomic_t *lock, atomic_uint_t old, atomic_uint_t new) /* {{{ */
+static inline atomic_uint_t atomic_cas_64(atomic_t *lock, atomic_uint_t old, atomic_uint_t new) /* {{{ */
{
__asm__ __volatile__("casx [%2], %3, %0 " : "=&r"(new) : "0"(new), "r"(lock), "r"(old): "memory");
@@ -118,7 +118,7 @@ static inline atomic_uint_t atomic_cmp_set(atomic_t *l
typedef uint32_t atomic_uint_t;
typedef volatile atomic_uint_t atomic_t;
-static inline int atomic_cas_32(atomic_t *lock, atomic_uint_t old, atomic_uint_t new) /* {{{ */
+static inline atomic_uint_t atomic_cas_32(atomic_t *lock, atomic_uint_t old, atomic_uint_t new) /* {{{ */
{
__asm__ __volatile__("cas [%2], %3, %0 " : "=&r"(new) : "0"(new), "r"(lock), "r"(old): "memory");
@@ -136,6 +136,64 @@ static inline atomic_uint_t atomic_cmp_set(atomic_t *l
#else /* #if (__sparcv9 || __sparcv9__) */
#error Sparc v8 and predecessors are not and will not be supported (see bug report 53310)
#endif /* #if (__sparcv9 || __sparcv9__) */
+
+#elif ( __mips__ || __mips64__ )
+
+#if (__LP64__ || _LP64)
+typedef uint64_t atomic_uint_t;
+typedef volatile atomic_uint_t atomic_t;
+
+static inline atomic_uint_t atomic_cas_64(atomic_t *lock, atomic_uint_t old, atomic_uint_t new) /* {{{ */
+{
+ atomic_uint_t v;
+
+ __asm__ __volatile__ (
+ "\t.set\tnoreorder\n"
+ "\tlld\t%0, 0(%1)\n"
+ "\tbne\t%0, %2, 1f\n"
+ "\tnop\n"
+ "\tscd\t%3, 0(%1)\n"
+ "1:\n"
+ "\t.set\treorder\n" :
+ "=r" (v) : "r" (lock), "r" (old), "r" (new) : "memory");
+
+ return v;
+}
+/* }}} */
+
+static inline atomic_uint_t atomic_cmp_set(atomic_t *lock, atomic_uint_t old, atomic_uint_t set) /* {{{ */
+{
+ return (atomic_cas_64(lock, old, set)==old);
+}
+/* }}} */
+#else
+typedef uint32_t atomic_uint_t;
+typedef volatile atomic_uint_t atomic_t;
+
+static inline atomic_uint_t atomic_cas_32(atomic_t *lock, atomic_uint_t old, atomic_uint_t new) /* {{{ */
+{
+ atomic_uint_t v;
+
+ __asm__ __volatile__ (
+ "\t.set\tnoreorder\n"
+ "\tll\t%0, 0(%1)\n"
+ "\tbne\t%0, %2, 1f\n"
+ "\tnop\n"
+ "\tsc\t%3, 0(%1)\n"
+ "1:\n"
+ "\t.set\treorder\n" :
+ "=r" (v) : "r" (lock), "r" (old), "r" (new) : "memory");
+
+ return v;
+}
+/* }}} */
+
+static inline atomic_uint_t atomic_cmp_set(atomic_t *lock, atomic_uint_t old, atomic_uint_t set) /* {{{ */
+{
+ return (atomic_cas_32(lock, old, set)==old);
+}
+/* }}} */
+#endif
#else

View File

@ -1,35 +0,0 @@
$OpenBSD: patch-sapi_fpm_php-fpm_conf_in,v 1.4 2018/04/24 15:26:58 sthen Exp $
Index: sapi/fpm/php-fpm.conf.in
--- sapi/fpm/php-fpm.conf.in.orig
+++ sapi/fpm/php-fpm.conf.in
@@ -161,7 +161,7 @@ group = @php_fpm_group@
; (IPv6 and IPv4-mapped) on a specific port;
; '/path/to/unix/socket' - to listen on a unix socket.
; Note: This value is mandatory.
-listen = 127.0.0.1:9000
+listen = /var/www/run/php-fpm.sock
; Set listen(2) backlog.
; Default Value: 65535 (-1 on FreeBSD and OpenBSD)
@@ -172,9 +172,9 @@ listen = 127.0.0.1:9000
; BSD-derived systems allow connections regardless of permissions.
; Default Values: user and group are set as the running user
; mode is set to 0660
-;listen.owner = @php_fpm_user@
-;listen.group = @php_fpm_group@
-;listen.mode = 0660
+listen.owner = www
+listen.group = www
+listen.mode = 0660
; When POSIX Access Control Lists are supported you can set them using
; these options, value is a comma separated list of user/group names.
; When set, listen.owner and listen.group are ignored
@@ -477,7 +477,7 @@ pm.max_spare_servers = 3
; possible. However, all PHP paths will be relative to the chroot
; (error_log, sessions.save_path, ...).
; Default Value: not set
-;chroot =
+chroot = /var/www
; Chdir to this directory at the start.
; Note: relative path can be used.

View File

@ -1,14 +0,0 @@
$OpenBSD: patch-sapi_phpdbg_phpdbg_h,v 1.1 2018/05/27 20:05:30 martijn Exp $
Index: sapi/phpdbg/phpdbg.h
--- sapi/phpdbg/phpdbg.h.orig
+++ sapi/phpdbg/phpdbg.h
@@ -64,7 +64,7 @@
# include "TSRM.h"
#endif
-#ifdef LIBREADLINE
+#ifdef HAVE_LIBREADLINE
# include <readline/readline.h>
# include <readline/history.h>
#endif

View File

@ -1,14 +0,0 @@
$OpenBSD: patch-scripts_Makefile_frag,v 1.1 2014/11/15 13:43:01 robert Exp $
--- scripts/Makefile.frag.orig.port Tue Jul 13 18:24:13 2010
+++ scripts/Makefile.frag Sat Jun 18 12:14:54 2011
@@ -3,8 +3,8 @@
# Build environment install
#
-phpincludedir = $(includedir)/php
-phpbuilddir = $(libdir)/build
+phpincludedir = $(peardir)/include
+phpbuilddir = $(peardir)/build
BUILD_FILES = \
scripts/phpize.m4 \

View File

@ -1,31 +0,0 @@
$OpenBSD: patch-scripts_php-config_in,v 1.1 2014/11/15 13:43:01 robert Exp $
--- scripts/php-config.in.orig.port Thu Jul 18 16:37:33 2013
+++ scripts/php-config.in Sun Jul 28 11:30:20 2013
@@ -1,12 +1,12 @@
#! /bin/sh
SED="@SED@"
-prefix="@prefix@"
+prefix='/var/www/pear'
datarootdir="@datarootdir@"
exec_prefix="@exec_prefix@"
version="@PHP_VERSION@"
vernum="@PHP_VERSION_ID@"
-include_dir="@includedir@/php"
+include_dir="@PEAR_INSTALLDIR@/include"
includes="-I$include_dir -I$include_dir/main -I$include_dir/TSRM -I$include_dir/Zend -I$include_dir/ext -I$include_dir/ext/date/lib"
ldflags="@PHP_LDFLAGS@"
libs="@EXTRA_LIBS@"
@@ -24,10 +24,11 @@ php_sapis="@PHP_INSTALLED_SAPIS@"
for sapi in $php_sapis; do
case $sapi in
cli)
- php_cli_binary="@bindir@/${program_prefix}php${program_suffix}${exe_extension}"
+ php_cli_binary="/usr/local/bin/php${program_suffix}"
;;
cgi)
php_cgi_binary="@bindir@/${program_prefix}php-cgi${program_suffix}${exe_extension}"
+ php_cgi_binary="/usr/local/bin/php-cgi${program_suffix}"
;;
esac
done

View File

@ -1,18 +0,0 @@
$OpenBSD: patch-scripts_phpize_in,v 1.1 2014/11/15 13:43:01 robert Exp $
--- scripts/phpize.in.orig.port Sat Jul 27 18:47:01 2013
+++ scripts/phpize.in Sat Jul 27 18:47:19 2013
@@ -1,11 +1,11 @@
#!/bin/sh
# Variable declaration
-prefix='@prefix@'
+prefix=@PEAR_INSTALLDIR@
datarootdir='@datarootdir@'
exec_prefix="`eval echo @exec_prefix@`"
-phpdir="`eval echo @libdir@`/build"
-includedir="`eval echo @includedir@`/php"
+phpdir="$prefix/build"
+includedir="$prefix/include"
builddir="`pwd`"
SED="@SED@"

View File

@ -1,30 +0,0 @@
$OpenBSD: suhosin-ext_suhosin_execute_c,v 1.1 2016/06/22 21:18:33 sthen Exp $
--- ext/suhosin/execute.c.orig.port Mon Feb 1 23:04:02 2016
+++ ext/suhosin/execute.c Mon Feb 1 23:38:49 2016
@@ -1312,6 +1312,9 @@ static php_uint32 suhosin_mt_rand(TSRMLS_D)
*/
static void suhosin_gen_entropy(php_uint32 *entropybuf TSRMLS_DC)
{
+#if defined(__OpenBSD__)
+ arc4random_buf(entropybuf, 8 * sizeof(php_uint32));
+#else
php_uint32 seedbuf[20];
/* On a modern OS code, stack and heap base are randomized */
unsigned long code_value = (unsigned long)suhosin_gen_entropy;
@@ -1335,7 +1338,7 @@ static void suhosin_gen_entropy(php_uint32 *entropybuf
#endif
seedbuf[5] = (php_uint32) 0x7fffffff * php_combined_lcg(TSRMLS_C);
-#ifndef PHP_WIN32
+#if !defined(PHP_WIN32)
fd = VCWD_OPEN("/dev/urandom", O_RDONLY);
if (fd >= 0) {
/* ignore error case - if urandom doesn't give us any/enough random bytes */
@@ -1354,6 +1357,7 @@ static void suhosin_gen_entropy(php_uint32 *entropybuf
suhosin_SHA256Update(&context, (unsigned char*)SUHOSIN_G(seedingkey), strlen(SUHOSIN_G(seedingkey)));
}
suhosin_SHA256Final((void *)entropybuf, &context);
+#endif /* openbsd */
}
/* }}} */

View File

@ -1,9 +0,0 @@
@comment $OpenBSD: PLIST-apache,v 1.3 2018/10/17 12:44:02 sthen Exp $
@option no-default-conflict
@option is-branch
@conflict php->=5.6,<=5.6.36p8
@conflict php-apache->=5.6,<5.7
lib/php-${PV}/libphp5.so
@sample ${MODPHP_CONFIG_PATH}/modules.sample/
share/examples/php-${PV}/modphp.conf
@sample ${MODPHP_CONFIG_PATH}/modules.sample/php-${PV}.conf

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-bz2,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-bz2->=5.6,<5.7
@conflict php5-bz2->=5.2
lib/php-${PV}/modules/bz2.so
share/examples/php-${PV}/bz2.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/bz2.ini

View File

@ -1,7 +0,0 @@
@comment $OpenBSD: PLIST-cgi,v 1.2 2018/05/25 13:59:19 sthen Exp $
@option no-default-conflict
@option is-branch
@conflict php-cgi->=5.6,<5.7
@pkgpath lang/php/5.6,-fastcgi
@bin bin/php-cgi-${PV}
@man man/man1/php-cgi-${PV}.1

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-curl,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-curl->=5.6,<5.7
@conflict php5-curl->=5.2
lib/php-${PV}/modules/curl.so
share/examples/php-${PV}/curl.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/curl.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-dba,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-dba->=5.6,<5.7
@conflict php5-dba->=5.2
lib/php-${PV}/modules/dba.so
share/examples/php-${PV}/dba.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/dba.ini

View File

@ -1,6 +0,0 @@
@comment $OpenBSD: PLIST-dbg,v 1.1 2018/05/27 20:05:30 martijn Exp $
@option no-default-conflict
@option is-branch
@conflict php-dbg->=5.6,<5.7
@bin bin/phpdbg-${PV}
@man man/man1/phpdbg-${PV}.1

View File

@ -1,27 +0,0 @@
@comment $OpenBSD: PLIST-gd,v 1.3 2018/06/15 10:20:53 sthen Exp $
@option no-default-conflict
@option is-branch
@conflict php-gd->=5.6,<5.7
@conflict php5-gd->=5.2
@conflict php-<=5.6.36p9
lib/php-${PV}/modules/gd.so
share/examples/php-${PV}/gd.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/gd.ini
share/php-${PV}/include/ext/gd/
share/php-${PV}/include/ext/gd/gd_compat.h
share/php-${PV}/include/ext/gd/gdcache.h
share/php-${PV}/include/ext/gd/libgd/
share/php-${PV}/include/ext/gd/libgd/gd.h
share/php-${PV}/include/ext/gd/libgd/gd_intern.h
share/php-${PV}/include/ext/gd/libgd/gd_io.h
share/php-${PV}/include/ext/gd/libgd/gdcache.h
share/php-${PV}/include/ext/gd/libgd/gdfontg.h
share/php-${PV}/include/ext/gd/libgd/gdfontl.h
share/php-${PV}/include/ext/gd/libgd/gdfontmb.h
share/php-${PV}/include/ext/gd/libgd/gdfonts.h
share/php-${PV}/include/ext/gd/libgd/gdfontt.h
share/php-${PV}/include/ext/gd/libgd/gdhelpers.h
share/php-${PV}/include/ext/gd/libgd/jisx0208.h
share/php-${PV}/include/ext/gd/libgd/wbmp.h
share/php-${PV}/include/ext/gd/libgd/webpimg.h
share/php-${PV}/include/ext/gd/php_gd.h

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-gmp,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-gmp->=5.6,<5.7
@conflict php5-gmp->=5.2
lib/php-${PV}/modules/gmp.so
share/examples/php-${PV}/gmp.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/gmp.ini

View File

@ -1,10 +0,0 @@
@comment $OpenBSD: PLIST-imap,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-imap->=5.6,<5.7
@conflict php5-imap->=5.2
lib/php-${PV}/modules/imap.so
share/examples/php-${PV}/imap.ini
@comment etc/master.passwd
@comment etc/spwd.db
@sample ${SYSCONFDIR}/php-${PV}.sample/imap.ini

View File

@ -1,7 +0,0 @@
@comment $OpenBSD: PLIST-intl,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-intl->=5.6,<5.7
lib/php-${PV}/modules/intl.so
share/examples/php-${PV}/intl.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/intl.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-ldap,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-ldap->=5.6,<5.7
@conflict php5-ldap->=5.2
lib/php-${PV}/modules/ldap.so
share/examples/php-${PV}/ldap.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/ldap.ini

View File

@ -1,368 +0,0 @@
@comment $OpenBSD: PLIST-main,v 1.22 2018/09/04 12:46:14 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php->=5.6,<5.7
@conflict php-fpm->=5.6,<5.7
@conflict php5-core->=5.2
@conflict php5-core-fastcgi->=5.2
@pkgpath lang/php/5.4
@pkgpath lang/php/5.6,-fpm
@pkgpath lang/php/5.6,-main,ap2
@extraunexec rm -f ${SYSCONFDIR}/php-${PV}/php-${PV}.sample/*
@mode 1700
@owner www
@group www
@sample /var/www/tmp/
@mode
@owner
@group
@rcscript ${RCDIR}/php${SV}_fpm
bin/phar-${PV}
@bin bin/php-${PV}
bin/php-config-${PV}
bin/phpize-${PV}
lib/php-${PV}/
lib/php-${PV}/modules/
lib/php-${PV}/modules/opcache.so
@man man/man1/phar-${PV}.1
@man man/man1/php-${PV}.1
@man man/man1/php-config-${PV}.1
@man man/man1/phpize-${PV}.1
@man man/man8/php-fpm-${PV}.8
@bin sbin/php-fpm-${PV}
share/doc/pkg-readmes/${PKGSTEM}
share/examples/php-${PV}/
@sample ${SYSCONFDIR}/php-${PV}.sample/
share/examples/php-${PV}/opcache.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/opcache.ini
share/examples/php-${PV}/php-fpm.conf
@sample ${SYSCONFDIR}/php-fpm.conf
share/examples/php-${PV}/php.ini-development
share/examples/php-${PV}/php.ini-production
@sample ${SYSCONFDIR}/php-${PV}.ini
share/php-${PV}/
share/php-${PV}/build/
share/php-${PV}/build/Makefile.global
share/php-${PV}/build/acinclude.m4
share/php-${PV}/build/config.guess
share/php-${PV}/build/config.sub
share/php-${PV}/build/libtool.m4
share/php-${PV}/build/ltmain.sh
share/php-${PV}/build/mkdep.awk
share/php-${PV}/build/phpize.m4
share/php-${PV}/build/run-tests.php
share/php-${PV}/build/scan_makefile_in.awk
share/php-${PV}/build/shtool
share/php-${PV}/include/
share/php-${PV}/include/TSRM/
share/php-${PV}/include/TSRM/TSRM.h
share/php-${PV}/include/TSRM/readdir.h
share/php-${PV}/include/TSRM/tsrm_config.h
share/php-${PV}/include/TSRM/tsrm_config.w32.h
share/php-${PV}/include/TSRM/tsrm_config_common.h
share/php-${PV}/include/TSRM/tsrm_nw.h
share/php-${PV}/include/TSRM/tsrm_strtok_r.h
share/php-${PV}/include/TSRM/tsrm_win32.h
share/php-${PV}/include/Zend/
share/php-${PV}/include/Zend/zend.h
share/php-${PV}/include/Zend/zend_API.h
share/php-${PV}/include/Zend/zend_alloc.h
share/php-${PV}/include/Zend/zend_ast.h
share/php-${PV}/include/Zend/zend_build.h
share/php-${PV}/include/Zend/zend_builtin_functions.h
share/php-${PV}/include/Zend/zend_closures.h
share/php-${PV}/include/Zend/zend_compile.h
share/php-${PV}/include/Zend/zend_config.h
share/php-${PV}/include/Zend/zend_config.nw.h
share/php-${PV}/include/Zend/zend_config.w32.h
share/php-${PV}/include/Zend/zend_constants.h
share/php-${PV}/include/Zend/zend_dtrace.h
share/php-${PV}/include/Zend/zend_dynamic_array.h
share/php-${PV}/include/Zend/zend_errors.h
share/php-${PV}/include/Zend/zend_exceptions.h
share/php-${PV}/include/Zend/zend_execute.h
share/php-${PV}/include/Zend/zend_extensions.h
share/php-${PV}/include/Zend/zend_float.h
share/php-${PV}/include/Zend/zend_gc.h
share/php-${PV}/include/Zend/zend_generators.h
share/php-${PV}/include/Zend/zend_globals.h
share/php-${PV}/include/Zend/zend_globals_macros.h
share/php-${PV}/include/Zend/zend_hash.h
share/php-${PV}/include/Zend/zend_highlight.h
share/php-${PV}/include/Zend/zend_indent.h
share/php-${PV}/include/Zend/zend_ini.h
share/php-${PV}/include/Zend/zend_ini_parser.h
share/php-${PV}/include/Zend/zend_ini_scanner.h
share/php-${PV}/include/Zend/zend_ini_scanner_defs.h
share/php-${PV}/include/Zend/zend_interfaces.h
share/php-${PV}/include/Zend/zend_istdiostream.h
share/php-${PV}/include/Zend/zend_iterators.h
share/php-${PV}/include/Zend/zend_language_parser.h
share/php-${PV}/include/Zend/zend_language_scanner.h
share/php-${PV}/include/Zend/zend_language_scanner_defs.h
share/php-${PV}/include/Zend/zend_list.h
share/php-${PV}/include/Zend/zend_llist.h
share/php-${PV}/include/Zend/zend_modules.h
share/php-${PV}/include/Zend/zend_multibyte.h
share/php-${PV}/include/Zend/zend_multiply.h
share/php-${PV}/include/Zend/zend_object_handlers.h
share/php-${PV}/include/Zend/zend_objects.h
share/php-${PV}/include/Zend/zend_objects_API.h
share/php-${PV}/include/Zend/zend_operators.h
share/php-${PV}/include/Zend/zend_ptr_stack.h
share/php-${PV}/include/Zend/zend_qsort.h
share/php-${PV}/include/Zend/zend_signal.h
share/php-${PV}/include/Zend/zend_stack.h
share/php-${PV}/include/Zend/zend_static_allocator.h
share/php-${PV}/include/Zend/zend_stream.h
share/php-${PV}/include/Zend/zend_string.h
share/php-${PV}/include/Zend/zend_strtod.h
share/php-${PV}/include/Zend/zend_ts_hash.h
share/php-${PV}/include/Zend/zend_types.h
share/php-${PV}/include/Zend/zend_variables.h
share/php-${PV}/include/Zend/zend_virtual_cwd.h
share/php-${PV}/include/Zend/zend_vm.h
share/php-${PV}/include/Zend/zend_vm_def.h
share/php-${PV}/include/Zend/zend_vm_execute.h
share/php-${PV}/include/Zend/zend_vm_opcodes.h
share/php-${PV}/include/ext/
share/php-${PV}/include/ext/date/
share/php-${PV}/include/ext/date/lib/
share/php-${PV}/include/ext/date/lib/timelib.h
share/php-${PV}/include/ext/date/lib/timelib_config.h
share/php-${PV}/include/ext/date/lib/timelib_structs.h
share/php-${PV}/include/ext/date/php_date.h
share/php-${PV}/include/ext/dom/
share/php-${PV}/include/ext/dom/xml_common.h
share/php-${PV}/include/ext/ereg/
share/php-${PV}/include/ext/ereg/php_ereg.h
share/php-${PV}/include/ext/ereg/php_regex.h
share/php-${PV}/include/ext/ereg/regex/
share/php-${PV}/include/ext/ereg/regex/cclass.h
share/php-${PV}/include/ext/ereg/regex/cname.h
share/php-${PV}/include/ext/ereg/regex/regex.h
share/php-${PV}/include/ext/ereg/regex/regex2.h
share/php-${PV}/include/ext/ereg/regex/utils.h
share/php-${PV}/include/ext/filter/
share/php-${PV}/include/ext/filter/php_filter.h
share/php-${PV}/include/ext/hash/
share/php-${PV}/include/ext/hash/php_hash.h
share/php-${PV}/include/ext/hash/php_hash_adler32.h
share/php-${PV}/include/ext/hash/php_hash_crc32.h
share/php-${PV}/include/ext/hash/php_hash_fnv.h
share/php-${PV}/include/ext/hash/php_hash_gost.h
share/php-${PV}/include/ext/hash/php_hash_haval.h
share/php-${PV}/include/ext/hash/php_hash_joaat.h
share/php-${PV}/include/ext/hash/php_hash_md.h
share/php-${PV}/include/ext/hash/php_hash_ripemd.h
share/php-${PV}/include/ext/hash/php_hash_sha.h
share/php-${PV}/include/ext/hash/php_hash_snefru.h
share/php-${PV}/include/ext/hash/php_hash_tiger.h
share/php-${PV}/include/ext/hash/php_hash_whirlpool.h
share/php-${PV}/include/ext/iconv/
share/php-${PV}/include/ext/iconv/php_have_bsd_iconv.h
share/php-${PV}/include/ext/iconv/php_have_glibc_iconv.h
share/php-${PV}/include/ext/iconv/php_have_ibm_iconv.h
share/php-${PV}/include/ext/iconv/php_have_iconv.h
share/php-${PV}/include/ext/iconv/php_have_libiconv.h
share/php-${PV}/include/ext/iconv/php_iconv.h
share/php-${PV}/include/ext/iconv/php_iconv_aliased_libiconv.h
share/php-${PV}/include/ext/iconv/php_iconv_broken_ignore.h
share/php-${PV}/include/ext/iconv/php_iconv_supports_errno.h
share/php-${PV}/include/ext/iconv/php_php_iconv_h_path.h
share/php-${PV}/include/ext/iconv/php_php_iconv_impl.h
share/php-${PV}/include/ext/json/
share/php-${PV}/include/ext/json/php_json.h
share/php-${PV}/include/ext/libxml/
share/php-${PV}/include/ext/libxml/php_libxml.h
share/php-${PV}/include/ext/mbstring/
share/php-${PV}/include/ext/mbstring/libmbfl/
share/php-${PV}/include/ext/mbstring/libmbfl/config.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/eaw_table.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfilter.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfilter_8bit.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfilter_pass.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfilter_wchar.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_allocators.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_consts.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_convert.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_defs.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_encoding.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_filter_output.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_ident.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_language.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_memory_device.h
share/php-${PV}/include/ext/mbstring/libmbfl/mbfl/mbfl_string.h
share/php-${PV}/include/ext/mbstring/mbstring.h
share/php-${PV}/include/ext/mbstring/php_mbregex.h
share/php-${PV}/include/ext/mbstring/php_onig_compat.h
share/php-${PV}/include/ext/mysqli/
share/php-${PV}/include/ext/mysqli/mysqli_mysqlnd.h
share/php-${PV}/include/ext/mysqli/php_mysqli_structs.h
share/php-${PV}/include/ext/mysqlnd/
share/php-${PV}/include/ext/mysqlnd/config-win.h
share/php-${PV}/include/ext/mysqlnd/mysql_float_to_double.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_alloc.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_block_alloc.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_charset.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_debug.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_enum_n_def.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_ext_plugin.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_libmysql_compat.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_net.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_portability.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_priv.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_result.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_result_meta.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_reverse_api.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_statistics.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_structs.h
share/php-${PV}/include/ext/mysqlnd/mysqlnd_wireprotocol.h
share/php-${PV}/include/ext/mysqlnd/php_mysqlnd.h
share/php-${PV}/include/ext/pcre/
share/php-${PV}/include/ext/pcre/pcrelib/
share/php-${PV}/include/ext/pcre/pcrelib/config.h
share/php-${PV}/include/ext/pcre/pcrelib/pcre.h
share/php-${PV}/include/ext/pcre/pcrelib/pcre_internal.h
share/php-${PV}/include/ext/pcre/pcrelib/pcreposix.h
share/php-${PV}/include/ext/pcre/pcrelib/ucp.h
share/php-${PV}/include/ext/pcre/php_pcre.h
share/php-${PV}/include/ext/pdo/
share/php-${PV}/include/ext/pdo/php_pdo.h
share/php-${PV}/include/ext/pdo/php_pdo_driver.h
share/php-${PV}/include/ext/pdo/php_pdo_error.h
share/php-${PV}/include/ext/phar/
share/php-${PV}/include/ext/phar/php_phar.h
share/php-${PV}/include/ext/session/
share/php-${PV}/include/ext/session/mod_files.h
share/php-${PV}/include/ext/session/mod_user.h
share/php-${PV}/include/ext/session/php_session.h
share/php-${PV}/include/ext/simplexml/
share/php-${PV}/include/ext/simplexml/php_simplexml.h
share/php-${PV}/include/ext/simplexml/php_simplexml_exports.h
share/php-${PV}/include/ext/sockets/
share/php-${PV}/include/ext/sockets/php_sockets.h
share/php-${PV}/include/ext/spl/
share/php-${PV}/include/ext/spl/php_spl.h
share/php-${PV}/include/ext/spl/spl_array.h
share/php-${PV}/include/ext/spl/spl_directory.h
share/php-${PV}/include/ext/spl/spl_dllist.h
share/php-${PV}/include/ext/spl/spl_engine.h
share/php-${PV}/include/ext/spl/spl_exceptions.h
share/php-${PV}/include/ext/spl/spl_fixedarray.h
share/php-${PV}/include/ext/spl/spl_functions.h
share/php-${PV}/include/ext/spl/spl_heap.h
share/php-${PV}/include/ext/spl/spl_iterators.h
share/php-${PV}/include/ext/spl/spl_observer.h
share/php-${PV}/include/ext/standard/
share/php-${PV}/include/ext/standard/base64.h
share/php-${PV}/include/ext/standard/basic_functions.h
share/php-${PV}/include/ext/standard/crc32.h
share/php-${PV}/include/ext/standard/credits.h
share/php-${PV}/include/ext/standard/credits_ext.h
share/php-${PV}/include/ext/standard/credits_sapi.h
share/php-${PV}/include/ext/standard/crypt_blowfish.h
share/php-${PV}/include/ext/standard/crypt_freesec.h
share/php-${PV}/include/ext/standard/css.h
share/php-${PV}/include/ext/standard/cyr_convert.h
share/php-${PV}/include/ext/standard/datetime.h
share/php-${PV}/include/ext/standard/dl.h
share/php-${PV}/include/ext/standard/exec.h
share/php-${PV}/include/ext/standard/file.h
share/php-${PV}/include/ext/standard/flock_compat.h
share/php-${PV}/include/ext/standard/fsock.h
share/php-${PV}/include/ext/standard/head.h
share/php-${PV}/include/ext/standard/html.h
share/php-${PV}/include/ext/standard/html_tables.h
share/php-${PV}/include/ext/standard/info.h
share/php-${PV}/include/ext/standard/md5.h
share/php-${PV}/include/ext/standard/microtime.h
share/php-${PV}/include/ext/standard/pack.h
share/php-${PV}/include/ext/standard/pageinfo.h
share/php-${PV}/include/ext/standard/php_array.h
share/php-${PV}/include/ext/standard/php_assert.h
share/php-${PV}/include/ext/standard/php_browscap.h
share/php-${PV}/include/ext/standard/php_crypt.h
share/php-${PV}/include/ext/standard/php_crypt_r.h
share/php-${PV}/include/ext/standard/php_dir.h
share/php-${PV}/include/ext/standard/php_dns.h
share/php-${PV}/include/ext/standard/php_ext_syslog.h
share/php-${PV}/include/ext/standard/php_filestat.h
share/php-${PV}/include/ext/standard/php_fopen_wrappers.h
share/php-${PV}/include/ext/standard/php_ftok.h
share/php-${PV}/include/ext/standard/php_http.h
share/php-${PV}/include/ext/standard/php_image.h
share/php-${PV}/include/ext/standard/php_incomplete_class.h
share/php-${PV}/include/ext/standard/php_iptc.h
share/php-${PV}/include/ext/standard/php_lcg.h
share/php-${PV}/include/ext/standard/php_link.h
share/php-${PV}/include/ext/standard/php_mail.h
share/php-${PV}/include/ext/standard/php_math.h
share/php-${PV}/include/ext/standard/php_metaphone.h
share/php-${PV}/include/ext/standard/php_password.h
share/php-${PV}/include/ext/standard/php_rand.h
share/php-${PV}/include/ext/standard/php_smart_str.h
share/php-${PV}/include/ext/standard/php_smart_str_public.h
share/php-${PV}/include/ext/standard/php_standard.h
share/php-${PV}/include/ext/standard/php_string.h
share/php-${PV}/include/ext/standard/php_type.h
share/php-${PV}/include/ext/standard/php_uuencode.h
share/php-${PV}/include/ext/standard/php_var.h
share/php-${PV}/include/ext/standard/php_versioning.h
share/php-${PV}/include/ext/standard/proc_open.h
share/php-${PV}/include/ext/standard/quot_print.h
share/php-${PV}/include/ext/standard/scanf.h
share/php-${PV}/include/ext/standard/sha1.h
share/php-${PV}/include/ext/standard/streamsfuncs.h
share/php-${PV}/include/ext/standard/uniqid.h
share/php-${PV}/include/ext/standard/url.h
share/php-${PV}/include/ext/standard/url_scanner_ex.h
share/php-${PV}/include/ext/standard/winver.h
share/php-${PV}/include/ext/xml/
share/php-${PV}/include/ext/xml/expat_compat.h
share/php-${PV}/include/ext/xml/php_xml.h
share/php-${PV}/include/include/
share/php-${PV}/include/main/
share/php-${PV}/include/main/SAPI.h
share/php-${PV}/include/main/build-defs.h
share/php-${PV}/include/main/fopen_wrappers.h
share/php-${PV}/include/main/php.h
share/php-${PV}/include/main/php_compat.h
share/php-${PV}/include/main/php_config.h
share/php-${PV}/include/main/php_content_types.h
share/php-${PV}/include/main/php_getopt.h
share/php-${PV}/include/main/php_globals.h
share/php-${PV}/include/main/php_ini.h
share/php-${PV}/include/main/php_main.h
share/php-${PV}/include/main/php_memory_streams.h
share/php-${PV}/include/main/php_network.h
share/php-${PV}/include/main/php_open_temporary_file.h
share/php-${PV}/include/main/php_output.h
share/php-${PV}/include/main/php_reentrancy.h
share/php-${PV}/include/main/php_scandir.h
share/php-${PV}/include/main/php_stdint.h
share/php-${PV}/include/main/php_streams.h
share/php-${PV}/include/main/php_syslog.h
share/php-${PV}/include/main/php_ticks.h
share/php-${PV}/include/main/php_variables.h
share/php-${PV}/include/main/php_version.h
share/php-${PV}/include/main/rfc1867.h
share/php-${PV}/include/main/snprintf.h
share/php-${PV}/include/main/spprintf.h
share/php-${PV}/include/main/streams/
share/php-${PV}/include/main/streams/php_stream_context.h
share/php-${PV}/include/main/streams/php_stream_filter_api.h
share/php-${PV}/include/main/streams/php_stream_glob_wrapper.h
share/php-${PV}/include/main/streams/php_stream_mmap.h
share/php-${PV}/include/main/streams/php_stream_plain_wrapper.h
share/php-${PV}/include/main/streams/php_stream_transport.h
share/php-${PV}/include/main/streams/php_stream_userspace.h
share/php-${PV}/include/main/streams/php_streams_int.h
share/php-${PV}/include/main/win32_internal_function_disabled.h
share/php-${PV}/include/main/win95nt.h
share/php-${PV}/include/sapi/
share/php-${PV}/include/sapi/cli/
share/php-${PV}/include/sapi/cli/cli.h
@sample ${SYSCONFDIR}/php-${PV}/

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-mcrypt,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-mcrypt->=5.6,<5.7
@conflict php5-mcrypt->=5.2
lib/php-${PV}/modules/mcrypt.so
share/examples/php-${PV}/mcrypt.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/mcrypt.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-mssql,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-mssql->=5.6,<5.7
@conflict php5-mssql->=5.2
lib/php-${PV}/modules/mssql.so
share/examples/php-${PV}/mssql.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/mssql.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-mysql,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-mysql->=5.6,<5.7
@conflict php5-mysql->=5.2
lib/php-${PV}/modules/mysql.so
share/examples/php-${PV}/mysql.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/mysql.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-mysqli,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-mysqli->=5.6,<5.7
@conflict php5-mysqli->=5.2
lib/php-${PV}/modules/mysqli.so
share/examples/php-${PV}/mysqli.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/mysqli.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-odbc,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-odbc->=5.6,<5.7
@conflict php5-odbc->=5.2
lib/php-${PV}/modules/odbc.so
share/examples/php-${PV}/odbc.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/odbc.ini

View File

@ -1,10 +0,0 @@
@comment $OpenBSD: PLIST-pcntl,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-pcntl->=5.6,<5.7
@conflict php5-pcntl->=5.2
@conflict pecl-pcntl-*
@pkgpath www/pecl-pcntl
lib/php-${PV}/modules/pcntl.so
share/examples/php-${PV}/pcntl.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/pcntl.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-pdo_dblib,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-pdo_dblib->=5.6,<5.7
@conflict php5-pdo_dblib->=5.2
lib/php-${PV}/modules/pdo_dblib.so
share/examples/php-${PV}/pdo_dblib.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/pdo_dblib.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-pdo_mysql,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-pdo_mysql->=5.6,<5.7
@conflict php5-pdo_mysql->=5.2
lib/php-${PV}/modules/pdo_mysql.so
share/examples/php-${PV}/pdo_mysql.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/pdo_mysql.ini

View File

@ -1,7 +0,0 @@
@comment $OpenBSD: PLIST-pdo_odbc,v 1.1 2018/05/25 13:59:19 sthen Exp $
@option no-default-conflict
@option is-branch
@conflict php-pdo_odbc->=5.6,<5.7
lib/php-${PV}/modules/pdo_odbc.so
share/examples/php-${PV}/pdo_odbc.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/pdo_odbc.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-pdo_pgsql,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-pdo_pgsql->=5.6,<5.7
@conflict php5-pdo_pgsql->=5.2
lib/php-${PV}/modules/pdo_pgsql.so
share/examples/php-${PV}/pdo_pgsql.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/pdo_pgsql.ini

View File

@ -1,7 +0,0 @@
@comment $OpenBSD: PLIST-pdo_sqlite,v 1.1 2018/05/25 13:59:19 sthen Exp $
@option no-default-conflict
@option is-branch
@conflict php-pdo_sqlite->=5.6,<5.7
lib/php-${PV}/modules/pdo_sqlite.so
share/examples/php-${PV}/pdo_sqlite.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/pdo_sqlite.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-pgsql,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-pgsql->=5.6,<5.7
@conflict php5-pgsql->=5.2
lib/php-${PV}/modules/pgsql.so
share/examples/php-${PV}/pgsql.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/pgsql.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-pspell,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-pspell->=5.6,<5.7
@conflict php5-pspell->=5.2
lib/php-${PV}/modules/pspell.so
share/examples/php-${PV}/pspell.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/pspell.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-shmop,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-shmop->=5.6,<5.7
@conflict php5-shmop->=5.2
lib/php-${PV}/modules/shmop.so
share/examples/php-${PV}/shmop.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/shmop.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-snmp,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-snmp->=5.6,<5.7
@conflict php5-snmp->=5.2
lib/php-${PV}/modules/snmp.so
share/examples/php-${PV}/snmp.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/snmp.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-soap,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-soap->=5.6,<5.7
@conflict php5-soap->=5.2
lib/php-${PV}/modules/soap.so
share/examples/php-${PV}/soap.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/soap.ini

View File

@ -1,7 +0,0 @@
@comment $OpenBSD: PLIST-sqlite3,v 1.1 2018/05/25 13:59:19 sthen Exp $
@option no-default-conflict
@option is-branch
@conflict php-sqlite3->=5.6,<5.7
lib/php-${PV}/modules/sqlite3.so
share/examples/php-${PV}/sqlite3.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/sqlite3.ini

View File

@ -1,9 +0,0 @@
@comment $OpenBSD: PLIST-sybase_ct,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-sybase_ct->=5.6,<5.7
@conflict php5-sybase_ct->=5.2
@pkgpath www/php5/extensions,-sybase_ct
lib/php-${PV}/modules/sybase_ct.so
share/examples/php-${PV}/sybase_ct.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/sybase_ct.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-tidy,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-tidy->=5.6,<5.7
@conflict php5-tidy->=5.2
lib/php-${PV}/modules/tidy.so
share/examples/php-${PV}/tidy.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/tidy.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-xmlrpc,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-xmlrpc->=5.6,<5.7
@conflict php5-xmlrpc->=5.2
lib/php-${PV}/modules/xmlrpc.so
share/examples/php-${PV}/xmlrpc.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/xmlrpc.ini

View File

@ -1,8 +0,0 @@
@comment $OpenBSD: PLIST-xsl,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-xsl->=5.6,<5.7
@conflict php5-xsl->=5.2
lib/php-${PV}/modules/xsl.so
share/examples/php-${PV}/xsl.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/xsl.ini

View File

@ -1,9 +0,0 @@
@comment $OpenBSD: PLIST-zip,v 1.2 2016/06/29 16:14:42 espie Exp $
@option no-default-conflict
@option is-branch
@conflict php-zip->=5.6,<5.7
@conflict pecl-zip-*
@pkgpath archivers/pecl-zip
lib/php-${PV}/modules/zip.so
share/examples/php-${PV}/zip.ini
@sample ${SYSCONFDIR}/php-${PV}.sample/zip.ini

View File

@ -1,12 +0,0 @@
#!/bin/ksh
#
# $OpenBSD: php56_fpm.rc,v 1.2 2018/01/11 19:27:02 rpe Exp $
daemon="${TRUEPREFIX}/sbin/php-fpm-${PV}"
. /etc/rc.d/rc.subr
pexp="php-fpm-${PV}: master process .*"
rc_reload=NO
rc_cmd $1

View File

@ -1,7 +1,6 @@
# $OpenBSD: Makefile,v 1.16 2018/12/11 11:46:15 sthen Exp $
# $OpenBSD: Makefile,v 1.17 2018/12/11 12:10:19 sthen Exp $
SUBDIR =
SUBDIR += 5.6
SUBDIR += 7.1
SUBDIR += 7.2

View File

@ -1,4 +1,4 @@
# $OpenBSD: Makefile.inc,v 1.127 2018/12/11 11:41:54 sthen Exp $
# $OpenBSD: Makefile.inc,v 1.128 2018/12/11 12:10:19 sthen Exp $
BROKEN-hppa= no __sync_bool_compare_and_swap support nor asm fallback
@ -105,21 +105,20 @@ TEST_FLAGS= NO_INTERACTION=1
ZEND_EXTENSIONS+= -opcache
# new subpackages must be added to devel/quirks $cve tables
PHP_EXTENSIONS+= -bz2 -curl -dba -gd -gmp -intl -imap -ldap \
-mysqli -odbc -pcntl -pdo_mysql -pdo_odbc -pdo_pgsql \
-pdo_sqlite -pgsql -pspell -shmop -soap -snmp \
-sqlite3 -pdo_dblib -tidy -xmlrpc -xsl -zip
.if ${PV} == "5.6"
PHP_EXTENSIONS+= -mysql -sybase_ct -mssql -mcrypt
.elif ${PV} == "7.1"
.if ${PV} == "7.1"
PHP_EXTENSIONS+= -mcrypt
.endif
SAPI+= -main -apache -cgi -dbg
MULTI_PACKAGES= ${SAPI} ${PHP_EXTENSIONS}
# setup for no_* build options to disable extensions with extra dep's;
# can't be used for version-specific extensions in 5.6/Makefile
# setup for no_* build options to allow disabling extensions with
# larger dependencies;
PSEUDO_FLAVORS= ${PHP_EXTENSIONS:C/-(pdo_)?mysqli?//:C/-(pcntl|shmop|zip)//:C/-/no_/g}
PSEUDO_FLAVORS+= no_apache
@ -191,17 +190,12 @@ CONFIGURE_ARGS+= --enable-dba=shared \
COMMENT-gd= image manipulation extensions for php
LIB_DEPENDS-gd= graphics/jpeg \
graphics/png
.if ${PV} == "5.6"
LIB_DEPENDS-gd+= devel/t1lib
WANTLIB-gd+= t1
.endif
WANTLIB-gd+= X11 Xpm freetype jpeg m png pthread xcb z
.if ${BUILD_PACKAGES:M-gd}
CONFIGURE_ARGS+= --with-gd=shared \
--with-jpeg-dir=${LOCALBASE} \
--with-png-dir=${LOCALBASE} \
--with-zlib-dir=/usr \
--with-t1lib=${LOCALBASE} \
--with-freetype-dir=${X11BASE} \
--with-xpm-dir=${X11BASE}
.endif
@ -390,36 +384,6 @@ CONFIGURE_ARGS+= --enable-zip=shared,${LOCALBASE}
LIB_DEPENDS-zip= # empty
WANTLIB-zip= pthread z
# the following extensions are 5.6-only:
.if ${PV} == "5.6"
# mysql
COMMENT-mysql= mysql database access extensions for php5
LIB_DEPENDS-mysql= # using mysqlnd
WANTLIB-mysql= pthread
.if ${BUILD_PACKAGES:M-mysql}
CONFIGURE_ARGS+= --with-mysql=shared
.endif
# sybase-ct
COMMENT-sybase_ct= sybase database access extensions for php5
LIB_DEPENDS-sybase_ct= databases/freetds
WANTLIB-sybase_ct= ct ffi gcrypt gmp gnutls gpg-error hogweed iconv \
idn2 intl nettle p11-kit pthread tasn1 unistring z
.if ${BUILD_PACKAGES:M-sybase_ct}
CONFIGURE_ARGS+= --with-sybase-ct=shared,${LOCALBASE}
.endif
# mssql
COMMENT-mssql= microsoft sql access extensions for php5
LIB_DEPENDS-mssql= databases/freetds
WANTLIB-mssql= ffi gcrypt gmp gnutls gpg-error hogweed iconv idn2 \
intl nettle p11-kit pthread sybdb tasn1 unistring z
.if ${BUILD_PACKAGES:M-mssql}
CONFIGURE_ARGS+= --with-mssql=shared,${LOCALBASE}
.endif
.endif
# some variables to substitute
SUBST_VARS+= MODPHP_CONFIG_PATH SV PV MV
UPDATE_PLIST_ARGS+= -i MV
@ -447,9 +411,7 @@ pre-configure:
.for i in ${MULTI_PACKAGES:N-main:S/-//g}
DESCR-${i}= ${.CURDIR}/../files/DESCR-${i}
PKGNAME-${i}= php-${i}-${V}
.if ${V:M5.6*}
PKGSPEC-${i}= php-${i}->=5.6,<5.7
.elif ${V:M7.1*}
.if ${V:M7.1*}
PKGSPEC-${i}= php-${i}->=7.1,<7.2
.elif ${V:M7.2*}
PKGSPEC-${i}= php-${i}->=7.2,<7.3
@ -480,10 +442,8 @@ post-install:
${INSTALL_MAN} ${WRKBUILD}/sapi/fpm/php-fpm.8 ${PREFIX}/man/man8/php-fpm-${PV}.8
${INSTALL_DATA} ${WRKBUILD}/sapi/fpm/php-fpm.conf \
${PREFIX}/share/examples/php-${PV}/php-fpm.conf
.if ${PV} != 5.6
cat ${WRKBUILD}/sapi/fpm/www.conf >> \
${PREFIX}/share/examples/php-${PV}/php-fpm.conf
.endif
${SUBST_CMD} -m 644 -c ${.CURDIR}/../files/php.conf \
${PREFIX}/share/examples/php-${PV}/modphp.conf

View File

@ -1,13 +1,10 @@
# $OpenBSD: php.port.mk,v 1.24 2018/10/26 21:22:01 sthen Exp $
# $OpenBSD: php.port.mk,v 1.25 2018/12/11 12:10:19 sthen Exp $
CATEGORIES+= lang/php
MODPHP_VERSION?= 7.1
.if ${MODPHP_VERSION} == 5.6
MODPHP_FLAVOR = ,php56
MODPHP_VSPEC = >=5.6,<5.7
.elif ${MODPHP_VERSION} == 7.1
.if ${MODPHP_VERSION} == 7.1
MODPHP_FLAVOR = ,php71
MODPHP_VSPEC = >=7.1,<7.2
.elif ${MODPHP_VERSION} == 7.2