aboutsummaryrefslogtreecommitdiffstats
path: root/multimedia/freevo
diff options
context:
space:
mode:
authorpav <pav@FreeBSD.org>2011-01-20 21:58:54 +0800
committerpav <pav@FreeBSD.org>2011-01-20 21:58:54 +0800
commit43c7d061e5bdc4e0b7b5f2c1a8235a683bf4d17b (patch)
tree6ab78ce5f6f7d73d7e1dde6958d63411a8f92430 /multimedia/freevo
parentf5e36c287a46dda865ab6215f22c883da073ea3f (diff)
downloadfreebsd-ports-gnome-43c7d061e5bdc4e0b7b5f2c1a8235a683bf4d17b.tar.gz
freebsd-ports-gnome-43c7d061e5bdc4e0b7b5f2c1a8235a683bf4d17b.tar.zst
freebsd-ports-gnome-43c7d061e5bdc4e0b7b5f2c1a8235a683bf4d17b.zip
Port was broken following recent python updates.
- remove dependency on python 2.5 version - add additional patches needed due to python Twisted library updates - fix rc.d script PR: ports/152965 Submitted by: J.R. Oldroyd <fbsd@opal.com> (maintainer) Feature safe: yes
Diffstat (limited to 'multimedia/freevo')
-rw-r--r--multimedia/freevo/Makefile9
-rw-r--r--multimedia/freevo/distinfo1
-rw-r--r--multimedia/freevo/files/freevo.in73
-rw-r--r--multimedia/freevo/files/patch-src-www-htdocs-fileinfo.rpy10
-rw-r--r--multimedia/freevo/files/patch-src-www-htdocs-guide.rpy11
-rw-r--r--multimedia/freevo/files/patch-src-www-htdocs-guidechannel.rpy10
-rw-r--r--multimedia/freevo/files/patch-src-www-htdocs-proginfo.rpy10
-rw-r--r--multimedia/freevo/files/patch-src-www-htdocs-search.rpy24
-rw-r--r--multimedia/freevo/files/patch-src-www-htdocs-vlcwin.rpy10
-rw-r--r--multimedia/freevo/files/patch-src-www-web_types.py34
10 files changed, 164 insertions, 28 deletions
diff --git a/multimedia/freevo/Makefile b/multimedia/freevo/Makefile
index 447b41332b58..7ece4c98b710 100644
--- a/multimedia/freevo/Makefile
+++ b/multimedia/freevo/Makefile
@@ -7,7 +7,7 @@
PORTNAME= freevo
PORTVERSION= 1.9.0
-PORTREVISION= 3
+PORTREVISION= 4
CATEGORIES= multimedia
MASTER_SITES= SF/${PORTNAME}/Freevo%20releases/${PORTVERSION}
@@ -35,7 +35,8 @@ FREEVO_UID= 523
FREEVO_GID= ${FREEVO_UID}
FREEVO_HOME= /var/db/${FREEVO_USER}
-SUB_LIST+= PORTVERSION=${PORTVERSION} \
+SUB_LIST+= PYTHON_VERSION=${PYTHON_DEFAULT_VERSION} \
+ PORTVERSION=${PORTVERSION} \
FREEVO_USER=${FREEVO_USER} \
FREEVO_GROUP=${FREEVO_GROUP} \
FREEVO_UID=${FREEVO_UID} \
@@ -68,6 +69,10 @@ post-patch:
@${REINPLACE_CMD} -e 's|/etc/freevo|${PREFIX}/etc/freevo|' ${WRKSRC}/freevo_config.py
@${REINPLACE_CMD} -e 's|/etc/freevo|${PREFIX}/etc/freevo|' ${WRKSRC}/local_conf.py.example
@${MV} ${WRKSRC}/src/www/htdocs/favorites.rpy.orig ${WRKDIR}
+ @${MV} ${WRKSRC}/src/www/htdocs/search.rpy.orig ${WRKDIR}
+ @${RM} ${WRKSRC}/src/www/htdocs/fileinfo.rpy.orig ${WRKSRC}/src/www/htdocs/guide.rpy.orig \
+ ${WRKSRC}/src/www/htdocs/guidechannel.rpy.orig ${WRKSRC}/src/www/htdocs/proginfo.rpy.orig \
+ ${WRKSRC}/src/www/htdocs/vlcwin.rpy.orig
post-install:
@${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
diff --git a/multimedia/freevo/distinfo b/multimedia/freevo/distinfo
index 149902366a91..aa99f83016fa 100644
--- a/multimedia/freevo/distinfo
+++ b/multimedia/freevo/distinfo
@@ -1,3 +1,2 @@
-MD5 (freevo-1.9.0.tar.gz) = aeb05e52f996258386af2951688bf6e3
SHA256 (freevo-1.9.0.tar.gz) = e3c97e1404bc5a171350d0c0edf8decaa6d4eb3eaa9e42112a903d375aaf8722
SIZE (freevo-1.9.0.tar.gz) = 27182867
diff --git a/multimedia/freevo/files/freevo.in b/multimedia/freevo/files/freevo.in
index 15129eafe94d..791033f73777 100644
--- a/multimedia/freevo/files/freevo.in
+++ b/multimedia/freevo/files/freevo.in
@@ -1,55 +1,78 @@
#!/bin/sh
+#
+# $FreeBSD$
+#
# PROVIDE: freevo
-# REQUIRE: DAEMON lircd
+# REQUIRE: LOGIN
# KEYWORD: shutdown
-#
+
# Uses the following /etc/rc.conf variables:
# freevo_enable="YES" master on/off
# freevo_recordserver_enable="YES" start freevo record server
# freevo_webserver_enable="YES" start freevo web server
# freevo_gui_enable="YES" start freevo GUI
-#
. /etc/rc.subr
name=freevo
rcvar=`set_rcvar`
-load_rc_config $name
-: ${freevo_enable="NO"}
-: ${freevo_recordserver_enable="NO"}
-: ${freevo_webserver_enable="NO"}
-: ${freevo_gui_enable="NO"}
+load_rc_config ${name}
+: ${freevo_enable:="NO"}
+: ${freevo_recordserver_enable:="NO"}
+: ${freevo_webserver_enable:="NO"}
+: ${freevo_gui_enable:="NO"}
freevo_user=${freevo_user:-"freevo"}
freevo_group=${freevo_group:-"freevo"}
freevo_uid=`pw usershow ${freevo_user} | awk -F: '{print $3}'`
freevo_dir=`pw usershow ${freevo_user} | awk -F: '{print $9}'`
-command=%%PREFIX%%/bin/freevo
-command_interpreter="%%PREFIX%%/bin/python2.5"
+command="%%PREFIX%%/bin/freevo"
+command_interpreter="%%PREFIX%%/bin/%%PYTHON_VERSION%%"
cd ${freevo_dir}
+msg() {
+ case "${no_msg}" in
+ 1) ;;
+ *) echo "$@" ;;
+ esac
+}
+
+freevo_start() {
+ [ ${freevo_recordserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --daemon recordserver" && msg Starting freevo recordserver.
+ [ ${freevo_webserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --daemon webserver" && msg Starting freevo webserver.
+ [ ${freevo_gui_enable} = "YES" ] && su ${freevo_user} -c "${command} --daemon" && msg Starting freevo GUI.
+}
+
+
+freevo_stop() {
+ [ ${freevo_gui_enable} = "YES" ] && su ${freevo_user} -c "${command} --stop" && msg Stopping freevo GUI.
+ [ ${freevo_webserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --stop webserver" && msg Stopping freevo webserver.
+ [ ${freevo_recordserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --stop recordserver" && msg Stopping freevo recordserver.
+}
+
+no_msg=""
+
case "$1" in
-start)
- [ ${freevo_recordserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --daemon recordserver"
- [ ${freevo_webserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --daemon webserver"
- [ ${freevo_gui_enable} = "YES" ] && su ${freevo_user} -c "${command} --daemon"
+start|faststart|onestart)
+ freevo_start
;;
-stop)
- [ ${freevo_recordserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --stop recordserver"
- [ ${freevo_webserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --stop webserver"
- [ ${freevo_gui_enable} = "YES" ] && su ${freevo_user} -c "${command} --stop"
+quietstart)
+ no_msg=1
+ freevo_start
+ ;;
+stop|faststop|onestop)
+ freevo_stop
+ ;;
+quietstop)
+ no_msg=1
+ freevo_stop
;;
restart)
- [ ${freevo_recordserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --stop recordserver"
- [ ${freevo_webserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --stop webserver"
- [ ${freevo_gui_enable} = "YES" ] && su ${freevo_user} -c "${command} --stop"
- [ ${freevo_recordserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --daemon recordserver"
- [ ${freevo_webserver_enable} = "YES" ] && su ${freevo_user} -c "${command} --daemon webserver"
- [ ${freevo_gui_enable} = "YES" ] && su ${freevo_user} -c "${command} --daemon"
+ freevo_stop
+ freevo_start
;;
esac
-
diff --git a/multimedia/freevo/files/patch-src-www-htdocs-fileinfo.rpy b/multimedia/freevo/files/patch-src-www-htdocs-fileinfo.rpy
new file mode 100644
index 000000000000..2cf689c512e4
--- /dev/null
+++ b/multimedia/freevo/files/patch-src-www-htdocs-fileinfo.rpy
@@ -0,0 +1,10 @@
+--- src/www/htdocs/fileinfo.rpy.orig 2009-04-02 12:50:13.000000000 -0400
++++ src/www/htdocs/fileinfo.rpy 2010-12-07 02:58:01.000000000 -0500
+@@ -33,7 +33,6 @@
+ import time
+
+ from www.web_types import HTMLResource, FreevoResource
+-from twisted.web.woven import page
+ import util
+ import config
+ import kaa.metadata as metadata
diff --git a/multimedia/freevo/files/patch-src-www-htdocs-guide.rpy b/multimedia/freevo/files/patch-src-www-htdocs-guide.rpy
new file mode 100644
index 000000000000..1055703b39df
--- /dev/null
+++ b/multimedia/freevo/files/patch-src-www-htdocs-guide.rpy
@@ -0,0 +1,11 @@
+--- src/www/htdocs/guide.rpy.orig 2009-02-19 12:59:44.000000000 -0500
++++ src/www/htdocs/guide.rpy 2010-12-07 02:56:47.000000000 -0500
+@@ -32,8 +32,6 @@
+ import sys, string
+ import time
+
+-from twisted.web.woven import page
+-
+ import config
+ import util.tv_util as tv_util
+ import util
diff --git a/multimedia/freevo/files/patch-src-www-htdocs-guidechannel.rpy b/multimedia/freevo/files/patch-src-www-htdocs-guidechannel.rpy
new file mode 100644
index 000000000000..7f9000f652a2
--- /dev/null
+++ b/multimedia/freevo/files/patch-src-www-htdocs-guidechannel.rpy
@@ -0,0 +1,10 @@
+--- src/www/htdocs/guidechannel.rpy.orig 2009-02-19 12:59:44.000000000 -0500
++++ src/www/htdocs/guidechannel.rpy 2010-12-07 02:58:10.000000000 -0500
+@@ -33,7 +33,6 @@
+ import time
+ import datetime
+
+-from twisted.web.woven import page
+ from twisted.web import static
+
+ import util.tv_util as tv_util
diff --git a/multimedia/freevo/files/patch-src-www-htdocs-proginfo.rpy b/multimedia/freevo/files/patch-src-www-htdocs-proginfo.rpy
new file mode 100644
index 000000000000..ef729ef2e79e
--- /dev/null
+++ b/multimedia/freevo/files/patch-src-www-htdocs-proginfo.rpy
@@ -0,0 +1,10 @@
+--- src/www/htdocs/proginfo.rpy.orig 2008-02-20 15:52:22.000000000 -0500
++++ src/www/htdocs/proginfo.rpy 2010-12-07 02:58:19.000000000 -0500
+@@ -33,7 +33,6 @@
+ import time
+
+ from www.web_types import HTMLResource, FreevoResource
+-from twisted.web.woven import page
+
+ import util.tv_util as tv_util
+ import util
diff --git a/multimedia/freevo/files/patch-src-www-htdocs-search.rpy b/multimedia/freevo/files/patch-src-www-htdocs-search.rpy
new file mode 100644
index 000000000000..172e1d8e0e88
--- /dev/null
+++ b/multimedia/freevo/files/patch-src-www-htdocs-search.rpy
@@ -0,0 +1,24 @@
+--- src/www/htdocs/search.rpy.orig 2009-02-19 12:59:44.000000000 -0500
++++ src/www/htdocs/search.rpy 2010-04-19 20:03:02.000000000 -0400
+@@ -113,17 +113,17 @@
+ if not chan: chan = 'UNKNOWN'
+ fv.tableCell(chan, 'class="'+status+'" colspan="1"')
+
+- fv.tableCell(prog.title, 'class="'+status+'" colspan="1"')
++ fv.tableCell(unicode(prog.title, 'iso-8859-1'), 'class="'+status+'" colspan="1"')
+ if prog.sub_title:
+- fv.tableCell(prog.sub_title, 'class="'+status+'" colspan="1"')
++ fv.tableCell(unicode(prog.sub_title, 'iso-8859-1'), 'class="'+status+'" colspan="1"')
+ else:
+ fv.tableCell('&nbsp;', 'class="'+status+'" colspan="1"')
+
+
+ if prog.desc == '':
+- cell = _('Sorry, the program description for %s is unavailable.') % ('<b>'+prog.title+'</b>')
++ cell = _('Sorry, the program description for %s is unavailable.') % ('<b>'+unicode(prog.title, 'iso-8859-1')+'</b>')
+ else:
+- cell = prog.desc
++ cell = unicode(prog.desc, 'iso-8859-1')
+ fv.tableCell(cell, 'class="'+status+'" colspan="1"')
+
+ if status == 'scheduled':
diff --git a/multimedia/freevo/files/patch-src-www-htdocs-vlcwin.rpy b/multimedia/freevo/files/patch-src-www-htdocs-vlcwin.rpy
new file mode 100644
index 000000000000..710366dfe3f0
--- /dev/null
+++ b/multimedia/freevo/files/patch-src-www-htdocs-vlcwin.rpy
@@ -0,0 +1,10 @@
+--- src/www/htdocs/vlcwin.rpy.orig 2008-02-20 15:52:22.000000000 -0500
++++ src/www/htdocs/vlcwin.rpy 2010-12-07 02:58:25.000000000 -0500
+@@ -33,7 +33,6 @@
+ import time
+
+ from www.web_types import HTMLResource, FreevoResource
+-from twisted.web.woven import page
+ import util
+ import config
+ import kaa.metadata as metadata
diff --git a/multimedia/freevo/files/patch-src-www-web_types.py b/multimedia/freevo/files/patch-src-www-web_types.py
new file mode 100644
index 000000000000..2b12865f3abe
--- /dev/null
+++ b/multimedia/freevo/files/patch-src-www-web_types.py
@@ -0,0 +1,34 @@
+--- src/www/web_types.py.orig 2009-05-07 13:34:38.000000000 -0400
++++ src/www/web_types.py 2010-12-05 10:54:51.000000000 -0500
+@@ -36,7 +36,6 @@
+ import config
+ import socket
+
+-from twisted.web.woven import page
+ from twisted.web.resource import Resource
+ from tv.record_client import RecordClient
+
+@@ -71,23 +70,6 @@
+
+
+
+-class FreevoPage(page.Page):
+- """
+- """
+- def __init__(self, model=None, template=None):
+- #print 'FreevoPage.__init__(model=%r, template=%r)' % (model, template)
+-
+- if not model:
+- model = {'foo': 'bar'}
+- if not template:
+- template = '<html><head><title>ERROR</title></head>' + \
+- '<body>ERROR: no template</body></html>'
+-
+- page.Page.__init__(self, model, template=template)
+-
+- self.addSlash = 0
+-
+-
+ class FreevoResource(Resource):
+ """
+ Base class of webpages which handels the authentication.