Bug 178445 - [patch] net-mgmt/netams: moving to optionsng
Summary: [patch] net-mgmt/netams: moving to optionsng
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-05-09 10:10 UTC by ru_M1cRO
Modified: 2013-05-10 12:30 UTC (History)
0 users

See Also:


Attachments
file.diff (4.09 KB, patch)
2013-05-09 10:10 UTC, ru_M1cRO
no flags Details | Diff
netams_tong.patch (4.14 KB, patch)
2013-05-09 11:03 UTC, ru_M1cRO
no flags Details | Diff
file.dat (230 bytes, text/plain; charset="us-ascii")
2013-05-09 11:03 UTC, ru_M1cRO
no flags Details
file.dat (215 bytes, text/plain; charset="us-ascii")
2013-05-10 12:28 UTC, dfilter service
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description ru_M1cRO 2013-05-09 10:10:02 UTC
patch for net-mgmt/netams for moving to optionsng

Fix: diff -Nru netams_old/Makefile netams/Makefile
--- netams_old/Makefile	2013-05-09 12:27:22.881706219 +0400
+++ netams/Makefile	2013-05-09 12:38:07.953705562 +0400
@@ -1,9 +1,5 @@
-# New ports collection makefile for: NetAMS
-# Date created:        24 December 2003
-# Whom: 	       jura@netams.com
-#
-# $FreeBSD: ports/net-mgmt/netams/Makefile,v 1.31 2012/11/17 06:00:34 svnexp Exp $
-#
+# Created by: Yuriy N. Shkandybin <jura@netams.com>
+# $FreeBSD$
 
 PORTNAME=	netams
 PORTVERSION=	3.4.5
@@ -21,10 +17,12 @@
 USE_RC_SUBR=	netams
 MANCOMPRESSED=	no
 
-OPTIONS=	DEBUG		"Build with debug symbols"			off \
-		MYSQL		"Build with MySQL storage support" 		on  \
-		POSTGRESQL	"Build with PostgreSQL storage support"		off \
-		CGI 		"Install admin/user CGI scripts"		off
+OPTIONS_DEFINE=	DEBUG MYSQL POSTGRESQL CGI
+OPTIONS_DEFAULT=	MYSQL
+DEBUG_DESC=	Build with debug symbols
+MYSQL_DESC=	Build with MySQL storage support
+POSTGRESQL_DESC=	Build with PostgreSQL storage support
+CGI_DESC=	Install admin/user CGI scripts
 
 SCRIPTS_ENV=	WRKDIRPREFIX="${WRKDIRPREFIX}" \
 		PREFIX="${PREFIX}" \
@@ -46,18 +44,18 @@
 
 .include <bsd.port.pre.mk>
 
-.if !defined(WITH_MYSQL) && !defined(WITH_POSTGRESQL)
+.if empty(PORT_OPTIONS:MMYSQL) && empty(PORT_OPTIONS:MPOSTGRESQL)
 IGNORE=requires at least one database backend selected. Run 'make config'
 .endif
 
-.if defined(WITH_POSTGRESQL)
+.if ${PORT_OPTIONS:MPOSTGRESQL}
 USE_PGSQL=		yes
 PLIST_SUB+=		POSTGRESQL=""
 .else
 PLIST_SUB+=		POSTGRESQL="@comment "
 .endif
 
-.if defined(WITH_MYSQL)
+.if ${PORT_OPTIONS:MMYSQL}
 USE_MYSQL=		yes
 BROKEN_WITH_MYSQL=	323
 PLIST_SUB+=		MYSQL=""
@@ -65,15 +63,15 @@
 PLIST_SUB+=		MYSQL="@comment "
 .endif
 
-.if defined(WITH_POSTGRESQL) && defined(WITH_CGI)
+.if ${PORT_OPTIONS:MPOSTGRESQL} && ${PORT_OPTIONS:MCGI}
 RUN_DEPENDS+=		p5-DBD-Pg>=0:${PORTSDIR}/databases/p5-DBD-Pg
 .endif
 
-.if defined(WITH_MYSQL) && defined(WITH_CGI)
+.if ${PORT_OPTIONS:MMYSQL} && ${PORT_OPTIONS:MCGI}
 RUN_DEPENDS+=		p5-DBD-mysql50>=0:${PORTSDIR}/databases/p5-DBD-mysql50
 .endif
 
