Skip site navigation (1)Skip section navigation (2)
Date:      Mon,  4 Nov 2013 17:20:15 +0100 (CET)
From:      Geoffroy Desvernay <dgeo@centrale-marseille.fr>
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   ports/183716: [MAINTAINER] net-mgmt/netdisco: make web insterface optional
Message-ID:  <20131104162015.C84611CDAF@dgeo.sysadm.ec-m.fr>
Resent-Message-ID: <201311061400.rA6E00Ks078996@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         183716
>Category:       ports
>Synopsis:       [MAINTAINER] net-mgmt/netdisco: make web insterface optional
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Wed Nov 06 14:00:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     Geoffroy Desvernay
>Release:        FreeBSD 9.2-RELEASE amd64
>Organization:
Ecole Centrale de Marseille
>Environment:
System: FreeBSD dgeo.sysadm.ec-m.fr 9.2-RELEASE FreeBSD 9.2-RELEASE #0: Thu Oct 24 18:38:54 CEST 2013
>Description:
 Added an option WEBUI to make web interface and dependencies to apache/mod_perl2 optional

Generated with FreeBSD Port Tools 0.99_8 (mode: change, diff: SVN)
>How-To-Repeat:
>Fix:

--- netdisco-1.3.2_1.patch begins here ---
Index: Makefile
===================================================================
--- Makefile	(revision 332738)
+++ Makefile	(working copy)
@@ -10,15 +10,13 @@
 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 @@
 		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 @@
 
 USES=		perl5
 USE_PGSQL=	yes
-USE_APACHE_RUN=	22+
 
 USE_RC_SUBR=	netdisco
 
@@ -76,6 +72,16 @@
 		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,15 +109,17 @@
 		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}
 
--- netdisco-1.3.2_1.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20131104162015.C84611CDAF>