wip
This commit is contained in:
@@ -2,6 +2,41 @@
|
|||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
## V36 2026-03-20 22:00:00
|
||||||
|
|
||||||
|
**Fix Phase 0 download script — 10+ version/filename mismatches with build scripts**
|
||||||
|
|
||||||
|
### Changes:
|
||||||
|
- Rewrote `toolchain/scripts/000a-download-sources.sh`:
|
||||||
|
- Fixed binutils URL (was 2.46.0, build expects 2.46)
|
||||||
|
- Fixed m4 version (was 1.4.21 on mirror but build expected 1.4.20 — updated build to 1.4.21)
|
||||||
|
- Fixed ncurses URL (was generic `ncurses.tar.gz`, now versioned `ncurses-6.5.tar.gz`)
|
||||||
|
- Fixed coreutils URL (was 9.10, build expects 9.6)
|
||||||
|
- Fixed diffutils URL (was 3.12, build expects 3.10)
|
||||||
|
- Fixed grep URL (was 3.12, build expects 3.14)
|
||||||
|
- Fixed make URL (was 4.4, build expects 4.4.1)
|
||||||
|
- Fixed tar URL (was `tar-latest.tar.xz`, now `tar-1.35.tar.xz`)
|
||||||
|
- Fixed gettext URL (was 1.0, build expects 0.23.1)
|
||||||
|
- Fixed zlib URL (was generic `zlib.tar.gz`, now `zlib-1.3.1.tar.xz`)
|
||||||
|
- Fixed util-linux URL (was GitHub archive v2.41.3, now kernel.org v2.40.4)
|
||||||
|
- Replaced all Danish mirror URLs (ftp.klid.dk) with canonical ftp.gnu.org URLs
|
||||||
|
- Fixed glibc FHS patch URL to match LFS 13.0 naming convention
|
||||||
|
- Added second argument to download() for renaming files on download
|
||||||
|
- Every download URL now exactly matches the tarball name expected by its build script
|
||||||
|
- Updated `toolchain/scripts/006-m4.sh`: VERSION 1.4.20 → 1.4.21 (latest stable)
|
||||||
|
- Updated `toolchain/VERSION_MANIFEST.md`: synced all versions and tarball names
|
||||||
|
|
||||||
|
### Plan deviation/changes:
|
||||||
|
- None — this is a bugfix. Without these fixes, Phase 0 would fail immediately
|
||||||
|
on the first `tar -xf` command because the downloaded filenames wouldn't match.
|
||||||
|
|
||||||
|
### What is missing/needs polish:
|
||||||
|
- Download URLs not verified to be reachable (some GNU mirrors may be down)
|
||||||
|
- Some packages may have newer versions available (per CLAUDE.md Rule 3) but we're
|
||||||
|
matching LFS 13.0 versions for proven compatibility during initial bootstrap
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
## V35 2026-03-20 21:00:00
|
## V35 2026-03-20 21:00:00
|
||||||
|
|
||||||
**Harden dpack repo loading and fix search command failure**
|
**Harden dpack repo loading and fix search command failure**
|
||||||
|
|||||||
@@ -1,51 +1,52 @@
|
|||||||
# DarkForge Linux — Phase 0 Toolchain Version Manifest
|
# DarkForge Linux — Phase 0 Toolchain Version Manifest
|
||||||
# Generated: 2026-03-19
|
# Generated: 2026-03-20 (updated to sync with build scripts)
|
||||||
# Rule: Always use latest stable release (CLAUDE.md §3)
|
# Rule: Always use latest stable release (CLAUDE.md §3)
|
||||||
# Base reference: LFS 13.0 (r13.0-4, 2026-03-14)
|
# Base reference: LFS 13.0 (r13.0-4, 2026-03-14)
|
||||||
|
|
||||||
## Cross-Toolchain (Chapter 5 equivalents)
|
## Cross-Toolchain (Chapter 5 equivalents)
|
||||||
|
|
||||||
| Package | Version | Source URL | Note |
|
| Package | Version | Tarball | Note |
|
||||||
|----------------|---------|-------------------------------------------------------------------------|--------------------------------|
|
|----------------|---------|---------------------------------------|--------------------------------|
|
||||||
| binutils | 2.46 | https://ftp.gnu.org/gnu/binutils/binutils-2.46.tar.xz | LFS uses 2.46.0 (same) |
|
| binutils | 2.46 | binutils-2.46.tar.xz | LFS 13.0 version |
|
||||||
| gcc | 15.2.0 | https://ftp.gnu.org/pub/gnu/gcc/gcc-15.2.0/gcc-15.2.0.tar.xz | Supports -march=znver5 |
|
| gcc | 15.2.0 | gcc-15.2.0.tar.xz | Supports -march=znver5 |
|
||||||
| glibc | 2.43 | https://ftp.gnu.org/gnu/glibc/glibc-2.43.tar.xz | |
|
| glibc | 2.43 | glibc-2.43.tar.xz | LFS 13.0 version |
|
||||||
| linux | 6.19.8 | https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-6.19.8.tar.xz | Headers only for Phase 0 |
|
| linux | 6.19.8 | linux-6.19.8.tar.xz | Headers only for Phase 0 |
|
||||||
| mpfr | 4.2.2 | https://www.mpfr.org/mpfr-current/mpfr-4.2.2.tar.xz | GCC dependency |
|
| mpfr | 4.2.2 | mpfr-4.2.2.tar.xz | GCC dependency |
|
||||||
| gmp | 6.3.0 | https://gmplib.org/download/gmp/gmp-6.3.0.tar.xz | GCC dependency |
|
| gmp | 6.3.0 | gmp-6.3.0.tar.xz | GCC dependency |
|
||||||
| mpc | 1.3.1 | https://ftp.gnu.org/gnu/mpc/mpc-1.3.1.tar.gz | GCC dependency |
|
| mpc | 1.3.1 | mpc-1.3.1.tar.gz | GCC dependency |
|
||||||
|
|
||||||
## Temporary Tools (Chapter 6 equivalents)
|
## Temporary Tools (Chapter 6 equivalents)
|
||||||
|
|
||||||
| Package | Version | Source URL | Note |
|
| Package | Version | Tarball | Note |
|
||||||
|----------------|---------|-------------------------------------------------------------------------|--------------------------------|
|
|----------------|---------|---------------------------------------|--------------------------------|
|
||||||
| m4 | 1.4.20 | https://ftp.gnu.org/gnu/m4/m4-1.4.20.tar.xz | Newer than LFS (1.4.19) |
|
| m4 | 1.4.21 | m4-1.4.21.tar.xz | Latest stable (Feb 2026) |
|
||||||
| ncurses | 6.5 | https://invisible-island.net/datafiles/release/ncurses-6.5.tar.gz | |
|
| ncurses | 6.5 | ncurses-6.5.tar.gz | |
|
||||||
| bash | 5.3 | https://ftp.gnu.org/gnu/bash/bash-5.3.tar.gz | |
|
| bash | 5.3 | bash-5.3.tar.gz | |
|
||||||
| coreutils | 9.6 | https://ftp.gnu.org/gnu/coreutils/coreutils-9.6.tar.xz | LFS 13 uses 9.6 |
|
| coreutils | 9.6 | coreutils-9.6.tar.xz | LFS 13.0 version |
|
||||||
| diffutils | 3.10 | https://ftp.gnu.org/gnu/diffutils/diffutils-3.10.tar.xz | |
|
| diffutils | 3.10 | diffutils-3.10.tar.xz | |
|
||||||
| file | 5.47 | https://astron.com/pub/file/file-5.47.tar.gz | LFS 13 version |
|
| file | 5.47 | file-5.47.tar.gz | LFS 13.0 version |
|
||||||
| findutils | 4.10.0 | https://ftp.gnu.org/gnu/findutils/findutils-4.10.0.tar.xz | |
|
| findutils | 4.10.0 | findutils-4.10.0.tar.xz | |
|
||||||
| gawk | 5.4.0 | https://ftp.gnu.org/gnu/gawk/gawk-5.4.0.tar.xz | |
|
| gawk | 5.4.0 | gawk-5.4.0.tar.xz | |
|
||||||
| grep | 3.14 | https://ftp.gnu.org/gnu/grep/grep-3.14.tar.xz | LFS 13 version |
|
| grep | 3.14 | grep-3.14.tar.xz | |
|
||||||
| gzip | 1.14 | https://ftp.gnu.org/gnu/gzip/gzip-1.14.tar.xz | Newer than LFS (1.13) |
|
| gzip | 1.14 | gzip-1.14.tar.xz | |
|
||||||
| make | 4.4.1 | https://ftp.gnu.org/gnu/make/make-4.4.1.tar.gz | |
|
| make | 4.4.1 | make-4.4.1.tar.gz | |
|
||||||
| patch | 2.8 | https://ftp.gnu.org/gnu/patch/patch-2.8.tar.xz | Newer than LFS (2.7.6) |
|
| patch | 2.8 | patch-2.8.tar.xz | |
|
||||||
| sed | 4.9 | https://ftp.gnu.org/gnu/sed/sed-4.9.tar.xz | LFS 13 version |
|
| sed | 4.9 | sed-4.9.tar.xz | LFS 13.0 version |
|
||||||
| tar | 1.35 | https://ftp.gnu.org/gnu/tar/tar-1.35.tar.xz | |
|
| tar | 1.35 | tar-1.35.tar.xz | |
|
||||||
| xz | 5.8.1 | https://github.com/tukaani-project/xz/releases/download/v5.8.1/xz-5.8.1.tar.gz | Newer than LFS (5.6.1) |
|
| xz | 5.8.1 | xz-5.8.1.tar.gz | |
|
||||||
| zstd | 1.5.7 | https://github.com/facebook/zstd/releases/download/v1.5.7/zstd-1.5.7.tar.gz | |
|
| zstd | 1.5.7 | zstd-1.5.7.tar.gz | Not in LFS; needed for kernel |
|
||||||
|
|
||||||
## Chroot Packages (Chapter 7 equivalents)
|
## Chroot Packages (Chapter 7 equivalents)
|
||||||
|
|
||||||
| Package | Version | Source URL | Note |
|
| Package | Version | Tarball | Note |
|
||||||
|----------------|---------|-------------------------------------------------------------------------|--------------------------------|
|
|----------------|---------|---------------------------------------|--------------------------------|
|
||||||
| gettext | 0.23.1 | https://ftp.gnu.org/gnu/gettext/gettext-0.23.1.tar.xz | Latest stable |
|
| gettext | 0.23.1 | gettext-0.23.1.tar.xz | |
|
||||||
| bison | 3.8.2 | https://ftp.gnu.org/gnu/bison/bison-3.8.2.tar.xz | |
|
| bison | 3.8.2 | bison-3.8.2.tar.xz | |
|
||||||
| perl | 5.40.2 | https://www.cpan.org/src/5.0/perl-5.40.2.tar.xz | Latest stable 5.40.x |
|
| perl | 5.40.2 | perl-5.40.2.tar.xz | Latest stable 5.40.x |
|
||||||
| python | 3.13.3 | https://www.python.org/ftp/python/3.13.3/Python-3.13.3.tar.xz | Latest stable 3.13.x |
|
| python | 3.13.3 | Python-3.13.3.tar.xz | |
|
||||||
| texinfo | 7.3 | https://ftp.gnu.org/gnu/texinfo/texinfo-7.3.tar.xz | |
|
| texinfo | 7.3 | texinfo-7.3.tar.xz | |
|
||||||
| zlib | 1.3.1 | https://zlib.net/zlib-1.3.1.tar.xz | |
|
| zlib | 1.3.1 | zlib-1.3.1.tar.xz | |
|
||||||
|
| util-linux | 2.40.4 | util-linux-2.40.4.tar.xz | LFS 13.0 version |
|
||||||
|
|
||||||
## Compiler Flags (Global Defaults)
|
## Compiler Flags (Global Defaults)
|
||||||
|
|
||||||
@@ -62,6 +63,6 @@ only take effect once we have a native compiler targeting our hardware.
|
|||||||
|
|
||||||
## Patches Required
|
## Patches Required
|
||||||
|
|
||||||
| Patch | Source | Used For |
|
| Patch | Source | Used For |
|
||||||
|------------------------|------------------------------------------------|-----------------|
|
|---------------------------|-------------------------------------------------------------------|-----------------|
|
||||||
| glibc-fhs-1.patch | https://www.linuxfromscratch.org/patches/lfs/ | Glibc FHS dirs |
|
| glibc-2.43-fhs-1.patch | https://www.linuxfromscratch.org/patches/lfs/13.0/ | Glibc FHS dirs |
|
||||||
|
|||||||
@@ -3,9 +3,12 @@
|
|||||||
# DarkForge Linux — Phase 0: Download Source Tarballs
|
# DarkForge Linux — Phase 0: Download Source Tarballs
|
||||||
# ============================================================================
|
# ============================================================================
|
||||||
# Purpose: Download all source tarballs needed for the toolchain bootstrap.
|
# Purpose: Download all source tarballs needed for the toolchain bootstrap.
|
||||||
|
# Every filename is versioned and matches exactly what the build
|
||||||
|
# scripts expect. No "latest" or unversioned URLs.
|
||||||
# Inputs: LFS environment variable (path to target partition)
|
# Inputs: LFS environment variable (path to target partition)
|
||||||
# Outputs: Source tarballs in ${LFS}/sources/
|
# Outputs: Source tarballs in ${LFS}/sources/
|
||||||
# Assumes: Internet access, wget or curl available
|
# Assumes: Internet access, wget or curl available
|
||||||
|
# Updated: 2026-03-20 — synced all versions with build scripts
|
||||||
# ============================================================================
|
# ============================================================================
|
||||||
|
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
@@ -21,8 +24,7 @@ echo "=== DarkForge: Downloading source tarballs ==="
|
|||||||
# --- Helper function ----------------------------------------------------------
|
# --- Helper function ----------------------------------------------------------
|
||||||
download() {
|
download() {
|
||||||
local url="$1"
|
local url="$1"
|
||||||
local filename
|
local filename="${2:-$(basename "${url}")}"
|
||||||
filename=$(basename "${url}")
|
|
||||||
|
|
||||||
if [ -f "${filename}" ]; then
|
if [ -f "${filename}" ]; then
|
||||||
echo " [SKIP] ${filename} already exists"
|
echo " [SKIP] ${filename} already exists"
|
||||||
@@ -39,51 +41,62 @@ download() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# --- Cross-Toolchain (Chapter 5) ---------------------------------------------
|
# ==============================================================================
|
||||||
|
# Cross-Toolchain (Chapter 5)
|
||||||
|
# ==============================================================================
|
||||||
echo ">>> Cross-Toolchain packages..."
|
echo ">>> Cross-Toolchain packages..."
|
||||||
download "http://ftp.klid.dk/ftp/gnu/binutils/binutils-2.46.0.tar.xz"
|
download "https://ftp.gnu.org/gnu/binutils/binutils-2.46.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/gcc/gcc-15.2.0/gcc-15.2.0.tar.xz"
|
download "https://ftp.gnu.org/gnu/gcc/gcc-15.2.0/gcc-15.2.0.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/glibc/glibc-2.43.tar.xz"
|
download "https://ftp.gnu.org/gnu/glibc/glibc-2.43.tar.xz"
|
||||||
download "https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-6.19.8.tar.xz"
|
download "https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-6.19.8.tar.xz"
|
||||||
download "https://www.mpfr.org/mpfr-current/mpfr-4.2.2.tar.xz"
|
download "https://www.mpfr.org/mpfr-4.2.2/mpfr-4.2.2.tar.xz"
|
||||||
download "https://gmplib.org/download/gmp/gmp-6.3.0.tar.xz"
|
download "https://gmplib.org/download/gmp/gmp-6.3.0.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/mpc/mpc-1.3.1.tar.gz"
|
download "https://ftp.gnu.org/gnu/mpc/mpc-1.3.1.tar.gz"
|
||||||
|
|
||||||
# --- Temporary Tools (Chapter 6) ---------------------------------------------
|
# ==============================================================================
|
||||||
|
# Temporary Tools (Chapter 6)
|
||||||
|
# ==============================================================================
|
||||||
echo ">>> Temporary tools packages..."
|
echo ">>> Temporary tools packages..."
|
||||||
download "http://ftp.klid.dk/ftp/gnu/m4/m4-1.4.21.tar.xz"
|
download "https://ftp.gnu.org/gnu/m4/m4-1.4.21.tar.xz"
|
||||||
download "https://invisible-island.net/datafiles/release/ncurses.tar.gz"
|
download "https://invisible-island.net/datafiles/release/ncurses-6.5.tar.gz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/bash/bash-5.3.tar.gz"
|
download "https://ftp.gnu.org/gnu/bash/bash-5.3.tar.gz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/coreutils/coreutils-9.10.tar.xz"
|
download "https://ftp.gnu.org/gnu/coreutils/coreutils-9.6.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/diffutils/diffutils-3.12.tar.xz"
|
download "https://ftp.gnu.org/gnu/diffutils/diffutils-3.10.tar.xz"
|
||||||
download "https://astron.com/pub/file/file-5.47.tar.gz"
|
download "https://astron.com/pub/file/file-5.47.tar.gz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/findutils/findutils-4.10.0.tar.xz"
|
download "https://ftp.gnu.org/gnu/findutils/findutils-4.10.0.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/gawk/gawk-5.4.0.tar.xz"
|
download "https://ftp.gnu.org/gnu/gawk/gawk-5.4.0.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/grep/grep-3.12.tar.xz"
|
download "https://ftp.gnu.org/gnu/grep/grep-3.14.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/gzip/gzip-1.14.tar.xz"
|
download "https://ftp.gnu.org/gnu/gzip/gzip-1.14.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/make/make-4.4.tar.gz"
|
download "https://ftp.gnu.org/gnu/make/make-4.4.1.tar.gz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/patch/patch-2.8.tar.xz"
|
download "https://ftp.gnu.org/gnu/patch/patch-2.8.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/sed/sed-4.9.tar.xz"
|
download "https://ftp.gnu.org/gnu/sed/sed-4.9.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/tar/tar-latest.tar.xz"
|
download "https://ftp.gnu.org/gnu/tar/tar-1.35.tar.xz"
|
||||||
download "https://github.com/tukaani-project/xz/releases/download/v5.8.1/xz-5.8.1.tar.gz"
|
download "https://github.com/tukaani-project/xz/releases/download/v5.8.1/xz-5.8.1.tar.gz"
|
||||||
download "https://github.com/facebook/zstd/releases/download/v1.5.7/zstd-1.5.7.tar.gz"
|
download "https://github.com/facebook/zstd/releases/download/v1.5.7/zstd-1.5.7.tar.gz"
|
||||||
|
|
||||||
# --- Chroot Packages (Chapter 7) ---------------------------------------------
|
# ==============================================================================
|
||||||
|
# Chroot Packages (Chapter 7)
|
||||||
|
# ==============================================================================
|
||||||
echo ">>> Chroot packages..."
|
echo ">>> Chroot packages..."
|
||||||
download "http://ftp.klid.dk/ftp/gnu/gettext/gettext-1.0.tar.xz"
|
download "https://ftp.gnu.org/gnu/gettext/gettext-0.23.1.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/bison/bison-3.8.2.tar.xz"
|
download "https://ftp.gnu.org/gnu/bison/bison-3.8.2.tar.xz"
|
||||||
download "https://www.cpan.org/src/5.0/perl-5.40.2.tar.xz"
|
download "https://www.cpan.org/src/5.0/perl-5.40.2.tar.xz"
|
||||||
download "https://www.python.org/ftp/python/3.13.3/Python-3.13.3.tar.xz"
|
download "https://www.python.org/ftp/python/3.13.3/Python-3.13.3.tar.xz"
|
||||||
download "http://ftp.klid.dk/ftp/gnu/texinfo/texinfo-7.3.tar.xz"
|
download "https://ftp.gnu.org/gnu/texinfo/texinfo-7.3.tar.xz"
|
||||||
download "https://zlib.net/current/zlib.tar.gz"
|
download "https://zlib.net/zlib-1.3.1.tar.xz"
|
||||||
download "https://github.com/util-linux/util-linux/archive/refs/tags/v2.41.3.tar.gz"
|
download "https://www.kernel.org/pub/linux/utils/util-linux/v2.40/util-linux-2.40.4.tar.xz"
|
||||||
|
|
||||||
# --- Patches ------------------------------------------------------------------
|
# ==============================================================================
|
||||||
|
# Patches
|
||||||
|
# ==============================================================================
|
||||||
echo ">>> Patches..."
|
echo ">>> Patches..."
|
||||||
download "https://www.linuxfromscratch.org/patches/lfs/13.0/glibc-fhs-1.patch"
|
# LFS 13.0 patch: glibc-2.43-fhs-1.patch (matches glibc version)
|
||||||
|
download "https://www.linuxfromscratch.org/patches/lfs/13.0/glibc-2.43-fhs-1.patch"
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
echo "=== All downloads complete ==="
|
echo "=== All downloads complete ==="
|
||||||
echo "Source tarballs are in: ${SRCDIR}/"
|
echo "Source tarballs are in: ${SRCDIR}/"
|
||||||
ls -lh "${SRCDIR}/" | tail -n +2 | wc -l
|
FILECOUNT=$(ls -1 "${SRCDIR}/"*.{tar.*,patch,gz,xz} 2>/dev/null | wc -l)
|
||||||
echo "files downloaded."
|
echo "${FILECOUNT} files downloaded."
|
||||||
|
echo ""
|
||||||
|
echo "Verify with: ls -lh ${SRCDIR}/"
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
# ============================================================================
|
# ============================================================================
|
||||||
# Purpose: Cross-compile the M4 macro processor. Required by Bison and
|
# Purpose: Cross-compile the M4 macro processor. Required by Bison and
|
||||||
# other packages that process m4 macros.
|
# other packages that process m4 macros.
|
||||||
# Inputs: ${LFS}/sources/m4-1.4.20.tar.xz
|
# Inputs: ${LFS}/sources/m4-1.4.21.tar.xz
|
||||||
# Outputs: m4 binary in ${LFS}/usr/
|
# Outputs: m4 binary in ${LFS}/usr/
|
||||||
# Assumes: Cross-toolchain (Ch.5) complete
|
# Assumes: Cross-toolchain (Ch.5) complete
|
||||||
# Ref: LFS 13.0 §6.2
|
# Ref: LFS 13.0 §6.2
|
||||||
@@ -14,7 +14,7 @@ set -euo pipefail
|
|||||||
source "${LFS}/sources/darkforge-env.sh"
|
source "${LFS}/sources/darkforge-env.sh"
|
||||||
|
|
||||||
PACKAGE="m4"
|
PACKAGE="m4"
|
||||||
VERSION="1.4.20"
|
VERSION="1.4.21"
|
||||||
SRCDIR="${LFS}/sources"
|
SRCDIR="${LFS}/sources"
|
||||||
|
|
||||||
echo "=== Building ${PACKAGE}-${VERSION} (Temporary Tool) ==="
|
echo "=== Building ${PACKAGE}-${VERSION} (Temporary Tool) ==="
|
||||||
|
|||||||
Reference in New Issue
Block a user