svn commit: r504996 - in branches/2019Q2/deskutils/conkyemail: . files

Kai Knoblich kai at FreeBSD.org
Sun Jun 23 22:38:07 UTC 2019


Author: kai
Date: Sun Jun 23 22:38:05 2019
New Revision: 504996
URL: https://svnweb.freebsd.org/changeset/ports/504996

Log:
  MFH: r504995
  
  deskutils/conkyemail: Fix invocation of Python script at runtime
  
  Since the default version of Python has been switched to 3.6 in r498529 the
  script "conkyEmail.py" that is invoked by the shell script "conkyEmail"
  fails at runtime due incompatible code.
  
  This occurs only if the Python meta port is also installed otherwise it
  won't start at all due a hardcoded reference (= /usr/bin/env python) in the
  shell script, thus:
  
  * Update and simplify the patch for "conkyEmail" by using placeholders for
    the Python interpreter and ${DATADIR} that will be replaced by the
    post-patch target. [1]
  
  Also while I'm here:
  * Silence all commands of the post-patch target to reduce cluttering of
    logfiles
  * Add license information
  * Pet portlint
  
  PR:		238487
  Submitted by:	Katsuyuki Miyoshi <katsubsd at gmail.com> (initial patch)
  Approved by:	ports-secteam (blanket: runtime fix, framework compliance)

Modified:
  branches/2019Q2/deskutils/conkyemail/Makefile
  branches/2019Q2/deskutils/conkyemail/files/patch-conkyEmail
Directory Properties:
  branches/2019Q2/   (props changed)

Modified: branches/2019Q2/deskutils/conkyemail/Makefile
==============================================================================
--- branches/2019Q2/deskutils/conkyemail/Makefile	Sun Jun 23 22:32:33 2019	(r504995)
+++ branches/2019Q2/deskutils/conkyemail/Makefile	Sun Jun 23 22:38:05 2019	(r504996)
@@ -3,6 +3,7 @@
 
 PORTNAME=	conkyemail
 PORTVERSION=	2.07
+PORTREVISION=	1
 CATEGORIES=	deskutils
 MASTER_SITES=	http://launchpadlibrarian.net/28462213/ \
 		LOCAL/vg
@@ -11,18 +12,24 @@ DISTNAME=	${PORTNAME}_${PORTVERSION}
 MAINTAINER=	ports at FreeBSD.org
 COMMENT=	Email script for conky
 
+LICENSE=	GPLv3
+LICENSE_FILE=	${WRKSRC}/COPYING
+
 RUN_DEPENDS=	conky:sysutils/conky
 
 USES=		python:2.7
 USE_PYTHON=	distutils
+
 NO_BUILD=	yes
 NO_ARCH=	yes
 
 WRKSRC=		${WRKDIR}/src
 
 post-patch:
-	cd ${WRKSRC} && ${REINPLACE_CMD} -e 's,/usr/share/${PORTNAME},${DATADIR},g' \
+	@cd ${WRKSRC} && ${REINPLACE_CMD} -e 's,/usr/share/${PORTNAME},${DATADIR},g; \
+						s,%%DATADIR%%,${DATADIR},; \
+						s,%%PYTHON_CMD%%,${PYTHON_CMD},' \
 		conkyEmail  conkyEmail.py setup.py example/conkyrc
-	cd ${WRKSRC} && ${RM} -r example/conkyrc.bak
+	@cd ${WRKSRC} && ${RM} -r example/conkyrc.bak
 
 .include <bsd.port.mk>

Modified: branches/2019Q2/deskutils/conkyemail/files/patch-conkyEmail
==============================================================================
--- branches/2019Q2/deskutils/conkyemail/files/patch-conkyEmail	Sun Jun 23 22:32:33 2019	(r504995)
+++ branches/2019Q2/deskutils/conkyemail/files/patch-conkyEmail	Sun Jun 23 22:38:05 2019	(r504996)
@@ -1,7 +1,8 @@
---- conkyEmail.orig	2008-09-09 06:12:46.000000000 +0800
-+++ conkyEmail	2010-05-08 02:28:45.000000000 +0800
+--- conkyEmail.orig	2008-09-08 22:12:46 UTC
++++ conkyEmail
 @@ -1,3 +1,3 @@
  #! /bin/sh
- cd /usr/share/conkyemail/
+-cd /usr/share/conkyemail/
 -$PYTHONPATH /usr/bin/python /usr/share/conkyemail/conkyEmail.py "$@"
-+$PYTHONPATH /usr/bin/env python /usr/share/conkyemail/conkyEmail.py "$@"
++cd %%DATADIR%%
++%%PYTHON_CMD%% %%DATADIR%%/conkyEmail.py "$@"


More information about the svn-ports-all mailing list