Skip to content

rpm: Install packages for the image's architecture - #304

Merged
martinpitt merged 1 commit into
amutable-systems:mainfrom
daandemeyer:push-ptwmoxpzzmxu
Oct 12, 2026
Merged

martinpitt merged 1 commit into
amutable-systems:mainfrom
daandemeyer:push-ptwmoxpzzmxu

Conversation

@daandemeyer

Copy link
Copy Markdown
Member

The rpm installer leaves libdnf5 to detect the architecture of the machine
the box runs on, so the box of an x86_64 host cannot install an arm64 image:

package filesystem-3.18-59.fc45.aarch64 from @commandline does not have a compatible architecture

Set libdnf5's arch and basearch to the image's architecture, which the
install spec already contains, and turn off rpm's architecture check the way
dnf5's --forcearch does. The pacman and deb installers already install for
the image's architecture.

Signed-off-by: Daan De Meyer daan@amutable.com

The rpm installer leaves libdnf5 to detect the architecture of the machine
the box runs on, so the box of an x86_64 host cannot install an arm64 image:

    package filesystem-3.18-59.fc45.aarch64 from @commandline does not have a compatible architecture

Set libdnf5's arch and basearch to the image's architecture, which the
install spec already contains, and turn off rpm's architecture check the way
dnf5's --forcearch does. The pacman and deb installers already install for
the image's architecture.

Signed-off-by: Daan De Meyer <daan@amutable.com>

@martinpitt martinpitt left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@martinpitt
martinpitt merged commit a8b86f6 into amutable-systems:main Oct 12, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants