← Back to issue list

snapcraft cleanbuild doesn't work with cross-compile stage-packages

View original Launchpad issue

Metadata

Project
snapcraft (launchpad)
Number
#1788654
Type
issue
State
closed
Author
~anonymouse67
Labels
Created
Updated
Closed

Current evaluation

⚠️ This summary may be outdated — the issue content or evaluation prompts have changed since this evaluation was made.

Closed without resolution. Snapcraft cleanbuild fails during cross-compilation because it does not automatically configure multi-arch package support inside the container. No fix was implemented, and the report appears abandoned.

Suggested action:

No scores available.

Issue body

When cross-compiling a snap on (for example) amd64 to run on armhf, I have rules like this in the snapcraft.yaml: stage-packages: - on amd64 to armhf: - "sqlite3:armhf" - else: - "sqlite3" Because when running the snap on an armhf machine, obviously it needs the armhf version and not the amd64 version. Hence the "sqlite:armhf" syntax to specify using the armhf version of the package. However, snapcraft cleanbuild doesn't setup the container in a way that supports this as it fails with: Failed to fetch stage packages: Error downloading packages for part 'gg-sdk-deps': The package 'sqlite3:armhf' was not found. You may need to add support for this architecture with 'dpkg --add-architecture armhf'.. Which obviously I can't do inside the lxd container as it was launched/setup by snapcraft with something like `snapcraft cleanbuild --target-arch=armhf`. So I think the bug here is that specifying `--target-arch=SOME_OTHER_ARCH` and arguably some permutation of the `architectures` key setup inside snapcraft.yaml need to trigger snapcraft to do the necessary things inside the container to setup installing cross-architecture packages, i.e. the dpkg --add-architecture step suggested and also setup /etc/apt/sources.list.

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.6-35b-a3b Closed without resolution. Snapcraft cleanbuild fails during cross-compilation because it does not automatically configure multi-arch package support inside the container. No fix was implemented, and the report appears abandoned.
qwen/qwen3.6-35b-a3b snapcraft cleanbuild failed when using cross-compile stage-packages due to missing container architecture setup. The issue was closed without resolution, effectively abandoned.
qwen3.6-35b-a3b-mtp-q6 Abandoned due to inactivity. The issue reported that snapcraft cleanbuild fails during cross-compilation because the LXD container lacks multi-arch dpkg setup. No resolution was implemented.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#1817288 snapcraft cleanbuild produces incorrect architecture snap snapcraft (launchpad) closed Abandoned and closed without resolution. The legacy mode cleanbuild multi-arch naming bug remains unfixed due to lack of activity and deprecation of legacy mode.
79%
#1675516 can't cleanbuild snapcraft itself snapcraft (launchpad) closed Closed without resolution or comments, the report of a failed snapcraft cleanbuild due to missing build-packages was abandoned.
79%
#1570414 Snapcraft doesn't check if cross-compiling before trying to install necessary tools snapcraft (launchpad) closed Closed without resolution or comments, likely abandoned or superseded. Snapcraft failed to conditionally install cross-compilation tools, triggering armhf build errors.
77%
#1983009 Snapcraft 7.1.0 fails to find stage package when cross-compiling snapcraft (launchpad) closed Closed. Snapcraft 7.1.0 fails to find stage packages like bluez when cross-compiling from amd64 to arm64/armhf, breaking builds. Issue closed without a provided resolution or fix.
77%
#1570706 Snapcraft cleanbuild command doesn't work snapcraft (launchpad) closed Closed without resolution, likely abandoned or superseded. The cleanbuild command failed due to LXC hash format incompatibility and container stop errors.
75%
#1811208 snapcraft failed to build with cleanbuild on 18.04 snapcraft (launchpad) closed Closed without resolution. The report details a multipass cleanbuild failure on Ubuntu 18.04 due to a missing msr module error. No fix was implemented, and the discussion was redirected to the Snapcraft forum.
74%
#4142 snapcraft remote-build exits with return code 0 even when some snaps failed to build for a given arch snapcraft closed Closed without comments or resolution, indicating the request was abandoned. No official fix or merge details were provided.
74%
#1666735 snapcraft cleanbuild does not work with lxd installed via snap snapcraft (launchpad) closed Closed without resolution or merge. The report notes snapcraft cleanbuild fails to detect LXD installed via snap, suggesting checks via snap list or lxc list instead of apt cache. No fix was implemented or documented.
74%
#1800119 snapcraft cleanbuild snapcraft (launchpad) closed Closed without resolution. The report details a PermissionError during snapcraft cleanbuild caused by restricted access to the .aptitude directory. With zero comments and no fix applied, the issue was abandoned or marked stale.
74%
#1615060 snapcraft clean is incomplete snapcraft (launchpad) closed Reporting that snapcraft clean skips local .snap files was closed without comments or resolution, indicating the report was abandoned or left unresolved.
74%