3
26
Fork
You've already forked mere
1

Infer package architecture from ELF metadata #22

Closed
opened 2026年03月25日 06:01:11 +01:00 by jhuntwork · 0 comments

The build system already scans every file in a split package for ELF metadata (for dependency and provision detection). This same
data can determine the package's architecture automatically rather than inheriting it from the parent recipe's archs field.

The rule:

  • All ELF files share the same architecture → package arch is that architecture
  • No ELF files present → package arch is any
  • Mixed ELF architectures → build error

This would allow arch-independent split packages (like ca-certs, which contains only certificate files) to be correctly tagged as
any without any recipe changes. An any-arch package built once could be shared across all architectures in the repo, avoiding
redundant builds.

The archs field in the recipe continues to serve its current purpose: declaring which architectures the recipe is intended to be
built on. The package-level arch becomes an output of the build, not an input.

The build system already scans every file in a split package for ELF metadata (for dependency and provision detection). This same data can determine the package's architecture automatically rather than inheriting it from the parent recipe's archs field. The rule: - All ELF files share the same architecture → package arch is that architecture - No ELF files present → package arch is any - Mixed ELF architectures → build error This would allow arch-independent split packages (like ca-certs, which contains only certificate files) to be correctly tagged as any without any recipe changes. An any-arch package built once could be shared across all architectures in the repo, avoiding redundant builds. The archs field in the recipe continues to serve its current purpose: declaring which architectures the recipe is intended to be built on. The package-level arch becomes an output of the build, not an input.
Sign in to join this conversation.
No Branch/Tag specified
main
skip-relocatables-in-arch-inference
convert
v0.14.0
v0.13.2
v0.13.1
v0.13.0
v0.12.2
v0.12.1
v0.12.0
v0.11.1
v0.11.0
v0.10.4
v0.10.3
v0.10.2
v0.10.1
v0.10.0
v0.9.7
v0.9.5
v0.9.4
v0.9.2
v0.9.0
v0.8.0
v0.7.2
v0.7.1
v0.7.0
v0.6.5
v0.6.4
v0.6.3
v0.6.2
Labels
Clear labels
No items
No labels
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
merelinux/mere#22
Reference in a new issue
merelinux/mere
No description provided.
Delete branch "%!s()"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?