From dan@m8-64.freebsd.cz  Wed Jun 26 14:52:55 2013
Return-Path: <dan@m8-64.freebsd.cz>
Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115])
	by hub.freebsd.org (Postfix) with ESMTP id DCA84A24
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 26 Jun 2013 14:52:55 +0000 (UTC)
	(envelope-from dan@m8-64.freebsd.cz)
Received: from m8-64.freebsd.cz (m8-64.freebsd.cz [195.113.20.206])
	by mx1.freebsd.org (Postfix) with ESMTP id 6EF491B2C
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 26 Jun 2013 14:52:54 +0000 (UTC)
Received: from m8-64.freebsd.cz (localhost [127.0.0.1])
	by m8-64.freebsd.cz (8.14.5/8.14.4) with ESMTP id r5QEqfh3042281
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 26 Jun 2013 16:52:41 +0200 (CEST)
	(envelope-from dan@m8-64.freebsd.cz)
Received: (from root@localhost)
	by m8-64.freebsd.cz (8.14.5/8.14.5/Submit) id r5QEqfRM042280;
	Wed, 26 Jun 2013 16:52:41 +0200 (CEST)
	(envelope-from dan)
Message-Id: <201306261452.r5QEqfRM042280@m8-64.freebsd.cz>
Date: Wed, 26 Jun 2013 16:52:41 +0200 (CEST)
From: Dan Lukes <dan@obluda.cz>
Reply-To: Dan Lukes <dan@obluda.cz>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: [ patch ] lang/gawk: unrecorded dependency
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         180004
>Category:       ports
>Synopsis:       [ patch ] lang/gawk: unrecorded dependency
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    johans
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Jun 26 15:00:00 UTC 2013
>Closed-Date:    Sat Jun 29 09:30:47 UTC 2013
>Last-Modified:  Sat Jun 29 09:40:00 UTC 2013
>Originator:     Dan Lukes
>Release:        FreeBSD
>Organization:
Obludarium
>Environment:
lang/gawk/Makefile 318249 2013-05-15 17:03:17Z johans

>Description:
	if math/mpfr and math/gmp are present at th etime of gawk compilation
        then they are detected by configure and linked to gawk
	such dependency is not recorded, so package installed
	on other system without mfpr&gmp will not start

>How-To-Repeat:
	compile lang/gawk on system with math/mpfr & math/gmp present
	then deinstall math/mpfr & math/gmp
	then try to run gawk
>Fix:

	gawk should not be linked against mpfr&gmp unless requested
	by administrator. 
	Dependencies need to be properly recorded in such case.

	See patch bellow

--- patch-gawk begins here ---
--- lang/gawk/Makefile.orig	2013-06-26 16:30:37.000000000 +0200
+++ lang/gawk/Makefile	2013-06-26 16:35:15.000000000 +0200
@@ -27,6 +27,17 @@
 
 .include <bsd.port.options.mk>
 
+.if ${PORT_OPTIONS:MPFR}
+LIB_DEPENDS=    gmp:${PORTSDIR}/math/gmp \
+                mpfr:${PORTSDIR}/math/mpfr
+CONFIGURE_ARGS= --with-gmp=${LOCALBASE} \
+                --with-mpfr=${LOCALBASE}
+                                
+.else
+CONFIGURE_ARGS+=--without-gmp\
+                --without-mpfr
+.endif
+
 .if ${PORT_OPTIONS:MNLS}
 USES+=		gettext
 PLIST_SUB+=	NLS=""
--- patch-gawk ends here ---


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->johans 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Wed Jun 26 15: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=180004 
State-Changed-From-To: open->closed 
State-Changed-By: johans 
State-Changed-When: Sat Jun 29 09:30:34 UTC 2013 
State-Changed-Why:  
Committed, thanks. 

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

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/180004: commit references a PR
Date: Sat, 29 Jun 2013 09:30:35 +0000 (UTC)

 Author: johans
 Date: Sat Jun 29 09:30:23 2013
 New Revision: 322035
 URL: http://svnweb.freebsd.org/changeset/ports/322035
 
 Log:
   - Make optional dependency on libmpfr explicit in GNU awk
     This adds support for multiple-precision floating-point computation
   
   PR:		ports/180004
   Submitted by:	Dan Lukes <dan@obluda.cz>
 
 Modified:
   head/lang/gawk/Makefile
 
 Modified: head/lang/gawk/Makefile
 ==============================================================================
 --- head/lang/gawk/Makefile	Sat Jun 29 09:25:14 2013	(r322034)
 +++ head/lang/gawk/Makefile	Sat Jun 29 09:30:23 2013	(r322035)
 @@ -11,6 +11,9 @@ COMMENT=	The GNU version of Awk
  
  LIB_DEPENDS=	sigsegv:${PORTSDIR}/devel/libsigsegv
  
 +OPTIONS_DEFINE=	MPFR
 +MPFR_DESC?=	Support multiple-precision floating-point computation
 +
  INFO=		gawk gawkinet
  
  USE_XZ=		true
 @@ -35,6 +38,12 @@ CONFIGURE_ARGS+=--disable-nls
  PLIST_SUB+=	NLS="@comment "
  .endif
  
 +.if ${PORT_OPTIONS:MMPFR}
 +LIB_DEPENDS=	mpfr:${PORTSDIR}/math/mpfr
 +.else
 +CONFIGURE_ARGS+=--without-gmp --without-mpfr
 +.endif
 +
  post-patch:
  	@${RM} -f ${WRKSRC}/doc/*.info
  	@${REINPLACE_CMD} -e 's/ -export-dynamic/ -Wl,--export-dynamic/' \
 _______________________________________________
 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:
