Rework gpsd configuration 91/29691/3
authorScott Murray <scott.murray@konsulko.com>
Sun, 18 Feb 2024 21:09:28 +0000 (16:09 -0500)
committerScott Murray <scott.murray@konsulko.com>
Tue, 20 Feb 2024 14:41:30 +0000 (14:41 +0000)
To remove the use of the "virtual/gpsd-conf" RPROVIDES as part of
futureproofing for YP 5.0 / Scarthgap, rework the machine-specific
gpsd configuration scheme to based on the gpsd-machine-conf recipe
that is intended for this upstream.  The gpsd-machine-conf recipe
is now unconditionally included in the navigation packagegroup,
but it will be empty on machines except those that add their own
content to it.

Bug-AGL: SPEC-5067

Change-Id: I7f1b555f154fe77c643019dae4bb90354ca2a4b4
Signed-off-by: Scott Murray <scott.murray@konsulko.com>
Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl-demo/+/29691
ci-image-boot-test: Jenkins Job builder account
Tested-by: Jenkins Job builder account
ci-image-build: Jenkins Job builder account

recipes-navigation/gpsd/gpsd-machine-conf_%.bbappend [new file with mode: 0644]
recipes-navigation/gpsd/gpsd-machine-conf_agldemo.inc [new file with mode: 0644]
recipes-navigation/gpsd/gpsd_agldemo.inc
recipes-platform/packagegroups/packagegroup-agl-ivi-navigation.bb

diff --git a/recipes-navigation/gpsd/gpsd-machine-conf_%.bbappend b/recipes-navigation/gpsd/gpsd-machine-conf_%.bbappend
new file mode 100644 (file)
index 0000000..77c0ef8
--- /dev/null
@@ -0,0 +1 @@
+require ${@bb.utils.contains('AGL_FEATURES', 'agldemo', 'gpsd-machine-conf_agldemo.inc', '', d)}
diff --git a/recipes-navigation/gpsd/gpsd-machine-conf_agldemo.inc b/recipes-navigation/gpsd/gpsd-machine-conf_agldemo.inc
new file mode 100644 (file)
index 0000000..f2bca1a
--- /dev/null
@@ -0,0 +1,8 @@
+# Mark package as machine specific, which the upstream stub recipe
+# does not do for unclear reasons.
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+# Allow an empty package as results from the upstream stub recipe.
+# This allows using the package without needing machine specific
+# hooks.
+ALLOW_EMPTY:${PN} = "1"
index 77dee8e..cb26510 100644 (file)
@@ -8,5 +8,3 @@ do_install:append() {
     install -m 0755 ${WORKDIR}/sw-device-hook ${D}${sysconfdir}/gpsd/device-hook
 }
 
-RPROVIDES:${PN}-conf:append = " virtual/gpsd-conf"
-
index 9db2c0b..f6c5e15 100644 (file)
@@ -12,7 +12,6 @@ PACKAGES = "\
 
 RDEPENDS:${PN} += "\
     gpsd \
+    gpsd-machine-conf \
     geoclue \
-    ${@bb.utils.contains('AGL_FEATURES', 'agldemo', 'virtual/gpsd-conf', '', d)} \
-    ${@bb.utils.contains('AGL_FEATURES', 'agl-refhw-h3', 'gpsd-conf-refhw', '', d)} \
     "