Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 24 Jan 2010 23:04:06 GMT
From:      Sevan Janiyan <venture37@geeklan.co.uk>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        lioux@FreeBSD.org
Subject:   ports/143194: [PATCH] net-p2p/i2p: use $SUB_FILES to update pkg-message 
Message-ID:  <201001242304.o0ON469B087048@newbie.thingamajig-systems.co.uk>
Resent-Message-ID: <201001242310.o0ONA6gT082498@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         143194
>Category:       ports
>Synopsis:       [PATCH] net-p2p/i2p: use $SUB_FILES to update pkg-message
>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:   Sun Jan 24 23:10:05 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator:     Sevan Janiyan
>Release:        FreeBSD 8.0-RELEASE-p2 amd64
>Organization:
>Environment:
System: FreeBSD newbie.thingamajig-systems.co.uk 8.0-RELEASE-p2 FreeBSD 8.0-RELEASE-p2 #0: Tue Jan  5 21:11:58 UTC
>Description:

Added file(s):
- files/wrapper.sh.in

Removed file(s):
- files/wrapper.sh

Port maintainer (lioux@FreeBSD.org) is cc'd.

Generated with FreeBSD Port Tools 0.99
>How-To-Repeat:
>Fix:

--- i2p-0.7.9.patch begins here ---
Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/net-p2p/i2p/Makefile,v
retrieving revision 1.56
diff -u -r1.56 Makefile
--- Makefile	18 Jan 2010 09:08:54 -0000	1.56
+++ Makefile	24 Jan 2010 23:03:15 -0000
@@ -54,14 +54,13 @@
 
 JETTY_DISTFILE=	jetty-5.1.12.zip
 
+SUB_FILES=	wrapper.sh
+
 post-extract:
 	@${MKDIR} ${WRKSRC}/apps/jetty/
 	@${CP} -f ${DISTDIR}/${JETTY_DISTFILE} ${WRKSRC}/apps/jetty/
 
 post-patch:
-	@${SED} \
-		-e "s|%%DATADIR%%|${DATADIR}|" \
-		${FILESDIR}/wrapper.sh > ${WRKDIR}/wrapper.sh
 # postinstall.sh SHOULD only do post installation house keeping
 	@${REINPLACE_CMD} -E \
 		-e 's|./i2prouter[[:space:]]+start||' \
