From 68528292e668ca68b64d14e3fe882d19af09f3c5 Mon Sep 17 00:00:00 2001 From: Bruce Dubbs Date: Wed, 21 May 2025 16:46:52 -0500 Subject: [PATCH 01/11] Changes for gcc15. --- chapter01/changelog.xml | 26 ++++++++++++++++++++++++++ chapter01/whatsnew.xml | 16 ++++++++-------- chapter03/patches.xml | 16 ++++++++-------- chapter06/bash.xml | 4 ++++ chapter08/bc.xml | 6 +++--- chapter08/expect.xml | 4 ++-- chapter08/gmp.xml | 4 ++++ chapter08/ncurses.xml | 4 ++-- packages.ent | 35 ++++++++++++++++++----------------- patches.ent | 15 +++++++-------- 10 files changed, 82 insertions(+), 48 deletions(-) diff --git a/chapter01/changelog.xml b/chapter01/changelog.xml index 14f3cb970..403b5f4c4 100644 --- a/chapter01/changelog.xml +++ b/chapter01/changelog.xml @@ -39,6 +39,32 @@ or as appropriate for the entry or if needed the entire day's listitem. --> + + 2025-06-01 + + + [bdubbs] - Update build instructions to accomodate + gcc-15 for bc, expect, ncurses, and gmp. + + + [bdubbs] - Update to gcc-15.1.0. Fixes + #5707. + + + [bdubbs] - Update to less-678. Fixes + #5724. + + + [bdubbs] - Update to readline-8.3-rc1. Fixes + #5726. + + + [bdubbs] - Update to bash-5.3-rc1. Fixes + #5714. + + + + 2025-05-15 diff --git a/chapter01/whatsnew.xml b/chapter01/whatsnew.xml index 819b1f243..f21ea40d4 100644 --- a/chapter01/whatsnew.xml +++ b/chapter01/whatsnew.xml @@ -38,9 +38,9 @@ - + @@ -89,9 +89,9 @@ Gawk-&gawk-version; - + GDBM-&gdbm-version; @@ -140,9 +140,9 @@ Kmod-&kmod-version; - + @@ -221,9 +221,9 @@ Python-&python-version; - + diff --git a/chapter03/patches.xml b/chapter03/patches.xml index dd592f663..907f6ed3e 100644 --- a/chapter03/patches.xml +++ b/chapter03/patches.xml @@ -26,15 +26,15 @@ --> - + + First, make an adjustment for compatibilty with gcc-15 and later: + +sed -i '/long long t1;/,+1s/()/(...)/' configure + Prepare GMP for compilation: ./configure --prefix=/usr \ diff --git a/chapter08/ncurses.xml b/chapter08/ncurses.xml index a825f63c9..84970f306 100644 --- a/chapter08/ncurses.xml +++ b/chapter08/ncurses.xml @@ -137,8 +137,8 @@ ): make DESTDIR=$PWD/dest install -install -vm755 dest/usr/lib/libncursesw.so.&ncurses-version; /usr/lib -rm -v dest/usr/lib/libncursesw.so.&ncurses-version; +install -vm755 dest/usr/lib/libncursesw.so.&ncurses-base-version; /usr/lib +rm -v dest/usr/lib/libncursesw.so.&ncurses-base-version; sed -e 's/^#if.*XOPEN.*$/#if 1/' \ -i dest/usr/include/curses.h cp -av dest/* / diff --git a/packages.ent b/packages.ent index 6e7985744..159bbc313 100644 --- a/packages.ent +++ b/packages.ent @@ -47,10 +47,10 @@ - - + + - + @@ -210,10 +210,10 @@ - - + + - + @@ -365,10 +365,10 @@ - - + + - + @@ -519,10 +519,11 @@ - - - - + + + + + @@ -618,11 +619,11 @@ - - - + + + - + diff --git a/patches.ent b/patches.ent index c7b2ab19b..d800a74d6 100644 --- a/patches.ent +++ b/patches.ent @@ -2,11 +2,10 @@ - + + + + From 722ec5bf97178aa805a281c7b055c44ac3248a09 Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Fri, 23 May 2025 15:58:21 +0800 Subject: [PATCH 03/11] glibc: Reuse DIR in upgrade instruction and unset it afterwards --- chapter08/glibc.xml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/chapter08/glibc.xml b/chapter08/glibc.xml index a7ce1190a..bcb275177 100644 --- a/chapter08/glibc.xml +++ b/chapter08/glibc.xml @@ -329,7 +329,8 @@ install -vm755 dest/usr/lib/*.so.* /usr/lib DIR=$(dirname $(gcc -print-libgcc-file-name)) [ -e $DIR/include/limits.h ] || mv $DIR/include{-fixed,}/limits.h [ -e $DIR/include/syslimits.h ] || mv $DIR/include{-fixed,}/syslimits.h -rm -rfv $(dirname $(gcc -print-libgcc-file-name))/include-fixed/* +rm -rfv $DIR/include-fixed/* +unset DIR Install the package: From 6a04e2420d3f8ffd43b1d01fd2d647ce40fb4013 Mon Sep 17 00:00:00 2001 From: Bruce Dubbs Date: Sat, 24 May 2025 07:28:03 -0500 Subject: [PATCH 04/11] Add some spaces --- chapter08/glibc.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chapter08/glibc.xml b/chapter08/glibc.xml index bcb275177..9468dda43 100644 --- a/chapter08/glibc.xml +++ b/chapter08/glibc.xml @@ -327,7 +327,7 @@ install -vm755 dest/usr/lib/*.so.* /usr/lib DIR=$(dirname $(gcc -print-libgcc-file-name)) -[ -e $DIR/include/limits.h ] || mv $DIR/include{-fixed,}/limits.h +[ -e $DIR/include/limits.h ] || mv $DIR/include{-fixed,}/limits.h [ -e $DIR/include/syslimits.h ] || mv $DIR/include{-fixed,}/syslimits.h rm -rfv $DIR/include-fixed/* unset DIR From 14b85031e4b0c8a55e70666288b3082620157570 Mon Sep 17 00:00:00 2001 From: Bruce Dubbs Date: Fri, 30 May 2025 11:00:14 -0500 Subject: [PATCH 05/11] Package updates. Update to systemd-257.6. Update to setuptools-80.9.0. Update to meson-1.8.1. Update to automake-1.18. Add Python-3.13.3-security_fixes-1.patch Add coreutils-9.7-upstream_fix-1.patch Add perl-5.40.2-upstream_fix-1.patch --- chapter01/changelog.xml | 16 ++++++++++++++++ chapter01/whatsnew.xml | 20 ++++++++++++++++---- chapter03/patches.xml | 29 ++++++++++++++++++----------- chapter08/coreutils.xml | 4 ++++ chapter08/perl.xml | 4 ++++ chapter08/python.xml | 21 +++++++++++++++++---- packages.ent | 24 ++++++++++++------------ patches.ent | 22 +++++++++++++++++----- 8 files changed, 104 insertions(+), 36 deletions(-) diff --git a/chapter01/changelog.xml b/chapter01/changelog.xml index 403b5f4c4..4106b4b6b 100644 --- a/chapter01/changelog.xml +++ b/chapter01/changelog.xml @@ -42,6 +42,22 @@ 2025-06-01 + + [bdubbs] - Update to systemd-257.6. Fixes + #5774. + + + [bdubbs] - Update to setuptools-80.9.0. Fixes + #5728. + + + [bdubbs] - Update to meson-1.8.1. Fixes + #5731. + + + [bdubbs] - Update to automake-1.18. Fixes + #5734. + [bdubbs] - Update build instructions to accomodate gcc-15 for bc, expect, ncurses, and gmp. diff --git a/chapter01/whatsnew.xml b/chapter01/whatsnew.xml index f21ea40d4..e81c594f4 100644 --- a/chapter01/whatsnew.xml +++ b/chapter01/whatsnew.xml @@ -35,9 +35,9 @@ - + Bash-&bash-version; @@ -236,9 +236,9 @@ Sysklogd-&sysklogd-version; - + @@ -296,6 +296,18 @@ Packaging-&packaging-version; + + bash-5.3-rc1-cross_compile_fix-1.patch + + + coreutils-9.7-upstream_fix-1.patch + + + perl-5.40.2-upstream_fix-1.patch + + + Python-3.13.3-security_fixes-1.patch + diff --git a/chapter03/patches.xml b/chapter03/patches.xml index 907f6ed3e..435fa6acd 100644 --- a/chapter03/patches.xml +++ b/chapter03/patches.xml @@ -52,6 +52,14 @@ + + Coreutils Upstream Fixe Patch - &coreutils-upstream-patch-size;: + + Download: + MD5 sum: &coreutils-upstream-patch-md5; + + + Coreutils Internationalization Fixes Patch - &coreutils-i18n-patch-size;: @@ -61,7 +69,7 @@ - Expect GCC14 Patch - &expect-gcc15-patch-size;: + Expect GCC15 Patch - &expect-gcc15-patch-size;: Download: MD5 sum: &expect-gcc15-patch-md5; @@ -118,24 +126,23 @@ --> - - + SysVinit Consolidated Patch - &sysvinit-consolidated-patch-size;: diff --git a/chapter08/coreutils.xml b/chapter08/coreutils.xml index 36d428981..abf5f7819 100644 --- a/chapter08/coreutils.xml +++ b/chapter08/coreutils.xml @@ -41,6 +41,10 @@ Installation of Coreutils + First apply a security patch identified upstream: + +patch -Np1 -i ../&coreutils-upstream-patch; + POSIX requires that programs from Coreutils recognize character boundaries correctly even in multibyte locales. The following patch fixes this non-compliance and other internationalization-related bugs. diff --git a/chapter08/perl.xml b/chapter08/perl.xml index b678f7f9d..0416aa85e 100644 --- a/chapter08/perl.xml +++ b/chapter08/perl.xml @@ -41,6 +41,10 @@ Installation of Perl + First, apply a security patch identified upstream: + +patch -Np1 -i ../&perl-upstream-fix-patch; + This version of Perl builds the Compress::Raw::Zlib and Compress::Raw::BZip2 modules. By default Perl will use an internal copy of the sources for the build. diff --git a/chapter08/python.xml b/chapter08/python.xml index ebda61181..0cbce0b0c 100644 --- a/chapter08/python.xml +++ b/chapter08/python.xml @@ -43,12 +43,17 @@ Installation of Python 3 + First, apply a security patch to the current package: + + patch -Np1 -i ../&python-security-fixes-patch; + Prepare Python for compilation: -./configure --prefix=/usr \ - --enable-shared \ - --with-system-expat \ - --enable-optimizations +./configure --prefix=/usr \ + --enable-shared \ + --with-system-expat \ + --enable-optimizations \ + --without-static-libpython The meaning of the configure options: @@ -72,6 +77,14 @@ + + --without-static-libpython + + This switch prevents building a large, but unneeded, static + library. + + + Compile the package: diff --git a/packages.ent b/packages.ent index 159bbc313..405b0c373 100644 --- a/packages.ent +++ b/packages.ent @@ -38,11 +38,11 @@ - - + + - + @@ -495,10 +495,10 @@ - - + + - + @@ -638,10 +638,10 @@ - - + + - + @@ -662,15 +662,15 @@ - + - + - + diff --git a/patches.ent b/patches.ent index d800a74d6..dc666134a 100644 --- a/patches.ent +++ b/patches.ent @@ -11,6 +11,7 @@ --> + @@ -19,6 +20,10 @@ + + + + @@ -26,22 +31,29 @@ - + + + + + + + + + + + + + Kmod-&kmod-version; diff --git a/chapter08/kbd.xml b/chapter08/kbd.xml index 3239d6a21..06537f271 100644 --- a/chapter08/kbd.xml +++ b/chapter08/kbd.xml @@ -80,9 +80,14 @@ sed -i 's/resizecons.8 //' docs/man/man8/Makefile.in make - To test the results, issue: - + The tests for this package will all fail in the chroot environment + because they require valgrind. In addition + on a full system with valgrind, several + tests still fail in a graphical environment. The tests pass in + a non-graphical environment. + Install the package: diff --git a/packages.ent b/packages.ent index 405b0c373..dffe24262 100644 --- a/packages.ent +++ b/packages.ent @@ -309,10 +309,10 @@ - + - + @@ -349,10 +349,10 @@ - - + + - + @@ -672,11 +672,11 @@ - - + + - + @@ -745,10 +745,10 @@ - + - + - + From 3975ea8c7e68479f88170a3b5b461da9983e0ec1 Mon Sep 17 00:00:00 2001 From: Bruce Dubbs Date: Sat, 31 May 2025 04:28:18 -0500 Subject: [PATCH 07/11] Current thanges to trunk: Update to iana-etc-20250519. Update to vim-9.1.1418. Update to kbd-2.8.0. Update to systemd-257.6. Update to setuptools-80.9.0. Update to meson-1.8.1. Update to automake-1.18. Update to gcc-15.1.0. Update build instructions to accomodate gcc-15. Update to less-678. Update to readline-8.3-rc1. Update to bash-5.3-rc1. --- chapter01/changelog.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chapter01/changelog.xml b/chapter01/changelog.xml index 00caf0e3a..7e38d65d4 100644 --- a/chapter01/changelog.xml +++ b/chapter01/changelog.xml @@ -93,7 +93,7 @@ - + 2025-05-15 From 6c311ec76ff60f275a336354a6661193390753c2 Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Tue, 27 May 2025 11:41:13 +0800 Subject: [PATCH 08/11] changingowner: Exclude symlinks from chown Make this consistent with addinguser. Applying chown to a symlink actually affects its target, and here the targets are in $LFS/usr and already covered. --- chapter07/changingowner.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chapter07/changingowner.xml b/chapter07/changingowner.xml index 178c7836e..f29932694 100644 --- a/chapter07/changingowner.xml +++ b/chapter07/changingowner.xml @@ -33,7 +33,7 @@ user root by running the following command: -chown --from &lfs-username; -R root:root $LFS/{usr,lib,var,etc,bin,sbin,tools} +chown --from &lfs-username; -R root:root $LFS/{usr,var,etc,tools} case $(uname -m) in x86_64) chown --from &lfs-username; -R root:root $LFS/lib64 ;; esac From 30ec5ae0ea81e671f0bbe7c65c840957f422ac02 Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Sat, 31 May 2025 19:27:05 +0800 Subject: [PATCH 09/11] gcc-pass2: Remove empty line --- chapter06/gcc-pass2.xml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/chapter06/gcc-pass2.xml b/chapter06/gcc-pass2.xml index 13baefa48..9bb8332c7 100644 --- a/chapter06/gcc-pass2.xml +++ b/chapter06/gcc-pass2.xml @@ -100,8 +100,7 @@ cd build --disable-libssp \ --disable-libvtv \ --enable-languages=c,c++ \ - LDFLAGS_FOR_TARGET=-L$PWD/$LFS_TGT/libgcc - + LDFLAGS_FOR_TARGET=-L$PWD/$LFS_TGT/libgcc The meaning of the new configure options: From 208415b81b2909fbec563340e303cd4b6d5a0c5f Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Sun, 1 Jun 2025 12:26:06 +0800 Subject: [PATCH 10/11] reboot: Remove references to files we no longer create And note /etc/resolv.conf is optional for the systemd revision. --- chapter11/reboot.xml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/chapter11/reboot.xml b/chapter11/reboot.xml index 5a8cfd51e..497445346 100644 --- a/chapter11/reboot.xml +++ b/chapter11/reboot.xml @@ -88,17 +88,14 @@ - /etc/bashrc - /etc/dircolors /etc/fstab /etc/hosts /etc/inputrc /etc/profile - /etc/resolv.conf + /etc/resolv.conf + (optional) /etc/vimrc - /root/.bash_profile - /root/.bashrc - /etc/sysconfig/ifconfig.eth0 + /etc/sysconfig/ifconfig.eth0 From 455724dc3478ad19a1e735a132a865d54edc942c Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Sun, 1 Jun 2025 12:54:01 +0800 Subject: [PATCH 11/11] patches: Fix a typo --- chapter03/patches.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chapter03/patches.xml b/chapter03/patches.xml index 435fa6acd..94b36acb5 100644 --- a/chapter03/patches.xml +++ b/chapter03/patches.xml @@ -53,7 +53,7 @@ - Coreutils Upstream Fixe Patch - &coreutils-upstream-patch-size;: + Coreutils Upstream Fix Patch - &coreutils-upstream-patch-size;: Download: MD5 sum: &coreutils-upstream-patch-md5;