aboutsummaryrefslogtreecommitdiff
path: root/audio/mt-daapd
diff options
context:
space:
mode:
authorEdwin Groothuis <edwin@FreeBSD.org>2004-08-05 23:00:10 +0000
committerEdwin Groothuis <edwin@FreeBSD.org>2004-08-05 23:00:10 +0000
commitab42fbb1c7e8e4ba1360ec7243108334e1f36f3f (patch)
treed72cdd6b13613ec9469e013d0d666bd92db46616 /audio/mt-daapd
parentb92d6f844ac451b23fc5c3ca1d4a8b180b764bfe (diff)
downloadports-ab42fbb1c7e8e4ba1360ec7243108334e1f36f3f.tar.gz
ports-ab42fbb1c7e8e4ba1360ec7243108334e1f36f3f.zip
Notes
Diffstat (limited to 'audio/mt-daapd')
-rw-r--r--audio/mt-daapd/Makefile27
-rw-r--r--audio/mt-daapd/distinfo4
-rw-r--r--audio/mt-daapd/files/mt-daapd.conf57
-rw-r--r--audio/mt-daapd/files/patch-gcc295481
-rw-r--r--audio/mt-daapd/pkg-deinstall27
-rw-r--r--audio/mt-daapd/pkg-install32
-rw-r--r--audio/mt-daapd/pkg-plist8
7 files changed, 143 insertions, 93 deletions
diff --git a/audio/mt-daapd/Makefile b/audio/mt-daapd/Makefile
index c2e874677a69..2c284f5be730 100644
--- a/audio/mt-daapd/Makefile
+++ b/audio/mt-daapd/Makefile
@@ -6,7 +6,7 @@
#
PORTNAME= mt-daapd
-PORTVERSION= 0.1.1
+PORTVERSION= 0.2.0
CATEGORIES= audio
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= mt-daapd
@@ -14,12 +14,9 @@ MASTER_SITE_SUBDIR= mt-daapd
MAINTAINER= Meno.Abels@Adviser.com
COMMENT= Multithread daapd yet another Server for Apple iTunes
+BUILD_DEPENDS= ${LOCALBASE}/lib/libgdbm.a:${PORTSDIR}/databases/gdbm
LIB_DEPENDS= id3tag.2:${PORTSDIR}/audio/libid3tag
-MAKE_ARGS= CC="${CC}" CFLAGS="${CFLAGS}" prefix="${PREFIX}" \
- LDFLAGS="${LDFLAGS}" LIBS="${LIBS}" \
- INSTALL_PROGRAM="${INSTALL_PROGRAM}"
-
GNU_CONFIGURE= yes
CONFIGURE_ENV= AUTOCONF=autoconf259 AUTOHEADER=autoheader259 CC="${CC} -pthread"
CONFIGURE_ARGS= --with-id3tag=${PREFIX}
@@ -27,12 +24,19 @@ CONFIGURE_ARGS= --with-id3tag=${PREFIX}
USE_AUTOHEADER_VER= 259
WANT_AUTOCONF_VER= 259
-DAAPD_USER= daapd
-DAAPD_GROUP= daapd
+DAAPD_USER?= daapd
+DAAPD_GROUP?= daapd
+
+PKGINSTALL= ${WRKDIR}/pkg-install
+PKGDEINSTALL= ${WRKDIR}/pkg-deinstall
FILES_SUB= USER=${DAAPD_USER} GROUP=${DAAPD_GROUP} \
PREFIX=${PREFIX} LOGDIR=${LOGDIR} DOCSDIR=${DOCSDIR} \
LOCALBASE=${LOCALBASE}
+pre-install:
+ @${SED} ${FILES_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
+ ${PKGDIR}/pkg-install > ${PKGINSTALL}
+ @${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
post-install:
.if !defined(NOPORTDOCS)
@@ -48,5 +52,14 @@ post-install:
${SED} ${FILES_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
${FILESDIR}/mt-daapd.conf > ${WRKDIR}/mt-daapd.conf
${INSTALL_DATA} ${WRKDIR}/mt-daapd.conf ${PREFIX}/etc/mt-daapd.conf.sample
+ ${MKDIR} ${PREFIX}/var/mt-daapd/db
+ ${MKDIR} ${PREFIX}/share/mt-daapd/mp3
+ ${CHMOD} 0755 ${PREFIX}/var/mt-daapd/db
+ ${CHMOD} 0755 ${PREFIX}/share/mt-daapd/mp3
+ ${CHOWN} ${DAAPD_USER}:${DAAPD_GROUP} ${PREFIX}/var/mt-daapd/db
+ ${CHOWN} ${DAAPD_USER}:${DAAPD_GROUP} ${PREFIX}/share/mt-daapd/mp3
+ ${SED} ${FILES_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
+ ${PKGDIR}/pkg-deinstall > ${PKGDEINSTALL}
+ ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
.include <bsd.port.mk>
diff --git a/audio/mt-daapd/distinfo b/audio/mt-daapd/distinfo
index e7eefe786a6f..910d32be4816 100644
--- a/audio/mt-daapd/distinfo
+++ b/audio/mt-daapd/distinfo
@@ -1,2 +1,2 @@
-MD5 (mt-daapd-0.1.1.tar.gz) = 8d2cbc30d73610aa974ca22a18c47b50
-SIZE (mt-daapd-0.1.1.tar.gz) = 284805
+MD5 (mt-daapd-0.2.0.tar.gz) = 62465e98dd93cd3553b329298d13399d
+SIZE (mt-daapd-0.2.0.tar.gz) = 372948
diff --git a/audio/mt-daapd/files/mt-daapd.conf b/audio/mt-daapd/files/mt-daapd.conf
index 547f67701615..45248d939d86 100644
--- a/audio/mt-daapd/files/mt-daapd.conf
+++ b/audio/mt-daapd/files/mt-daapd.conf
@@ -1,4 +1,4 @@
-# $Id: mt-daapd.conf,v 1.3 2004/01/04 20:13:19 rpedde Exp $
+# $Id: mt-daapd.conf,v 1.9 2004/04/18 20:24:14 rpedde Exp $
#
# This is the mt-daapd config file.
#
@@ -29,6 +29,14 @@ port 3689
admin_pw mt-daapd
#
+# db_dir (required)
+#
+# This is where mt-daapd stores its database of song information.
+#
+
+db_dir %%PREFIX%%/var/mt-daapd/db
+
+#
# mp3_dir (required)
#
# Location of the mp3 files to share
@@ -82,5 +90,52 @@ playlist %%PREFIX%%/etc/mt-daapd.playlist
#password mp3
+#
+# extensions (optional)
+#
+# These are the file extensions that the daap server will
+# try to index and serve. By default, it only indexes and
+# serves .mp3 files. It can also server .m4a and .m4p files,
+# and just about any other files, really. Unfortunately, while
+# it can *attempt* to serve other files (.ogg?), iTunes won't
+# play them. Perhaps this would be useful on Linux with
+# Rhythmbox, once it understands daap. (hurry up!)
+#
+
+extensions .mp3,.m4a,.m4p
+#
+# logfile (optional)
+#
+# This is the file to log to. If this is not configured,
+# then it will log to the syslog.
+#
+# Not that the -d <level> switch will control the log verbosity.
+# By default, it runs at log level 1. Log level 9 will churn
+# out scads of useless debugging information. Values in between
+# will vary the amount of logging you get.
+#
+
+logfile /var/log/mt-daapd.log
+#
+# art_filename (optional)
+#
+# There is experimental support thanks to Hiren Joshi
+# (hirenj@mooh.org) for dynamically adding art to the id3v2
+# header as it is streamed (!!). If you were using a music system
+# like zina or andromeda, for example, with cover art called
+# "_folderOpenImage.jpg", you could use the parameter
+# art_file _folderOpenImage.jpg and if the file _folderOpenImage.jpg
+# was located in the same folder as the .mp3 file, it would appear
+# in iTunes. Cool, eh?
+#
+# This is EXPERIMENTAL, so if you run into strange problems with
+# seeking in the songs, or songs that won't stream and leave an
+# exclamation point, then comment out this directive and try again.
+#
+# Do let me know (rpedde@users.sourceforge.net) if you have
+# problems with it though. And thanks again to Hiren.
+#
+
+#art_filename _folderOpenImage.jpg
diff --git a/audio/mt-daapd/files/patch-gcc2954 b/audio/mt-daapd/files/patch-gcc2954
deleted file mode 100644
index a9e6fdf00fdc..000000000000
--- a/audio/mt-daapd/files/patch-gcc2954
+++ /dev/null
@@ -1,81 +0,0 @@
-diff -nur ../../mt-daapd-0.1.1/src/configfile.c ./src/configfile.c
---- ../../mt-daapd-0.1.1/src/configfile.c Tue Jan 20 05:41:20 2004
-+++ ./src/configfile.c Mon Mar 15 09:21:00 2004
-@@ -122,11 +122,10 @@
- int config_read(char *file) {
- FILE *fin;
- char *buffer;
-- int err;
-+ int err=0;
- char *value;
- char *comment;
- char path_buffer[PATH_MAX];
-- err=0;
- CONFIGELEMENT *pce;
- int handled;
-
-Only in ./src: configfile.o
-Only in ./src: daap-proto.o
-Only in ./src: daap.o
-Only in ./src: db-memory.o
-Only in ./src: err.o
-Only in ./src: lexer.o
-Only in ./src: mDNS.o
-Only in ./src: mDNSPosix.o
-Only in ./src: mDNSUNP.o
-diff -nur ../../mt-daapd-0.1.1/src/main.c ./src/main.c
---- ../../mt-daapd-0.1.1/src/main.c Tue Jan 27 06:30:25 2004
-+++ ./src/main.c Mon Mar 15 09:19:38 2004
-@@ -417,13 +417,13 @@
- int status;
- int parseonly=0;
- int foreground=0;
-- config.use_mdns=1;
-
- #ifdef DEBUG
- char *optval="d:c:mpf";
- #else
- char *optval="c:mpf";
- #endif /* DEBUG */
-+ config.use_mdns=1;
-
- fprintf(stderr,"mt-daapd: version %s\n",VERSION);
- fprintf(stderr,"Copyright (c) 2003 Ron Pedde. All rights reserved\n");
-Only in ./src: main.o
-diff -nur ../../mt-daapd-0.1.1/src/mdns/mDNSUNP.h ./src/mdns/mDNSUNP.h
---- ../../mt-daapd-0.1.1/src/mdns/mDNSUNP.h Thu Oct 23 23:43:01 2003
-+++ ./src/mdns/mDNSUNP.h Mon Mar 15 09:23:00 2004
-@@ -93,7 +93,9 @@
- #endif
-
- #if !defined(HAVE_SOCKLEN_T)
-+#ifndef __FreeBSD__
- typedef unsigned int socklen_t;
-+#endif
- #endif
-
- #define IFI_NAME 16 /* same as IFNAMSIZ in <net/if.h> */
-Only in ./src: mp3-scanner.o
-Only in ./src: mt-daapd
-Only in ./src: parser.o
-Only in ./src: playlist.o
-Only in ./src: rend-posix.o
-Only in ./src: rend-unix.o
-Only in ./src: restart.o
-Only in ./src: uici.o
-diff -nur ../../mt-daapd-0.1.1/src/webserver.c ./src/webserver.c
---- ../../mt-daapd-0.1.1/src/webserver.c Sun Jan 4 06:27:43 2004
-+++ ./src/webserver.c Mon Mar 15 09:20:21 2004
-@@ -919,9 +919,9 @@
- *
- */
- int ws_testarg(ARGLIST *root, char *key, char *value) {
-+ char *retval=ws_getarg(root,key);
- DPRINTF(ERR_DEBUG,"Checking to see if %s matches %s\n",key,value);
-
-- char *retval=ws_getarg(root,key);
- if(!retval)
- return 0;
-
-Only in ./src: webserver.o
-Only in .: stamp-h1
diff --git a/audio/mt-daapd/pkg-deinstall b/audio/mt-daapd/pkg-deinstall
new file mode 100644
index 000000000000..f7bc12de979c
--- /dev/null
+++ b/audio/mt-daapd/pkg-deinstall
@@ -0,0 +1,27 @@
+#!/bin/sh
+#
+# $FreeBSD: /tmp/pcvs/ports/audio/mt-daapd/Attic/pkg-deinstall,v 1.1 2004-08-05 23:00:09 edwin Exp $
+#
+
+PATH=/bin:/usr/bin:/usr/sbin
+
+case $2 in
+
+POST-DEINSTALL)
+ echo '---> Starting post-deinstall script:'
+
+ if [ -f %%PREFIX%%/etc/mt-daapd.conf ]; then
+ echo '---> You seem to have made some custom daapd configuration.'
+ echo '---> The "%%USER%%" user and "%%GROUP%%" group were therefore not deleted.'
+ echo '---> You may delete them with "pw groupdel %%GROUP%%; pw userdel %%USER%%".'
+
+ else
+ echo '---> Removing group "%%GROUP%%"'
+ /usr/sbin/pw groupdel -n %%GROUP%%
+ echo '---> Removing user "%%USER%%"'
+ echo 'y' | /usr/sbin/pw userdel -n %%USER%%
+ fi
+
+ ;;
+
+esac
diff --git a/audio/mt-daapd/pkg-install b/audio/mt-daapd/pkg-install
new file mode 100644
index 000000000000..a80c1bc96d88
--- /dev/null
+++ b/audio/mt-daapd/pkg-install
@@ -0,0 +1,32 @@
+#!/bin/sh
+#
+# $FreeBSD: /tmp/pcvs/ports/audio/mt-daapd/Attic/pkg-install,v 1.1 2004-08-05 23:00:09 edwin Exp $
+#
+
+PATH=/bin:/usr/bin:/usr/sbin
+
+case $2 in
+
+PRE-INSTALL)
+ echo "---> Starting pre-install script:"
+
+ if pw showgroup "%%GROUP%%" 2>/dev/null; then
+ echo "---> Using existing group \"%%GROUP%%\""
+ else
+ echo "---> Adding group \"%%GROUP%%\""
+ pw addgroup %%GROUP%% -h - || exit 1
+ fi
+
+
+ # Create user if required
+ if pw showuser "%%USER%%" 2>/dev/null; then
+ echo "---> Using existing user \"%%USER%%\""
+ else
+ echo "---> Adding user \"%%USER%%\""
+ pw adduser %%USER%% -g %%GROUP%% -h - \
+ -d "/nonexistent" -s "/sbin/nologin" -c "daapd User" || exit 1
+ fi
+
+ ;;
+
+esac
diff --git a/audio/mt-daapd/pkg-plist b/audio/mt-daapd/pkg-plist
index 46b0e6c5ce7e..189303790fab 100644
--- a/audio/mt-daapd/pkg-plist
+++ b/audio/mt-daapd/pkg-plist
@@ -6,6 +6,7 @@ share/mt-daapd/admin-root/aspl-license.html
share/mt-daapd/admin-root/aspl-license.txt
share/mt-daapd/admin-root/config-update.html
share/mt-daapd/admin-root/config.html
+share/mt-daapd/admin-root/feedback.html
share/mt-daapd/admin-root/ftr.html
share/mt-daapd/admin-root/gpl-license.html
share/mt-daapd/admin-root/gpl-license.txt
@@ -18,8 +19,11 @@ share/mt-daapd/admin-root/mt-daapd.png
share/mt-daapd/admin-root/required.gif
share/mt-daapd/admin-root/status.html
share/mt-daapd/admin-root/thanks.html
-%%PORTDOCS%%@dirrm share/mt-daapd/admin-root
-%%PORTDOCS%%@dirrm share/mt-daapd
+@dirrm var/mt-daapd/db
+@dirrm var/mt-daapd
+@dirrm share/mt-daapd/mp3
+@dirrm share/mt-daapd/admin-root
+@dirrm share/mt-daapd
%%PORTDOCS%%%%DOCSDIR%%/README
%%PORTDOCS%%%%DOCSDIR%%/AUTHORS
%%PORTDOCS%%%%DOCSDIR%%/COPYING