summaryrefslogtreecommitdiff
path: root/x11/xfstt
diff options
context:
space:
mode:
authorgrant <grant@pkgsrc.org>2002-09-27 14:47:06 +0000
committergrant <grant@pkgsrc.org>2002-09-27 14:47:06 +0000
commit157d169588f9ac43c63a06d19d65f6c75abb2256 (patch)
tree1ac06f8cf57ff273ba60fc90b94297457a107bf4 /x11/xfstt
parentc071f4051e8bb86bea249d21932b9d3f28a6e4f3 (diff)
downloadpkgsrc-157d169588f9ac43c63a06d19d65f6c75abb2256.tar.gz
* use bsd.pkg.install.mk and automatic rc.d script handling.
* convert to rc.subr-style script.
Diffstat (limited to 'x11/xfstt')
-rw-r--r--x11/xfstt/Makefile8
-rw-r--r--x11/xfstt/files/xfstt.sh29
2 files changed, 16 insertions, 21 deletions
diff --git a/x11/xfstt/Makefile b/x11/xfstt/Makefile
index f6a731b3d23..bdd5b01123f 100644
--- a/x11/xfstt/Makefile
+++ b/x11/xfstt/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.8 2002/08/22 02:22:14 grant Exp $
+# $NetBSD: Makefile,v 1.9 2002/09/27 14:47:06 grant Exp $
#
DISTNAME= xfstt_1.3
@@ -17,6 +17,8 @@ USE_X11BASE= YES
USE_GMAKE= YES
WRKSRC= ${WRKDIR}/${PKGNAME}
+RCD_SCRIPTS= xfstt
+
post-patch:
@( \
cd ${WRKSRC} ; \
@@ -35,10 +37,8 @@ do-install:
${INSTALL_DATA} ${WRKSRC}/CHANGES ${PREFIX}/share/doc/xfstt
${INSTALL_DATA} ${WRKSRC}/INSTALL ${PREFIX}/share/doc/xfstt
${INSTALL_DATA} ${WRKSRC}/THANKS ${PREFIX}/share/doc/xfstt
- ${SED} -e "/%%PREFIX%%/s##${PREFIX}#g" ${FILESDIR}/xfstt.sh \
- > ${PREFIX}/etc/rc.d/xfstt
- ${CHMOD} 755 ${PREFIX}/etc/rc.d/xfstt
${INSTALL_DATA_DIR} ${PREFIX}/lib/X11/fonts/TrueType
${ECHO} belongs to xfstt pkg >${PREFIX}/lib/X11/fonts/TrueType/.keepme
+.include "../../mk/bsd.pkg.install.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/x11/xfstt/files/xfstt.sh b/x11/xfstt/files/xfstt.sh
index 376c2574a35..74bf3eeca8d 100644
--- a/x11/xfstt/files/xfstt.sh
+++ b/x11/xfstt/files/xfstt.sh
@@ -1,22 +1,17 @@
-#!/bin/sh
+#!@RCD_SCRIPTS_SHELL@
#
-# $NetBSD: xfstt.sh,v 1.2 2002/09/20 04:05:45 grant Exp $
+# $NetBSD: xfstt.sh,v 1.3 2002/09/27 14:47:06 grant Exp $
#
+# PROVIDE: xfstt
+# REQUIRE: DAEMON
-PREFIX=%%PREFIX%%
+. /etc/rc.subr
-case "$1" in
+name="xfstt"
+command="@PREFIX@/bin/${name}"
+command_flags="--user nobody --notcp --daemon &"
+pidfile="/var/run/${name}.pid"
+start_precmd="${command} --sync >/dev/null"
-start)
- ${PREFIX}/bin/xfstt --sync >/dev/null
- ${PREFIX}/bin/xfstt --user nobody --notcp --daemon && echo -n ' xfstt'
- ;;
-stop)
- kill `ps -auxwww | grep xfstt | awk '{ print $2 }'`
- echo -n ' xfstt'
- ;;
-*)
- echo "$0 start | stop"
- ;;
-
-esac
+load_rc_config $name
+run_rc_command "$1"