From nobody@FreeBSD.org  Fri Mar 14 05:31:30 2008
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 554E4106566C
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 14 Mar 2008 05:31:30 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id 429418FC15
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 14 Mar 2008 05:31:30 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.2/8.14.2) with ESMTP id m2E5SApC038167
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 14 Mar 2008 05:28:10 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.2/8.14.1/Submit) id m2E5SA5C038166;
	Fri, 14 Mar 2008 05:28:10 GMT
	(envelope-from nobody)
Message-Id: <200803140528.m2E5SA5C038166@www.freebsd.org>
Date: Fri, 14 Mar 2008 05:28:10 GMT
From: Scot Hetzel <swhetzel@gmail.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [patch] comms/gnokii: several depencancy fixes
X-Send-Pr-Version: www-3.1
X-GNATS-Notify: mad@madpilot.net

>Number:         121687
>Category:       ports
>Synopsis:       [patch] comms/gnokii: several depencancy fixes
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    rafan
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Mar 14 05:40:01 UTC 2008
>Closed-Date:    Sun Mar 16 09:21:38 UTC 2008
>Last-Modified:  Sun Mar 16 09:21:38 UTC 2008
>Originator:     Scot Hetzel
>Release:        FreeBSD 8.0-CURRENT
>Organization:
>Environment:
FreeBSD hp010 8.0-CURRENT FreeBSD 8.0-CURRENT #0: Sat Feb 16 06:42:46 CST 2008     root@hp010:/usr/src/sys/amd64/compile/DV8135NR  amd64

>Description:
When rebuilding comms/gnokii, I found that the port would fail to find libical.so.0.  The reason for this failure is that the current ical port is installing the library as libical.so.27.

I also had the devel/pcsc-lite port installed, and when I built comms/gnokii the configure script found the pcsc-lite library and compiled in support for PC/SC cards.

Another thing I found annoying is the automatic dependency on MySQL and PostgresSQL. For instance, when the x11/kde3 is installed, it will pull in quite a few dependencies when installing the various ports that make up KDE.  During the install, it will install both MySQL and PostgresSQL.  A few ports down the road, it will build gnokii which will detect both *SQL ports are install, which causes gnokii to compile in support for both of them.  I would prefer to have the ability to disable one or both automatic dependencies. 
>How-To-Repeat:
Run `make config` and choose the MDNS_AVAHI option, then try to build the port.

Install both MySQL and PostgresSQL, then build the port.  It will have a dependency on both ports.

>Fix:
The attached patch fixes these dependency problems.

Patch attached with submission follows:

Index: comms/gnokii/Makefile
===================================================================
RCS file: /home/ncvs/ports/comms/gnokii/Makefile,v
retrieving revision 1.62
diff -u -r1.62 Makefile
--- comms/gnokii/Makefile	16 Feb 2008 16:36:58 -0000	1.62
+++ comms/gnokii/Makefile	7 Mar 2008 13:57:11 -0000
@@ -42,7 +42,7 @@
 
 .include <bsd.port.pre.mk>
 
-.if exists(${LOCALBASE}/lib/libical.so.0)
+.if exists(${LOCALBASE}/lib/libical.so)
 WITH_ICAL=	yes
 .endif
 
@@ -50,8 +50,12 @@
 WITH_USB=	yes
 .endif
 
+.if exists(${LOCALBASE}/lib/libpcsclite.so) && !defined(WITHOUT_PCSC)
+WITH_PCSC=	yes
+.endif
+
 .if defined(WITH_ICAL)
-LIB_DEPENDS+=	ical.0:${PORTSDIR}/devel/libical
+LIB_DEPENDS+=	ical.27:${PORTSDIR}/devel/libical
 .endif
 
 .if defined(WITH_USB)
@@ -62,6 +66,14 @@
 CONFIGURE_ARGS+=	--disable-libusb
 .endif
 
+.if defined(WITH_PCSC)
+LIB_DEPENDS+=	pcsclite.1:${PORTSDIR}/devel/pcsc-lite
+
+CONFIGURE_ARGS+=	--enable-libpcsclite
+.else
+CONFIGURE_ARGS+=	--disable-libpcsclite
+.endif
+
 # If smsd is enabled check if MySQL or PostgreSQL are installed and
 # build the modules, no switches to make this port build those, if
 # you want them, just install them before this port. The port will
@@ -73,14 +85,14 @@
 .else
 PLIST_SUB+=	SMSD=''
 MAN8+=		smsd.8
-.if exists(${LOCALBASE}/lib/mysql/libmysqlclient.so)
+.if exists(${LOCALBASE}/lib/mysql/libmysqlclient.so) && !defined(WITHOUT_MYSQL)
 USE_MYSQL=	yes
 PLIST_SUB+=	MSM=''
 WITH_MYSQL=	yes
 .else
 PLIST_SUB+=	MSM='@comment '
 .endif
-.if exists(${LOCALBASE}/bin/psql)
+.if exists(${LOCALBASE}/bin/psql) && !defined(WITHOUT_PGSQL)
 USE_PGSQL=	yes
 PLIST_SUB+=	PGM=''
 WITH_PGSQL=	yes


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->feedback 
State-Changed-By: edwin 
State-Changed-When: Fri Mar 14 05:40:06 UTC 2008 
State-Changed-Why:  
Awaiting maintainers feedback (via the GNATS Auto Assign Tool) 

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

From: Guido Falsi <mad@madpilot.net>
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/121687: [patch] comms/gnokii: several depencancy fixes
Date: Fri, 14 Mar 2008 11:30:53 +0100

 On Fri, Mar 14, 2008 at 05:40:04AM +0000, Edwin Groothuis wrote:
 > Maintainer of comms/gnokii,
 
 I see no problem with the patch, thank you for pointing out the
 problems.
 
 I approve it.
 
 -- 
 Guido Falsi <mad@madpilot.net>
State-Changed-From-To: feedback->open 
State-Changed-By: linimon 
State-Changed-When: Sat Mar 15 08:14:27 UTC 2008 
State-Changed-Why:  
Maintainer approved. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=121687 
Responsible-Changed-From-To: freebsd-ports-bugs->rafan 
Responsible-Changed-By: rafan 
Responsible-Changed-When: Sun Mar 16 09:09:53 UTC 2008 
Responsible-Changed-Why:  
I'll take it. 

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

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/121687: commit references a PR
Date: Sun, 16 Mar 2008 09:11:54 +0000 (UTC)

 rafan       2008-03-16 09:11:50 UTC
 
   FreeBSD ports repository
 
   Modified files:
     comms/gnokii         Makefile 
   Log:
   - Fix automatic dependencies
   
   PR:             ports/121687
   Submitted by:   Scot Hetzel <swhetzel at gmail.com>
   Approved by:    Guido Falsi <mad at madpilot.net> (maintainer)
   
   Revision  Changes    Path
   1.63      +16 -4     ports/comms/gnokii/Makefile
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
State-Changed-From-To: open->closed 
State-Changed-By: rafan 
State-Changed-When: Sun Mar 16 09:21:37 UTC 2008 
State-Changed-Why:  
Committed. Thanks! 

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