No description
  • Shell 83.6%
  • Python 13.1%
  • Makefile 3.3%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-06-19 10:24:33 -07:00
bootstrap Fix tpkg command syntax throughout repo 2026-06-19 09:39:55 -07:00
dev Fix package categorization 2026-06-18 23:58:09 -07:00
editor/vim/9.1.0 Define editor/vim/9.1.0 BLFS package 2026-06-19 00:20:47 -07:00
example/hello/1.0.0 Add example patches following naming convention 2026-06-18 22:06:21 -07:00
lib Add dependency resolver script and update package deps 2026-06-19 00:06:23 -07:00
net Define net/openssh/9.8p1 BLFS package 2026-06-19 00:20:49 -07:00
scripts Add dependency resolver script and update package deps 2026-06-19 00:06:23 -07:00
shell/bash/5.2.32 fix: update bash install script to create bin directory and symlink correctly 2026-06-19 10:23:35 -07:00
sys Create sys/lfs-base/1.0 meta-package 2026-06-19 00:06:27 -07:00
util fix: remove docdir sed manipulation from openssl and grep build scripts 2026-06-19 00:11:29 -07:00
www/lynx/2.9.2 Define www/lynx/2.9.2 BLFS package 2026-06-19 00:20:47 -07:00
x11 Define x11/xorg-server/21.1.13 X11 package 2026-06-19 00:21:17 -07:00
.gitignore feat: add gzip file patterns to gitignore 2026-06-19 10:24:33 -07:00
BOOTSTRAP-CYCLE.md Document circular dependency handling for LFS toolchain 2026-06-19 00:06:40 -07:00
BUILDING.md Add LFS build documentation 2026-06-19 00:23:21 -07:00
Makefile Fix tpkg command syntax throughout repo 2026-06-19 09:39:55 -07:00
README.md Write comprehensive LFS + tpkg integration guide 2026-06-19 00:29:33 -07:00
ROADMAP.md Mark Phase 10: Documentation and Community Integration as DONE 2026-06-19 00:29:49 -07:00

tpkg Package Repository

This repository holds tpkg packages for building a Linux From Scratch (LFS) system, organized in a category/package/version/ directory hierarchy.

Quick Start

Build an entire LFS system with a single command:

./bootstrap/build-lfs.sh

Or step by step:

./bootstrap/verify-host.sh
make                          # Build temp toolchain
sudo ./bootstrap/enter-chroot.sh
tpkg install lfs-base         # Inside chroot
./bootstrap/configure-bootloader.sh

See BUILDING.md for detailed step-by-step instructions.

LFS Chapter Mapping

This repository's package structure maps to the LFS book as follows:

LFS Chapter tpkg Phase Packages/Commands
Ch 2: Host Requirements Phase 1 - Prep bootstrap/verify-host.sh
Ch 4: Environment Setup Phase 1 - Prep bootstrap/setup-lfs-env.sh
Ch 5: Cross Toolchain Phase 2 - Toolchain dev/binutils/2.43, dev/gcc/14.2.0, lib/glibc/2.40
Ch 6: Chroot Build Phase 3 - Core bootstrap/enter-chroot.sh + tpkg install lfs-base
Ch 7: System Config Phase 4 - Config sys/sysvinit/3.08, sys/base-files/1.0
Ch 8: Boot Phase 5 - Boot sys/linux/6.11.5, sys/grub/2.12
BLFS Packages Post-LFS net/wget/1.24.5, net/openssh/9.8p1, editor/vim/9.1.0

Directory Layout

<category>/
  <package>/
    <version>/
      package.json          # Package metadata (required)
      patches/              # Optional LFS patches
        001_fix-build.p1.patch

Category Reference

Valid categories and their contents:

Category Contains
dev Development tools: binutils, gcc, m4, make, patch, pkg-config
lib Libraries: glibc, ncurses
shell Shells: bash
util Utilities: coreutils, diffutils, findutils, gawk, grep, gzip, sed, tar, xz, bzip2
sys System: linux, util-linux, e2fsprogs, grub, sysvinit, base-files, profile, eudev
net Networking: openssl, openssh, wget, curl
www Web: lynx
editor Editors: vim
x11 X11: libxcb, xorg-server, xfce4

Troubleshooting

Circular dependency: glibc <-> linux

The kernel build doesn't need glibc (it's self-contained). The build order is: linux headers -> glibc -> full linux kernel. See BOOTSTRAP-CYCLE.md.

Missing dependencies: perl, zlib

openssl needs perl (use host perl), curl needs zlib (not yet packaged). These are build-time only; warnings can be safely ignored.

Toolchain verification fails

Run make check or python3 scripts/dep-resolve --check-cycles to verify the dependency graph. Ensure $LFS and $LFS_TGT are set correctly.

Patch application issues

Patches in patches/ directories are applied in indexed order (001-999). Verify patch strip level matches the .p0/.p1 suffix.