mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-27 00:57:50 +00:00
- Update to 0.7
- Change it to run as jabber and not more as root, which is an unecessary security risk [1] PR: ports/93991 [1] Submitted by: Neil Darlow <neil@darlow.co.uk> [1] Approved by: portmgr (erwing)
This commit is contained in:
parent
4fdf2c1e25
commit
2b80f5825b
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=156936
@ -5,8 +5,7 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PORTNAME= pyicq
|
||||
PORTVERSION= 0.6
|
||||
PORTREVISION= 1
|
||||
PORTVERSION= 0.7
|
||||
CATEGORIES= net-im
|
||||
MASTER_SITES= http://www.blathersource.org/download.php/pyicq-t/
|
||||
PKGNAMEPREFIX= jabber-
|
||||
@ -18,7 +17,8 @@ MAINTAINER= garga@FreeBSD.org
|
||||
COMMENT= Python ICQ-Transport for Jabber
|
||||
|
||||
RUN_DEPENDS= ${PYTHON_SITELIBDIR}/OpenSSL/__init__.py:${PORTSDIR}/security/py-openssl \
|
||||
${PYTHON_SITELIBDIR}/twisted/__init__.py:${PORTSDIR}/devel/py-twisted
|
||||
${PYTHON_SITELIBDIR}/twisted/__init__.py:${PORTSDIR}/devel/py-twisted \
|
||||
${PYTHON_SITELIBDIR}/PIL/__init__.py::${PORTSDIR}/graphics/py-imaging
|
||||
|
||||
NO_BUILD= yes
|
||||
USE_PYTHON= yes
|
||||
@ -29,32 +29,35 @@ SUB_LIST= PYTHON_CMD=${PYTHON_CMD}
|
||||
|
||||
INST_DIR= ${PREFIX}/lib/jabber/${PORTNAME}
|
||||
|
||||
PORTDOCS= COPYING README TODO
|
||||
PORTDOCS= COPYING README NEWS
|
||||
|
||||
post-extract:
|
||||
@${FIND} ${WRKSRC}/src -type d -name '.svn' | ${XARGS} ${RM} -rf
|
||||
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e '/spooldir/s|\.|/var/spool/jabber|' \
|
||||
-e '/pid/s|PyICQt.pid|/var/jabberd/pid/${PORTNAME}.pid|' \
|
||||
-e '/<debugOn>/s|<debugOn>|<!--<debugOn>-->|' \
|
||||
-e '/pid/s|PyICQt.pid|/var/jabberd/pid/PyICQt.pid|' \
|
||||
${WRKSRC}/config_example.xml
|
||||
@${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g; s|%%PYTHON_CMD%%|${PYTHON_CMD}|g' \
|
||||
${WRKSRC}/src/main.py
|
||||
@${REINPLACE_CMD} -i "" 's|#!/usr/bin/python|#!${PYTHON_CMD}|' \
|
||||
${WRKSRC}/PyICQt.py
|
||||
@${RM} ${WRKSRC}/src/main.py.*
|
||||
@${MV} ${WRKSRC}/src/config.py ${WRKSRC}/src/config.py.sample
|
||||
|
||||
do-install:
|
||||
${INSTALL} -d ${INST_DIR}
|
||||
${CP} -pPR ${WRKSRC}/src/* ${INST_DIR}/
|
||||
${CHMOD} 755 ${INST_DIR}/main.py
|
||||
[ -f ${INST_DIR}/config.py ] || ${CP} ${INST_DIR}/config.py.sample ${INST_DIR}/config.py
|
||||
${MKDIR} ${INST_DIR}/src ${INST_DIR}/data
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/PyICQt.py ${INST_DIR}
|
||||
${INSTALL_DATA} ${WRKSRC}/data/defaultAIMAvatar.png ${INST_DIR}/data
|
||||
${INSTALL_DATA} ${WRKSRC}/data/defaultICQAvatar.png ${INST_DIR}/data
|
||||
@${CP} -Rv ${WRKSRC}/src/* ${INST_DIR}/src
|
||||
@${FIND} ${INST_DIR}/src/ -type d -exec ${CHMOD} 755 "{}" \;
|
||||
@${FIND} ${INST_DIR}/src/ -type f -exec ${CHMOD} 644 "{}" \;
|
||||
@${MKDIR} ${EXAMPLESDIR}/etc
|
||||
${INSTALL_DATA} ${WRKSRC}/config_example.xml ${EXAMPLESDIR}/etc/jabber-pyicq.xml
|
||||
[ -f ${PREFIX}/etc/jabber-pyicq.xml ] || ${CP} ${EXAMPLESDIR}/etc/jabber-pyicq.xml ${PREFIX}/etc/jabber-pyicq.xml
|
||||
.if !defined(NOPORTDOCS)
|
||||
${MKDIR} ${DOCSDIR}
|
||||
.for portdoc in ${PORTDOCS}
|
||||
@${MKDIR} ${DOCSDIR}
|
||||
${INSTALL_DATA} ${WRKSRC}/${portdoc} ${DOCSDIR}/
|
||||
.endfor
|
||||
.endif
|
||||
|
@ -1,3 +1,3 @@
|
||||
MD5 (jabber/pyicq-t-0.6.tar.gz) = 5c6f8cd598465124d886f1c47f88c809
|
||||
SHA256 (jabber/pyicq-t-0.6.tar.gz) = 143f1b037e8a0c83d69ac51f28835e8ce963f52c076ac6175715c60f05a63011
|
||||
SIZE (jabber/pyicq-t-0.6.tar.gz) = 140654
|
||||
MD5 (jabber/pyicq-t-0.7.tar.gz) = d5e668f215bd36c82a1e5506fc484888
|
||||
SHA256 (jabber/pyicq-t-0.7.tar.gz) = 127889288441f9fa92e0ae992a3c4e884228d130f71b950f826404c91aa9e3cf
|
||||
SIZE (jabber/pyicq-t-0.7.tar.gz) = 138023
|
||||
|
@ -22,10 +22,11 @@ load_rc_config $name
|
||||
: ${jabber_pyicq_enable="NO"}
|
||||
: ${jabber_pyicq_dir="%%PREFIX%%/lib/jabber/pyicq"}
|
||||
: ${jabber_pyicq_piddir="/var/jabberd/pid"}
|
||||
: ${jabber_pyicq_user="jabber"}
|
||||
|
||||
pidfile="${jabber_pyicq_piddir}/pyicq.pid"
|
||||
pidfile="${jabber_pyicq_piddir}/PyICQt.pid"
|
||||
command_interpreter="%%PYTHON_CMD%%"
|
||||
command="${jabber_pyicq_dir}/main.py"
|
||||
command_args="-o pid=${pidfile} &"
|
||||
command="${jabber_pyicq_dir}/PyICQt.py"
|
||||
command_args="-b -o pid=${pidfile}"
|
||||
|
||||
run_rc_command "$1"
|
||||
|
@ -1,24 +1,16 @@
|
||||
--- src/main.py.orig Tue Jun 7 09:54:58 2005
|
||||
+++ src/main.py Tue Jun 7 09:56:26 2005
|
||||
--- src/main.py.orig Sat Feb 11 01:14:59 2006
|
||||
+++ src/main.py Thu Mar 2 17:01:07 2006
|
||||
@@ -1,3 +1,4 @@
|
||||
+#!%%PYTHON_CMD%%
|
||||
# Copyright 2004 James Bunton <james@delx.cjb.net>
|
||||
# Copyrigh 2004-2005 Daniel Henninger <jadestorm@nc.rr.com>
|
||||
# Licensed for distribution under the GPL version 2, check COPYING for details
|
||||
|
||||
@@ -13,15 +14,9 @@
|
||||
print("You are using version %s of Python, at least 2.3 is required." % (sys.version[:3]))
|
||||
os._exit(0)
|
||||
@@ -34,7 +35,7 @@
|
||||
|
||||
-name = "PyICQt"
|
||||
-exe = os.path.realpath(sys.executable)
|
||||
-if (exe.find("python") >= 0):
|
||||
- print("Restarting with process name %s..." % (name))
|
||||
- os.execv(exe, [name, sys.argv[0]]+sys.argv[1:])
|
||||
-
|
||||
import config
|
||||
import xmlconfig
|
||||
-conffile = "config.xml"
|
||||
+conffile = "%%PREFIX%%/etc/jabber-pyicq.xml"
|
||||
options = {}
|
||||
opts, args = getopt.getopt(sys.argv[1:], "c:o:dDl:h", ["config=", "option=", "debug", "Debug", "log=", "help"])
|
||||
for o, v in opts:
|
||||
daemonizeme = False
|
||||
opts, args = getopt.getopt(sys.argv[1:], "bc:o:dDgtl:h", ["background", "config=", "option=", "debug", "Debug", "garbage", "traceback", "log=", "help"])
|
||||
|
@ -2,43 +2,75 @@
|
||||
@unexec if cmp -s %D/%%EXAMPLESDIR%%/etc/jabber-pyicq.xml %D/etc/jabber-pyicq.xml; then rm -f %D/etc/jabber-pyicq.xml; fi
|
||||
%%EXAMPLESDIR%%/etc/jabber-pyicq.xml
|
||||
@exec [ -f %D/etc/jabber-pyicq.xml ] || cp %B/%f %D/etc/jabber-pyicq.xml
|
||||
@unexec if cmp -s %D/lib/jabber/pyicq/config.py.sample %D/lib/jabber/pyicq/config.py; then rm -f %D/lib/jabber/pyicq/config.py; fi
|
||||
lib/jabber/pyicq/config.py.sample
|
||||
@exec [ -f %D/lib/jabber/pyicq/config.py ] || cp %B/%f %D/lib/jabber/pyicq/config.py
|
||||
lib/jabber/pyicq/debug.py
|
||||
lib/jabber/pyicq/disco.py
|
||||
lib/jabber/pyicq/jabw.py
|
||||
lib/jabber/pyicq/lang.py
|
||||
lib/jabber/pyicq/legacy/__init__.py
|
||||
lib/jabber/pyicq/legacy/glue.py
|
||||
lib/jabber/pyicq/legacy/icqt.py
|
||||
lib/jabber/pyicq/main.py
|
||||
lib/jabber/pyicq/misciq.py
|
||||
lib/jabber/pyicq/register.py
|
||||
lib/jabber/pyicq/session.py
|
||||
lib/jabber/pyicq/stats.py
|
||||
lib/jabber/pyicq/tlib/__init__.py
|
||||
lib/jabber/pyicq/tlib/countrycodes.py
|
||||
lib/jabber/pyicq/tlib/domish.py
|
||||
lib/jabber/pyicq/tlib/jabber/__init__.py
|
||||
lib/jabber/pyicq/tlib/jabber/client.py
|
||||
lib/jabber/pyicq/tlib/jabber/component.py
|
||||
lib/jabber/pyicq/tlib/jabber/jid.py
|
||||
lib/jabber/pyicq/tlib/jabber/jstrports.py
|
||||
lib/jabber/pyicq/tlib/langcodes.py
|
||||
lib/jabber/pyicq/tlib/oscar.py
|
||||
lib/jabber/pyicq/tlib/socks5.py
|
||||
lib/jabber/pyicq/tlib/sockserror.py
|
||||
lib/jabber/pyicq/tlib/xmlstream.py
|
||||
lib/jabber/pyicq/utils.py
|
||||
lib/jabber/pyicq/webadmin/__init__.py
|
||||
lib/jabber/pyicq/webadmin/handler.py
|
||||
lib/jabber/pyicq/xdb.py
|
||||
lib/jabber/pyicq/xmlconfig.py
|
||||
@dirrm lib/jabber/pyicq/legacy
|
||||
@dirrm lib/jabber/pyicq/tlib/jabber
|
||||
@dirrm lib/jabber/pyicq/tlib
|
||||
@dirrm lib/jabber/pyicq/webadmin
|
||||
lib/jabber/pyicq/PyICQt.py
|
||||
lib/jabber/pyicq/data/defaultAIMAvatar.png
|
||||
lib/jabber/pyicq/data/defaultICQAvatar.png
|
||||
lib/jabber/pyicq/src/avatar.py
|
||||
lib/jabber/pyicq/src/bool.py
|
||||
lib/jabber/pyicq/src/config.py
|
||||
lib/jabber/pyicq/src/contact.py
|
||||
lib/jabber/pyicq/src/daemonize.py
|
||||
lib/jabber/pyicq/src/debug.py
|
||||
lib/jabber/pyicq/src/disco.py
|
||||
lib/jabber/pyicq/src/globals.py
|
||||
lib/jabber/pyicq/src/imgmanip.py
|
||||
lib/jabber/pyicq/src/jabw.py
|
||||
lib/jabber/pyicq/src/lang.py
|
||||
lib/jabber/pyicq/src/langs/sv.py
|
||||
lib/jabber/pyicq/src/langs/cs.py
|
||||
lib/jabber/pyicq/src/langs/de.py
|
||||
lib/jabber/pyicq/src/langs/en.py
|
||||
lib/jabber/pyicq/src/langs/es.py
|
||||
lib/jabber/pyicq/src/langs/fr.py
|
||||
lib/jabber/pyicq/src/langs/nl.py
|
||||
lib/jabber/pyicq/src/langs/pl.py
|
||||
lib/jabber/pyicq/src/langs/ru.py
|
||||
lib/jabber/pyicq/src/langs/__init__.py
|
||||
lib/jabber/pyicq/src/legacy/__init__.py
|
||||
lib/jabber/pyicq/src/legacy/glue.py
|
||||
lib/jabber/pyicq/src/legacy/icqt.py
|
||||
lib/jabber/pyicq/src/legacy/legacyiq.py
|
||||
lib/jabber/pyicq/src/legacy/legacylist.py
|
||||
lib/jabber/pyicq/src/main.py
|
||||
lib/jabber/pyicq/src/misciq.py
|
||||
lib/jabber/pyicq/src/register.py
|
||||
lib/jabber/pyicq/src/sasl.py
|
||||
lib/jabber/pyicq/src/session.py
|
||||
lib/jabber/pyicq/src/tlib/__init__.py
|
||||
lib/jabber/pyicq/src/tlib/countrycodes.py
|
||||
lib/jabber/pyicq/src/tlib/domish.py
|
||||
lib/jabber/pyicq/src/tlib/jabber/__init__.py
|
||||
lib/jabber/pyicq/src/tlib/jabber/client.py
|
||||
lib/jabber/pyicq/src/tlib/jabber/component.py
|
||||
lib/jabber/pyicq/src/tlib/jabber/jid.py
|
||||
lib/jabber/pyicq/src/tlib/jabber/jstrports.py
|
||||
lib/jabber/pyicq/src/tlib/jabber/xmpp_stringprep.py
|
||||
lib/jabber/pyicq/src/tlib/langcodes.py
|
||||
lib/jabber/pyicq/src/tlib/oscar.py
|
||||
lib/jabber/pyicq/src/tlib/scheduler.py
|
||||
lib/jabber/pyicq/src/tlib/socks5.py
|
||||
lib/jabber/pyicq/src/tlib/sockserror.py
|
||||
lib/jabber/pyicq/src/tlib/twistwrap.py
|
||||
lib/jabber/pyicq/src/tlib/xmlstream.py
|
||||
lib/jabber/pyicq/src/utils.py
|
||||
lib/jabber/pyicq/src/web/__init__.py
|
||||
lib/jabber/pyicq/src/web/handler.py
|
||||
lib/jabber/pyicq/src/web/xmppcred.py
|
||||
lib/jabber/pyicq/src/xdb/__init__.py
|
||||
lib/jabber/pyicq/src/xdb/legacyaimtransport.py
|
||||
lib/jabber/pyicq/src/xdb/legacyjittransport.py
|
||||
lib/jabber/pyicq/src/xdb/mysql.py
|
||||
lib/jabber/pyicq/src/xdb/template.py
|
||||
lib/jabber/pyicq/src/xdb/xmlfiles.py
|
||||
lib/jabber/pyicq/src/xmlconfig.py
|
||||
@dirrm lib/jabber/pyicq/src/langs
|
||||
@dirrm lib/jabber/pyicq/src/legacy
|
||||
@dirrm lib/jabber/pyicq/src/tlib/jabber
|
||||
@dirrm lib/jabber/pyicq/src/tlib
|
||||
@dirrm lib/jabber/pyicq/src/web
|
||||
@dirrm lib/jabber/pyicq/src/xdb
|
||||
@dirrm lib/jabber/pyicq/src
|
||||
@dirrm lib/jabber/pyicq/data
|
||||
@dirrm lib/jabber/pyicq
|
||||
@dirrmtry lib/jabber
|
||||
@dirrm %%EXAMPLESDIR%%/etc
|
||||
|
Loading…
Reference in New Issue
Block a user