From gvs@road.yandex.ru  Mon Sep 13 14:41:21 2004
Return-Path: <gvs@road.yandex.ru>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 4DA1A16A4CE
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 13 Sep 2004 14:41:21 +0000 (GMT)
Received: from road.yandex.ru (road.yandex.ru [213.180.193.165])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 90B2043D3F
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 13 Sep 2004 14:41:20 +0000 (GMT)
	(envelope-from gvs@road.yandex.ru)
Received: from road.yandex.ru (localhost.yandex.net [127.0.0.1] (may be forged))
	by road.yandex.ru (8.13.1/8.13.1) with ESMTP id i8DEgL1g089879
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 13 Sep 2004 18:42:21 +0400 (MSD)
	(envelope-from gvs@road.yandex.ru)
Received: (from root@localhost)
	by road.yandex.ru (8.13.1/8.13.1/Submit) id i8DEgKO7089878;
	Mon, 13 Sep 2004 18:42:20 +0400 (MSD)
	(envelope-from gvs)
Message-Id: <200409131442.i8DEgKO7089878@road.yandex.ru>
Date: Mon, 13 Sep 2004 18:42:20 +0400 (MSD)
From: Seva Gluschenko <gvs@rinet.ru>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: x11/kdelibs3 and misc/kdeutils3 have optional dependencies
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         71703
>Category:       ports
>Synopsis:       x11/kdelibs3 and misc/kdeutils3 have optional dependencies
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Sep 13 14:50:22 GMT 2004
>Closed-Date:    Mon Sep 13 15:40:17 GMT 2004
>Last-Modified:  Mon Sep 13 15:40:17 GMT 2004
>Originator:     Seva Gluschenko
>Release:        FreeBSD 5.3-BETA3 i386
>Organization:
Yandex LLC
>Environment:
System: FreeBSD road.yandex.ru 5.3-BETA3 FreeBSD 5.3-BETA3 #11: Tue Sep 7 19:13:32 MSD 2004 gvs@road.yandex.ru:/local/obj/local/usr/src/sys/ROAD i386


	
>Description:
	x11/kdelibs3 port depends on devel/fam which isn't really needed.
	misc/kdeutils port depends on net-mgmt/net-snmp which isn't really needed, too.
>How-To-Repeat:
	
>Fix:

	Apply patch below, it makes the dependencies mentioned optional:

	# cd /usr/ports
	# patch < /path/to/file

--- misc/kdeutils3/Makefile.orig	Mon Sep 13 10:55:38 2004
+++ misc/kdeutils3/Makefile	Mon Sep 13 18:34:36 2004
@@ -15,7 +15,6 @@
 MAINTAINER?=	kde@FreeBSD.org
 COMMENT=	Utilities for the KDE integrated X11 desktop
 
-LIB_DEPENDS=	netsnmp:${PORTSDIR}/net-mgmt/net-snmp
 RUN_DEPENDS=	gpg:${PORTSDIR}/security/gnupg
 
 CONFLICTS=	kgpg-*
@@ -33,8 +32,21 @@
 
 CONFLICTS=	kgpg-[0-9]*
 
+OPTIONS=	SNMP "SNMP utilities support" off
+
 INSTALLS_SHLIB=	yes
 LDCONFIG_DIRS+=	%%PREFIX%%/lib %%PREFIX%%/lib/kde3
 
 .include "${.CURDIR}/../../x11/kde3/Makefile.kde"
 .include <bsd.port.mk>
+
+.if exists(${LOCALBASE}/bin/snmpwalk)
+.	if !defined(WITH_SNMP)
+SNMP_OVERRIDE=	yes
+WITH_SNMP=	yes
+.	endif
+.endif
+
+.if defined(WITH_SNMP)
+LIB_DEPENDS+=	netsnmp:${PORTSDIR}/net-mgmt/net-snmp
+.endif # defined ($(WITH_SNMP))
--- x11/kdelibs3/Makefile.orig	Mon Sep  6 22:34:18 2004
+++ x11/kdelibs3/Makefile	Mon Sep 13 18:38:50 2004
@@ -25,7 +25,6 @@
 		artsc.0:${PORTSDIR}/audio/arts \
 		aspell:${PORTSDIR}/textproc/aspell \
 		cups.2:${PORTSDIR}/print/cups-base \
-		fam.0:${PORTSDIR}/devel/fam \
 		idn:${PORTSDIR}/devel/libidn \
 		jasper:${PORTSDIR}/graphics/jasper \
 		tiff.4:${PORTSDIR}/graphics/tiff \
@@ -58,6 +57,8 @@
 FONTSCALE=	${X11BASE}/lib/X11/fonts/TTF/luximb.ttf
 FONTENCOD=	${X11BASE}/lib/X11/fonts/encodings/tcvn-0.enc
 
+OPTIONS=	FAM "file alteration monitor feature" off
+
 .include "${.CURDIR}/../../x11/kde3/Makefile.kde"
 .include <bsd.port.pre.mk>
 
@@ -65,6 +66,17 @@
 .if !exists(/usr/bin/bzip2)
 LIB_DEPENDS+=	bz2.1:${PORTSDIR}/archivers/bzip2
 .endif # !exists(/usr/bin/bzip2)
+
+.if exists(${LOCALBASE}/bin/fam)
+.	if !defined(WITH_FAM)
+FAM_OVERRIDE=	yes
+WITH_FAM=	yes
+.	endif
+.endif
+
+.if defined(WITH_FAM)
+LIB_DEPENDS+=	fam.0:${PORTSDIR}/devel/fam
+.endif # defined ($(WITH_FAM))
 
 pre-configure:
 	${REINPLACE_CMD} "s, kspell,,g" ${WRKSRC}/doc/Makefile.in


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: lofi 
State-Changed-When: Mon Sep 13 15:35:17 GMT 2004 
State-Changed-Why:  
Build switches are deprecated for kde module ports. Additionally, omitting those 
dependencies invalidates pkg-plist. 

If you want to work around the snmp dependency badly, consider submitting a split 
port for the application in kdeutils which introduces the dependency. This is 
not possible for the fam dependency in kdelibs so this dependency will need to 
remain. 

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