-.if defined(WITH_CGI)
+.if ${PORT_OPTIONS:MCGI}
 RUN_DEPENDS+=	p5-GD>=0:${PORTSDIR}/graphics/p5-GD \
 		p5-GD-Graph>=0:${PORTSDIR}/graphics/p5-GD-Graph \
 		p5-GD-TextUtil>=0:${PORTSDIR}/graphics/p5-GD-TextUtil \
@@ -88,15 +86,15 @@
 .endif
 
 pre-patch:
-.if !defined(WITH_DEBUG)
+.if empty(PORT_OPTIONS:MDEBUG)
 	@${REINPLACE_CMD} -e 's|.*sh configure.sh|& -nodebug|' \
 		${WRKSRC}/Makefile
 .endif
-.if !defined(WITH_POSTGRESQL)
+.if empty(PORT_OPTIONS:MPOSTGRESQL)
 	@${REINPLACE_CMD} -e 's|locate_file "libpq\.so".*|v1="" \&\& v2=""|' \
 		${WRKSRC}/configure.sh
 .endif
-.if defined(WITH_MYSQL)
+.if ${PORT_OPTIONS:MWITH_MYSQL}
 	@${REINPLACE_CMD} -e 's|^#!/usr/bin/perl|#!/usr/local/bin/perl|' ${WRKSRC}/addon/mysql_rotate.pl
 .else
 	@${REINPLACE_CMD} -e 's|locate_file "libmysqlclient\.so".*|v1="" \&\& v2=""|' \
@@ -121,11 +119,11 @@
 	${INSTALL_DATA} ${WRKSRC}/addon/ru-networks.txt ${DATADIR}/ru-networks.txt.sample
 	${INSTALL_DATA} ${WRKSRC}/addon/ua-networks.txt ${DATADIR}/ua-networks.txt.sample
 	${INSTALL_DATA} ${WRKSRC}/addon/.netamsctl.rc ${DATADIR}/.netamsctl.rc
-.if defined(WITH_MYSQL)
+.if ${PORT_OPTIONS:MMYSQL}
 	${INSTALL_DATA} ${WRKSRC}/addon/mysql_rotate.pl ${DATADIR}/mysql_rotate.pl
 	${INSTALL_DATA} ${WRKSRC}/addon/cardtool_schema.sql ${DATADIR}/tools/cardtool_schema.sql
 .endif
-.if defined(WITH_POSTGRESQL)
+.if ${PORT_OPTIONS:MPOSTGRESQL}
 	${INSTALL_DATA} ${WRKSRC}/addon/cardtool_schema-Pg.sql ${DATADIR}/tools/cardtool_schema-Pg.sql
 	${INSTALL_DATA} ${WRKSRC}/addon/postgresql_schema.sql ${DATADIR}/tools/postgresql_schema.sql
 .endif
@@ -138,7 +136,7 @@
 	${INSTALL_DATA} ${WRKSRC}/addon/oracle/netams_tg.sql ${DATADIR}/tools/oracle/netams_tg.sql
 	${INSTALL_DATA} ${WRKSRC}/addon/oracle/netams_ts.sql ${DATADIR}/tools/oracle/netams_ts.sql
 	${INSTALL_DATA} ${WRKSRC}/addon/netams-apache-freebsd.conf ${DATADIR}/netams-apache-freebsd.conf
-.if defined(WITH_CGI)
+.if ${PORT_OPTIONS:MCGI}
 	${MKDIR} ${WWWDIR} ${WWWDIR}/cgi-bin ${WWWDIR}/cgi-bin/admin ${WWWDIR}/images
 	${INSTALL_DATA} ${WRKSRC}/addon/index.html ${WWWDIR}/index.html
 	${INSTALL_DATA} ${WRKSRC}/addon/netams.js ${WWWDIR}/netams.js


Patch attached with submission follows:
How-To-Repeat: Install it
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2013-05-09 10:10:21 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 2 Edwin Groothuis freebsd_committer freebsd_triage 2013-05-09 10:10:21 UTC
Maintainer of net-mgmt/netams,

Please note that PR ports/178445 has just been submitted.

If it contains a patch for an upgrade, an enhancement or a bug fix
you agree on, reply to this email stating that you approve the patch
and a committer will take care of it.

The full text of the PR can be found at:
    http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/178445

-- 
Edwin Groothuis via the GNATS Auto Assign Tool
edwin@FreeBSD.org
Comment 3 ru_M1cRO 2013-05-09 11:03:43 UTC
09.05.2013, 13:10, "edwin@FreeBSD.org" <edwin@FreeBSD.org>:
> Synopsis: [patch] net-mgmt/netams: moving to optionsng
>
> State-Changed-From-To: open->feedback
> State-Changed-By: edwin
> State-Changed-When: Thu May 9 09:10:21 UTC 2013
> State-Changed-Why:
> Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
>
> http://www.freebsd.org/cgi/query-pr.cgi?pr=178445

Patch with multi options for databases was attached.

-- 
With Best Regards,
Ilya A. Arkhipov
Comment 4 dfilter service freebsd_committer freebsd_triage 2013-05-10 12:28:41 UTC
Author: bapt
Date: Fri May 10 11:28:32 2013
New Revision: 317790
URL: http://svnweb.freebsd.org/changeset/ports/317790

Log:
  Convert to new options framework
  While here do some build with clang fixes
  
  PR:		ports/178445, ports/178446, ports/178444, ports/178443, ports/178425, ports/178423
  Submitted by:	"Ilya A. Arkhipov" <rum1cro@yandex.ru>

Modified:
  head/net-mgmt/circe/Makefile
  head/net-mgmt/dhcdrop/Makefile
  head/net-mgmt/macroscope/Makefile
  head/net-mgmt/nedi/Makefile
  head/net-mgmt/netams/Makefile
  head/net-mgmt/p5-Cflow/Makefile
  head/net-mgmt/pftabled/Makefile
  head/net-mgmt/pnp/Makefile

Modified: head/net-mgmt/circe/Makefile
==============================================================================
--- head/net-mgmt/circe/Makefile	Fri May 10 11:24:42 2013	(r317789)
+++ head/net-mgmt/circe/Makefile	Fri May 10 11:28:32 2013	(r317790)
@@ -1,9 +1,5 @@
-# New ports collection makefile for: circe
-# Date created:		23 July 2010
-# Whom:			Berkeley NAC-Team
-#
+# Created by: Berkeley NAC-Team <circe-port-maintainers@bws.net.berkeley.edu>
 # $FreeBSD$
-#
 
 PORTNAME=	circe
 PORTVERSION=	0.2.3
@@ -33,11 +29,12 @@ USE_PERL5=	yes
 DIST_SUBDIR=	${PORTNAME}
 WRKSRC=		${WRKDIR}
 
-OPTIONS=	ENCRYPT "Encrypt the destination URL in redirection" Off
+OPTIONS_DEFINE=	ENCRYPT
+ENCRYPT_DESC=	Encrypt destination URL in redirection
 
 .include <bsd.port.options.mk>
 
-.if defined(WITH_ENCRYPT)
+.if ${PORT_OPTIONS:MENCRYPT}
 RUN_DEPENDS+=	p5-Crypt-DES>=0:${PORTSDIR}/security/p5-Crypt-DES \
 		p5-Crypt-OpenSSL-AES>=0:${PORTSDIR}/security/p5-Crypt-OpenSSL-AES
 .endif

Modified: head/net-mgmt/dhcdrop/Makefile
==============================================================================
--- head/net-mgmt/dhcdrop/Makefile	Fri May 10 11:24:42 2013	(r317789)
+++ head/net-mgmt/dhcdrop/Makefile	Fri May 10 11:28:32 2013	(r317790)
@@ -1,9 +1,5 @@
-# New ports collection makefile for:    dhcdrop
-# Date created:         Aug 9 2009
-# Whom:                 Nick F
-#
+# Created by: Nick F <ffault@gmail.com>
 # $FreeBSD$
-#
 
 PORTNAME=	dhcdrop
 PORTVERSION=	0.5
@@ -21,12 +17,18 @@ MANLANG=	"" ru
 
 PLIST_FILES=	sbin/dhcdrop
 
-OPTIONS=	STATIC "Build a static version of dhcdrop" off
+OPTIONS_DEFINE=	STATIC
+STATIC_DESC=	Build a static version of dhcdrop
 
 .include <bsd.port.options.mk>
 
-.if defined(WITH_STATIC)
+.if ${PORT_OPTIONS:MSTATIC}
 CONFIGURE_ARGS+=--enable-static-build
 .endif
 
+post-patch:
+	@${REINPLACE_CMD} -e \
+		's,inline void rand_ether_addr,static void rand_ether_addr,' \
+			${WRKSRC}/src/dhcdrop.[c,h]
+
 .include <bsd.port.mk>

