From d8b24aaae603cae1c61016aac7e028376ce80788 Mon Sep 17 00:00:00 2001 From: Brian Murray Date: Wed, 23 Jun 2021 09:12:44 -0700 Subject: [PATCH 1/3] add iotg as a subarch of amd64 w/ image-intel kernel --- live-build/auto/config | 48 ++++++++++++++++++++++++++++++------------ 1 file changed, 34 insertions(+), 14 deletions(-) diff --git a/live-build/auto/config b/live-build/auto/config index d4c535ef..46761a83 100755 --- a/live-build/auto/config +++ b/live-build/auto/config @@ -299,7 +299,7 @@ if [ -z "${IMAGEFORMAT:-}" ]; then case $PROJECT:${SUBPROJECT:-} in ubuntu-cpc:*|ubuntu:desktop-preinstalled) case $SUBARCH in - raspi) + raspi|iotg) IMAGEFORMAT=ubuntu-image ;; *) @@ -632,20 +632,32 @@ case $PROJECT in desktop-preinstalled) add_task install minimal standard ubuntu-desktop - if [ "$SUBARCH" = "raspi" ]; then - add_task install ubuntu-desktop-raspi - # XXX: Are those actually needed? I see we use those for ubuntu-cpc, which is the project - # for existing raspi preinstalled images - # XXX: I would prefer to use --hdd-label=desktop-rootfs like 040-hyperv-desktop-images.binary - OPTS="${OPTS:+$OPTS }--initramfs=none" - OPTS="${OPTS:+$OPTS }--system=normal" - OPTS="${OPTS:+$OPTS }--hdd-label=cloudimg-rootfs" - OPTS="${OPTS:+$OPTS }--ext-resize-blocks=536870912 --ext-block-size=4096" - OPTS="${OPTS:+$OPTS }--ext-fudge-factor=15" - fi - ## Otherwise HYPERV image options.... *crickets* see the hyperv hook + case $SUBARCH in + raspi) + add_task install ubuntu-desktop-raspi + # XXX: Are those actually needed? I see we use those for ubuntu-cpc, which is the project + # for existing raspi preinstalled images + # XXX: I would prefer to use --hdd-label=desktop-rootfs like 040-hyperv-desktop-images.binary + OPTS="${OPTS:+$OPTS }--initramfs=none" + OPTS="${OPTS:+$OPTS }--system=normal" + OPTS="${OPTS:+$OPTS }--hdd-label=cloudimg-rootfs" + OPTS="${OPTS:+$OPTS }--ext-resize-blocks=536870912 --ext-block-size=4096" + OPTS="${OPTS:+$OPTS }--ext-fudge-factor=15" + ;; + iotg) + KERNEL_FLAVOURS='image-intel' + COMPONENTS='main restricted universe' + OPTS="${OPTS:+$OPTS }--initramfs=none" + OPTS="${OPTS:+$OPTS }--system=normal" + OPTS="${OPTS:+$OPTS }--hdd-label=cloudimg-rootfs" + OPTS="${OPTS:+$OPTS }--ext-resize-blocks=536870912 --ext-block-size=4096" + OPTS="${OPTS:+$OPTS }--ext-fudge-factor=15" + ;; + *) + ## Otherwise HYPERV image options.... *crickets* see the hyperv hook + ;; + esac ;; - *) LIVE_TASK='ubuntu-live' add_task install minimal standard ubuntu-desktop @@ -960,6 +972,14 @@ case $PROJECT in _) add_chroot_hook remove-python-py ;; + amd64) + KERNEL_FLAVOURS="${SUBARCH:-$KERNEL_FLAVOURS}" + case $SUBARCH in + iotg) + COMPONENTS='main restricted universe' + KERNEL_FLAVOURS='image-intel' + esac + ;; esac lb config noauto \ From 066422894bca11c204ef016617e13fe9c9f4f3b0 Mon Sep 17 00:00:00 2001 From: Brian Murray Date: Wed, 23 Jun 2021 11:09:19 -0700 Subject: [PATCH 2/3] also support building an ubuntu-cpc amd64 iotg image --- live-build/auto/config | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/live-build/auto/config b/live-build/auto/config index 46761a83..4aede1e7 100755 --- a/live-build/auto/config +++ b/live-build/auto/config @@ -819,6 +819,10 @@ case $PROJECT in amd64) if [ "${SUBARCH:-}" = "generic" ]; then KERNEL_FLAVOURS=generic + elif [ "${SUBARCH:-}" = "iotg" ]; then + KERNEL_FLAVOURS=image-intel + COMPONENTS='main restricted universe' + OPTS="${OPTS:+$OPTS }--initramfs=none" fi ;; riscv64*) From ad3e755974c1d4e9ba7a4258e00f15c70501da8f Mon Sep 17 00:00:00 2001 From: Brian Murray Date: Wed, 30 Jun 2021 15:43:47 -0700 Subject: [PATCH 3/3] rename iotg to intel-iotg so its slightly more descriptive --- live-build/auto/config | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/live-build/auto/config b/live-build/auto/config index 4aede1e7..196160d2 100755 --- a/live-build/auto/config +++ b/live-build/auto/config @@ -299,7 +299,7 @@ if [ -z "${IMAGEFORMAT:-}" ]; then case $PROJECT:${SUBPROJECT:-} in ubuntu-cpc:*|ubuntu:desktop-preinstalled) case $SUBARCH in - raspi|iotg) + raspi|intel-iotg) IMAGEFORMAT=ubuntu-image ;; *) @@ -644,7 +644,7 @@ case $PROJECT in OPTS="${OPTS:+$OPTS }--ext-resize-blocks=536870912 --ext-block-size=4096" OPTS="${OPTS:+$OPTS }--ext-fudge-factor=15" ;; - iotg) + intel-iotg) KERNEL_FLAVOURS='image-intel' COMPONENTS='main restricted universe' OPTS="${OPTS:+$OPTS }--initramfs=none" @@ -819,7 +819,7 @@ case $PROJECT in amd64) if [ "${SUBARCH:-}" = "generic" ]; then KERNEL_FLAVOURS=generic - elif [ "${SUBARCH:-}" = "iotg" ]; then + elif [ "${SUBARCH:-}" = "intel-iotg" ]; then KERNEL_FLAVOURS=image-intel COMPONENTS='main restricted universe' OPTS="${OPTS:+$OPTS }--initramfs=none" @@ -979,7 +979,7 @@ case $PROJECT in amd64) KERNEL_FLAVOURS="${SUBARCH:-$KERNEL_FLAVOURS}" case $SUBARCH in - iotg) + intel-iotg) COMPONENTS='main restricted universe' KERNEL_FLAVOURS='image-intel' esac