36 lines
978 B
Bash
Executable File
36 lines
978 B
Bash
Executable File
#!/bin/bash
|
|
# ============================================================================
|
|
# DarkForge Linux — Phase 3, Chapter 8: diffutils
|
|
# ============================================================================
|
|
# Purpose: Build diffutils (diff, cmp, diff3, sdiff).
|
|
# Compares files and produces difference reports.
|
|
# Inputs: /sources/diffutils-3.10.tar.xz
|
|
# Outputs: diffutils binaries in /usr/bin/
|
|
# Assumes: Running inside chroot
|
|
# Ref: LFS 13.0 §8.62
|
|
# ============================================================================
|
|
|
|
set -euo pipefail
|
|
|
|
source /sources/toolchain-scripts/100-chroot-env.sh
|
|
|
|
PACKAGE="diffutils"
|
|
VERSION="3.10"
|
|
|
|
echo "=== Building ${PACKAGE}-${VERSION} ==="
|
|
|
|
cd /sources
|
|
tar -xf "${PACKAGE}-${VERSION}.tar.xz"
|
|
cd "${PACKAGE}-${VERSION}"
|
|
|
|
./configure --prefix=/usr
|
|
|
|
make
|
|
# Optional: run tests
|
|
# make check || true
|
|
make install
|
|
|
|
cd /sources
|
|
rm -rf "${PACKAGE}-${VERSION}"
|
|
echo "=== ${PACKAGE}-${VERSION} complete ==="
|