Closed fosslinux closed 8 months ago
HELP NEEDED - kernel bootstrap mode is broken ?!. Consistently segfaults just into fiwix. statically compiled bash binary segfaults. memory mapping issue ?? not sure what's going on here
In order to make this a bit easier, I think some parts of this PR can be splitted to their own PRs, reducing the amount of changes introduced by this PR and hopefully making it easier to pinpoint the source of the problem.
However, that would require rebasing this PR and conflicts are expected, but I can help with that.
I'm in the process of cleaning up the commit history for this PR, and fixing little bits and pieces.
I think I've split out everything from this PR that can be logically split out.
We have as dependencies for this PR;
Only large remaining error is fiwix -> linux not working. This is in the process of being fixed.
I'm fairly happy with this now. CI is obviously broken but I would still like to limit the scope of this PR.
This is still fairly rough around the edges; but all of the core functionality I wanted has been implemented.
This does not create any meaningful change to the bootstrap path used. Rather this is a fairly significant refactor of live-bootstrap to make it easier to reason about, more sustainable to make changes to in the future, and fix a number of long-standing issues.
run.kaem
,run.sh
,run-after-fiwix.sh
,run2.sh
), which didn't actually convey any meaning. There were so many varied cases depending on chroot/kernel bootstrap/etc. I believe that this is the biggest barrier to understanding the project. Technical details;/init
's are generated files nowsteps/manifest
. The M2-Planet programseed/script-generator.c
transforms the manifest dynamically into a series of kaem/shell scripts that invoke one another. The syntax of the manifest is detailed in the manifest. All associated scripts required to get to the point where the manifest can be used (which is almost immediately after stage0-posix), live inseed/
./external
in the rootfs./external
is mounted from a disk, everything else comes from an initrd. Onceutil-linux
is built, everything transfers into that disk, moving off the initrd./steps/env
replaces.env
./steps/env
propagates throughout the entire filesystem./usr/lib/mes
and/usr/include/mes
, and no/usr/include/musl
.TODOS