4 ms·
I remember trying to automate non-distribution builds of a functional GNU/Linux operating system and trying to not read Linux from Scratch but just official ker
by andrewmcwatters 2y ago
I remember trying to automate non-distribution builds of a functional GNU/Linux operating system and trying to not read Linux from Scratch but just official kernel.org documentation.[1]
Unfortunately, the state of Linux documentation is so poor, you can't do it. You need to reference a number of third-party articles that kernel.org itself sometimes links you to.
I believe kernel.org might also mention Linux from Scratch, but LFS does a very poor job of explaining why you need particular dependencies straight out of initramfs.
You need a functional shell, and you need to get your installation on to an actual drive. Neither of those things are explained in sufficient detail with the current documentation available today.
LFS at best says "throw in these ingredients," and leaves you with no other information. You can probably read man pages and piece this stuff together, but it requires that you, at the very least, hardcode where to install files with fsck/mount/cp, I think.
Edit: LFS also does a really poor job of explaining why it chooses its "Basic System Software," much of which isn't actually required for a common GNU/Linux system.
[1]: https://github.com/andrewmcwatters/linux-workflow https://github.com/andrewmcwatters/linux-workflow
- machinestops 2y ago> why you need particular dependencies straight out of initramfs. It came as a shock to me to learn that initramfs is mostly optional. It can be skipped, and you can boot straight into userland.
- andrewmcwatters 2y agoYes, but if I understand correctly, you’d need to configure for this specifically. I think standard configurations and installations use them.
- machinestops 2y agoYes, it requires specific configuration. The reason most distributions of Linux use them is it allows you to dynamically discover and load kernel modules at boot time, and provide a fallback for if mounting the disk fails.
- rcxdude 2y agoIt doesn't really need specific configuration. Most linux kernels will boot if not given an initramfs and just a root=<whatever> command line. The main thing is whether enough kernel modules are compiled in to find and read the disk and filesystem.