From f3a33b7dce86344b5e3a7ea0e75fe9faea08d1a7 Mon Sep 17 00:00:00 2001 From: Dimitri John Ledkov Date: Tue, 26 Sep 2023 18:54:39 +0100 Subject: [PATCH 1/2] Add support for X13s subarch Add mapping to use laptop-23.10 kernel. Ensure that enhanced-secureboot is only setup on amd64 arch. LP: #2037099 Signed-off-by: Dimitri John Ledkov --- live-build/auto/build | 3 +++ live-build/auto/config | 51 +++++++++++++++++++++++++----------------- 2 files changed, 33 insertions(+), 21 deletions(-) diff --git a/live-build/auto/build b/live-build/auto/build index bcae184d..71761537 100755 --- a/live-build/auto/build +++ b/live-build/auto/build @@ -642,6 +642,9 @@ for FLAVOUR in $LB_LINUX_FLAVOURS; do oem-*) FLAVOUR="oem" ;; + laptop-*) + FLAVOUR="laptop" + ;; image-intel) FLAVOUR="intel" ;; diff --git a/live-build/auto/config b/live-build/auto/config index 7896b6fd..593b921b 100755 --- a/live-build/auto/config +++ b/live-build/auto/config @@ -715,6 +715,10 @@ case $PROJECT in ;; *) touch config/universe-enabled + KERNEL_FLAVOURS='generic-hwe-22.04' + if [ "$SUBARCH" = "X13s" ]; then + KERNEL_FLAVOURS='laptop-23.10' + fi PASSES_TO_LAYERS="true" # the minimal layer, for minimal installs add_task minimal minimal standard ubuntu-desktop-minimal ubuntu-desktop-minimal-default-languages @@ -725,18 +729,37 @@ case $PROJECT in add_task minimal.standard.live ubuntu-live remove_package minimal.standard.live ubiquity-frontend-gtk add_snap minimal.standard.live ubuntu-desktop-installer/classic - add_package minimal.standard.live linux-generic-hwe-22.04 casper - # the enhanced-secureboot layer, contains all packages for the enhanced secureboot install - add_package minimal.enhanced-secureboot cryptsetup boot-managed-by-snapd - add_package minimal.standard.enhanced-secureboot cryptsetup boot-managed-by-snapd - + add_package minimal.standard.live linux-$KERNEL_FLAVOURS casper # language support seeded_langs="$(get_seeded_languages desktop)" echo "$seeded_langs" | tr ' ' ',' > config/seeded-languages derive_language_layers minimal desktop-minimal desktop-minimal-default-languages "$seeded_langs" - derive_language_layers minimal.enhanced-secureboot desktop-minimal desktop-default-languages "$seeded_langs" derive_language_layers minimal.standard desktop desktop-default-languages "$seeded_langs" - derive_language_layers minimal.standard.enhanced-secureboot desktop desktop-default-languages "$seeded_langs" + + # Enchanced secureboot stuff + case "$ARCH" in + amd64) + # the enhanced-secureboot layer, contains all packages for the enhanced secureboot install + add_package minimal.enhanced-secureboot cryptsetup boot-managed-by-snapd + add_package minimal.standard.enhanced-secureboot cryptsetup boot-managed-by-snapd + derive_language_layers minimal.enhanced-secureboot desktop-minimal desktop-default-languages "$seeded_langs" + derive_language_layers minimal.standard.enhanced-secureboot desktop desktop-default-languages "$seeded_langs" + cat <<-EOF > config/minimal.enhanced-secureboot.catalog-in.yaml + id: ubuntu-desktop-minimal + variations: + minimal-enhanced-secureboot: + path: minimal.enhanced-secureboot.squashfs + snapd_system_label: enhanced-secureboot-desktop + EOF + cat <<-EOF > config/minimal.standard.enhanced-secureboot.catalog-in.yaml + id: ubuntu-desktop + variations: + enhanced-secureboot: + path: minimal.standard.enhanced-secureboot.squashfs + snapd_system_label: enhanced-secureboot-desktop + EOF + ;; + esac # now let's create the neccessary catalog files cat <<-EOF > config/minimal.catalog-in.yaml @@ -752,13 +775,6 @@ case $PROJECT in minimal: path: minimal.squashfs EOF - cat <<-EOF > config/minimal.enhanced-secureboot.catalog-in.yaml - id: ubuntu-desktop-minimal - variations: - minimal-enhanced-secureboot: - path: minimal.enhanced-secureboot.squashfs - snapd_system_label: enhanced-secureboot-desktop - EOF cat <<-EOF > config/minimal.standard.catalog-in.yaml name: "Ubuntu Desktop" description: >- @@ -771,13 +787,6 @@ case $PROJECT in standard: path: minimal.standard.squashfs EOF - cat <<-EOF > config/minimal.standard.enhanced-secureboot.catalog-in.yaml - id: ubuntu-desktop - variations: - enhanced-secureboot: - path: minimal.standard.enhanced-secureboot.squashfs - snapd_system_label: enhanced-secureboot-desktop - EOF /usr/share/livecd-rootfs/checkout-translations-branch \ https://git.launchpad.net/subiquity po config/catalog-translations ;; From f1ab0f33c82fbd32349074688134ed97880fb577 Mon Sep 17 00:00:00 2001 From: Dimitri John Ledkov Date: Wed, 27 Sep 2023 00:02:46 +0100 Subject: [PATCH 2/2] lowercase Gbp-Dch: ignore --- live-build/auto/config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/live-build/auto/config b/live-build/auto/config index 593b921b..dac739e6 100755 --- a/live-build/auto/config +++ b/live-build/auto/config @@ -716,7 +716,7 @@ case $PROJECT in *) touch config/universe-enabled KERNEL_FLAVOURS='generic-hwe-22.04' - if [ "$SUBARCH" = "X13s" ]; then + if [ "$SUBARCH" = "x13s" ]; then KERNEL_FLAVOURS='laptop-23.10' fi PASSES_TO_LAYERS="true"