From c0998da8e761e33b6f05d60a0703af66faea9886 Mon Sep 17 00:00:00 2001 From: Jan Kiszka Date: Tue, 26 Sep 2023 09:55:36 +0200 Subject: [PATCH 1/2] Make Node-RED packages optional Allows to shrink the example image build time specifically. Signed-off-by: Jan Kiszka --- Kconfig | 12 +++++++++++- kas/opt/no-node-red.yml | 16 ++++++++++++++++ recipes-core/images/iot2050-image-example.bb | 11 ++++++++--- 3 files changed, 35 insertions(+), 4 deletions(-) create mode 100644 kas/opt/no-node-red.yml diff --git a/Kconfig b/Kconfig index bd862860c..ee673e2f5 100644 --- a/Kconfig +++ b/Kconfig @@ -75,9 +75,19 @@ config KAS_INCLUDE_RT default "kas/opt/preempt-rt.yml" depends on PREEMPT_RT +config NODE_RED + bool "Node-RED support" + default y + help + Building image with Node-RED support. + +config KAS_INCLUDE_NO_NODE_RED + string + default "kas/opt/no-node-red.yml" + depends on !NODE_RED + config DOCKER bool "Docker support" - default n help Building image with docker support. diff --git a/kas/opt/no-node-red.yml b/kas/opt/no-node-red.yml new file mode 100644 index 000000000..7626ac847 --- /dev/null +++ b/kas/opt/no-node-red.yml @@ -0,0 +1,16 @@ +# +# Copyright (c) Siemens AG, 2023 +# +# Authors: +# Jan Kiszka +# +# This file is subject to the terms and conditions of the MIT License. See +# COPYING.MIT file in the top-level directory. +# + +header: + version: 14 + +local_conf_header: + no-node-red: | + IOT2050_NODE_RED_SUPPORT = "0" diff --git a/recipes-core/images/iot2050-image-example.bb b/recipes-core/images/iot2050-image-example.bb index fa306724e..d3d9f28ef 100644 --- a/recipes-core/images/iot2050-image-example.bb +++ b/recipes-core/images/iot2050-image-example.bb @@ -37,11 +37,16 @@ IMAGE_INSTALL += " \ iot2050-firmware-update \ tcf-agent \ mraa \ - node-red \ - node-red-gpio \ - node-red-preinstalled-nodes \ ${@ 'board-conf-tools' if d.getVar('QEMU_IMAGE') != '1' else '' } \ libteec1 \ optee-client-dev \ tee-supplicant \ " + +IOT2050_NOD_RED_SUPPORT ?= "1" + +IMAGE_INSTALL += "${@ ' \ + node-red \ + node-red-gpio \ + node-red-preinstalled-nodes \ + ' if d.getVar('IOT2050_NOD_RED_SUPPORT') == '1' else ''}" From 249e9e47210eda7f5c2945e1cb6089b950d49db7 Mon Sep 17 00:00:00 2001 From: Jan Kiszka Date: Tue, 26 Sep 2023 09:56:17 +0200 Subject: [PATCH 2/2] Update all kas headers to version 14 Only the top-level files are evaluated by kas so far, but this is still more consistent. Signed-off-by: Jan Kiszka --- kas-iot2050-boot-pg1.yml | 2 +- kas-iot2050-boot-pg2.yml | 2 +- kas-iot2050-example.yml | 2 +- kas-iot2050-qemu.yml | 2 +- kas-iot2050-swupdate.yml | 2 +- kas/opt/debian-mirror.yml | 2 +- kas/opt/docker.yml | 2 +- kas/opt/lxde.yml | 2 +- kas/opt/otpcmd/key-provision-3keys.yml | 2 +- kas/opt/otpcmd/key-provision-enabling-only.yml | 2 +- kas/opt/otpcmd/key-provision-keys-only.yml | 2 +- kas/opt/otpcmd/key-provision.yml | 2 +- kas/opt/otpcmd/key-switch-2to3.yml | 2 +- kas/opt/otpcmd/key-switch.yml | 2 +- kas/opt/otpcmd/otp.yml | 2 +- kas/opt/package-lock.yml | 2 +- kas/opt/preempt-rt.yml | 2 +- kas/opt/rpmb-setup.yml | 2 +- kas/opt/sdk.yml | 2 +- kas/opt/secure-boot.yml | 2 +- kas/opt/upstream.yml | 2 +- 21 files changed, 21 insertions(+), 21 deletions(-) diff --git a/kas-iot2050-boot-pg1.yml b/kas-iot2050-boot-pg1.yml index dd0775140..980275c7c 100644 --- a/kas-iot2050-boot-pg1.yml +++ b/kas-iot2050-boot-pg1.yml @@ -10,7 +10,7 @@ # header: - version: 10 + version: 14 includes: - kas/iot2050.yml diff --git a/kas-iot2050-boot-pg2.yml b/kas-iot2050-boot-pg2.yml index d935759d9..2d3df3bfc 100644 --- a/kas-iot2050-boot-pg2.yml +++ b/kas-iot2050-boot-pg2.yml @@ -10,7 +10,7 @@ # header: - version: 10 + version: 14 includes: - kas/iot2050.yml diff --git a/kas-iot2050-example.yml b/kas-iot2050-example.yml index 14434b4fa..7ef69137d 100644 --- a/kas-iot2050-example.yml +++ b/kas-iot2050-example.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 includes: - kas/iot2050.yml diff --git a/kas-iot2050-qemu.yml b/kas-iot2050-qemu.yml index 9007aaf55..4b6ed9220 100644 --- a/kas-iot2050-qemu.yml +++ b/kas-iot2050-qemu.yml @@ -6,7 +6,7 @@ # header: - version: 10 + version: 14 machine: iot2050-qemu diff --git a/kas-iot2050-swupdate.yml b/kas-iot2050-swupdate.yml index b965cedff..91f46c9b3 100644 --- a/kas-iot2050-swupdate.yml +++ b/kas-iot2050-swupdate.yml @@ -6,7 +6,7 @@ # header: - version: 10 + version: 14 includes: - kas-iot2050-example.yml diff --git a/kas/opt/debian-mirror.yml b/kas/opt/debian-mirror.yml index dc2a05991..a032e22a9 100644 --- a/kas/opt/debian-mirror.yml +++ b/kas/opt/debian-mirror.yml @@ -10,7 +10,7 @@ # header: - version: 10 + version: 14 local_conf_header: debian-mirror: | diff --git a/kas/opt/docker.yml b/kas/opt/docker.yml index 6579d5ace..5bc112c00 100644 --- a/kas/opt/docker.yml +++ b/kas/opt/docker.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 local_conf_header: docker-support: | diff --git a/kas/opt/lxde.yml b/kas/opt/lxde.yml index cf0e35866..e0f4ee3ae 100644 --- a/kas/opt/lxde.yml +++ b/kas/opt/lxde.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 local_conf_header: add-lxde: | diff --git a/kas/opt/otpcmd/key-provision-3keys.yml b/kas/opt/otpcmd/key-provision-3keys.yml index 63faa46f7..8bed3dbf3 100644 --- a/kas/opt/otpcmd/key-provision-3keys.yml +++ b/kas/opt/otpcmd/key-provision-3keys.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 includes: - otp.yml diff --git a/kas/opt/otpcmd/key-provision-enabling-only.yml b/kas/opt/otpcmd/key-provision-enabling-only.yml index f1bd77def..b0afc966f 100644 --- a/kas/opt/otpcmd/key-provision-enabling-only.yml +++ b/kas/opt/otpcmd/key-provision-enabling-only.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 includes: - otp.yml diff --git a/kas/opt/otpcmd/key-provision-keys-only.yml b/kas/opt/otpcmd/key-provision-keys-only.yml index 88e0a9ef6..54aefe994 100644 --- a/kas/opt/otpcmd/key-provision-keys-only.yml +++ b/kas/opt/otpcmd/key-provision-keys-only.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 includes: - otp.yml diff --git a/kas/opt/otpcmd/key-provision.yml b/kas/opt/otpcmd/key-provision.yml index 16d772d9d..341c19f05 100644 --- a/kas/opt/otpcmd/key-provision.yml +++ b/kas/opt/otpcmd/key-provision.yml @@ -9,6 +9,6 @@ # header: - version: 10 + version: 14 includes: - otp.yml diff --git a/kas/opt/otpcmd/key-switch-2to3.yml b/kas/opt/otpcmd/key-switch-2to3.yml index 522aa48ca..5d2508fda 100644 --- a/kas/opt/otpcmd/key-switch-2to3.yml +++ b/kas/opt/otpcmd/key-switch-2to3.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 includes: - key-switch.yml diff --git a/kas/opt/otpcmd/key-switch.yml b/kas/opt/otpcmd/key-switch.yml index 64fee6c0c..d55c09724 100644 --- a/kas/opt/otpcmd/key-switch.yml +++ b/kas/opt/otpcmd/key-switch.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 includes: - otp.yml diff --git a/kas/opt/otpcmd/otp.yml b/kas/opt/otpcmd/otp.yml index 092640bc9..65fcfb22c 100644 --- a/kas/opt/otpcmd/otp.yml +++ b/kas/opt/otpcmd/otp.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 local_conf_header: otpcmd_override: | diff --git a/kas/opt/package-lock.yml b/kas/opt/package-lock.yml index 631121d3f..3c1d43c81 100644 --- a/kas/opt/package-lock.yml +++ b/kas/opt/package-lock.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 local_conf_header: package-lock: | diff --git a/kas/opt/preempt-rt.yml b/kas/opt/preempt-rt.yml index 25fc1b3fb..a92fd725d 100644 --- a/kas/opt/preempt-rt.yml +++ b/kas/opt/preempt-rt.yml @@ -6,7 +6,7 @@ # header: - version: 10 + version: 14 local_conf_header: preempt-rt: | diff --git a/kas/opt/rpmb-setup.yml b/kas/opt/rpmb-setup.yml index f888e3734..6b991cc4d 100644 --- a/kas/opt/rpmb-setup.yml +++ b/kas/opt/rpmb-setup.yml @@ -9,7 +9,7 @@ # header: - version: 10 + version: 14 local_conf_header: optee-os-iot2050_override: | diff --git a/kas/opt/sdk.yml b/kas/opt/sdk.yml index 519a9669c..2074226ab 100644 --- a/kas/opt/sdk.yml +++ b/kas/opt/sdk.yml @@ -6,6 +6,6 @@ # header: - version: 10 + version: 14 task: populate_sdk diff --git a/kas/opt/secure-boot.yml b/kas/opt/secure-boot.yml index 9e80dbe6b..d3327ffe7 100644 --- a/kas/opt/secure-boot.yml +++ b/kas/opt/secure-boot.yml @@ -6,7 +6,7 @@ # header: - version: 10 + version: 14 local_conf_header: secureboot_override: | diff --git a/kas/opt/upstream.yml b/kas/opt/upstream.yml index 074a4e90c..f56d7b3d7 100644 --- a/kas/opt/upstream.yml +++ b/kas/opt/upstream.yml @@ -6,7 +6,7 @@ # header: - version: 10 + version: 14 local_conf_header: upstream-versions: |