Modified: head/net-mgmt/macroscope/Makefile
==============================================================================
--- head/net-mgmt/macroscope/Makefile	Fri May 10 11:24:42 2013	(r317789)
+++ head/net-mgmt/macroscope/Makefile	Fri May 10 11:28:32 2013	(r317790)
@@ -1,9 +1,5 @@
-# New ports collection makefile for:	macroscope
-# Date created:		2007-05-14
-# Whom:			Dukashvili Guram <white_raven@users.berlios.de>
-#
+# Created by: Dukashvili Guram <white_raven@users.berlios.de>
 # $FreeBSD$
-#
 
 PORTNAME=		macroscope
 PORTVERSION=		1.0.3787
@@ -25,21 +21,23 @@ USE_BZIP2=		yes
 USE_DOS2UNIX=		yes
 USES=			cmake
 
-OPTIONS=		MYSQL		"With MySQL support" on \
-			FIREBIRD	"With Firebird support" off
+OPTIONS_DEFINE=	MYSQL FIREBIRD DOCS
+MYSQL_DESC=	With MySQL support
+FIREBIRD_DESC=	With Firebird support
+OPTIONS_DEFAULT=	MYSQL
 
 .include <bsd.port.pre.mk>
 
-.if defined(NOPORTDOCS)
+.if ! ${PORT_OPTIONS:MDOCS}
 CMAKE_ARGS+=		-DCMAKE_NOT_INSTALL_DOC:BOOL=ON
 .endif
 
-.if !defined(WITHOUT_MYSQL)
+.if ${PORT_OPTIONS:MMYSQL}
 WANT_MYSQL_VER=		50
 USE_MYSQL=		yes
 .endif
 
-.if !defined(WITHOUT_FIREBIRD)
+.if ${PORT_OPTIONS:MFIREBIRD}
 WITH_FIREBIRD_VER=	2
 USE_FIREBIRD=		yes
 .endif

Modified: head/net-mgmt/nedi/Makefile
==============================================================================
--- head/net-mgmt/nedi/Makefile	Fri May 10 11:24:42 2013	(r317789)
+++ head/net-mgmt/nedi/Makefile	Fri May 10 11:28:32 2013	(r317790)
@@ -1,9 +1,5 @@
-# New ports collection makefile for:	nedi
-# Date created:				2007-02-04
-# Whom:					cristi
-#
+# Created by: cristi <cristi@net.utcluj.ro>
 # $FreeBSD$
-#
 
 PORTNAME=	nedi
 DISTVERSION=	1.0.w
@@ -24,7 +20,8 @@ WRKSRC=		${WRKDIR}/${PORTNAME}
 NO_BUILD=	yes
 USE_PERL5=	yes
 
-OPTIONS=	GD "Use GD" OFF
+OPTIONS_DEFINE=	GD
+GD_DESC=	Use GD
 
 LATEST_LINK=	${PORTNAME}${PKGNAMESUFFIX}
 
@@ -33,7 +30,7 @@ LATEST_LINK=	${PORTNAME}${PKGNAMESUFFIX}
 USE_PHP=	session snmp mysql
 WANT_PHP_WEB=	yes
 
-.if defined(WITH_GD) && !defined(WITHOUT_GD)
+.if ${PORT_OPTIONS:MGD}
 USE_PHP+=	gd
 .endif
 

Modified: head/net-mgmt/netams/Makefile
==============================================================================
--- head/net-mgmt/netams/Makefile	Fri May 10 11:24:42 2013	(r317789)
+++ head/net-mgmt/netams/Makefile	Fri May 10 11:28:32 2013	(r317790)
@@ -1,9 +1,5 @@
-# New ports collection makefile for: NetAMS
-# Date created:        24 December 2003
-# Whom: 	       jura@netams.com
-#
+# Created by: Yuriy N. Shkandybin <jura@netams.com>
 # $FreeBSD$
-#
 
 PORTNAME=	netams
 PORTVERSION=	3.4.5
@@ -21,10 +17,14 @@ SUB_FILES=	pkg-message
 USE_RC_SUBR=	netams
 MANCOMPRESSED=	no
 
