From nobody@FreeBSD.org  Mon Dec  9 17:55:34 2013
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115])
	(using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by hub.freebsd.org (Postfix) with ESMTPS id CB8A1B8B
	for <freebsd-gnats-submit@FreeBSD.org>; Mon,  9 Dec 2013 17:55:34 +0000 (UTC)
Received: from oldred.freebsd.org (oldred.freebsd.org [IPv6:2001:1900:2254:206a::50:4])
	(using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by mx1.freebsd.org (Postfix) with ESMTPS id AB0A4106A
	for <freebsd-gnats-submit@FreeBSD.org>; Mon,  9 Dec 2013 17:55:34 +0000 (UTC)
Received: from oldred.freebsd.org ([127.0.1.6])
	by oldred.freebsd.org (8.14.5/8.14.7) with ESMTP id rB9HtY6j033667
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 9 Dec 2013 17:55:34 GMT
	(envelope-from nobody@oldred.freebsd.org)
Received: (from nobody@localhost)
	by oldred.freebsd.org (8.14.5/8.14.5/Submit) id rB9HtYDr033657;
	Mon, 9 Dec 2013 17:55:34 GMT
	(envelope-from nobody)
Message-Id: <201312091755.rB9HtYDr033657@oldred.freebsd.org>
Date: Mon, 9 Dec 2013 17:55:34 GMT
From: Matthieu Volat <mazhe@alkumuna.eu>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [patch] net/mDNSResponder build with yacc (bison not needed)
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         184639
>Category:       ports
>Synopsis:       [patch] net/mDNSResponder build with yacc (bison not needed)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    sunpoet
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Dec 09 18:00:00 UTC 2013
>Closed-Date:    Sat Jan 04 08:26:26 UTC 2014
>Last-Modified:  Sat Jan  4 08:30:05 UTC 2014
>Originator:     Matthieu Volat
>Release:        9.2-RELEASE
>Organization:
>Environment:
FreeBSD freedom.alkumuna.eu 9.2-RELEASE FreeBSD 9.2-RELEASE #0 r255898: Thu Sep 26 22:50:31 UTC 2013     root@bake.isc.freebsd.org:/usr/obj/usr/src/sys/GENERIC  amd64
>Description:
I have noticed by chance that parser files in net/mDNSResponder are in fact well writen and will work with base yacc implementation, thus do not require devel/bison to build.

I've attached a patch that remove the dependency and change the BISON value.
>How-To-Repeat:

>Fix:
See enclosed patch:
1. remove bison in use flags
2. set BISON value to yacc in mDNSPosix/Makefile

Patch attached with submission follows:

diff -ru mDNSResponder.orig/Makefile mDNSResponder/Makefile
--- mDNSResponder.orig/Makefile	2013-12-09 18:21:53.000000000 +0100
+++ mDNSResponder/Makefile	2013-12-09 18:22:32.000000000 +0100
@@ -17,7 +17,7 @@
 BUILD_WRKSRC=	${WRKSRC}/mDNSPosix
 INSTALL_WRKSRC=	${WRKSRC}/mDNSPosix
 MAKE_ARGS=	LOCALBASE=${PREFIX} MANPATH=${MANPREFIX}/man os=freebsd
-USES=		bison gmake
+USES=		gmake
 USE_LDCONFIG=	yes
 USE_RC_SUBR=	mdnsd mdnsresponder
 
diff -ru mDNSResponder.orig/files/patch-mDNSPosix-Makefile mDNSResponder/files/patch-mDNSPosix-Makefile
--- mDNSResponder.orig/files/patch-mDNSPosix-Makefile	2013-12-09 18:21:53.000000000 +0100
+++ mDNSResponder/files/patch-mDNSPosix-Makefile	2013-12-09 18:39:59.000000000 +0100
@@ -1,5 +1,5 @@
---- mDNSPosix/Makefile.orig	2011-11-03 08:23:39.000000000 +0800
-+++ mDNSPosix/Makefile	2013-10-13 02:29:12.791431406 +0800
+--- mDNSPosix/Makefile.orig	2012-10-18 00:11:12.000000000 +0200
++++ mDNSPosix/Makefile	2013-12-09 18:39:26.000000000 +0100
 @@ -54,7 +54,7 @@
  SHAREDDIR ?= ../mDNSShared
  JDK = /usr/jdk
@@ -18,7 +18,15 @@
  # FreeBSD 4 requires threaded code to be compiled and linked using the "-pthread" option,
  # and requires that the "-lpthread" link option NOT be used
  # This appies only to FreeBSD -- "man cc" on FreeBSD says:
-@@ -216,7 +216,7 @@
+@@ -133,6 +133,7 @@
+ LINKOPTS_PTHREAD = -pthread
+ JAVACFLAGS_OS += -I$(JDK)/include/freebsd
+ LDCONFIG = ldconfig
++BISON = @yacc
+ else
+ 
+ ifeq ($(os),openbsd)
+@@ -216,7 +217,7 @@
  
  all: setup Daemon libdns_sd Clients SAClient SAResponder SAProxyResponder Identify NetMonitor dnsextd $(OPTIONALTARG)
  
@@ -27,7 +35,7 @@
  
  # 'setup' sets up the build directory structure the way we want
  setup:
-@@ -259,10 +259,10 @@
+@@ -259,10 +260,10 @@
  	@$(LD) $(LINKOPTS) -o $@ $+
  	@$(STRIP) $@
  
@@ -40,7 +48,7 @@
  	@$(MAKE) -C ../Clients
  
  # nss_mdns target builds the Name Service Switch module
-@@ -276,43 +276,43 @@
+@@ -276,43 +277,43 @@
  #############################################################################
  
  # The Install targets place built stuff in their proper places
@@ -95,7 +103,7 @@
  	$(CP) $< $@
  	chmod ugo+x $@
  	$@ start
-@@ -329,26 +329,26 @@
+@@ -329,26 +330,26 @@
  endif
  endif
  
@@ -128,7 +136,7 @@
  	$(CP) $< $@
  	chmod 444 $@
  
-@@ -490,6 +490,8 @@
+@@ -490,6 +491,8 @@
  $(BUILDDIR)/dnsextd:                 $(DNSEXTDOBJ) $(OBJDIR)/dnsextd.c.threadsafe.o
  	$(CC) $+ -o $@ $(LINKOPTS) $(LINKOPTS_PTHREAD)
  


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->sunpoet 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Mon Dec 9 18:00:08 UTC 2013 
Responsible-Changed-Why:  
Over to maintainer (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=184639 
State-Changed-From-To: open->closed 
State-Changed-By: sunpoet 
State-Changed-When: Sat Jan 4 08:26:26 UTC 2014 
State-Changed-Why:  
Committed. Thanks! 

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

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/184639: commit references a PR
Date: Sat,  4 Jan 2014 08:24:43 +0000 (UTC)

 Author: sunpoet
 Date: Sat Jan  4 08:24:35 2014
 New Revision: 338627
 URL: http://svnweb.freebsd.org/changeset/ports/338627
 
 Log:
   - Use yacc (in base system) instead of bison (from ports tree)
   
   PR:		ports/184639
   Submitted by:	Matthieu Volat <mazhe@alkumuna.eu>
 
 Modified:
   head/net/mDNSResponder/Makefile
   head/net/mDNSResponder/files/patch-mDNSPosix-Makefile
 
 Modified: head/net/mDNSResponder/Makefile
 ==============================================================================
 --- head/net/mDNSResponder/Makefile	Sat Jan  4 08:21:28 2014	(r338626)
 +++ head/net/mDNSResponder/Makefile	Sat Jan  4 08:24:35 2014	(r338627)
 @@ -17,7 +17,7 @@ CONFLICTS=	avahi-libdns-[0-9]*
  BUILD_WRKSRC=	${WRKSRC}/mDNSPosix
  INSTALL_WRKSRC=	${WRKSRC}/mDNSPosix
  MAKE_ARGS=	LOCALBASE=${PREFIX} MANPATH=${MANPREFIX}/man os=freebsd
 -USES=		bison gmake
 +USES=		gmake
  USE_LDCONFIG=	yes
  USE_RC_SUBR=	mdnsd mdnsresponder
  
 
 Modified: head/net/mDNSResponder/files/patch-mDNSPosix-Makefile
 ==============================================================================
 --- head/net/mDNSResponder/files/patch-mDNSPosix-Makefile	Sat Jan  4 08:21:28 2014	(r338626)
 +++ head/net/mDNSResponder/files/patch-mDNSPosix-Makefile	Sat Jan  4 08:24:35 2014	(r338627)
 @@ -1,14 +1,16 @@
 ---- mDNSPosix/Makefile.orig	2011-11-03 08:23:39.000000000 +0800
 -+++ mDNSPosix/Makefile	2013-10-13 02:29:12.791431406 +0800
 -@@ -54,7 +54,7 @@
 +--- mDNSPosix/Makefile.orig	2012-10-18 06:11:12.000000000 +0800
 ++++ mDNSPosix/Makefile	2014-01-04 11:50:07.945929359 +0800
 +@@ -54,8 +54,8 @@
   SHAREDDIR ?= ../mDNSShared
   JDK = /usr/jdk
   
  -CC = @cc
 +-BISON = @bison
  +CC ?= @cc
 - BISON = @bison
 ++BISON = @yacc
   FLEX = @flex
   LD = ld -shared
 + CP = cp
  @@ -122,7 +122,7 @@
   # If not already defined, set LOCALBASE to /usr/local
   LOCALBASE?=/usr/local
 _______________________________________________
 svn-ports-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/svn-ports-all
 To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
 
>Unformatted:
