From cedb6546434395d34866a12c00cd602244e7cd39 Mon Sep 17 00:00:00 2001 From: Joachim Wiberg Date: Tue, 22 Oct 2024 18:32:55 +0200 Subject: [PATCH] Add support for overriding the compatible string Signed-off-by: Joachim Wiberg --- Config.in | 11 +++++++++++ board/common/post-build.sh | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/Config.in b/Config.in index 62def073..1f369c4a 100644 --- a/Config.in +++ b/Config.in @@ -52,6 +52,17 @@ config INFIX_IMAGE_ID Mandatory. When INFIX_RELEASE is set, this string is appended to the IMAGE_ID with a '-' separator. +config INFIX_COMPATIBLE + string "Operating system compatible string" + default "${INFIX_IMAGE_ID}" + help + A lower-case string (no spaces or other characters outside of 0–9, + a–z, ".", "_" and "-"), used for image identification at upgrade. + E.g., the RAUC [system] compatible string. + + Mandatory. Defaults to $INFIX_IMAGE_ID, which in turn is composed + of $INFIX_ID-$BR2_ARCH. + config INFIX_TAGLINE string "Operating system tagline" default "Infix -- a Network Operating System" diff --git a/board/common/post-build.sh b/board/common/post-build.sh index a387bd50..9aedc585 100755 --- a/board/common/post-build.sh +++ b/board/common/post-build.sh @@ -62,7 +62,7 @@ else fi if [ -f "$TARGET_DIR/etc/rauc/system.conf" ]; then - sed -i "s/compatible=.*/compatible=$NAME/" "$TARGET_DIR/etc/rauc/system.conf" + sed -i "s/compatible=.*/compatible=$INFIX_COMPATIBLE/" "$TARGET_DIR/etc/rauc/system.conf" fi # This is a symlink to /usr/lib/os-release, so we remove this to keep