Part IV. The chroot and kpkg
The bootstrap leaves a small working system in build/fs, the target tree. From the 20_selfhost phase on, every package is built inside that tree, entered as a chroot, by KDOS’s package manager kpkg. Each package comes from a recipe under ports/, or under src/ for KDOS’s own programs.
This part is for anyone who builds KDOS or wants to read a package page with understanding. It has two chapters:
- Entering the chroot shows how the build enters the tree: what it mounts and which environment variables it lets through.
- Anatomy of a kpkg install follows one
kpkg installthrough every step it takes.
The package pages in the rest of the book describe those steps for one port each; this part explains the steps themselves, once.
See also
- Packaging: ports, packages, the solver and the recipe hash
- Writing ports: the recipe format
- Part V: the first package phase