mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] [PATCH v3] gpsd: fix gpsdctl@.service
@ 2020-08-03 14:29 Ladislav Michl
  2020-08-17  6:18 ` [ptxdist] [APPLIED] " Michael Olbrich
  0 siblings, 1 reply; 2+ messages in thread
From: Ladislav Michl @ 2020-08-03 14:29 UTC (permalink / raw)
  To: ptxdist

gpsdctl@.service is supposed to call gpsdctl which is not installed
at all. Also fix gpsctl vs gpsdctl confusion.

Signed-off-by: Ladislav Michl <ladis@linux-mips.org>
---
 CHANGES:
 -v2: do not select GPSD_GPSDCTL
 -v3: fix typo
 projectroot/usr/lib/systemd/system/gpsdctl@.service | 4 ++--
 rules/gpsd.in                                       | 8 ++++++++
 rules/gpsd.make                                     | 8 ++++++--
 3 files changed, 16 insertions(+), 4 deletions(-)

diff --git a/projectroot/usr/lib/systemd/system/gpsdctl@.service b/projectroot/usr/lib/systemd/system/gpsdctl@.service
index 24d291408..6266fd8b8 100644
--- a/projectroot/usr/lib/systemd/system/gpsdctl@.service
+++ b/projectroot/usr/lib/systemd/system/gpsdctl@.service
@@ -8,5 +8,5 @@ After=dev-%i.device
 Type=oneshot
 Environment="GPSD_SOCKET=/var/run/gpsd.sock"
 RemainAfterExit=yes
-ExecStart=/usr/bin/gpsdctl add /dev/%I
-ExecStop=/usr/bin/gpsdctl remove /dev/%I
+ExecStart=/usr/sbin/gpsdctl add /dev/%I
+ExecStop=/usr/sbin/gpsdctl remove /dev/%I
diff --git a/rules/gpsd.in b/rules/gpsd.in
index b69570af0..9e3ea51f6 100644
--- a/rules/gpsd.in
+++ b/rules/gpsd.in
@@ -260,6 +260,14 @@ menu "install options"
 		  queries with a format that is substantially easier to
 		  parse than the NMEA 0183 emitted by most GPS receivers.
 
+	config GPSD_GPSDCTL
+		bool
+		prompt "gpsdctl"
+		help
+		  gpsdctl is a tool for sending commands to an instance of
+		  gpsd over its control socket to add or remove devices from
+		  the daemon's device list.
+
 	config GPSD_SYSTEMD_UNIT
 		bool
 		default y
diff --git a/rules/gpsd.make b/rules/gpsd.make
index 7f7e369f3..a6739e37e 100644
--- a/rules/gpsd.make
+++ b/rules/gpsd.make
@@ -43,7 +43,8 @@ GPSD_PROGS-$(PTXCONF_GPSD_GPSMON)	+= gpsmon
 GPSD_PROGS-$(PTXCONF_GPSD_NTPSHMMON)	+= ntpshmmon
 GPSD_PROGS-$(PTXCONF_GPSD_PPSCHECK)	+= ppscheck
 
-GPSD_BUILD_CLIENTS := $(if $(strip $(GPSD_PROGS-y)),yes,no)
+GPSD_BUILD_CLIENTS := $(call ptx/ifdef, PTXCONF_GPSD_GPSDCTL, yes, \
+			$(if $(strip $(GPSD_PROGS-y)), yes, no))
 
 # Python programs
 GPSD_PROGS-$(PTXCONF_GPSD_GEGPS)	+= gegps
@@ -160,6 +161,9 @@ $(STATEDIR)/gpsd.targetinstall:
 ifdef PTXCONF_GPSD_GPSD
 	@$(call install_copy, gpsd, 0, 0, 0755, -, /usr/sbin/gpsd)
 endif
+ifdef PTXCONF_GPSD_GPSDCTL
+	@$(call install_copy, gpsd, 0, 0, 0755, -, /usr/sbin/gpsdctl)
+endif
 ifdef PTXCONF_GPSD_SYSTEMD_UNIT
 	@$(call install_alternative, gpsd, 0, 0, 644, \
 		/usr/lib/systemd/system/gpsd.service)
@@ -172,7 +176,7 @@ ifdef PTXCONF_GPSD_SYSTEMD_UNIT
 		/usr/lib/systemd/system/gpsd.socket)
 	@$(call install_link, gpsd, ../gpsd.socket, \
 		/usr/lib/systemd/system/sockets.target.wants/gpsd.socket)
-ifdef PTXCONF_GPSD_GPSCTL
+ifdef PTXCONF_GPSD_GPSDCTL
 	@$(call install_alternative, gpsd, 0, 0, 644, \
 		/usr/lib/systemd/system/gpsdctl@.service)
 endif
-- 
2.28.0


_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
To unsubscribe, send a mail with subject "unsubscribe" to ptxdist-request@pengutronix.de

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [ptxdist] [APPLIED] gpsd: fix gpsdctl@.service
  2020-08-03 14:29 [ptxdist] [PATCH v3] gpsd: fix gpsdctl@.service Ladislav Michl
@ 2020-08-17  6:18 ` Michael Olbrich
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Olbrich @ 2020-08-17  6:18 UTC (permalink / raw)
  To: ptxdist

