Portlint(1) fixes.

Makefile unwanted spaces and changes to the tab and remove unwanted comments.
Files are not installed.
UID / GID immobilized.

PR:		151298
Submitted by:	Takefu <takefu@airport.fm>
Approved by:	itetcu - Maintainer timeout (Mark Foster mark@foster.cc)
This commit is contained in:
Beech Rintoul 2010-11-26 23:07:50 +00:00
parent 2976d6ac2c
commit d114df80a9
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=265218
5 changed files with 77 additions and 48 deletions

View file

@ -1,6 +1,6 @@
# New ports collection makefile for: mt-daapd-devel
# Date created: 26 Nov 2007
# Whom: Mark Foster <mark@foster.cc>
# New ports collection makefile for: mt-daapd-devel
# Date created: 26 Nov 2007
# Whom: Mark Foster <mark@foster.cc>
# $FreeBSD$
#
@ -26,14 +26,13 @@ LIB_DEPENDS= ogg:${PORTSDIR}/audio/libogg \
CONFLICTS= mt-daapd-0.2.*
GNU_CONFIGURE= yes
CONFIGURE_ENV= CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}" \
CONFIGURE_ENV= CFLAGS+="${PTHREAD_CFLAGS}" \
CPPFLAGS="${CPPFLAGS} -I${LOCALBASE}/include" \
LDFLAGS="-L${LOCALBASE}/lib" \
LIBS="-L${LOCALBASE}/lib ${PTHREAD_LIBS}"
CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
CONFIGURE_ARGS= --prefix=${LOCALBASE} --with-id3tag=${PREFIX} --enable-sqlite3 --enable-oggvorbis --enable-flac
#USE_AUTOTOOLS= autoheader:261 autoconf:261:env
CONFIGURE_ARGS= --prefix=${PREFIX} --with-id3tag=${PREFIX} \
--enable-sqlite3 --enable-oggvorbis --enable-flac
DAAPD_USER?= daapd
DAAPD_GROUP?= daapd
@ -41,7 +40,9 @@ DAAPD_DBDIR?= ${PREFIX}/var/db/${PORTNAME}
USE_RC_SUBR= mt-daapd
PLIST_SUB+= DAAPD_DBDIR=${DAAPD_DBDIR}
SUB_LIST+= USER=${DAAPD_USER} GROUP=${DAAPD_GROUP} DAAPD_DBDIR=${DAAPD_DBDIR}
SUB_LIST+= USER=${DAAPD_USER}\
GROUP=${DAAPD_GROUP}\
DAAPD_DBDIR=${DAAPD_DBDIR}
SUB_FILES+= pkg-install pkg-deinstall
USE_LDCONFIG= yes
@ -76,9 +77,6 @@ post-install:
@${CHMOD} 0755 ${DATADIR}
@${CHOWN} ${DAAPD_USER}:${DAAPD_GROUP} ${DAAPD_DBDIR}
@${CHOWN} ${DAAPD_USER}:${DAAPD_GROUP} ${DATADIR}
${LN} -sf ${PREFIX}/lib/mt-daapd/plugins/libout-daap.so.0.0 ${PREFIX}/lib/mt-daapd/plugins/libout-daap.so
${LN} -sf ${PREFIX}/lib/mt-daapd/plugins/librsp.so.0.0 ${PREFIX}/lib/mt-daapd/plugins/librsp.so
${LN} -sf ${PREFIX}/lib/mt-daapd/plugins/libssc-script.so.0.0 ${PREFIX}/lib/mt-daapd/plugins/libssc-script.so
@${ECHO_MSG} "This port installs a sample configuration file in"
@${ECHO_MSG} "${LOCALBASE}/etc/mt-daapd.conf.sample"

View file

@ -0,0 +1,11 @@
--- contrib/Makefile.in.orig 2007-10-29 15:03:19.000000000 +0900
+++ contrib/Makefile.in 2010-10-08 18:39:10.000000000 +0900
@@ -200,7 +200,7 @@
EXTRA_DIST = README mt-daapd.spec mt-daapd.conf.templ mt-daapd-ssc.sh mt-daapd-ssc.pl
BUILT_SOURCES = mt-daapd.conf
bin_SCRIPTS = mt-daapd-ssc.sh
-dbdir = "$(localstatedir)/cache/mt-daapd"
+dbdir = "$(localstatedir)/db/firefly"
all: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) all-recursive

View file

