svn commit: r341189 - in head: Mk mail/policyd2
John Marino
marino at FreeBSD.org
Sun Jan 26 14:34:25 UTC 2014
Author: marino
Date: Sun Jan 26 14:34:24 2014
New Revision: 341189
URL: http://svnweb.freebsd.org/changeset/ports/341189
QAT: https://qat.redports.org/buildarchive/r341189/
Log:
mail/policyd2: Fix WebUI, add it as an option
* Add WEBUI to the standard option descriptions
* Use PHP only if WebUI option selected
* Specify proper php database driver depending on database selected
between mysql, pgsql, or sqlite
* Port revision bumped because it fixes bug depending on options selected
Due to bitrot caused by staging work, this patch had to be rewritten
from scratch. I believe the intent has been maintained.
PR: ports/184503
Submitted by: Christopher Davis
Approved by: maintainer (Chifeng)
Rewritten b: marino@
Modified:
head/Mk/bsd.options.desc.mk
head/mail/policyd2/Makefile
Modified: head/Mk/bsd.options.desc.mk
==============================================================================
--- head/Mk/bsd.options.desc.mk Sun Jan 26 14:33:08 2014 (r341188)
+++ head/Mk/bsd.options.desc.mk Sun Jan 26 14:34:24 2014 (r341189)
@@ -457,6 +457,7 @@ WAVPACK_DESC?= WavPack lossless audio f
WEBKIT_DESC?= WebKit support
WEBP_DESC?= WebP image format support
WEBSERVER_DESC?= Build and/or install internal web server
+WEBUI_DESC?= Build and/or install web user interface
WMA_DESC?= Windows Media Audio support
WMF_DESC?= Windows Metafile support
WXGTK_DESC?= wxGTK GUI toolkit support
Modified: head/mail/policyd2/Makefile
==============================================================================
--- head/mail/policyd2/Makefile Sun Jan 26 14:33:08 2014 (r341188)
+++ head/mail/policyd2/Makefile Sun Jan 26 14:34:24 2014 (r341189)
@@ -3,7 +3,7 @@
PORTNAME= policyd2
PORTVERSION= 2.0.12
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= mail
MASTER_SITES= http://devlabs.linuxassist.net/attachments/download/${DOWNLOAD_FOLDER}/
DISTNAME= cluebringer-${PORTVERSION}
@@ -11,15 +11,12 @@ DISTNAME= cluebringer-${PORTVERSION}
MAINTAINER= chifeng at gmail.com
COMMENT= Policyd v2 is a multi-platform policy server for popular MTAs
-OPTIONS_DEFINE= DOCS
-
RUN_DEPENDS= p5-Net-Server>=0:${PORTSDIR}/net/p5-Net-Server \
p5-Net-CIDR>=0:${PORTSDIR}/net-mgmt/p5-Net-CIDR \
p5-Config-IniFiles>=0:${PORTSDIR}/devel/p5-Config-IniFiles \
p5-Cache-FastMmap>=0:${PORTSDIR}/devel/p5-Cache-FastMmap
USES= perl5 shebangfix
-USE_PHP= yes
NO_BUILD= yes
BINMODE= 0755
USE_RC_SUBR= policyd2
@@ -34,14 +31,27 @@ WEBUIDIR= ${PREFIX}/www/policyd
PORTDOCS= AUTHORS ChangeLog INSTALL TODO WISHLIST
PORTDATA= *
-OPTIONS_DEFINE= MYSQL PGSQL SQLITE
-OPTIONS_DEFAULT= MYSQL
+OPTIONS_DEFINE= MYSQL PGSQL SQLITE WEBUI
+OPTIONS_DEFAULT=MYSQL WEBUI
-USE_PHP= pdo_mysql
MYSQL_RUN_DEPENDS= p5-DBD-mysql>=0:${PORTSDIR}/databases/p5-DBD-mysql
SQLITE_RUN_DEPENDS= p5-DBD-SQLite>=0:${PORTSDIR}/databases/p5-DBD-SQLite
PGSQL_RUN_DEPENDS= p5-DBD-Pg>=0:${PORTSDIR}/databases/p5-DBD-Pg
+.include <bsd.port.options.mk>
+
+.if ${PORT_OPTIONS:MWEBUI}
+. if ${PORT_OPTIONS:MMYSQL}
+USE_PHP= pdo_mysql
+. endif
+. if ${PORT_OPTIONS:MSQLITE}
+USE_PHP= pdo_sqlite
+. endif
+. if ${PORT_OPTIONS:MPGSQL}
+USE_PHP= pdo_pgsql
+. endif
+.endif
+
post-patch:
@${REINPLACE_CMD} 's|/etc|${PREFIX}/etc|' ${WRKSRC}/cbpadmin \
${WRKSRC}/cbpolicyd
More information about the svn-ports-all
mailing list