summaryrefslogtreecommitdiff
path: root/audio/mserv
diff options
context:
space:
mode:
authorabs <abs@pkgsrc.org>2003-09-03 19:55:25 +0000
committerabs <abs@pkgsrc.org>2003-09-03 19:55:25 +0000
commit6d0e8294c3097f6ffb51ae97639d59ba279d5720 (patch)
treed916818fd63c62ef5035ea086c2956b52094f1ee /audio/mserv
parent7a10834052061c152ac76cf81a1c76e8f0516e6f (diff)
downloadpkgsrc-6d0e8294c3097f6ffb51ae97639d59ba279d5720.tar.gz
Update mserv to 0.35nb1
Fix english.lang install location Install mservedit Add INSTALL and LICENSE to PLIST Fix config 'player_ogg=prog_ogg' -> 'player_ogg=prog_ogg123' Add PARSE_OGG_INFO
Diffstat (limited to 'audio/mserv')
-rw-r--r--audio/mserv/Makefile34
-rw-r--r--audio/mserv/PLIST6
-rw-r--r--audio/mserv/distinfo8
-rw-r--r--audio/mserv/patches/patch-aa4
-rw-r--r--audio/mserv/patches/patch-ac99
-rw-r--r--audio/mserv/patches/patch-af4
6 files changed, 127 insertions, 28 deletions
diff --git a/audio/mserv/Makefile b/audio/mserv/Makefile
index 2a5a0dd69e1..f26c5fcacd4 100644
--- a/audio/mserv/Makefile
+++ b/audio/mserv/Makefile
@@ -1,7 +1,8 @@
-# $NetBSD: Makefile,v 1.11 2003/09/03 12:35:12 martin Exp $
+# $NetBSD: Makefile,v 1.12 2003/09/03 19:55:25 abs Exp $
#
DISTNAME= mserv-0.35
+PKGREVISION= 1
CATEGORIES= audio
MASTER_SITES= http://www.mserv.org/download/
@@ -10,22 +11,29 @@ HOMEPAGE= http://www.mserv.org/
COMMENT= Local centralised music server environment
DEPENDS+= mpg123-[0-9]*:../mpg123
-GNU_CONFIGURE=
-REPLACE_PERL= mserv/mservedit webclient/main.cgi webclient/margin.cgi webclient/mserv.cgi
+GNU_CONFIGURE= yes
+CONFIGURE_ENV+= MY_LIBS="-lvorbisfile -lvorbis"
+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
+ ${MV} ${WRKSRC}/mserv/soundcard.h ${WRKSRC}/mserv/mservsoundcard.h
post-install:
- ${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
+ ${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/libogg/buildlink2.mk"
+.include "../../audio/libvorbis/buildlink2.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/audio/mserv/PLIST b/audio/mserv/PLIST
index e301a024277..4e205e9a698 100644
--- a/audio/mserv/PLIST
+++ b/audio/mserv/PLIST
@@ -1,13 +1,13 @@
-@comment $NetBSD: PLIST,v 1.2 2002/06/14 20:04:07 abs Exp $
+@comment $NetBSD: PLIST,v 1.3 2003/09/03 19:55:26 abs Exp $
bin/mserv
bin/mservcmd
bin/mservedit
-bin/mservplay
include/mservcli.h
lib/libmservcli.a
-lib/libmservplus.a
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
diff --git a/audio/mserv/distinfo b/audio/mserv/distinfo
index fa2dd6aba5e..7966c37a32d 100644
--- a/audio/mserv/distinfo
+++ b/audio/mserv/distinfo
@@ -1,10 +1,10 @@
-$NetBSD: distinfo,v 1.11 2003/09/03 12:35:12 martin Exp $
+$NetBSD: distinfo,v 1.12 2003/09/03 19:55:26 abs Exp $
SHA1 (mserv-0.35.tar.gz) = 850835946e4d5a0deccdd22a18f30170c0a7b57c
Size (mserv-0.35.tar.gz) = 280299 bytes
-SHA1 (patch-aa) = 4bdcc9aa6ff563c91f0667966ff8256c28b6e063
+SHA1 (patch-aa) = 22bb3f2af2494e50456c9b1bf136774b3b300aae
SHA1 (patch-ab) = 9d1b9fe0ee1b5392e2249b50d3e27426b17c9c04
-SHA1 (patch-ac) = dc28b407833857388717b614a0d739cc0042a765
-SHA1 (patch-af) = e4d07c5f70c2b45ed0c92255bdf713ed9031d60e
+SHA1 (patch-ac) = 41d542c783cbc969afc931b0149edc5c90675b51
+SHA1 (patch-af) = 2839b8e0c51a4c1c182173abc1c406b66a915ac4
SHA1 (patch-ag) = 232ce715468e8a59820b856a586dc708d65a2b5e
SHA1 (patch-am) = 925a304562d89c3aca32a3f07f00eab912e8d2dd
diff --git a/audio/mserv/patches/patch-aa b/audio/mserv/patches/patch-aa
index dc08a5e46db..ec320f9bee4 100644
--- a/audio/mserv/patches/patch-aa
+++ b/audio/mserv/patches/patch-aa
@@ -1,4 +1,4 @@
-$NetBSD: patch-aa,v 1.6 2003/09/03 12:35:12 martin Exp $
+$NetBSD: patch-aa,v 1.7 2003/09/03 19:55:28 abs Exp $
--- mserv/Makefile.in.orig 2003-08-03 16:57:19.000000000 +0200
+++ mserv/Makefile.in 2003-09-03 14:01:16.000000000 +0200
@@ -7,7 +7,7 @@ $NetBSD: patch-aa,v 1.6 2003/09/03 12:35:12 martin Exp $
target_vendor = @target_vendor@
-INCLUDES = -I../hdr -DDATADIR=\"${datadir}\"
-+INCLUDES = -I../hdr -DDATADIR=\"${datadir}\" -DBINDIR=\"${prefix}/bin\"
++INCLUDES = -I../hdr -DDATADIR=\"${datadir}\" -DBINDIR=\"${prefix}/bin\" -DPARSE_OGG_INFO=1
bin_PROGRAMS = mserv
diff --git a/audio/mserv/patches/patch-ac b/audio/mserv/patches/patch-ac
index 027f015d01a..be6de327900 100644
--- a/audio/mserv/patches/patch-ac
+++ b/audio/mserv/patches/patch-ac
@@ -1,8 +1,18 @@
-$NetBSD: patch-ac,v 1.5 2003/09/03 12:35:12 martin Exp $
+$NetBSD: patch-ac,v 1.6 2003/09/03 19:55:28 abs Exp $
---- mserv/mserv.c.orig 2003-08-03 16:57:20.000000000 +0200
-+++ mserv/mserv.c 2003-09-03 13:52:35.000000000 +0200
-@@ -67,7 +67,7 @@
+--- mserv/mserv.c.orig Sun Aug 3 15:57:20 2003
++++ mserv/mserv.c
+@@ -62,12 +62,17 @@ met:
+ #include <sys/ioctl.h>
+ #include <time.h>
+
++#ifdef PARSE_OGG_INFO
++#include <vorbis/codec.h>
++#include <vorbis/vorbisfile.h>
++#endif
++
+ #include "mserv.h"
+ #include "misc.h"
#include "cmd.h"
#include "acl.h"
#include "mp3info.h"
@@ -11,3 +21,84 @@ $NetBSD: patch-ac,v 1.5 2003/09/03 12:35:12 martin Exp $
#include "defconf.h"
#include "conf.h"
#include "opt.h"
+@@ -2098,8 +2103,17 @@ static t_track *mserv_loadtrk(const char
+ }
+ if (duration == 0 && !*miscinfo) {
+ len = strlen(fullpath_file);
++#ifdef PARSE_OGG_INFO
++ if (len > 4 && !stricmp(".mp3", fullpath_file+len-4) ||
++ !stricmp(".ogg", fullpath_file+len-4)) {
++ if (!stricmp(".mp3", fullpath_file+len-4))
++ duration = mserv_mp3info_readlen(fullpath_file, &bitrate, &id3tag);
++ else
++ duration = mserv_ogginfo_readlen(fullpath_file, &bitrate, &id3tag);
++#else
+ if (len > 4 && !stricmp(".mp3", fullpath_file+len-4)) {
+ duration = mserv_mp3info_readlen(fullpath_file, &bitrate, &id3tag);
++#endif
+ if (duration == -1) {
+ mserv_log("Unable to determine details of mp3 '%s': %s",
+ filename, strerror(errno));
+@@ -3427,6 +3441,62 @@ int mserv_setmixer(t_client *cl, int wha
+ close(mixer_fd);
+ mserv_response(cl, "NAN", NULL);
+ return -1;
++}
++
++#endif
++
++#ifdef PARSE_OGG_INFO
++int mserv_ogginfo_readlen(const char *fname, int *bitrate_ret,
++ t_id3tag *id3tag)
++{
++ OggVorbis_File vf;
++ FILE *f;
++ ogg_sync_state sync;
++ vorbis_info *vi;
++ vorbis_comment *vc;
++ char **comment;
++ double duration;
++
++ if (id3tag)
++ memset(id3tag, 0, sizeof(*id3tag));
++
++ if ((f = fopen(fname, "rb")) == NULL)
++ return -1;
++
++ if (ov_open(f, &vf, NULL, 0) < 0) {
++ fclose(f);
++ return -1;
++ }
++
++ if ( !(vi = ov_info(&vf, -1)) || !(vc = ov_comment(&vf, -1))) {
++ ov_clear(&vf);
++ fclose(f);
++ return -1;
++ }
++
++ if (bitrate_ret)
++ *bitrate_ret = vi->bitrate_nominal;
++
++ for (comment = vc->user_comments ; *comment ; ++comment) {
++ if (strncmp(*comment, "title=", 6) == 0) {
++ strlcpy(id3tag->title, *comment + 6, MP3ID3_TITLELEN+1);
++ id3tag->present = 1;
++ }
++ else if (strncmp(*comment, "artist=", 7) == 0)
++ strlcpy(id3tag->artist, *comment + 7, MP3ID3_ARTISTLEN+1);
++ else if (strncmp(*comment, "album=", 6) == 0)
++ strlcpy(id3tag->album, *comment + 6, MP3ID3_ALBUMLEN+1);
++ else if (strncmp(*comment, "date=", 5) == 0)
++ strlcpy(id3tag->year, *comment + 5, MP3ID3_YEARLEN+1);
++ else if (strncmp(*comment, "genre=", 6) == 0)
++ strlcpy(id3tag->genre, *comment + 6, 31);
++ /* tracknumber ignored */
++ }
++
++ duration = ov_time_total(&vf, -1);
++ ov_clear(&vf);
++ fclose(f);
++ return (int)duration * 100;
+ }
+
+ #endif
diff --git a/audio/mserv/patches/patch-af b/audio/mserv/patches/patch-af
index c85252ba51c..695db1f8890 100644
--- a/audio/mserv/patches/patch-af
+++ b/audio/mserv/patches/patch-af
@@ -1,4 +1,4 @@
-$NetBSD: patch-af,v 1.6 2003/09/03 12:35:13 martin Exp $
+$NetBSD: patch-af,v 1.7 2003/09/03 19:55:28 abs Exp $
--- mserv/defconf.c.orig 2003-08-04 20:25:36.000000000 +0200
+++ mserv/defconf.c 2003-09-03 13:44:02.000000000 +0200
@@ -82,7 +82,7 @@ $NetBSD: patch-af,v 1.6 2003/09/03 12:35:13 martin Exp $
+"player_mp3=prog_mpg123\n"
+"player_wav=prog_play\n"
+"player_au=prog_play\n"
-+"player_ogg=prog_ogg\n"
++"player_ogg=prog_ogg123\n"
+"\n"
+"# Set default random mode, either on or off. You must still tell mserv to\n"
+"# start playing (PLAY).\n"