diff options
author | kim <kim@pkgsrc.org> | 2004-01-12 04:18:18 +0000 |
---|---|---|
committer | kim <kim@pkgsrc.org> | 2004-01-12 04:18:18 +0000 |
commit | d0b24d2f88c0af5613a60fe14882bc01fe31f8ab (patch) | |
tree | 4dc3317b09d19c07aec4c172021a34b97400a87f /audio | |
parent | a542b62c6be6f71b3a7eefb4bfd05b8ffccfa321 (diff) | |
download | pkgsrc-d0b24d2f88c0af5613a60fe14882bc01fe31f8ab.tar.gz |
Development version of mserv: streaming server instead of local playback.
Diffstat (limited to 'audio')
-rw-r--r-- | audio/mserv-devel/DESCR | 7 | ||||
-rw-r--r-- | audio/mserv-devel/Makefile | 35 | ||||
-rw-r--r-- | audio/mserv-devel/PLIST | 25 | ||||
-rw-r--r-- | audio/mserv-devel/distinfo | 7 | ||||
-rw-r--r-- | audio/mserv-devel/patches/patch-aa | 13 | ||||
-rw-r--r-- | audio/mserv-devel/patches/patch-ab | 13 | ||||
-rw-r--r-- | audio/mserv-devel/patches/patch-ac | 107 |
7 files changed, 207 insertions, 0 deletions
diff --git a/audio/mserv-devel/DESCR b/audio/mserv-devel/DESCR new file mode 100644 index 00000000000..875c8c0bcc1 --- /dev/null +++ b/audio/mserv-devel/DESCR @@ -0,0 +1,7 @@ +The main purpose of Mserv is to play songs that those in the room want +to hear. It works by each user rating the songs they hear - at the +moment this means they type rate good via telnet or click GOOD via web, +but hopefully there will be Windows/X clients available soon. Mserv +uses the ratings, the date the song was last played, the filter +settings and who is currently logged in. It then compiles a 'top' list +of songs that are most likely to be played. diff --git a/audio/mserv-devel/Makefile b/audio/mserv-devel/Makefile new file mode 100644 index 00000000000..fc25bc5dd79 --- /dev/null +++ b/audio/mserv-devel/Makefile @@ -0,0 +1,35 @@ +# $NetBSD: Makefile,v 1.1.1.1 2004/01/12 04:18:18 kim Exp $ +# + +DISTNAME= mserv-0.39a +CATEGORIES= audio +MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=mserv/} + +MAINTAINER= kim@tac.nyc.ny.us +HOMEPAGE= http://www.mserv.org/ +COMMENT= Local centralised music server environment + +GNU_CONFIGURE= yes +CONFIGURE_ARGS+= --with-engine-icecast +CONFIGURE_ARGS+= --datadir=${PREFIX}/share/mserv +USE_BUILDLINK2= yes +REPLACE_PERL= support/mservedit webclient/main.cgi \ + webclient/margin.cgi webclient/mserv.cgi + +post-configure: + ${MV} ${WRKSRC}/mserv/soundcard.h ${WRKSRC}/mserv/mservsoundcard.h + +post-install: + ${INSTALL_SCRIPT} ${WRKSRC}/support/mservedit ${PREFIX}/bin + ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/mserv + ${INSTALL_DATA} \ + ${WRKSRC}/INSTALL \ + ${WRKSRC}/LICENSE \ + ${PREFIX}/share/doc/mserv + ${INSTALL_DATA_DIR} ${PREFIX}/share/mserv/webclient + ${INSTALL_DATA} \ + ${WRKSRC}/webclient/* \ + ${PREFIX}/share/mserv/webclient + +.include "../../audio/libshout/buildlink2.mk" +.include "../../mk/bsd.pkg.mk" diff --git a/audio/mserv-devel/PLIST b/audio/mserv-devel/PLIST new file mode 100644 index 00000000000..56b58932bfa --- /dev/null +++ b/audio/mserv-devel/PLIST @@ -0,0 +1,25 @@ +@comment $NetBSD: PLIST,v 1.1.1.1 2004/01/12 04:18:18 kim Exp $ +bin/mserv +bin/mservcmd +bin/mservedit +include/mservcli.h +lib/libmservcli.a +lib/libmservcli.la +lib/libmservcli.so +lib/libmservcli.so.0 +lib/libmservcli.so.0.1 +man/man1/mserv.1 +man/man1/mservcmd.1 +share/doc/mserv/INSTALL +share/doc/mserv/LICENSE +share/mserv/english.lang +share/mserv/webclient/README +share/mserv/webclient/back.gif +share/mserv/webclient/index.html +share/mserv/webclient/main.cgi +share/mserv/webclient/margin.cgi +share/mserv/webclient/mserv.cgi +share/mserv/webclient/mserv7.gif +@dirrm share/mserv/webclient +@dirrm share/mserv +@dirrm share/doc/mserv diff --git a/audio/mserv-devel/distinfo b/audio/mserv-devel/distinfo new file mode 100644 index 00000000000..c69c9d75921 --- /dev/null +++ b/audio/mserv-devel/distinfo @@ -0,0 +1,7 @@ +$NetBSD: distinfo,v 1.1.1.1 2004/01/12 04:18:18 kim Exp $ + +SHA1 (mserv-0.39a.tar.gz) = cb101fe7e4aca8b5fd950eec408938a2b3bf1a1b +Size (mserv-0.39a.tar.gz) = 333570 bytes +SHA1 (patch-aa) = 167417f1d0cd15bea6dbef46a3a0e0841d41fa4c +SHA1 (patch-ab) = f6692d59b1da163a273639347cd53ee7c56ec64b +SHA1 (patch-ac) = 47ac4716cbba0ff3f2acde1b896e56c309abe102 diff --git a/audio/mserv-devel/patches/patch-aa b/audio/mserv-devel/patches/patch-aa new file mode 100644 index 00000000000..0c4887a2543 --- /dev/null +++ b/audio/mserv-devel/patches/patch-aa @@ -0,0 +1,13 @@ +$NetBSD: patch-aa,v 1.1.1.1 2004/01/12 04:18:18 kim Exp $ + +--- mserv/cmd.c.orig Sun Aug 31 18:51:07 2003 ++++ mserv/cmd.c Tue Oct 14 17:50:28 2003 +@@ -52,7 +52,7 @@ + #include <math.h> + #include "mserv.h" + #include "misc.h" +-#include "soundcard.h" ++#include "mservsoundcard.h" + #include "acl.h" + #include "filter.h" + #include "cmd.h" diff --git a/audio/mserv-devel/patches/patch-ab b/audio/mserv-devel/patches/patch-ab new file mode 100644 index 00000000000..4a44e08fe4b --- /dev/null +++ b/audio/mserv-devel/patches/patch-ab @@ -0,0 +1,13 @@ +$NetBSD: patch-ab,v 1.1.1.1 2004/01/12 04:18:18 kim Exp $ + +--- mserv/mserv.c.orig Sun Aug 31 18:52:34 2003 ++++ mserv/mserv.c Tue Oct 14 17:50:57 2003 +@@ -67,7 +67,7 @@ + #include "cmd.h" + #include "acl.h" + #include "mp3info.h" +-#include "soundcard.h" ++#include "mservsoundcard.h" + #include "defconf.h" + #include "conf.h" + #include "opt.h" diff --git a/audio/mserv-devel/patches/patch-ac b/audio/mserv-devel/patches/patch-ac new file mode 100644 index 00000000000..34d0878eacd --- /dev/null +++ b/audio/mserv-devel/patches/patch-ac @@ -0,0 +1,107 @@ +$NetBSD: patch-ac,v 1.1.1.1 2004/01/12 04:18:18 kim Exp $ + +--- mserv/output-icecast.c.orig Sun Aug 31 18:52:35 2003 ++++ mserv/output-icecast.c Sat Oct 18 23:01:21 2003 +@@ -170,7 +170,7 @@ + *error = "Failed setting Icecast hostname"; + goto failed; + } +- if (shout_set_protocol(o->shout, SHOUT_PROTOCOL_HTTP) != SHOUTERR_SUCCESS) { ++ if (shout_set_protocol(o->shout, SHOUT_PROTOCOL_XAUDIOCAST) != SHOUTERR_SUCCESS) { + mserv_log("Failed setting Icecast protocol: %s", shout_get_error(o->shout)); + *error = "Failed setting Icecast protocol"; + goto failed; +@@ -186,8 +186,8 @@ + goto failed; + } + if (shout_set_mount(o->shout, mount) != SHOUTERR_SUCCESS) { +- mserv_log("Failed setting Icecast hostname: %s", shout_get_error(o->shout)); +- *error = "Failed setting Icecast hostname"; ++ mserv_log("Failed setting Icecast mount: %s", shout_get_error(o->shout)); ++ *error = "Failed setting Icecast mount"; + goto failed; + } + if (shout_set_user(o->shout, user) != SHOUTERR_SUCCESS) { +@@ -195,7 +195,7 @@ + *error = "Failed setting Icecast user"; + goto failed; + } +- if (shout_set_format(o->shout, SHOUT_FORMAT_VORBIS) != SHOUTERR_SUCCESS) { ++ if (shout_set_format(o->shout, SHOUT_FORMAT_MP3) != SHOUTERR_SUCCESS) { + mserv_log("Failed setting Icecast format: %s", shout_get_error(o->shout)); + *error = "Failed setting Icecast format"; + goto failed; +@@ -209,6 +209,7 @@ + mserv_log("Successfully connected to Icecast host '%s@%s' for mount '%s'", + host, port, mount); + ++#if 0 + vorbis_info_init(&o->vi); + if (vorbis_encode_init(&o->vi, o->channels, o->samplerate, -1, + o->bitrate, -1) != 0) { +@@ -248,6 +249,8 @@ + } + } + } ++#endif ++ + /* + if (gettimeofday(&o->lasttime, NULL) == -1) { + *error = "Failed to gettimeofday()"; +@@ -389,9 +392,11 @@ + } + o->buffer_ready_bytes = 0; + } ++ + /* if we have no ready buffer, and we have a full normal buffer, + * send it to vorbis */ + if (o->buffer_ready_bytes == 0 && o->buffer_bytes == o->buffer_size) { ++#if 0 + vorbbuf = vorbis_analysis_buffer(&o->vd, + o->buffer_size / (o->channels * 2)); + if (mserv_debug) +@@ -413,7 +418,27 @@ + o->buffer_size / (o->channels * 2)); + vorbis_analysis_wrote(&o->vd, o->buffer_size / (o->channels * 2)); + o->buffer_bytes = 0; ++#else ++ reqbufsize = o->buffer_ready_bytes + o->buffer_bytes; ++ reqbufsize = ((reqbufsize / 8192) + 1) * 8192; /* add granularity */ ++ if (reqbufsize > o->buffer_ready_size) { ++ newbuf = realloc(o->buffer_ready, reqbufsize); ++ mserv_log("Extending output buffer size from %d to %d bytes", ++ o->buffer_ready_size, reqbufsize); ++ if (newbuf == NULL) { ++ mserv_log("Out of memory extending output buffer"); ++ exit(1); ++ } ++ o->buffer_ready = newbuf; ++ o->buffer_ready_size = reqbufsize; ++ } ++ memcpy(o->buffer_ready + o->buffer_ready_bytes, ++ o->buffer_float, o->buffer_bytes); ++ o->buffer_ready_bytes += o->buffer_bytes; ++ o->buffer_bytes = 0; ++#endif + } ++ + /* if we haven't got a full buffer, read in more from the player */ + while (o->buffer_bytes < o->buffer_size) { + /* try and read more from the input stream */ +@@ -508,6 +533,8 @@ + } + } + } ++ ++#if 0 + /* does vorbis have anything decoded from what we've already sent it via + * vorbis_analysis_wrote above? */ + if (mserv_debug) +@@ -550,6 +577,7 @@ + mserv_log(" done. received %d ogg pages from libvorbis", pages); + mserv_log(" encoded output buffer now %d bytes", o->buffer_ready_bytes); + } ++#endif + } + + /* end of stream: vorbis_analysis_wrote(&o->vd, 0); */ |