From nobody@FreeBSD.org  Fri Jul 20 01:55:12 2012
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 07B68106566C
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 20 Jul 2012 01:55:11 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id DCCFF8FC08
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 20 Jul 2012 01:55:11 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.4/8.14.4) with ESMTP id q6K1tBgV046421
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 20 Jul 2012 01:55:11 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.4/8.14.4/Submit) id q6K1tBLT046413;
	Fri, 20 Jul 2012 01:55:11 GMT
	(envelope-from nobody)
Message-Id: <201207200155.q6K1tBLT046413@red.freebsd.org>
Date: Fri, 20 Jul 2012 01:55:11 GMT
From: Glen Barber <gjb@FreeBSD.org>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [patch] net/fping: Update to OPTIONSNG, enforces usage of with or without IPv6
X-Send-Pr-Version: www-3.1
X-GNATS-Notify: jharris@widomaker.com

>Number:         170014
>Category:       ports
>Synopsis:       [patch] net/fping: Update to OPTIONSNG, enforces usage of with or without IPv6
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    gjb
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jul 20 02:00:29 UTC 2012
>Closed-Date:    Fri Aug 03 01:38:25 UTC 2012
>Last-Modified:  Fri Aug 03 01:38:25 UTC 2012
>Originator:     Glen Barber
>Release:        10.0-CURRENT #18 r237614
>Organization:
>Environment:
FreeBSD nucleus 10.0-CURRENT FreeBSD 10.0-CURRENT #18 r237614: Tue Jun 26 22:30:48 EDT 2012     root@nucleus:/usr/obj/usr/src/sys/NUCLEUS  amd64

>Description:
The net/fping port can be build with IPv6 support, however this is not compatible with the default IPv4.

I propose the attached patch, which:

1.) Updates the port to use OPTIONSNG;
2.) As a result of 1, enforces the selection of no more than one NET (IPV4 or IPV6) option.

>How-To-Repeat:

>Fix:
Patch is attached, will await maintainer feedback.


Patch attached with submission follows:

Index: head/net/fping/Makefile
===================================================================
--- head/net/fping/Makefile	(revision 301201)
+++ head/net/fping/Makefile	(working copy)
@@ -23,7 +23,17 @@
 CONFIGURE_ARGS=	--bindir="${PREFIX}/sbin"
 MAN8=		fping.8
 
-.if defined(WITH_IPV6)
+OPTIONS_SINGLE=	NET
+OPTIONS_SINGLE_NET=IPV4 IPV6
+
+OPTIONS_DEFAULT=IPV4
+
+IPV4_DESC=	IPv4 support
+IPV6_DESC=	IPv6 support
+
+.include <bsd.port.options.mk>
+
+.if ${PORT_OPTIONS:MIPV6}
 # IPv6 not enabled by default, as it does not work together with IPv4.
 CFLAGS+=	-DIPV6
 .endif


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->gjb 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Fri Jul 20 02:00:41 UTC 2012 
Responsible-Changed-Why:  
Submitter has GNATS access (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=170014 
State-Changed-From-To: open->feedback 
State-Changed-By: edwin 
State-Changed-When: Fri Jul 20 02:00:47 UTC 2012 
State-Changed-Why:  
Awaiting maintainers feedback (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=170014 

From: Edwin Groothuis <edwin@FreeBSD.org>
To: jharris@widomaker.com
Cc: bug-followup@FreeBSD.org
Subject: Re: ports/170014: [patch] net/fping: Update to OPTIONSNG, enforces usage of with or without IPv6
Date: Fri, 20 Jul 2012 02:00:44 UT

 Maintainer of net/fping,
 
 Please note that PR ports/170014 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/170014
 
 -- 
 Edwin Groothuis via the GNATS Auto Assign Tool
 edwin@FreeBSD.org
State-Changed-From-To: feedback->closed 
State-Changed-By: gjb 
State-Changed-When: Fri Aug 3 01:37:06 UTC 2012 
State-Changed-Why:  
Close this, as it seems we have two ports that do the exact 
opposite of one another (i.e., setting WITH_IPV6 or WITHOUT_IPV6). 

Sounds like a job for OPTIONSNG to me. 


http://www.freebsd.org/cgi/query-pr.cgi?pr=170014 
>Unformatted:
