ports/160388: [PATCH] deskutils/deskbar-applet: conditionally depend on simplejson
Ruslan Mahmatkhanov
cvs-src at yandex.ru
Fri Sep 2 10:10:12 UTC 2011
>Number: 160388
>Category: ports
>Synopsis: [PATCH] deskutils/deskbar-applet: conditionally depend on simplejson
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Fri Sep 02 10:10:11 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator: Ruslan Mahmatkhanov
>Release: 9.0-BETA1
>Organization:
>Environment:
9.0-BETA1 i386
>Description:
deskbar-applet uncoditionally depends on devel/py-simplejson, but it actually should not. simplejson only used in ${WRKSRC}/deskbar/handlers/googlesearch.py:
"""
try:
import json
except:
try:
import simplejson as json
except:
pass
"""
It tries first to import json module (that is a part of python since 2.6) and fallbacks to simplejson if json module is not found.
This patch make it depend on devel/py-simplejson only if python version < 2.6.
>How-To-Repeat:
>Fix:
Patch attached with submission follows:
diff -ruNa deskbar-applet.orig/Makefile deskbar-applet/Makefile
--- deskbar-applet.orig/Makefile 2011-02-25 13:59:08.000000000 +0300
+++ deskbar-applet/Makefile 2011-09-02 14:01:03.000000000 +0400
@@ -8,7 +8,7 @@
PORTNAME= deskbar-applet
PORTVERSION= 2.32.0
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= deskutils gnome
MASTER_SITES= GNOME
DIST_SUBDIR= gnome2
@@ -17,8 +17,7 @@
COMMENT= Omnipresent versatile search interface
BUILD_DEPENDS= ${PYTHON_SITELIBDIR}/dbus/__init__.py:${PORTSDIR}/devel/py-dbus
-RUN_DEPENDS= ${PYTHON_SITELIBDIR}/dbus/__init__.py:${PORTSDIR}/devel/py-dbus \
- ${PYTHON_PKGNAMEPREFIX}simplejson>=2.0:${PORTSDIR}/devel/py-simplejson
+RUN_DEPENDS= ${PYTHON_SITELIBDIR}/dbus/__init__.py:${PORTSDIR}/devel/py-dbus
USE_BZIP2= yes
USE_GETTEXT= yes
@@ -38,6 +37,10 @@
.include <bsd.port.pre.mk>
+.if ${PYTHON_REL} < 260
+RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}simplejson>=2.0.9:${PORTSDIR}/devel/py-simplejson
+.endif
+
_OSRELEASE!= ${UNAME} -r
.if !defined(WITHOUT_EVO)
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list