Thanks, applied as ec1da408c486ef53abb1f8408d4bf5d54f079df6.

Michael

[sent from post-receive hook]

On Mon, 17 Aug 2020 08:18:15 +0200, Ladislav Michl <ladis@linux-mips.org> wrote:
> gpsdctl@.service is supposed to call gpsdctl which is not installed
> at all. Also fix gpsctl vs gpsdctl confusion.
> 
> Signed-off-by: Ladislav Michl <ladis@linux-mips.org>
> Message-Id: <20200803142935.GA2907440@lenoch>
> Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
> 
> diff --git a/projectroot/usr/lib/systemd/system/gpsdctl@.service b/projectroot/usr/lib/systemd/system/gpsdctl@.service
> index 24d291408e24..6266fd8b87a2 100644
> --- a/projectroot/usr/lib/systemd/system/gpsdctl@.service
> +++ b/projectroot/usr/lib/systemd/system/gpsdctl@.service
> @@ -8,5 +8,5 @@ After=dev-%i.device
>  Type=oneshot
>  Environment="GPSD_SOCKET=/var/run/gpsd.sock"
>  RemainAfterExit=yes
> -ExecStart=/usr/bin/gpsdctl add /dev/%I
> -ExecStop=/usr/bin/gpsdctl remove /dev/%I
> +ExecStart=/usr/sbin/gpsdctl add /dev/%I
> +ExecStop=/usr/sbin/gpsdctl remove /dev/%I
> diff --git a/rules/gpsd.in b/rules/gpsd.in
> index b69570af0f49..9e3ea51f6359 100644
> --- a/rules/gpsd.in
> +++ b/rules/gpsd.in
> @@ -260,6 +260,14 @@ menu "install options"
>  		  queries with a format that is substantially easier to
>  		  parse than the NMEA 0183 emitted by most GPS receivers.
>  
> +	config GPSD_GPSDCTL
> +		bool
> +		prompt "gpsdctl"
> +		help
> +		  gpsdctl is a tool for sending commands to an instance of
> +		  gpsd over its control socket to add or remove devices from
> +		  the daemon's device list.
> +
>  	config GPSD_SYSTEMD_UNIT
>  		bool
>  		default y
> diff --git a/rules/gpsd.make b/rules/gpsd.make
> index 7f7e369f3ac1..a6739e37e6c2 100644
> --- a/rules/gpsd.make
> +++ b/rules/gpsd.make
> @@ -43,7 +43,8 @@ GPSD_PROGS-$(PTXCONF_GPSD_GPSMON)	+= gpsmon
>  GPSD_PROGS-$(PTXCONF_GPSD_NTPSHMMON)	+= ntpshmmon
>  GPSD_PROGS-$(PTXCONF_GPSD_PPSCHECK)	+= ppscheck
>  
> -GPSD_BUILD_CLIENTS := $(if $(strip $(GPSD_PROGS-y)),yes,no)
> +GPSD_BUILD_CLIENTS := $(call ptx/ifdef, PTXCONF_GPSD_GPSDCTL, yes, \
> +			$(if $(strip $(GPSD_PROGS-y)), yes, no))
>  
>  # Python programs
>  GPSD_PROGS-$(PTXCONF_GPSD_GEGPS)	+= gegps
> @@ -160,6 +161,9 @@ $(STATEDIR)/gpsd.targetinstall:
>  ifdef PTXCONF_GPSD_GPSD
>  	@$(call install_copy, gpsd, 0, 0, 0755, -, /usr/sbin/gpsd)
>  endif
> +ifdef PTXCONF_GPSD_GPSDCTL
> +	@$(call install_copy, gpsd, 0, 0, 0755, -, /usr/sbin/gpsdctl)
> +endif
>  ifdef PTXCONF_GPSD_SYSTEMD_UNIT
>  	@$(call install_alternative, gpsd, 0, 0, 644, \
>  		/usr/lib/systemd/system/gpsd.service)
> @@ -172,7 +176,7 @@ ifdef PTXCONF_GPSD_SYSTEMD_UNIT
>  		/usr/lib/systemd/system/gpsd.socket)
>  	@$(call install_link, gpsd, ../gpsd.socket, \
>  		/usr/lib/systemd/system/sockets.target.wants/gpsd.socket)
> -ifdef PTXCONF_GPSD_GPSCTL
> +ifdef PTXCONF_GPSD_GPSDCTL
>  	@$(call install_alternative, gpsd, 0, 0, 644, \
>  		/usr/lib/systemd/system/gpsdctl@.service)
>  endif

_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
To unsubscribe, send a mail with subject "unsubscribe" to ptxdist-request@pengutronix.de

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-08-17  6:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-03 14:29 [ptxdist] [PATCH v3] gpsd: fix gpsdctl@.service Ladislav Michl
2020-08-17  6:18 ` [ptxdist] [APPLIED] " Michael Olbrich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox