From 3909ee206c177c7130c5d5a5f9b25aaad9897866 Mon Sep 17 00:00:00 2001 From: Scott Murray Date: Tue, 20 Feb 2024 12:29:24 -0500 Subject: Add KUKSA.val databroker image features Rework inclusion of KUKSA.val databroker server and client support into image features that can be specified via IMAGE_FEATURES, and use that in our demo image definitions. As well, add a new agl-kvm-host-kuksa feature that allows configuring the KVM demo build to run the databroker on the host instead of in the IVI guest. Some further application configuration changes are required for that to fully work, those will come in follow up commits. Bug-AGL: SPEC-5082 Change-Id: Ice931fe924c1bf49709999eeabcb998ee191fc80 Signed-off-by: Scott Murray Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl-demo/+/29699 ci-image-boot-test: Jenkins Job builder account Reviewed-by: Jan-Simon Moeller Tested-by: Jenkins Job builder account ci-image-build: Jenkins Job builder account (cherry picked from commit 0c14b48d5b0c1129e79f7a59daaedd3f55989c5c) Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl-demo/+/29760 --- .../images/agl-cluster-demo-platform-flutter.bb | 18 ++++++++---------- recipes-platform/images/agl-cluster-demo-platform.bb | 14 +++++++------- recipes-platform/images/agl-demo-features.inc | 9 +++++---- recipes-platform/images/agl-ivi-demo-base.bb | 6 +----- recipes-platform/images/agl-ivi-demo-features.inc | 11 +++++++++++ recipes-platform/images/agl-kvm-demo-platform.bb | 7 +++++++ .../packagegroup-agl-demo-platform-flutter.bb | 1 - .../packagegroups/packagegroup-agl-demo-platform.bb | 1 - templates/feature/agl-kvm-host-kuksa/50_local.conf.inc | 1 + .../README_feature_agl-kvm-host-kuksa.md | 17 +++++++++++++++++ templates/feature/agl-kvm-host-kuksa/included.dep | 1 + 11 files changed, 58 insertions(+), 28 deletions(-) create mode 100644 recipes-platform/images/agl-ivi-demo-features.inc create mode 100644 templates/feature/agl-kvm-host-kuksa/50_local.conf.inc create mode 100644 templates/feature/agl-kvm-host-kuksa/README_feature_agl-kvm-host-kuksa.md create mode 100644 templates/feature/agl-kvm-host-kuksa/included.dep diff --git a/recipes-platform/images/agl-cluster-demo-platform-flutter.bb b/recipes-platform/images/agl-cluster-demo-platform-flutter.bb index ff3816d9..5cf3daf9 100644 --- a/recipes-platform/images/agl-cluster-demo-platform-flutter.bb +++ b/recipes-platform/images/agl-cluster-demo-platform-flutter.bb @@ -3,19 +3,19 @@ SUMMARY = "Baseline Flutter Image for Release" LICENSE = "MIT" require recipes-platform/images/agl-image-compositor.bb +require agl-demo-features.inc IMAGE_FEATURES += "splash package-management ssh-server-openssh" -# Break out KUKSA.val packages, as demo unit configuration -# points at KUKSA.val server on the IVI board in full demo -# builds with the "agl-demo-preload" feature enabled. -KUKSA_DATABROKER_PACKAGES = " \ - packagegroup-agl-kuksa-val-databroker \ - ${@bb.utils.contains('DISTRO_FEATURES', 'agl-devel', 'packagegroup-agl-kuksa-val-databroker-devel' , '', d)} \ +# KUKSA.val databroker is not installed with "agl-demo-preload" +# feature enabled, since demo unit configuration points at the +# databroker on the IVI board in that setup. +IMAGE_FEATURES += " \ + kuksa-val-databroker-client \ + ${@bb.utils.contains("AGL_FEATURES", "agl-demo-preload", "", "kuksa-val-databroker", d)} \ " - -# generic +# Generic IMAGE_INSTALL += "\ ${@bb.utils.contains("AGL_FEATURES", "agl-demo-preload", "psplash-inverted-config", "", d)} \ ${@bb.utils.contains("AGL_FEATURES", "agl-demo-preload", "weston-ini-conf-landscape-inverted", "weston-ini-conf-landscape", d)} \ @@ -23,8 +23,6 @@ IMAGE_INSTALL += "\ packagegroup-agl-networking \ cluster-receiver \ \ - kuksa-certificates-agl-ca \ - ${@bb.utils.contains("AGL_FEATURES", "agl-demo-preload", "", "${KUKSA_DATABROKER_PACKAGES}", d)} \ simple-can-simulator \ " diff --git a/recipes-platform/images/agl-cluster-demo-platform.bb b/recipes-platform/images/agl-cluster-demo-platform.bb index a4992467..c427af66 100644 --- a/recipes-platform/images/agl-cluster-demo-platform.bb +++ b/recipes-platform/images/agl-cluster-demo-platform.bb @@ -3,6 +3,7 @@ DESCRIPTION = "AGL Cluster Demo Platform image currently contains a simple clust LICENSE = "MIT" require recipes-platform/images/agl-image-compositor.bb +require agl-demo-features.inc IMAGE_FEATURES += "splash package-management ssh-server-openssh" @@ -10,12 +11,12 @@ inherit features_check REQUIRED_DISTRO_FEATURES = "wayland" -# Break out KUKSA.val packages, as demo unit configuration -# points at KUKSA.val server on the IVI board in full demo -# builds with the "agl-demo-preload" feature enabled. -KUKSA_DATABROKER_PACKAGES = " \ - packagegroup-agl-kuksa-val-databroker \ - ${@bb.utils.contains('DISTRO_FEATURES', 'agl-devel', 'packagegroup-agl-kuksa-val-databroker-devel' , '', d)} \ +# KUKSA.val databroker is not installed with "agl-demo-preload" +# feature enabled, since demo unit configuration points at the +# databroker on the IVI board in that setup. +IMAGE_FEATURES += " \ + kuksa-val-databroker-client \ + ${@bb.utils.contains("AGL_FEATURES", "agl-demo-preload", "", "kuksa-val-databroker", d)} \ " # add packages for cluster demo platform (include demo apps) here @@ -24,6 +25,5 @@ IMAGE_INSTALL += " \ kuksa-certificates-agl-ca \ ${@bb.utils.contains("AGL_FEATURES", "agl-demo-preload", "cluster-demo-config", "", d)} \ ${@bb.utils.contains("AGL_FEATURES", "agl-demo-preload", "weston-ini-conf-landscape-inverted", "weston-ini-conf-landscape", d)} \ - ${@bb.utils.contains("AGL_FEATURES", "agl-demo-preload", "", "${KUKSA_DATABROKER_PACKAGES}", d)} \ ${@bb.utils.contains("AGL_FEATURES", "AGLCI", "qemu-set-display", "", d)} \ " diff --git a/recipes-platform/images/agl-demo-features.inc b/recipes-platform/images/agl-demo-features.inc index beaad0bb..b3374976 100644 --- a/recipes-platform/images/agl-demo-features.inc +++ b/recipes-platform/images/agl-demo-features.inc @@ -1,4 +1,5 @@ -FEATURE_PACKAGES_agl-demo-preload = "packagegroup-agl-demo-preload" -FEATURE_PACKAGES_agl-demo-cluster-support = "packagegroup-agl-demo-cluster-support" - -IMAGE_FEATURES += "${@bb.utils.filter("AGL_FEATURES", "agl-demo-preload agl-demo-cluster-support", d)}" +FEATURE_PACKAGES_kuksa-val-databroker-client = " \ + kuksa-certificates-agl-ca \ + ${@bb.utils.contains('DISTRO_FEATURES', 'agl-devel', 'packagegroup-agl-kuksa-val-databroker-devel' , '', d)} \ +" +FEATURE_PACKAGES_kuksa-val-databroker = "packagegroup-agl-kuksa-val-databroker" diff --git a/recipes-platform/images/agl-ivi-demo-base.bb b/recipes-platform/images/agl-ivi-demo-base.bb index da8d2eec..da4d2684 100644 --- a/recipes-platform/images/agl-ivi-demo-base.bb +++ b/recipes-platform/images/agl-ivi-demo-base.bb @@ -2,11 +2,10 @@ require agl-image-ivi.bb DESCRIPTION = "AGL demo base image" -require agl-demo-features.inc +require agl-ivi-demo-features.inc require agl-demo-container-guest-integration.inc AGL_DEVEL_INSTALL += "\ - packagegroup-agl-kuksa-val-databroker-devel \ simple-can-simulator \ unzip \ mpc \ @@ -18,6 +17,3 @@ IMAGE_INSTALL += " \ ${AGL_APPS_INSTALL} \ ${@bb.utils.contains("DISTRO_FEATURES", "agl-devel", "${AGL_DEVEL_INSTALL}" , "", d)} \ " - - - diff --git a/recipes-platform/images/agl-ivi-demo-features.inc b/recipes-platform/images/agl-ivi-demo-features.inc new file mode 100644 index 00000000..19a7792e --- /dev/null +++ b/recipes-platform/images/agl-ivi-demo-features.inc @@ -0,0 +1,11 @@ +require agl-demo-features.inc + +FEATURE_PACKAGES_agl-demo-preload = "packagegroup-agl-demo-preload" +FEATURE_PACKAGES_agl-demo-cluster-support = "packagegroup-agl-demo-cluster-support" + +IMAGE_FEATURES += "${@bb.utils.filter("AGL_FEATURES", "agl-demo-preload agl-demo-cluster-support", d)}" + +IMAGE_FEATURES += " \ + kuksa-val-databroker-client \ + ${@bb.utils.contains("AGL_FEATURES", "agl-kvm-host-kuksa", "", "kuksa-val-databroker", d)} \ +" diff --git a/recipes-platform/images/agl-kvm-demo-platform.bb b/recipes-platform/images/agl-kvm-demo-platform.bb index 4337ec02..338b3e6c 100644 --- a/recipes-platform/images/agl-kvm-demo-platform.bb +++ b/recipes-platform/images/agl-kvm-demo-platform.bb @@ -3,9 +3,16 @@ DESCRIPTION = "AGL KVM+QEMU Demo Platform image." LICENSE = "MIT" require recipes-platform/images/agl-image-compositor.bb +require agl-demo-features.inc IMAGE_FEATURES += "splash package-management ssh-server-openssh" +# If building with "agl-kvm-host-kuksa", the databroker and likely +# some clients run on the host +IMAGE_FEATURES += " \ + ${@bb.utils.contains("AGL_FEATURES", "agl-kvm-host-kuksa", "kuksa-val-databroker kuksa-val-databroker-client", "", d)} \ +" + # Add packages for KVM+QEMU demo platform here IMAGE_INSTALL += " \ packagegroup-agl-core-connectivity \ diff --git a/recipes-platform/packagegroups/packagegroup-agl-demo-platform-flutter.bb b/recipes-platform/packagegroups/packagegroup-agl-demo-platform-flutter.bb index 015cde97..3fba1b8c 100644 --- a/recipes-platform/packagegroups/packagegroup-agl-demo-platform-flutter.bb +++ b/recipes-platform/packagegroups/packagegroup-agl-demo-platform-flutter.bb @@ -11,7 +11,6 @@ PACKAGES = "\ " RDEPENDS:${PN} += "\ - packagegroup-agl-kuksa-val-databroker \ packagegroup-agl-demo \ " diff --git a/recipes-platform/packagegroups/packagegroup-agl-demo-platform.bb b/recipes-platform/packagegroups/packagegroup-agl-demo-platform.bb index f03229da..28f79cf2 100644 --- a/recipes-platform/packagegroups/packagegroup-agl-demo-platform.bb +++ b/recipes-platform/packagegroups/packagegroup-agl-demo-platform.bb @@ -11,7 +11,6 @@ PACKAGES = "\ " RDEPENDS:${PN} += "\ - packagegroup-agl-kuksa-val-databroker \ packagegroup-agl-demo \ " diff --git a/templates/feature/agl-kvm-host-kuksa/50_local.conf.inc b/templates/feature/agl-kvm-host-kuksa/50_local.conf.inc new file mode 100644 index 00000000..6259e41f --- /dev/null +++ b/templates/feature/agl-kvm-host-kuksa/50_local.conf.inc @@ -0,0 +1 @@ +AGL_FEATURES += "agl-kvm-host-kuksa" diff --git a/templates/feature/agl-kvm-host-kuksa/README_feature_agl-kvm-host-kuksa.md b/templates/feature/agl-kvm-host-kuksa/README_feature_agl-kvm-host-kuksa.md new file mode 100644 index 00000000..1b607aa3 --- /dev/null +++ b/templates/feature/agl-kvm-host-kuksa/README_feature_agl-kvm-host-kuksa.md @@ -0,0 +1,17 @@ +--- +description: Feature agl-kvm-host-kuksa +authors: Scott Murray +--- + +### Feature agl-kvm-host-kuksa + +* Enables support for running KUKSA.val databroker on host in KVM+QEMU demo images + +### Dependent features pulled by agl-kvm-host-kuksa + +The following features are pulled: + +* agl-kvm + +Note that enabling this feature results in a configuration where building images +other than agl-kvm-demo-platform will likely not give the desired results. diff --git a/templates/feature/agl-kvm-host-kuksa/included.dep b/templates/feature/agl-kvm-host-kuksa/included.dep new file mode 100644 index 00000000..b2b1014c --- /dev/null +++ b/templates/feature/agl-kvm-host-kuksa/included.dep @@ -0,0 +1 @@ +agl-kvm -- cgit 1.2.3-korg