From debd6adca618a9a5029972323fe9953b4d6b006f Mon Sep 17 00:00:00 2001
From: Rong-En Fan <rafan@FreeBSD.org>
Date: Sun, 16 Mar 2008 09:11:50 +0000
Subject: - Fix automatic dependencies

PR:		ports/121687
Submitted by:	Scot Hetzel <swhetzel at gmail.com>
Approved by:	Guido Falsi <mad at madpilot.net> (maintainer)
---
 comms/gnokii/Makefile | 20 ++++++++++++++++----
 1 file changed, 16 insertions(+), 4 deletions(-)

(limited to 'comms/gnokii')

diff --git a/comms/gnokii/Makefile b/comms/gnokii/Makefile
index 5c409a0ffc96..d3d4e419f91a 100644
--- a/comms/gnokii/Makefile
+++ b/comms/gnokii/Makefile
@@ -42,7 +42,7 @@ WANT_GNOME=	yes
 
 .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_ICAL=	yes
 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+=	--enable-libusb
 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 @@ PLIST_SUB+=	MSM='@comment '
 .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
-- 
cgit v1.2.3