-OPTIONS=	DEBUG		"Build with debug symbols"			off \
-		MYSQL		"Build with MySQL storage support" 		on  \
-		POSTGRESQL	"Build with PostgreSQL storage support"		off \
-		CGI 		"Install admin/user CGI scripts"		off
+OPTIONS_DEFINE=	DEBUG CGI
+OPTIONS_DEFAULT=	MYSQL
+OPTIONS_MULTI=	DATABASE
+OPTIONS_MULTI_DATABASE=	MYSQL POSTGRESQL
+DEBUG_DESC=	Build with debug symbols
+MYSQL_DESC=	Build with MySQL storage support
+POSTGRESQL_DESC=	Build with PostgreSQL storage support
+CGI_DESC=	Install admin/user CGI scripts
 
 SCRIPTS_ENV=	WRKDIRPREFIX="${WRKDIRPREFIX}" \
 		PREFIX="${PREFIX}" \
@@ -46,18 +46,14 @@ MAN8=		netams.8 flowprobe.8 netamsctl.8
 
 .include <bsd.port.pre.mk>
 
-.if !defined(WITH_MYSQL) && !defined(WITH_POSTGRESQL)
-IGNORE=requires at least one database backend selected. Run 'make config'
-.endif
-
-.if defined(WITH_POSTGRESQL)
+.if ${PORT_OPTIONS:MPOSTGRESQL}
 USE_PGSQL=		yes
 PLIST_SUB+=		POSTGRESQL=""
 .else
 PLIST_SUB+=		POSTGRESQL="@comment "
 .endif
 
-.if defined(WITH_MYSQL)
+.if ${PORT_OPTIONS:MMYSQL}
 USE_MYSQL=		yes
 BROKEN_WITH_MYSQL=	323
 PLIST_SUB+=		MYSQL=""
@@ -65,15 +61,15 @@ PLIST_SUB+=		MYSQL=""
 PLIST_SUB+=		MYSQL="@comment "
 .endif
 
-.if defined(WITH_POSTGRESQL) && defined(WITH_CGI)
+.if ${PORT_OPTIONS:MPOSTGRESQL} && ${PORT_OPTIONS:MCGI}
 RUN_DEPENDS+=		p5-DBD-Pg>=0:${PORTSDIR}/databases/p5-DBD-Pg
 .endif
 
-.if defined(WITH_MYSQL) && defined(WITH_CGI)
+.if ${PORT_OPTIONS:MMYSQL} && ${PORT_OPTIONS:MCGI}
 RUN_DEPENDS+=		p5-DBD-mysql50>=0:${PORTSDIR}/databases/p5-DBD-mysql50
 .endif
 
-.if defined(WITH_CGI)
+.if ${PORT_OPTIONS:MCGI}
 RUN_DEPENDS+=	p5-GD>=0:${PORTSDIR}/graphics/p5-GD \
 		p5-GD-Graph>=0:${PORTSDIR}/graphics/p5-GD-Graph \
 		p5-GD-TextUtil>=0:${PORTSDIR}/graphics/p5-GD-TextUtil \
@@ -88,15 +84,15 @@ PLIST_SUB+=	CGI="@comment "
 .endif
 
 pre-patch:
-.if !defined(WITH_DEBUG)
+.if ! ${PORT_OPTIONS:MDEBUG}
 	@${REINPLACE_CMD} -e 's|.*sh configure.sh|& -nodebug|' \
 		${WRKSRC}/Makefile
 .endif
-.if !defined(WITH_POSTGRESQL)
+.if ! ${PORT_OPTIONS:MPOSTGRESQL}
 	@${REINPLACE_CMD} -e 's|locate_file "libpq\.so".*|v1="" \&\& v2=""|' \
 		${WRKSRC}/configure.sh
 .endif
-.if defined(WITH_MYSQL)
+.if ${PORT_OPTIONS:MWITH_MYSQL}
 	@${REINPLACE_CMD} -e 's|^#!/usr/bin/perl|#!/usr/local/bin/perl|' ${WRKSRC}/addon/mysql_rotate.pl
 .else
 	@${REINPLACE_CMD} -e 's|locate_file "libmysqlclient\.so".*|v1="" \&\& v2=""|' \
@@ -121,11 +117,11 @@ do-install:
 	${INSTALL_DATA} ${WRKSRC}/addon/ru-networks.txt ${DATADIR}/ru-networks.txt.sample
 	${INSTALL_DATA} ${WRKSRC}/addon/ua-networks.txt ${DATADIR}/ua-networks.txt.sample
 	${INSTALL_DATA} ${WRKSRC}/addon/.netamsctl.rc ${DATADIR}/.netamsctl.rc