Index: files/wrapper.sh
===================================================================
RCS file: files/wrapper.sh
diff -N files/wrapper.sh
--- files/wrapper.sh	4 Mar 2005 02:47:29 -0000	1.2
+++ /dev/null	1 Jan 1970 00:00:00 -0000
@@ -1,71 +0,0 @@
-#!/bin/sh
-#
-# Under a BSDL license. Copyright by Mario S F Ferreira <lioux@FreeBSD.org>
-# $FreeBSD: ports/net-p2p/i2p/files/wrapper.sh,v 1.2 2005/03/04 02:47:29 lioux Exp $
-
-DATADIR="%%DATADIR%%"
-#
-I2P_HOME="${HOME}/i2p"
-I2P_RC_SCRIPT=i2prouter
-I2P_POSTINSTALL_SCRIPT=postinstall.sh
-#
-I2P_INSTALL_TARBALL=i2p.tar.bz2
-I2P_UPDATE_ZIP=i2pupdate.zip
-
-if [ -z "${HOME}" -o ! -d "${HOME}" ]; then
-	echo 'ERROR: Please, set HOME environment variable to a valid value!'
-	echo 'ERROR: You may LOSE data if the variable is pointed at an'
-	echo 'ERROR: incorrect location!'
-	exit 1
-fi
-
-case "$1" in
-	restart|start|status|stop)
-		echo "i2p ${1}"
-		if [ -f "${I2P_HOME}/${I2P_RC_SCRIPT}" ]; then
-			case "$1" in
-				restart|start)
-					echo 'To access i2p:'
-					echo 'Point your browser at http://localhost:7657/ to access configuration'
-					echo 'Point your browser proxy at http://localhost:4444/ to access i2p network'
-				;;
-			esac
-			exec sh "${I2P_HOME}/${I2P_RC_SCRIPT}" ${1}
-		else
-			echo 'ERROR: i2p is not installed'
-			echo 'ERROR: Please install i2p first'
-			exit 2
-		fi
-		;;
-	install)
-		echo "i2p ${1}"
-		if [ ! -d "${I2P_HOME}" ]; then
-			rm -Rf "${I2P_HOME}"
-			mkdir -p "${I2P_HOME}"
-		fi
-		cd "${HOME}" && \
-			tar -xvjf "${DATADIR}/${I2P_INSTALL_TARBALL}" && \
-			cd "${I2P_HOME}" &&  \
-				exec sh "${I2P_HOME}/${I2P_POSTINSTALL_SCRIPT}"
-		;;
-	uninstall)
-		echo "i2p ${1}"
-		exec rm -Rf "${I2P_HOME}"
-		;;
-	update)
-		echo "i2p ${1}"
-		if [ ! -d "${I2P_HOME}" ]; then
-			echo 'ERROR: i2p is not installed'
-			echo 'ERROR: Please install i2p before trying to update it'
-			exit 3
-		fi
-		cd "${I2P_HOME}" &&  \
-			exec unzip -o "${DATADIR}/${I2P_UPDATE_ZIP}"
-		;;
-	*)
-		echo ""
-		echo "Usage: `basename $0` { start | stop | status | restart | install | uninstall | update }"
-		echo ""
-		exit 64
-		;;
-esac
Index: files/wrapper.sh.in
===================================================================
RCS file: files/wrapper.sh.in
diff -N files/wrapper.sh.in
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ files/wrapper.sh.in	24 Jan 2010 23:03:15 -0000
@@ -0,0 +1,71 @@
+#!/bin/sh
+#
+# Under a BSDL license. Copyright by Mario S F Ferreira <lioux@FreeBSD.org>
+# $FreeBSD: ports/net-p2p/i2p/files/wrapper.sh,v 1.2 2005/03/04 02:47:29 lioux Exp $
+
+DATADIR="%%DATADIR%%"
+#
+I2P_HOME="${HOME}/i2p"
+I2P_RC_SCRIPT=i2prouter
+I2P_POSTINSTALL_SCRIPT=postinstall.sh
+#
+I2P_INSTALL_TARBALL=i2p.tar.bz2
+I2P_UPDATE_ZIP=i2pupdate.zip
+
+if [ -z "${HOME}" -o ! -d "${HOME}" ]; then
+	echo 'ERROR: Please, set HOME environment variable to a valid value!'
+	echo 'ERROR: You may LOSE data if the variable is pointed at an'
+	echo 'ERROR: incorrect location!'
+	exit 1
+fi
+
+case "$1" in
+	restart|start|status|stop)
+		echo "i2p ${1}"
+		if [ -f "${I2P_HOME}/${I2P_RC_SCRIPT}" ]; then
+			case "$1" in
+				restart|start)
+					echo 'To access i2p:'
+					echo 'Point your browser at http://localhost:7657/ to access configuration'
+					echo 'Point your browser proxy at http://localhost:4444/ to access i2p network'
+				;;
+			esac
+			exec sh "${I2P_HOME}/${I2P_RC_SCRIPT}" ${1}
+		else
+			echo 'ERROR: i2p is not installed'
+			echo 'ERROR: Please install i2p first'
+			exit 2
+		fi
+		;;
+	install)
+		echo "i2p ${1}"
+		if [ ! -d "${I2P_HOME}" ]; then
+			rm -Rf "${I2P_HOME}"
+			mkdir -p "${I2P_HOME}"
+		fi
+		cd "${HOME}" && \
+			tar -xvjf "${DATADIR}/${I2P_INSTALL_TARBALL}" && \
+			cd "${I2P_HOME}" &&  \
+				exec sh "${I2P_HOME}/${I2P_POSTINSTALL_SCRIPT}"
+		;;
+	uninstall)
+		echo "i2p ${1}"
+		exec rm -Rf "${I2P_HOME}"
+		;;
+	update)
+		echo "i2p ${1}"
+		if [ ! -d "${I2P_HOME}" ]; then
+			echo 'ERROR: i2p is not installed'
+			echo 'ERROR: Please install i2p before trying to update it'
+			exit 3
+		fi
+		cd "${I2P_HOME}" &&  \
+			exec unzip -o "${DATADIR}/${I2P_UPDATE_ZIP}"
+		;;
+	*)
+		echo ""
+		echo "Usage: `basename $0` { start | stop | status | restart | install | uninstall | update }"
+		echo ""
+		exit 64
+		;;
+esac
--- i2p-0.7.9.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201001242304.o0ON469B087048>