View | Details | Raw Unified | Return to bug 75516
Collapse All | Expand All

(-)mpd/Makefile (-1 / +5 lines)
Lines 21-26 Link Here
21
MANCOMPRESSED=	maybe
21
MANCOMPRESSED=	maybe
22
22
23
USE_OPENSSL	=yes
23
USE_OPENSSL	=yes
24
USE_RC_SUBR=    yes
24
MAKE_ENV=	COPTS="${COPTS} -I${OPENSSLINC}" LDADD="${LDADD} -L${OPENSSLLIB}"
25
MAKE_ENV=	COPTS="${COPTS} -I${OPENSSLINC}" LDADD="${LDADD} -L${OPENSSLLIB}"
25
26
26
.include <bsd.port.pre.mk>
27
.include <bsd.port.pre.mk>
Lines 31-36 Link Here
31
	@${ECHO}
32
	@${ECHO}
32
33
33
post-install:
34
post-install:
34
	@${INSTALL_SCRIPT} -m 751 ${FILESDIR}/mpd.sh ${PREFIX}/etc/rc.d/mpd.sh.sample
35
	@${SED} -e "s=%%RC_SUBR%%=${RC_SUBR}=" \
36
		-e "s=%%PREFIX%%=${PREFIX}=" \
37
		< ${FILESDIR}/mpd.sh > ${WRKSRC}/mpd.sh
38
	@${INSTALL_SCRIPT} ${WRKSRC}/mpd.sh ${PREFIX}/etc/rc.d/mpd.sh
35
39
36
.include <bsd.port.post.mk>
40
.include <bsd.port.post.mk>
(-)mpd/files/mpd.sh (-32 / +24 lines)
Lines 1-37 Link Here
1
#!/bin/sh
1
#!/bin/sh
2
#
2
# $FreeBSD: ports/net/mpd/files/mpd.sh,v 1.1 2003/11/22 20:51:05 archie Exp $
3
# $FreeBSD: ports/net/mpd/files/mpd.sh,v 1.1 2003/11/22 20:51:05 archie Exp $
4
#
5
# PROVIDE: mpd
6
# REQUIRE: NETWORKING
7
# KEYWORD: FreeBSD
8
#
9
# Add the following line to /etc/rc.conf to enable mpd:
10
#
11
# mpd_enable="YES"
12
#
3
13
4
DAEMON=/usr/local/sbin/mpd
14
mpd_flags="-b"
5
PIDFILE=/var/run/mpd.pid
15
mpd_enable="NO"
6
16
7
case "$1" in
17
. %%RC_SUBR%%
8
start)
9
	if [ -f "${DAEMON}" -a -x "${DAEMON}" ]; then
10
		if [ -f "${PIDFILE}" ]; then
11
			echo ' mpd PID file found - not starting'
12
		else
13
			"${DAEMON}" -b -p "${PIDFILE}"
14
			echo -n ' mpd'
15
		fi
16
	else
17
		echo ' "${DAEMON}" executable not found - mpd not starting'
18
	fi
19
	;;
20
stop)
21
	if [ -f "${PIDFILE}" ]; then
22
		read -r pid junk < "${PIDFILE}"
23
		kill ${pid}
24
	else
25
		echo ' mpd PID file not found - not killing'
26
	fi
27
	;;
28
restart)
29
	$0 stop
30
	sleep 2
31
	$0 start
32
	;;
33
*)
34
	echo "usage: ${0##*/} {start|stop|restart}" >&2
35
	;;
36
esac
37
18
19
name=mpd
20
rcvar=`set_rcvar`
21
22
prefix=%%PREFIX%%
23
procname=${prefix}/sbin/mpd
24
pidfile=/var/run/mpd.pid
25
required_files="${prefix}/etc/mpd/mpd.conf ${prefix}/etc/mpd/mpd.links"
26
command="${prefix}/sbin/mpd"
27
28
load_rc_config ${name}
29
run_rc_command "$1"
(-)mpd/pkg-plist (-1 / +1 lines)
Lines 2-8 Link Here
2
etc/mpd/mpd.links.sample
2
etc/mpd/mpd.links.sample
3
etc/mpd/mpd.secret.sample
3
etc/mpd/mpd.secret.sample
4
etc/mpd/mpd.script.sample
4
etc/mpd/mpd.script.sample
5
etc/rc.d/mpd.sh.sample
5
etc/rc.d/mpd.sh
6
sbin/mpd
6
sbin/mpd
7
%%PORTDOCS%%%%DOCSDIR%%/README
7
%%PORTDOCS%%%%DOCSDIR%%/README
8
%%PORTDOCS%%%%DOCSDIR%%/mpd.ps
8
%%PORTDOCS%%%%DOCSDIR%%/mpd.ps

Return to bug 75516