-.if defined(WITH_MYSQL)
+.if ${PORT_OPTIONS:MMYSQL}
 	${INSTALL_DATA} ${WRKSRC}/addon/mysql_rotate.pl ${DATADIR}/mysql_rotate.pl
 	${INSTALL_DATA} ${WRKSRC}/addon/cardtool_schema.sql ${DATADIR}/tools/cardtool_schema.sql
 .endif
-.if defined(WITH_POSTGRESQL)
+.if ${PORT_OPTIONS:MPOSTGRESQL}
 	${INSTALL_DATA} ${WRKSRC}/addon/cardtool_schema-Pg.sql ${DATADIR}/tools/cardtool_schema-Pg.sql
 	${INSTALL_DATA} ${WRKSRC}/addon/postgresql_schema.sql ${DATADIR}/tools/postgresql_schema.sql
 .endif
@@ -138,7 +134,7 @@ do-install:
 	${INSTALL_DATA} ${WRKSRC}/addon/oracle/netams_tg.sql ${DATADIR}/tools/oracle/netams_tg.sql
 	${INSTALL_DATA} ${WRKSRC}/addon/oracle/netams_ts.sql ${DATADIR}/tools/oracle/netams_ts.sql
 	${INSTALL_DATA} ${WRKSRC}/addon/netams-apache-freebsd.conf ${DATADIR}/netams-apache-freebsd.conf
-.if defined(WITH_CGI)
+.if ${PORT_OPTIONS:MCGI}
 	${MKDIR} ${WWWDIR} ${WWWDIR}/cgi-bin ${WWWDIR}/cgi-bin/admin ${WWWDIR}/images
 	${INSTALL_DATA} ${WRKSRC}/addon/index.html ${WWWDIR}/index.html
 	${INSTALL_DATA} ${WRKSRC}/addon/netams.js ${WWWDIR}/netams.js

Modified: head/net-mgmt/p5-Cflow/Makefile
==============================================================================
--- head/net-mgmt/p5-Cflow/Makefile	Fri May 10 11:24:42 2013	(r317789)
+++ head/net-mgmt/p5-Cflow/Makefile	Fri May 10 11:28:32 2013	(r317790)
@@ -1,9 +1,5 @@
-# New ports collection makefile for:	p5-Cflow
-# Date created:			Di  13 Mär 2001 19:37:25 CET
-# Whom:				Andreas Klemm <andreas@klemm.gtn.com>
-#
+# Created by: Andreas Klemm <andreas@klemm.gtn.com>
 # $FreeBSD$
-#
 
 PORTNAME=	Cflow
 PORTVERSION=	1.053
@@ -16,11 +12,12 @@ PKGNAMEPREFIX=	p5-
 MAINTAINER=	fw@moov.de
 COMMENT=	Analyze raw flow files written by cflowd (Cisco NetFlow data)
 
-OPTIONS=	FLOW_TOOLS	"Enable flow-tools support"	off
+OPTIONS_DEFINE=	FLOW_TOOLS
+FLOW_TOOLS_DESC=	Enable flow-tools support
 
-.include <bsd.port.pre.mk>
+.include <bsd.port.options.mk>
 
-.if defined(WITH_FLOW_TOOLS)
+.if ${PORT_OPTIONS:MFLOW_TOOLS}
 BUILD_DEPENDS+=	${LOCALBASE}/lib/libft.a:${PORTSDIR}/net-mgmt/flow-tools
 RUN_DEPENDS+=	${LOCALBASE}/lib/libft.a:${PORTSDIR}/net-mgmt/flow-tools
 
@@ -34,4 +31,4 @@ PERL_CONFIGURE=	YES
 MAN1=		flowdumper.1
 MAN3=		Cflow.3
 
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>

Modified: head/net-mgmt/pftabled/Makefile
==============================================================================
--- head/net-mgmt/pftabled/Makefile	Fri May 10 11:24:42 2013	(r317789)
+++ head/net-mgmt/pftabled/Makefile	Fri May 10 11:28:32 2013	(r317790)
@@ -1,9 +1,5 @@
-# New ports collection makefile for:	pftabled
-# Date created:		2006-11-21
-# Whom:			Bartlomiej Rutkowski <r@robakdesign.com>
-#
+# Created by: Bartlomiej Rutkowski <r@robakdesign.com>
 # $FreeBSD$
