On September 4, 2021 11:04:02 AM GMT+02:00, Richard Purdie <richard.pur...@linuxfoundation.org> wrote: >On Sat, 2021-09-04 at 09:18 +0200, Jan Nieuwenhuizen wrote: >> John Gilmore writes: >> >> Hi! >> >> > Does the GNU Mes bootstrap-reducing team have a plan to replace Grub and >> > the Linux kernel and init (and perhaps a BIOS?) with something tiny that >> > runs on bare metal and implements a file system, the mount command, and >> > processes? Many realtime OS's are much smaller than Linux or BSD and >> > yet have those capabilities. eCos might be a great start, and is free, >> > highly portable, and includes a POSIX layer (and TCP/IP for debugging), >> > though it currently lacks fork/exec/wait. The original V7 UNIX kernel >> > would work, if process sizes and filename sizes are patched, and a few >> > device drivers written for modern disk and CDROM drives. Such a >> > bootstrap kernel would enable the Scheme bootstrap programs to run well >> > enough to build gcc, then use gcc to build the Linux kernel, then boot >> > it, and continue building. >> >> This is a valid concern and these are nice pointers. In my FOSDEM21 >> talk (https://fosdem.org/2021/schedule/event/gnumes/) I mention the fact >> that we still have work to do here. However, there are no concrete >> plans that I know of just yet, at least not as a basis for real world >> bootstrap of a full GNU/Linux system. >> >> GNU Mes is being deployed in the GNU Guix bootstrap and a new effort has >> just started to port the reduced binary seed bootstrap to NixOS. We are >> still working to integrate the "full source bootstrap" into GNU Guix. >> The plans after that are to replace critical usage of GNU Guile with GNU >> Mes. There is also work on ARM, RISC-V and the Hurd going on. This >> probably means, e.g., backporting RISC-V support to gcc-4.6, in short: >> lots of work todo here. >> >> The fact remains that the team is still quite small and GNU Guix and >> even NixOS I think are niche distributions. It would be amazing to get >> a GNU Mes based reduced binary seed bootstrap into Debian. That could >> increase our exposure a lot and may free up some development time for >> doing more wild stuff. Alas, except for chats some of us had I do not >> know of concrete plans here either. > >You may want to consider Yocto Project in that area. The strength YP has is >that >it is a cross compiled and customised Linux (and other RTOS) built reproducibly >from source with tightly controlled host dependencies. It can "self host", i.e. >build itself reproducibily from within its own tools too. > >As such, there would be a very specific target that would need to be built to >achieve bootstrap and the system could take it from there. There are also >probably ways to minimise the bootstrap needed, that just hasn't been too much >of a focus for the project. > >Cheers, > >Richard >
Hi! I'm not deeply involved in the bootstrappable project but I believe the required bootstrap seed in guix is already a lot smaller than the yocto projects dependencies (but maybe a few steps are also still missing here). I wonder if reproducibly rebuilding the bootstrap seed is possible/easy with guix though? I remember us talking about the Linux and bootloader dependencies at the end of the Marrakesh retreat and (due to recent exposure) I was thinking about ways to use uboot as another stage to bootstrapping a full Linux system. I'm unsure how good a choice this actually is for this, but I've some experience hacking on it and (at least on arm platforms) it seems kind of a natural next lower level. On the plus side it has fairly good hardware support already, already has a rudimentary inbuilt shell and is easily extensible. There's not really any resemblance of a POSIX api though I think. I wonder what some goalpost here would look like. Compiling some (old) version of the Linux kernel from uboot? I'll need to read up on the current bootstrap path again. Marcus