← Back to issue list

kernel plugin: pick the correct kernel-image-target per architecture

View original Launchpad issue

Metadata

Project
snapcraft (launchpad)
Number
#1604801
Type
issue
State
closed
Author
~p-pisati
Labels
Created
Updated
Closed

Current evaluation

Closed without resolution or implementation. The request for dynamic architecture-based kernel-image-target selection in the snapcraft kernel plugin was abandoned.

Suggested action:

No scores available.

Issue body

Different kernel architecture needs different kernel-image-target: ARCH=arm: ... Architecture specific targets (arm): * zImage - Compressed kernel image (arch/arm/boot/zImage) Image - Uncompressed kernel image (arch/arm/boot/Image) ... ARCH=arm64: ... Architecture specific targets (arm64): * Image.gz - Compressed kernel image (arch/arm64/boot/Image.gz) Image - Uncompressed kernel image (arch/arm64/boot/Image) ... ARCH=powerpc: ... Architecture specific targets (powerpc): * zImage - Build default images selected by kernel config zImage.* - Compressed kernel image (arch/powerpc/boot/zImage.*) ... etcetc At the moment snapcraft.yaml::kernel-image-target could be only a string, and to support compiling the kernel for different architectures from the same snapcraft.yaml, we need a dynamic mechanism - either an internal mapping in snapcraft: case ARCH: amd64) target=bzImage arm) target=zImage arm64) target=Image ... etcetc ... esac or a callback mechanism (as we exploited in kdefconfig to support multiple archs/configs): ... kdefconfig: ['--makefile=debian/snapcraft.mk', 'branch=master','flavour=generic', 'config'] ... $ cat debian/snapcraft.mk ifeq ($(ARCH),) arch := $(shell uname -m | sed -e s/i.86/i386/ -e s/x86_64/amd64/ \ -e s/arm.*/armhf/ -e s/s390/s390x/ -e s/ppc.*/powerpc/ \ -e s/aarch64.*/arm64/ ) else ifeq ($(ARCH),arm) arch := armhf else arch := $(ARCH) endif config: cat debian.$(branch)/config/config.common.ubuntu debian.$(branch)/config/$(arch)/config.common.$(arch) debian.$(branch)/config/$(arch)/config.flavour.$(flavour) >.config The entire snapcraft.yaml that we would like to ship with the generic Ubuntu kernel, is attached below.

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.6-35b-a3b Closed without resolution or implementation. The request for dynamic architecture-based kernel-image-target selection in the snapcraft kernel plugin was abandoned.
qwen/qwen3.6-35b-a3b Closed without resolution. The feature request for dynamic architecture-based kernel-image-target selection in the snapcraft kernel plugin was abandoned or superseded by newer plugin versions, as shown by zero comments and prolonged inactivity.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#689 kernel plugin: kernel targets depending on debarch snapcraft merged Merged. Updates the kernel plugin to select image targets based on debarch, enabling multi-architecture kernel builds from a single snapcraft.yaml. Validated for amd64, arm64, and armhf.
73%
#1149 kernel plugin: if kernel's target == NULL, use per-arch default target snapcraft closed Superseded by pull request #1209, which implements the per-arch default target logic, resolves related issues, and includes required unit tests.
72%
#1665659 kernel plugin: if kernel's target == NULL, use per-arch default target snapcraft (launchpad) closed Fixed by implementing automatic fallback to per-architecture default kernel targets when unspecified. The plugin now selects bzImage for i386/amd64, zImage for arm, and Image.gz for arm64.
71%
#1567564 kernel plugin should use initrd from /boot in the os snap, not from /usr/lib snapcraft (launchpad) closed Closed without resolution. The proposal to update the snapcraft kernel plugin to source initrd from /boot instead of /usr/lib was abandoned or superseded by later changes, leaving the legacy duplication in place.
71%
#1136 kernel plugin: if kernel's target == NULL, use per-arch default target snapcraft closed Abandoned after reviewer requested signing the CLA, using a canonical email, and filing a bug report first. No merge occurred.
70%