Date: Sat, 9 Nov 2013 14:05:30 +0000 (UTC) From: William Grzybowski <wg@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r333292 - head/net-mgmt/netdisco Message-ID: <201311091405.rA9E5UAn095899@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: wg Date: Sat Nov 9 14:05:30 2013 New Revision: 333292 URL: http://svnweb.freebsd.org/changeset/ports/333292 Log: net-mgmt/netdisco: make web insterface optional PR: ports/183716 Submitted by: maintainer Modified: head/net-mgmt/netdisco/Makefile Modified: head/net-mgmt/netdisco/Makefile ============================================================================== --- head/net-mgmt/netdisco/Makefile Sat Nov 9 13:45:42 2013 (r333291) +++ head/net-mgmt/netdisco/Makefile Sat Nov 9 14:05:30 2013 (r333292) @@ -10,15 +10,13 @@ MASTER_SITES= SF MAINTAINER= dgeo@centrale-marseille.fr COMMENT= Web-based network management tool for moderate to large networks -OPTIONS_DEFINE= DOCS GRAPHVIZ MIBS -OPTIONS_DEFAULT=DOCS GRAPHVIZ MIBS +OPTIONS_DEFINE= DOCS GRAPHVIZ MIBS WEBUI +OPTIONS_DEFAULT=DOCS GRAPHVIZ MIBS WEBUI MIBS_DESC= Depend on net-mgmt/netdisco-mibs GRAPHVIZ_DESC= Install GraphViz for network map support +WEBUI_DESC= With web interface (mod_perl2+apache22) -RUN_DEPENDS+= ${APACHE_PKGNAMEPREFIX}mod_perl2>=0:${PORTSDIR}/www/mod_perl2 \ - p5-Apache-DBI>=0:${PORTSDIR}/www/p5-Apache-DBI \ - p5-libapreq2>=0:${PORTSDIR}/www/p5-libapreq2 \ - p5-Net-SNMP>=0:${PORTSDIR}/net-mgmt/p5-Net-SNMP \ +RUN_DEPENDS+= p5-Net-SNMP>=0:${PORTSDIR}/net-mgmt/p5-Net-SNMP \ p5-SNMP-Info>=3.01:${PORTSDIR}/net-mgmt/p5-SNMP-Info \ p5-HTML-Mason>=0:${PORTSDIR}/www/p5-HTML-Mason \ p5-DB_File-Lock>=0:${PORTSDIR}/devel/p5-DB_File-Lock \ @@ -26,7 +24,6 @@ RUN_DEPENDS+= ${APACHE_PKGNAMEPREFIX}mod p5-Net-NBName>=0:${PORTSDIR}/net/p5-Net-NBName \ p5-DBD-Pg>=0:${PORTSDIR}/databases/p5-DBD-Pg \ p5-HTML-Parser>=0:${PORTSDIR}/www/p5-HTML-Parser \ - p5-MasonX-Request-WithApacheSession>=0:${PORTSDIR}/www/p5-MasonX-Request-WithApacheSession \ p5-Parallel-ForkManager>=0:${PORTSDIR}/devel/p5-Parallel-ForkManager USERS= netdisco @@ -34,7 +31,6 @@ GROUPS= netdisco USES= perl5 USE_PGSQL= yes -USE_APACHE_RUN= 22+ USE_RC_SUBR= netdisco @@ -64,7 +60,7 @@ MIBSDIR= ${PREFIX}/share/netdisco-mibs .if ${PORT_OPTIONS:MMIBS} RUN_DEPENDS+= ${MIBSDIR}/mib_index.txt:${PORTSDIR}/net-mgmt/netdisco-mibs BUILD_DEPENDS+= ${MIBSDIR}/mib_index.txt:${PORTSDIR}/net-mgmt/netdisco-mibs -. include "${.CURDIR}/../netdisco-mibs/bsd.port.netdisco.mk" +. include "${.CURDIR}/../netdisco-mibs/bsd.port.netdisco.mk" MIBINCLUDES!=${ECHO} \"${MIBDIRS:S/^/${MIBSDIR}\//}\" MIBINCLUDES:=${MIBINCLUDES:S/ /:/g:S/"//g} .else @@ -76,6 +72,16 @@ RUN_DEPENDS+= p5-Graph>=0:${PORTSDIR}/ma p5-GraphViz>=0:${PORTSDIR}/graphics/p5-GraphViz .endif +.if ${PORT_OPTIONS:MWEBUI} +RUN_DEPENDS+= ${APACHE_PKGNAMEPREFIX}mod_perl2>=0:${PORTSDIR}/www/mod_perl2 \ + p5-Apache-DBI>=0:${PORTSDIR}/www/p5-Apache-DBI \ + p5-libapreq2>=0:${PORTSDIR}/www/p5-libapreq2 \ + p5-MasonX-Request-WithApacheSession>=0:${PORTSDIR}/www/p5-MasonX-Request-WithApacheSession +USE_APACHE_RUN= 22 +.else +WWWDIR= "@comment " +.endif + pre-install: . for i in ${ALTER_FILES} @(${MV} ${WRKSRC}/${i}.bak ${WRKSRC}/${i} 2>/dev/null || ${TRUE}) @@ -103,18 +109,19 @@ do-install: cd ${WRKSRC} && ${INSTALL_SCRIPT} ${i} ${PREFIX}/bin . endfor - ${MKDIR} ${WWWDIR} - cd ${WRKSRC}/html && ${INSTALL_DATA} autohandler *.* ${WWWDIR} +. if ${PORT_OPTIONS:MWEBUI} + ${MKDIR} ${WWWDIR} + cd ${WRKSRC}/html && ${INSTALL_DATA} autohandler *.* ${WWWDIR} - ${MKDIR} ${WWWDIR}/doc - cd ${WRKSRC}/html/doc && ${INSTALL_DATA} *.* ${WWWDIR}/doc + ${MKDIR} ${WWWDIR}/doc + cd ${WRKSRC}/html/doc && ${INSTALL_DATA} *.* ${WWWDIR}/doc - ${CHOWN} -R ${WWWOWN}:${WWWGRP} ${WWWDIR} + ${CHOWN} -R ${WWWOWN}:${WWWGRP} ${WWWDIR} - ${MKDIR} ${WWWDIR}/mason + ${MKDIR} ${WWWDIR}/mason +. endif ${INSTALL_DATA} ${WRKSRC}/netdisco.pm ${SITE_PERL} - ${INSTALL} -d -m 750 -o ${USERS} -g ${GROUPS} ${ETCDIR} . for i in ${CONFIG_FILES}
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201311091405.rA9E5UAn095899>