ports/115592: Update port: astro/gpsd Added rc.d script
Douglas William Thrift
douglas at douglasthrift.net
Fri Aug 17 01:10:02 UTC 2007
>Number: 115592
>Category: ports
>Synopsis: Update port: astro/gpsd Added rc.d script
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Fri Aug 17 01:10:01 GMT 2007
>Closed-Date:
>Last-Modified:
>Originator: Douglas William Thrift
>Release: FreeBSD 6.2-RELEASE-jc1 i386
>Organization:
>Environment:
System: FreeBSD slowhand.douglasthrift.net 6.2-RELEASE-jc1 FreeBSD 6.2-RELEASE-jc1 #0: Fri Feb 16 19:33:37 PST 2007 user at jail14.johncompanies.com:/usr/obj/usr/src/sys/jail14 i386
>Description:
Gpsd lacked an rc.d start up script, so I wrote one.
>How-To-Repeat:
>Fix:
--- gpsd.patch begins here ---
diff -Nrux .svn -x work /usr/ports/astro/gpsd/Makefile gpsd/Makefile
--- /usr/ports/astro/gpsd/Makefile Mon Aug 6 13:40:11 2007
+++ gpsd/Makefile Thu Aug 16 17:56:37 2007
@@ -15,6 +15,7 @@
MAINTAINER= toxa at toxahost.ru
COMMENT= Daemon that monitors one or more GPSes attached to a host computer
+USE_RC_SUBR= gpsd.sh
USE_AUTOTOOLS= libtool:15
GNU_CONFIGURE= yes
USE_LDCONFIG= yes
diff -Nrux .svn -x work /usr/ports/astro/gpsd/files/gpsd.sh.in gpsd/files/gpsd.sh.in
--- /usr/ports/astro/gpsd/files/gpsd.sh.in Wed Dec 31 16:00:00 1969
+++ gpsd/files/gpsd.sh.in Thu Aug 16 17:53:26 2007
@@ -0,0 +1,40 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: gpsd
+# REQUIRE: NETWORKING DAEMON cleanvar devfs
+# BEFORE: ntpd
+# KEYWORD: shutdown
+
+#
+# Add the following lines to /etc/rc.conf to enable gpsd:
+#
+# gpsd_enable (bool): Set to "NO" by default.
+# Set it to "YES" to enable gpsd.
+#
+# gpsd_flags (str): Set to "" by default.
+# See gpsd(8) for flags.
+#
+# gpsd_devices (str): Set to "" by default.
+# Example: "/dev/cuaU0" for a USB serial GPS.
+#
+
+. %%RC_SUBR%%
+
+name=gpsd
+rcvar=`set_rcvar`
+
+load_rc_config $name
+
+# Set defaults
+: ${gpsd_enable:="NO"}
+: ${gpsd_flags:=""}
+: ${gpsd_devices:=""}
+
+pidfile=/var/run/$name.pid
+command=%%PREFIX%%/sbin/$name
+command_args="-P $pidfile $gpsd_devices"
+
+run_rc_command "$1"
--- gpsd.patch ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list