@ -1,7 +1,6 @@
#!/bin/sh
#
# $FreeBSD$
# formerly $ FreeBSD: ports/audio/mt-daapd/pkg-deinstall,v 1.1 2004/08/05 23:00:09 edwin Exp $
#
PATH=/bin:/usr/bin:/usr/sbin
@ -11,16 +10,16 @@ case $2 in
POST-DEINSTALL)
echo '---> Starting post-deinstall script:'
if [ -f /usr/local/etc/mt-daapd.conf ]; then
if [ -f %%PREFIX%%/etc/mt-daapd.conf ]; then
echo '---> You seem to have made some custom daapd configuration.'
echo '---> The "daapd" user and "daapd" group were therefore not deleted.'
echo '---> You may delete them with "pw groupdel daapd; pw userdel daapd".'
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 "daapd"'
/usr/sbin/pw groupdel -n daapd
echo '---> Removing user "daapd"'
echo 'y' | /usr/sbin/pw userdel -n daapd
echo '---> Removing group "%%GROUP%%"'
/usr/sbin/pw groupdel -n %%GROUP%%
echo '---> Removing user "%%USER%%"'
echo 'y' | /usr/sbin/pw userdel -n %%USER%%
fi
;;

View file

@ -1,33 +1,53 @@
#!/bin/sh
#
# $FreeBSD: /tmp/pcvs/ports/audio/firefly/files/Attic/pkg-install.in,v 1.1 2008-10-19 15:59:16 miwi Exp $
# formerly $ FreeBSD: ports/audio/mt-daapd/pkg-install,v 1.1 2004/08/05 23:00:09 edwin Exp $
# $FreeBSD: /tmp/pcvs/ports/audio/firefly/files/Attic/pkg-install.in,v 1.2 2010-11-26 23:07:50 beech Exp $
#
PATH=/bin:/usr/bin:/usr/sbin
if [ "$2" != "PRE-INSTALL" ]; then
exit 0
fi
case $2 in
SC_GROUP=%%GROUP%%
SC_USER=%%USER%%
SC_SHELL=/sbin/nologin
SC_HOME=/nonexistent
PW=`which pw`
PRE-INSTALL)
echo "---> Starting pre-install script:"
if ! ${PW} show group ${SC_GROUP} -q >/dev/null; then
gid=3689
while ${PW} show group -g ${gid} -q >/dev/null; do
gid=`expr ${gid} + 1`
done
if ! ${PW} add group ${SC_GROUP} -g ${gid}; then
e=$?
echo "*** Failed to add group \`${SC_GROUP}'. Please add it manually."
exit ${e}
fi
echo "*** Added group \`${SC_GROUP}' (id ${gid})"
else
gid=`${PW} show group ${SC_GROUP} 2>/dev/null | cut -d: -f3`
fi
if pw showgroup "daapd" 2>/dev/null; then
echo "---> Using existing group \"daapd\""
else
echo "---> Adding group \"daapd\""
pw addgroup daapd -h - || exit 1
fi
# Create user if required
if pw showuser "daapd" 2>/dev/null; then
echo "---> Using existing user \"daapd\""
else
echo "---> Adding user \"daapd\""
pw adduser daapd -g daapd -h - \
-d "/nonexistent" -s "/sbin/nologin" -c "daapd User" || exit 1
fi
;;
esac
if ! ${PW} show user ${SC_USER} -q >/dev/null; then
uid=3689
while ${PW} show user -u ${uid} -q >/dev/null; do
uid=`expr ${uid} + 1`
done
if ! ${PW} add user ${SC_USER} -u ${uid} -g ${gid} -d "${SC_HOME}" \
-c "daapd User" -s "${SC_SHELL}" -p "*" \
; then
e=$?
echo "*** Failed to add user \`${SC_USER}'. Please add it manually."
exit ${e}
fi
echo "*** Added user \`${SC_USER}' (id ${uid})"
else
if ! ${PW} mod user ${SC_USER} -g ${gid} -d "${SC_HOME}" \
-c "daapd User" -s "${SC_SHELL}" -p "*" \
; then
e=$?
echo "*** Failed to update user \`${SC_USER}'."
exit ${e}
fi
echo "*** Updated user \`${SC_USER}'."
fi

View file

@ -2,9 +2,6 @@
bin/mt-daapd-ssc.sh
bin/wavstreamer
etc/mt-daapd.conf.sample
lib/mt-daapd/plugins/libout-daap.so
lib/mt-daapd/plugins/librsp.so
lib/mt-daapd/plugins/libssc-script.so
lib/mt-daapd/plugins/out-daap.a
lib/mt-daapd/plugins/out-daap.la
lib/mt-daapd/plugins/out-daap.so
@ -78,3 +75,7 @@ share/mt-daapd/admin-root/zlib-license.txt
%%PORTDOCS%%@dirrm %%DOCSDIR%%
@dirrmtry lib/mt-daapd/plugins
@dirrmtry lib/mt-daapd
@rmtry var/db/firefly/songs3.db
@dirrmtry var/db/firefly
@dirrmtry var/db
@dirrmtry var