-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update php/5.3 to 5.3.8 and enable fpm support. the original fpm diff
was from william@ but i had a slightly different approach of implementing it in the port itself.
- Loading branch information
Showing
12 changed files
with
138 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,23 @@ | ||
# $OpenBSD: Makefile,v 1.14 2011/07/22 10:28:54 sthen Exp $ | ||
# $OpenBSD: Makefile,v 1.15 2011/08/27 13:13:13 robert Exp $ | ||
|
||
PV= 5.3 | ||
V= ${PV}.6 | ||
V= ${PV}.8 | ||
SUHOSIN_PHPV= ${V} | ||
SUHOSIN_P_V= 0.9.10 | ||
|
||
REVISION-main= 1 | ||
REVISION-fastcgi= 2 | ||
|
||
INI_TEMPLATES= development production | ||
|
||
# fpm | ||
PKGNAME-fpm?= php-fpm-${V} | ||
MULTI_PACKAGES+= -fpm | ||
COMMENT-fpm= stand-alone FPM version of PHP | ||
CONFIGURE_ARGS+= --enable-fpm \ | ||
--localstatedir=/var \ | ||
--with-fpm-user=www \ | ||
--with-fpm-group=www | ||
LIB_DEPENDS-fpm= ${LIB_DEPENDS-main} | ||
WANTLIB-fpm= ${WANTLIB-main} | ||
RUN_DEPENDS-fpm= ${RUN_DEPENDS-main} \ | ||
php-${V}:lang/php/${PV} | ||
|
||
.include <bsd.port.mk> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
MD5 (php-5.3.6.tar.gz) = iKKwAEe8U6+7vfEOviilfg== | ||
MD5 (php-5.3.8.tar.gz) = 9M5A1dFWymapltu4oOdmag== | ||
MD5 (suhosin-0.9.32.1.tar.gz) = JqhvD2hKZWw+eJ4+tOwdsw== | ||
MD5 (suhosin-patch-5.3.6-0.9.10.patch.gz) = qjp7nadDlx4b1/T/nASLHA== | ||
RMD160 (php-5.3.6.tar.gz) = WNtkT6w9TL/gnobONyp5vWOxj1M= | ||
MD5 (suhosin-patch-5.3.8-0.9.10.patch.gz) = CFguUC/tgiHGV3BCykXduA== | ||
RMD160 (php-5.3.8.tar.gz) = 7wt3tRKoD/tj+YOkr/IomIaAFEk= | ||
RMD160 (suhosin-0.9.32.1.tar.gz) = YYTu8za509XIhafR3L8g2XsFXo0= | ||
RMD160 (suhosin-patch-5.3.6-0.9.10.patch.gz) = 2WxsTCkahBFQfms2nFkKvruNmeE= | ||
SHA1 (php-5.3.6.tar.gz) = mrzepFjAlseJUEcn6QcG1whel1U= | ||
RMD160 (suhosin-patch-5.3.8-0.9.10.patch.gz) = GfeJv0ml/tLNiLGZ/YrF0f+pvcg= | ||
SHA1 (php-5.3.8.tar.gz) = CtG8v+0BQtFyLsID4myxDvUkxwQ= | ||
SHA1 (suhosin-0.9.32.1.tar.gz) = k/yx1flmkcTFCAihTdPW1Lv+pFE= | ||
SHA1 (suhosin-patch-5.3.6-0.9.10.patch.gz) = jcLHUUEr3JIfVnn639rcZq0phow= | ||
SHA256 (php-5.3.6.tar.gz) = UhqdFAtMqzJK7O7TFAmnl94gaAhCBxAW1gzFrjzJRi4= | ||
SHA1 (suhosin-patch-5.3.8-0.9.10.patch.gz) = PDjoc1hLj54yWoE8ybGXo0JZUJk= | ||
SHA256 (php-5.3.8.tar.gz) = vRdSgiYNSZMkmdom5a6NgejlQSOuIuFv/JbJ7e6Ojw8= | ||
SHA256 (suhosin-0.9.32.1.tar.gz) = 0oOry9GAPqoRu9kctarnJ7K7qzoAod6FEPhdjMWY5JA= | ||
SHA256 (suhosin-patch-5.3.6-0.9.10.patch.gz) = SLgVHqRB5JpD86dRsKqc73334FWUizNdCRaN8DGUP1E= | ||
SIZE (php-5.3.6.tar.gz) = 14368718 | ||
SHA256 (suhosin-patch-5.3.8-0.9.10.patch.gz) = Cg2sDkNDWW8r/O8n3PcYBSS3i7HS0sqHg3Cn0PgxPSY= | ||
SIZE (php-5.3.8.tar.gz) = 14789551 | ||
SIZE (suhosin-0.9.32.1.tar.gz) = 119117 | ||
SIZE (suhosin-patch-5.3.6-0.9.10.patch.gz) = 40024 | ||
SIZE (suhosin-patch-5.3.8-0.9.10.patch.gz) = 41175 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,11 @@ | ||
$OpenBSD: patch-ext_gd_config_m4,v 1.3 2011/06/18 19:49:50 sthen Exp $ | ||
--- ext/gd/config.m4.orig.port Wed May 27 09:18:24 2009 | ||
+++ ext/gd/config.m4 Sat Jun 18 12:14:48 2011 | ||
@@ -108,13 +108,13 @@ AC_DEFUN([PHP_GD_PNG],[ | ||
AC_MSG_ERROR([PNG support requires ZLIB. Use --with-zlib-dir=<DIR>]) | ||
fi | ||
--- ext/gd/config.m4.orig.port Thu Aug 25 19:09:16 2011 | ||
+++ ext/gd/config.m4 Thu Aug 25 19:10:18 2011 | ||
@@ -97,7 +97,7 @@ | ||
if test "$PHP_PNG_DIR" != "no"; then | ||
|
||
- if test ! -f $GD_PNG_DIR/include/png.h; then | ||
+ if test ! -f $GD_PNG_DIR/include/libpng/png.h; then | ||
AC_MSG_ERROR([png.h not found.]) | ||
fi | ||
for i in $PHP_PNG_DIR /usr/local /usr; do | ||
- test -f $i/include/png.h && GD_PNG_DIR=$i && break | ||
+ test -f $i/include/libpng/png.h && GD_PNG_DIR=$i && break | ||
done | ||
|
||
PHP_CHECK_LIBRARY(png,png_write_image, | ||
[ | ||
- PHP_ADD_INCLUDE($GD_PNG_DIR/include) | ||
+ PHP_ADD_INCLUDE($GD_PNG_DIR/include/libpng) | ||
PHP_ADD_LIBRARY_WITH_PATH(z, $PHP_ZLIB_DIR/$PHP_LIBDIR, GD_SHARED_LIBADD) | ||
PHP_ADD_LIBRARY_WITH_PATH(png, $GD_PNG_DIR/$PHP_LIBDIR, GD_SHARED_LIBADD) | ||
],[ | ||
if test -z "$GD_PNG_DIR"; then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,11 @@ | ||
$OpenBSD: patch-ext_openssl_config0_m4,v 1.2 2011/06/18 19:49:50 sthen Exp $ | ||
--- ext/openssl/config0.m4.orig.port Sun Jan 7 18:38:22 2007 | ||
+++ ext/openssl/config0.m4 Sat Jun 18 12:14:50 2011 | ||
@@ -16,7 +16,7 @@ if test "$PHP_OPENSSL" != "no"; then | ||
--- ext/openssl/config0.m4.orig.port Thu Aug 25 19:08:39 2011 | ||
+++ ext/openssl/config0.m4 Thu Aug 25 19:09:03 2011 | ||
@@ -16,7 +16,7 @@ | ||
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])) | ||
|
||
PHP_SETUP_OPENSSL(OPENSSL_SHARED_LIBADD, | ||
[ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- sapi/fpm/Makefile.frag.orig.port Thu Aug 25 19:33:35 2011 | ||
+++ sapi/fpm/Makefile.frag Thu Aug 25 19:33:53 2011 | ||
@@ -3,7 +3,7 @@ | ||
$(builddir)/fpm: | ||
@mkdir -p $(builddir)/fpm | ||
|
||
-$(SAPI_FPM_PATH): $(builddir)/fpm $(PHP_GLOBAL_OBJS) $(PHP_SAPI_OBJS) $(SAPI_EXTRA_DEPS) | ||
+$(SAPI_FPM_PATH): $(builddir)/fpm $(PHP_GLOBAL_OBJS) $(PHP_FPM_OBJS) $(SAPI_EXTRA_DEPS) | ||
$(BUILD_FPM) | ||
|
||
$(builddir)/fpm/fpm_conf.lo: $(builddir)/../../main/build-defs.h |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
--- sapi/fpm/config.m4.orig.port Sun Jun 26 17:48:11 2011 | ||
+++ sapi/fpm/config.m4 Thu Aug 25 19:35:16 2011 | ||
@@ -423,7 +423,9 @@ | ||
|
||
PHP_FPM_CFLAGS="-I$abs_srcdir/sapi/fpm" | ||
|
||
- INSTALL_IT=":" | ||
+ if test "$PHP_SAPI" = "default"; then | ||
+ PHP_SAPI="fpm" | ||
+ fi | ||
PHP_FPM_FILES="fpm/fastcgi.c \ | ||
fpm/fpm.c \ | ||
fpm/fpm_children.c \ | ||
@@ -449,7 +451,8 @@ | ||
fpm/zlog.c \ | ||
" | ||
|
||
- PHP_SELECT_SAPI(fpm, program, $PHP_FPM_FILES $PHP_FPM_TRACE_FILES, $PHP_FPM_CFLAGS, '$(SAPI_FPM_PATH)') | ||
+ PHP_ADD_SOURCES(sapi/fpm, $PHP_FPM_FILES $PHP_FPM_TRACE_FILES, $PHP_FPM_CFLAGS, fpm) | ||
+ PHP_ADD_SOURCES(/main, internal_functions.c,,fpm) | ||
|
||
case $host_alias in | ||
*aix*) | ||
@@ -459,11 +462,19 @@ | ||
BUILD_FPM="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_SAPI_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(SAPI_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" | ||
;; | ||
*) | ||
- BUILD_FPM="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_SAPI_OBJS) \$(EXTRA_LIBS) \$(SAPI_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" | ||
+ BUILD_FPM="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_FPM_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)" | ||
;; | ||
esac | ||
|
||
+ PHP_FPM_TARGET="\$(SAPI_FPM_PATH)" | ||
+ PHP_INSTALL_FPM_TARGET="install-fpm" | ||
PHP_SUBST(BUILD_FPM) | ||
+ PHP_SUBST(PHP_FPM_OBJS) | ||
+ PHP_SUBST(PHP_FPM_TARGET) | ||
+ PHP_SUBST(PHP_INSTALL_FPM_TARGET) | ||
+ if test "$PHP_SAPI" = "fpm" ; then | ||
+ PHP_BUILD_PROGRAM($SAPI_FPM_PATH) | ||
+ fi | ||
else | ||
AC_MSG_RESULT(no) | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
PHP-FPM (FastCGI Process Manager) is an alternative PHP FastCGI | ||
implementation with some additional features useful for sites of | ||
any size, especially busier sites. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
@comment $OpenBSD: PLIST-fpm,v 1.1 2011/08/27 13:13:13 robert Exp $ | ||
@man man/man8/php-fpm-${PV}.8 | ||
@bin sbin/php-fpm-${PV} | ||
share/examples/php-${PV}/php-fpm.conf | ||
@sample ${SYSCONFDIR}/php-fpm.conf | ||
@rcscript ${RCDIR}/php_fpm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/bin/sh | ||
# | ||
# $OpenBSD: php_fpm.rc,v 1.1 2011/08/27 13:13:13 robert Exp $ | ||
|
||
daemon="${TRUEPREFIX}/sbin/php-fpm-${PV}" | ||
|
||
. /etc/rc.d/rc.subr | ||
|
||
pexp="php-fpm-${PV}: master.*" | ||
|
||
rc_reload() { | ||
pkill -USR2 -f "^${pexp}" | ||
} | ||
|
||
rc_cmd $1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters