diff options
author | khorben <khorben@pkgsrc.org> | 2022-05-20 19:52:41 +0000 |
---|---|---|
committer | khorben <khorben@pkgsrc.org> | 2022-05-20 19:52:41 +0000 |
commit | 82a29a79bbfae5dc87f3163513cacc12c26087d4 (patch) | |
tree | 9cf2349cd8b270ac698a59a432281db5d4679336 /geography/gpsd | |
parent | a07936977384944bb65c42c268a6e64e6046fcfd (diff) | |
download | pkgsrc-82a29a79bbfae5dc87f3163513cacc12c26087d4.tar.gz |
gpsd: provide a RC script
Bumps PKGREVISION.
Tested on NetBSD/amd64.
"ok with this" gdt@
Diffstat (limited to 'geography/gpsd')
-rw-r--r-- | geography/gpsd/Makefile | 5 | ||||
-rw-r--r-- | geography/gpsd/files/gpsd.sh | 32 |
2 files changed, 36 insertions, 1 deletions
diff --git a/geography/gpsd/Makefile b/geography/gpsd/Makefile index 0c5698e54fa..48b122c808e 100644 --- a/geography/gpsd/Makefile +++ b/geography/gpsd/Makefile @@ -1,6 +1,7 @@ -# $NetBSD: Makefile,v 1.63 2022/04/28 11:43:14 gdt Exp $ +# $NetBSD: Makefile,v 1.64 2022/05/20 19:52:41 khorben Exp $ DISTNAME= gpsd-3.24 +PKGREVISION= 1 CATEGORIES= geography MASTER_SITES= http://download-mirror.savannah.gnu.org/releases/gpsd/ # will probably switch to https://gitlab.com/gpsd/gpsd/releases @@ -46,6 +47,8 @@ SCONS_ARGS+= leapfetch=no # scons is hard to understand, so enable debugging always SCONS_ARGS+= --debug=explain,prepare +RCD_SCRIPTS= gpsd + SUBST_CLASSES+= pyenv SUBST_MESSAGE.pyenv= Fixing Python path in test script # We would choose post-configure, but gpsd's build system blurs diff --git a/geography/gpsd/files/gpsd.sh b/geography/gpsd/files/gpsd.sh new file mode 100644 index 00000000000..903dc56abdd --- /dev/null +++ b/geography/gpsd/files/gpsd.sh @@ -0,0 +1,32 @@ +#!@RCD_SCRIPTS_SHELL@ +# +# $NetBSD: gpsd.sh,v 1.1 2022/05/20 19:52:41 khorben Exp $ +# +# Interface daemon for GPS receivers +# +# PROVIDE: gpsd +# REQUIRE: DAEMON +# +# You will need to set some variables in @SYSCONFBASE@/rc.conf to start gpsd: +# +# gpsd=YES +# gpsd_devices= # List of devices for gpsd to monitor +# # this variable is required. +# gpsd_flags= # Additional options to provide to gpsd +# # this variable is optional and defaults to "-n". + +$_rc_subr_loaded . @SYSCONFBASE@/rc.subr + +name="gpsd" +rcvar=${name} +command="@PREFIX@/sbin/${name}" +start_precmd="gpsd_start_precmd" + +gpsd_start_precmd() +{ + rc_flags="$rc_flags ${gpsd_devices}" +} + +load_rc_config $name +: ${gpsd_flags:=-n} +run_rc_command "$1" |