py-zeya -> zeya

ok ajacoutot@, sthen@, rpointel@
This commit is contained in:
dcoppa 2011-07-20 07:53:25 +00:00
parent 6ad8fbc302
commit 5288db10ba
15 changed files with 7 additions and 265 deletions

View File

@ -1,4 +1,4 @@
# $OpenBSD: Makefile,v 1.264 2011/07/14 14:14:46 dcoppa Exp $
# $OpenBSD: Makefile,v 1.265 2011/07/20 07:56:30 dcoppa Exp $
# $FreeBSD: Makefile,v 1.40 1997/11/16 22:49:20 fenner Exp $
SUBDIR =
@ -167,7 +167,6 @@
SUBDIR += py-tagpy
SUBDIR += py-vorbis
SUBDIR += py-xmms
SUBDIR += py-zeya
SUBDIR += pykaraoke
SUBDIR += pympd
SUBDIR += rhythmbox
@ -239,5 +238,6 @@
SUBDIR += xmms2-scrobbler
SUBDIR += xmmsctrl
SUBDIR += xmp
SUBDIR += zeya
.include <bsd.port.subdir.mk>

View File

@ -1,63 +0,0 @@
# $OpenBSD: Makefile,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
COMMENT = html5-powered web music server
MODPY_EGG_VERSION = 0.5
DISTNAME = zeya_${MODPY_EGG_VERSION}.orig
PKGNAME = py-zeya-${MODPY_EGG_VERSION}
CATEGORIES = audio www
HOMEPAGE = http://web.psung.name/zeya/
MASTER_SITES = http://archive.ubuntu.com/ubuntu/pool/universe/z/zeya/ \
http://ftp.de.debian.org/debian/pool/main/z/zeya/
MAINTAINER = David Coppa <dcoppa@openbsd.org>
# AGPLv3 (GNU Affero Public License)
PERMIT_PACKAGE_CDROM = Yes
PERMIT_PACKAGE_FTP = Yes
PERMIT_DISTFILES_CDROM =Yes
PERMIT_DISTFILES_FTP = Yes
MODULES = lang/python
RUN_DEPENDS = audio/faad \
audio/flac \
audio/mpg123 \
audio/py-tagpy \
audio/vorbis-tools \
devel/py-simplejson
MODPY_ADJ_FILES = zeya.py \
zeyaclient.py \
zeyatest.py
ZEYA_MODULES = ${WRKBUILD}/backends.py \
${WRKBUILD}/common.py \
${WRKBUILD}/decoders.py \
${WRKBUILD}/directory.py \
${WRKBUILD}/m3u.py \
${WRKBUILD}/options.py \
${WRKBUILD}/pls.py \
${WRKBUILD}/rhythmbox.py
NO_BUILD = Yes
NO_REGRESS = Yes
PKG_ARCH = *
WRKDIST = ${WRKDIR}
do-install:
${SUBST_CMD} ${WRKBUILD}/backends.py \
${WRKBUILD}/decoders.py ${WRKBUILD}/zeya.py \
${WRKBUILD}/zeyaclient.py
${INSTALL_SCRIPT} ${WRKBUILD}/zeya.py ${PREFIX}/sbin/zeya
${INSTALL_SCRIPT} ${WRKBUILD}/zeyaclient.py \
${PREFIX}/bin/zeyaclient
${INSTALL_DATA_DIR} ${PREFIX}/lib/zeya ${PREFIX}/share/zeya
${INSTALL_DATA} ${ZEYA_MODULES} ${PREFIX}/lib/zeya/
${INSTALL_DATA} ${WRKBUILD}/resources/* ${PREFIX}/share/zeya/
${INSTALL_MAN} ${WRKBUILD}/doc/zeyaclient.1 ${PREFIX}/man/man1/
${INSTALL_MAN} ${WRKBUILD}/doc/zeya.1 ${PREFIX}/man/man8/zeya.8
.include <bsd.port.mk>

View File

@ -1,5 +0,0 @@
MD5 (zeya_0.5.orig.tar.gz) = lXRRzOT2Ofv93y96oSlRKg==
RMD160 (zeya_0.5.orig.tar.gz) = qUUGdMpzG5HutNqn38PPUOgyHEM=
SHA1 (zeya_0.5.orig.tar.gz) = 71U04/Ep7/YCw3z5PYAMfmRjy/Q=
SHA256 (zeya_0.5.orig.tar.gz) = lHdKHECDcK8v8yvIYzyGLpYLlVKvIVutmchEFRtwe5M=
SIZE (zeya_0.5.orig.tar.gz) = 54245

View File

@ -1,12 +0,0 @@
$OpenBSD: patch-backends_py,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
--- backends.py.orig Mon Jul 11 11:38:36 2011
+++ backends.py Mon Jul 11 11:41:08 2011
@@ -70,7 +70,7 @@ def filename_to_stream(filename, out_stream, bitrate,
except KeyError:
raise StreamGenerationError(
"Couldn't play specified format: %r" % (filename,))
- encoder_path = "/usr/bin/oggenc"
+ encoder_path = "${LOCALBASE}/bin/oggenc"
if not os.path.exists(encoder_path):
raise StreamGenerationError(
("No Vorbis encoder found at %s. " % (encoder_path,)) + \

View File

@ -1,29 +0,0 @@
$OpenBSD: patch-decoders_py,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
--- decoders.py.orig Mon Jul 11 11:38:30 2011
+++ decoders.py Mon Jul 11 11:42:12 2011
@@ -27,17 +27,17 @@ import os
# To use any of the command lines, append a filename as the last argument.
decoders = {
- 'flac': ("/usr/bin/flac", "-d", "-c", "--totally-silent"),
- 'mp3': ("/usr/bin/mpg123", "-s", "-q"),
- 'ogg': ("/usr/bin/oggdec", "-Q", "-o", "-"),
- 'm4a': ("/usr/bin/faad", "-w", "-q"),
+ 'flac': ("${LOCALBASE}/bin/flac", "-d", "-c", "--totally-silent"),
+ 'mp3': ("${LOCALBASE}/bin/mpg123", "-s", "-q"),
+ 'ogg': ("${LOCALBASE}/bin/oggdec", "-Q", "-o", "-"),
+ 'm4a': ("${LOCALBASE}/bin/faad", "-w", "-q"),
}
decoder_messages = {
- 'flac': "/usr/bin/flac not found. Please install 'flac' to play .flac files.",
- 'mp3': "/usr/bin/mpg123 not found. Please install 'mpg123' to play .mp3 files.",
- 'ogg': "/usr/bin/oggdec not found. Please install 'vorbis-tools' to play .ogg files.",
- 'm4a': "/usr/bin/faad not found. Please install 'faad' to play .m4a files.",
+ 'flac': "${LOCALBASE}/bin/flac not found. Please install 'flac' to play .flac files.",
+ 'mp3': "${LOCALBASE}/bin/mpg123 not found. Please install 'mpg123' to play .mp3 files.",
+ 'ogg': "${LOCALBASE}/bin/oggdec not found. Please install 'vorbis-tools' to play .ogg files.",
+ 'm4a': "${LOCALBASE}/bin/faad not found. Please install 'faad' to play .m4a files.",
}
# The set of extensions for which we've warned the user that the decoder is not

View File

@ -1,23 +0,0 @@
$OpenBSD: patch-directory_py,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
Fall back gracefully when 'followlinks' arg is not supported
(upstream git commit e9e8033274102d34541f54d530b8e4dd5096b23e)
--- directory.py.orig Tue Sep 21 08:13:42 2010
+++ directory.py Mon Jul 11 10:58:20 2011
@@ -169,7 +169,14 @@ class DirectoryBackend(LibraryBackend):
raise IOError("Error: directory %r doesn't exist." % (self._media_path,))
print "Scanning for music in %r..." % (os.path.abspath(self._media_path),)
# Iterate over all the files.
- for path, dirs, files in os.walk(self._media_path, followlinks=True):
+ try:
+ all_files_recursively = os.walk(self._media_path, followlinks=True)
+ except TypeError:
+ # os.walk in Python 2.5 and earlier don't support the followlinks
+ # argument. Fall back to not including it (in this case, Zeya will
+ # not index music underneath symlinked directories).
+ all_files_recursively = os.walk(self._media_path)
+ for path, dirs, files in all_files_recursively:
# Sort dirs so that subdirectories will subsequently be visited
# alphabetically (see os.walk).
dirs.sort(key=tokenize_filename)

View File

@ -1,20 +0,0 @@
$OpenBSD: patch-doc_zeya_1,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
--- doc/zeya.1.orig Tue Sep 21 08:13:42 2010
+++ doc/zeya.1 Thu Jul 14 15:46:11 2011
@@ -5,7 +5,7 @@
\\$2 \(la\\$1\(ra\\$3
..
.if \n(.g .mso www.tmac
-.TH zeya 1 2009-10-19 "" ""
+.TH zeya 8 2009-10-19 "" ""
.SH NAME
zeya \- a web music server
.SH SYNOPSIS
@@ -67,7 +67,3 @@ format.
.SH COPYRIGHT
Zeya was written by Phil Sung and Samson Yeung and is licensed
under the terms of the GNU Affero GPL license, version 3 or later.
-.SH "SEE ALSO"
-\*(T<\fI/usr/share/doc/zeya/README\fR\*(T>
-.PP
-\*(T<\fI/usr/share/doc/zeya/TODO\fR\*(T>

View File

@ -1,11 +0,0 @@
$OpenBSD: patch-doc_zeyaclient_1,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
--- doc/zeyaclient.1.orig Mon Jul 11 11:15:58 2011
+++ doc/zeyaclient.1 Mon Jul 11 11:16:29 2011
@@ -35,7 +35,3 @@ to return to the prompt.
\fBzeyaclient\fR was written by Phil Sung and is
licensed under the terms of the GNU Affero GPL license, version 3
or later.
-.SH "SEE ALSO"
-\*(T<\fI/usr/share/doc/zeya/README\fR\*(T>
-.PP
-\*(T<\fI/usr/share/doc/zeya/TODO\fR\*(T>

View File

@ -1,32 +0,0 @@
$OpenBSD: patch-zeya_py,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
--- zeya.py.orig Tue Sep 21 08:13:42 2010
+++ zeya.py Mon Jul 11 18:59:16 2011
@@ -50,6 +50,10 @@ try:
except (ImportError, AttributeError):
import simplejson as json
+modules_dir = '${TRUEPREFIX}/lib/zeya'
+
+sys.path.append(modules_dir)
+
import backends
import decoders
import options
@@ -347,7 +351,7 @@ def run_server(backend, bind_address, port, bitrate, b
'playlists': playlists }
library_repr = json.dumps(output, ensure_ascii=False)
- basedir = os.path.abspath(os.path.dirname(os.path.realpath(sys.argv[0])))
+ basedir = modules_dir
auth_data = None
if basic_auth_file is not None:
@@ -357,7 +361,7 @@ def run_server(backend, bind_address, port, bitrate, b
auth_data[s_user] = s_pass
zeya_handler = ZeyaHandler(backend,
library_repr,
- os.path.join(basedir, 'resources'),
+ '${TRUEPREFIX}/share/zeya',
bitrate,
auth_type=NO_AUTH if basic_auth_file is None else BASIC_AUTH,
auth_data=auth_data,

View File

@ -1,12 +0,0 @@
$OpenBSD: patch-zeyaclient_py,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
--- zeyaclient.py.orig Mon Jul 11 11:38:24 2011
+++ zeyaclient.py Mon Jul 11 11:42:34 2011
@@ -99,7 +99,7 @@ def run(server_path):
for song in matching_songs:
print "\r%s - %s" % (song['title'], song['artist'])
song_url = "%s/getcontent?key=%d" % (server_path, song['key'])
- p = subprocess.Popen(["/usr/bin/ogg123", "-q", song_url])
+ p = subprocess.Popen(["${LOCALBASE}/bin/ogg123", "-q", song_url])
try:
p.communicate()
except KeyboardInterrupt:

View File

@ -1,5 +0,0 @@
Zeya is a media player that lets you bring your music to any computer
with a web browser. The client runs in any browser that supports the
HTML5 draft standard technologies (Mozilla Firefox 4.0+, Google Chrome
or Chromium 4.0.223+, Microsoft Internet Explorer 6, 7, or 8 with the
Google Chrome Frame plugin).

View File

@ -1,31 +0,0 @@
@comment $OpenBSD: PLIST,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
@newgroup _zeya:680
@newuser _zeya:680:_zeya:daemon:zeya user:/nonexistent:/sbin/nologin
bin/zeyaclient
lib/zeya/
lib/zeya/backends.py
lib/zeya/common.py
lib/zeya/decoders.py
lib/zeya/directory.py
lib/zeya/m3u.py
lib/zeya/options.py
lib/zeya/pls.py
lib/zeya/rhythmbox.py
@man man/man1/zeyaclient.1
@man man/man8/zeya.8
sbin/zeya
share/zeya/
share/zeya/clear_search.png
share/zeya/favicon.png
share/zeya/library.html
share/zeya/next.png
share/zeya/pause.png
share/zeya/play.png
share/zeya/previous.png
share/zeya/repeat.png
share/zeya/search.png
share/zeya/shuffle.png
share/zeya/spinner.gif
share/zeya/zeya.css
share/zeya/zeya.js
@rcscript ${RCDIR}/zeya

View File

@ -1,16 +0,0 @@
#!/bin/sh
#
# $OpenBSD: zeya.rc,v 1.1.1.1 2011/07/14 14:05:50 dcoppa Exp $
daemon="${TRUEPREFIX}/sbin/zeya"
daemon_flags="--path=/var/tmp"
daemon_user="_zeya"
. /etc/rc.d/rc.subr
pexp="${MODPY_BIN} ${daemon}${daemon_flags:+ ${daemon_flags}}"
rc_bg=YES
rc_reload=NO
rc_cmd $1

View File

@ -1,11 +1,11 @@
# $OpenBSD: Makefile,v 1.54 2011/07/19 09:21:25 jasper Exp $
# $OpenBSD: Makefile,v 1.55 2011/07/20 07:59:28 dcoppa Exp $
COMMENT = exceptions to pkg_add rules
CATEGORIES = devel databases
DISTFILES =
# API.rev
PKGNAME = quirks-1.52
PKGNAME = quirks-1.53
PKG_ARCH = *
MAINTAINER = Marc Espie <espie@openbsd.org>

View File

@ -1,7 +1,7 @@
#! /usr/bin/perl
# ex:ts=8 sw=4:
# $OpenBSD: Quirks.pm,v 1.59 2011/07/19 09:21:25 jasper Exp $
# $OpenBSD: Quirks.pm,v 1.60 2011/07/20 07:59:28 dcoppa Exp $
#
# Copyright (c) 2009 Marc Espie <espie@openbsd.org>
#
@ -248,7 +248,8 @@ my $stem_extensions = {
'pscyr' => 'ru-pscyr',
'wqy-zenhei-ttf' => 'zh-wqy-zenhei-ttf',
'wqy-bitmapfont' => 'zh-wqy-bitmapfont',
'ptsans' => 'ru-ptsans'
'ptsans' => 'ru-ptsans',
'py-zeya' => 'zeya'
};
# ->is_base_system($handle, $state):