nommu UML(x86_64): an appropriate way to create alternate packages of busybox/musl

Package Information

  • Package name: busybox, musl
  • Alpine architecture: x86_64

Summary

I'd like to ask you here for a suggestion to create new packages for x86_64 NOMMU architecture which we're recently proposing as a UML implementation.

The latest patch as of now is: https://lore.kernel.org/linux-um/cover.1731290567.git.thehajime@gmail.com/

This alternate UML is built with !CONFIG_MMU with x86_64 architecture. The UML instances need a rootfs which contains a proper file layout, but as !MMU, we need a libc (and other userspace programs) which aware of the kernel !MMU configuration (like mmap handling, vfork(2) instead of fork(2)).

Thus we wish to use busybox and musl with properly configured build options for NOMMU environment.

Here is my nasty attempt to create apk packages for them, but I'm not sure if this is a right way to do this kind of thing.

thehajime/aports!2 (diffs)

so my specific question would be:

  • do we need yet another architecture (e.g., x86_64-nommu), instead of adding two nommu packages to x86_64 arch ?
    • for the moment, I don't know other packages than busybox/musl which have nommu dependency (e.g., calling vfork(2) instead of fork(2)).
  • can we replace pre-installed busybox/musl with an alternate package ?
    • suppose the busybox package is already installed and users wish to install busybox-nommu. the above diff tries to do this but doesn't remove the original busybox package. I'd like to see a way how to handle this environment.
    • musl-nommu package (which I added) also attempts to do the same as busybox-nommu is trying to.

Any suggestions are very appreciated.