-#
 
 PORTNAME=	pftabled
 PORTVERSION=	1.09
@@ -21,19 +17,21 @@ PLIST_FILES=	bin/pftabled-client sbin/pf
 GNU_CONFIGURE=	yes
 USE_GMAKE=	yes
 
-OPTIONS=	PERLC   "A Sample Perl Client" on \
-		PYTHONC "A Sample Python Client" on
+OPTIONS_DEFINE=	PERLC PYTHONC
+OPTIONS_DEFAULT=	PERLC PYTHONC
+PERLC_DESC=	A Sample Perl Client
+PYTHONC_DESC=	A Sample Python Client
 
 .include <bsd.port.pre.mk>
 
-.if !defined(WITHOUT_PERLC)
+.if ${PORT_OPTIONS:MPERLC}
 . if ${PERL_LEVEL} < 500703
 RUN_DEPENDS+=	p5-Digest-MD5>=2.16:${PORTSDIR}/security/p5-Digest-MD5
 . endif
 PLIST_FILES+=	bin/pftabled-client.pl
 .endif
 
-.if !defined(WITHOUT_PYTHONC)
+.if ${PORT_OPTIONS:MPYTHONC}
 PLIST_FILES+=	bin/pftabled-client.py
 .endif
 
@@ -41,10 +39,10 @@ post-patch:
 	@${REINPLACE_CMD} -e 's|cat1/pftabled.0|man1/pftabled.0|' ${WRKSRC}/Makefile.in
 
 post-install:
-.if !defined(WITHOUT_PERLC)
+.if ${PORT_OPTIONS:MPERLC}
 	${INSTALL_SCRIPT} ${WRKSRC}/pftabled-client.pl ${PREFIX}/bin/
 .endif
-.if !defined(WITHOUT_PYTHONC)
+.if ${PORT_OPTIONS:MPYTHONC}
 	${INSTALL_SCRIPT} ${WRKSRC}/pftabled-client.py ${PREFIX}/bin/
 .endif
 

Modified: head/net-mgmt/pnp/Makefile
==============================================================================
--- head/net-mgmt/pnp/Makefile	Fri May 10 11:24:42 2013	(r317789)
+++ head/net-mgmt/pnp/Makefile	Fri May 10 11:28:32 2013	(r317790)
@@ -1,9 +1,5 @@
-# New ports collection makefile for:	pnp
-# Date created:				16 August 2008
-# Whom:					rea-fbsd@codelabs.ru
-#
+# Created by: rea-fbsd@codelabs.ru
 # $FreeBSD$
-#
 
 PORTNAME=	pnp
 PORTVERSION=	0.6.18
@@ -23,7 +19,9 @@ RUN_DEPENDS=	${LOCALBASE}/bin/rrdtool:${
 
 MAKE_JOBS_UNSAFE=	yes
 
-OPTIONS=	PDF "Use built-in fpdf library to produce PDF views" ON
+OPTIONS_DEFINE=	PDF
+OPTIONS_DEFAULT=	PDF
+PDF_DESC=	Use built-in fpdf library to produce PDF views
 
 .include <bsd.port.options.mk>
 
@@ -47,7 +45,7 @@ PNP_URL?=	${NAGIOSHTMURL}/pnp
 FPDF_DIR?=	share/fpdf
 SPOOL_DIRS=	${PNP_STATE}:${NAGIOSUSER}:${NAGIOSGROUP}:0750%${PNP_RRDS}:${NAGIOSUSER}:${NAGIOSGROUP}:0750%${PNP_SPOOL}:${NAGIOSUSER}:${NAGIOSGROUP}:0750
 
-.if !defined(WITH_PDF)
+.if ! ${PORT_OPTIONS:MPDF}
 EXTRA_PATCHES+=	${FILESDIR}/extra-patch-disable-pdf
 .endif
 
@@ -77,7 +75,7 @@ SUB_LIST=	SPOOL_DIRS=${SPOOL_DIRS} \
 		NAGIOSUSER=${NAGIOSUSER} \
 		NAGIOSGROUP=${NAGIOSGROUP}
 
-.if defined(WITH_PDF)
+.if ${PORT_OPTIONS:MPDF}
 PNP_USE_FPDF=	1
 .else
 PNP_USE_FPDF=	0
Comment 5 Baptiste Daroussin freebsd_committer freebsd_triage 2013-05-10 12:30:12 UTC
State Changed
From-To: feedback->closed

Committed. Thanks!