* [git.ipfire.org] IPFire 2.x development tree branch, next, updated. b35d097a0a65ed5cf893a5baacfeab7bbc47c2d1
@ 2025-10-29 11:05 Michael Tremer
0 siblings, 0 replies; only message in thread
From: Michael Tremer @ 2025-10-29 11:05 UTC (permalink / raw)
To: ipfire-scm
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "IPFire 2.x development tree".
The branch, next has been updated
via b35d097a0a65ed5cf893a5baacfeab7bbc47c2d1 (commit)
via 5a20173cbb11edad06f7bc4e36deda4d27f6c6dc (commit)
from 61542019375860a6808d1f5ffb418c9f29dc5a0b (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit b35d097a0a65ed5cf893a5baacfeab7bbc47c2d1
Author: Michael Tremer <michael.tremer@ipfire.org>
Date: Tue Oct 28 15:41:43 2025 +0000
make.sh: Disable the toolchain during normal builds
This is a precaution because I have seen some files from the toolchain
being baked into the initrd. That should not happen and by keeping PATH
clean, there is no chance for any confusion.
In order to have the tools available that we need to build the initial
system, we will now have to pass a flag.
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
commit 5a20173cbb11edad06f7bc4e36deda4d27f6c6dc
Author: Michael Tremer <michael.tremer@ipfire.org>
Date: Tue Oct 28 17:13:44 2025 +0000
make.sh: Create a better PID 1 inside the environment
This is required so that we won't have any make processes locking up any
more. When the build process is getting aborted, this script will now
cleanly terminate anything inside the container and not block make as
PID 1.
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
-----------------------------------------------------------------------
Summary of changes:
make.sh | 181 ++++++++++++++++++++++++++++++++-----------------------
tools/execute.sh | 22 +++++--
2 files changed, 123 insertions(+), 80 deletions(-)
Difference in files:
diff --git a/make.sh b/make.sh
index 006a69a46..5bdc7690c 100755
--- a/make.sh
+++ b/make.sh
@@ -676,7 +676,7 @@ execute() {
# Update some variables
environ+=(
- [PATH]="${TOOLS_DIR}/ccache/bin:/bin:/usr/bin:/sbin:/usr/sbin:${TOOLS_DIR}/sbin:${TOOLS_DIR}/bin"
+ [PATH]="${TOOLS_DIR}/ccache/bin:/bin:/usr/bin:/sbin:/usr/sbin"
[HOME]="/root"
# Paths
@@ -708,6 +708,13 @@ execute() {
fi
;;
+ # Make the toolchain available in PATH
+ --enable-toolchain)
+ environ+=(
+ [PATH]="${environ[PATH]}:${TOOLS_DIR}/sbin:${TOOLS_DIR}/bin"
+ )
+ ;;
+
--interactive)
interactive="true"
@@ -949,20 +956,40 @@ lfsmake1() {
}
lfsmake2() {
- local pkg="${1}"
- shift
+ local args=()
+ local pkg
+
+ # Parse command line arguments
+ while [ $# -gt 0 ]; do
+ local arg="${1}"
+ shift
+
+ case "${arg}" in
+ # Collect any arguments
+ --*)
+ args+=( "${arg}" )
+ ;;
+
+ # Abort once we found the package
+ *)
+ pkg="${arg}"
+ break
+ ;;
+ esac
+ done
# Run the common check
lfsmakecommoncheck "${pkg}" "$@"
[ $? == 1 ] && return 0
# Download source outside of the toolchain
- if ! make_pkg --network "${pkg}" download "$@"; then
+ if ! make_pkg --network "${args[@]}" "${pkg}" download "$@"; then
exiterror "Downloading ${pkg}"
fi
# Run install on the package
- if ! make_pkg --chroot --timer="update_runtime" "${pkg}" b2 install "$@"; then
+ if ! make_pkg --chroot --timer="update_runtime" \
+ "${args[@]}" "${pkg}" b2 install "$@"; then
print_status FAIL
exiterror "Building ${pkg}"
@@ -1402,76 +1429,78 @@ build_toolchain() {
build_system() {
local LOGFILE="${LOG_DIR}/_build.${SNAME}.log"
- lfsmake2 stage2
- lfsmake2 linux HEADERS=1
- lfsmake2 man-pages
- lfsmake2 glibc
- lfsmake2 tzdata
- lfsmake2 cleanup-toolchain
- lfsmake2 zlib-ng
- [ "${BUILD_ARCH}" = "riscv64" ] && lfsmake2 gcc PASS=A
- lfsmake2 zstd
- lfsmake2 autoconf
- lfsmake2 autoconf-archive
- lfsmake2 automake
- lfsmake2 help2man
- lfsmake2 libtool
- lfsmake2 binutils
- lfsmake2 gmp
- lfsmake2 mpfr
- lfsmake2 libmpc
- lfsmake2 pkg-config
- lfsmake2 libxcrypt
- lfsmake2 file
- lfsmake2 gcc
- lfsmake2 attr
- lfsmake2 acl
- lfsmake2 sed
- lfsmake2 berkeley
- lfsmake2 coreutils
- lfsmake2 iana-etc
- lfsmake2 m4
- lfsmake2 bison
- lfsmake2 ncurses
- lfsmake2 perl
- lfsmake2 readline
- lfsmake2 bzip2
- lfsmake2 xz
- lfsmake2 lzip
- lfsmake2 pcre
- lfsmake2 pcre2
- lfsmake2 gettext
- lfsmake2 bash
- lfsmake2 diffutils
- lfsmake2 ed
- lfsmake2 findutils
- lfsmake2 flex
- lfsmake2 gawk
- lfsmake2 go
- lfsmake2 grep
- lfsmake2 groff
- lfsmake2 gperf
- lfsmake2 gzip
- lfsmake2 hostname
- lfsmake2 whois
- lfsmake2 kbd
- lfsmake2 less
- lfsmake2 procps
- lfsmake2 make
- lfsmake2 libpipeline
- lfsmake2 man
- lfsmake2 net-tools
- lfsmake2 patch
- lfsmake2 psmisc
- lfsmake2 shadow
- lfsmake2 sysklogd
- lfsmake2 sysvinit
- lfsmake2 tar
- lfsmake2 texinfo
- lfsmake2 util-linux
- lfsmake2 vim
- lfsmake2 e2fsprogs
- lfsmake2 jq
+ lfsmake2 --enable-toolchain stage2
+ lfsmake2 --enable-toolchain linux HEADERS=1
+ lfsmake2 --enable-toolchain man-pages
+ lfsmake2 --enable-toolchain glibc
+ lfsmake2 --enable-toolchain tzdata
+ lfsmake2 --enable-toolchain cleanup-toolchain
+ lfsmake2 --enable-toolchain zlib-ng
+ [ "${BUILD_ARCH}" = "riscv64" ] && lfsmake2 --enable-toolchain gcc PASS=A
+ lfsmake2 --enable-toolchain zstd
+ lfsmake2 --enable-toolchain autoconf
+ lfsmake2 --enable-toolchain autoconf-archive
+ lfsmake2 --enable-toolchain automake
+ lfsmake2 --enable-toolchain help2man
+ lfsmake2 --enable-toolchain libtool
+ lfsmake2 --enable-toolchain binutils
+ lfsmake2 --enable-toolchain gmp
+ lfsmake2 --enable-toolchain mpfr
+ lfsmake2 --enable-toolchain libmpc
+ lfsmake2 --enable-toolchain pkg-config
+ lfsmake2 --enable-toolchain libxcrypt
+ lfsmake2 --enable-toolchain file
+ lfsmake2 --enable-toolchain gcc
+ lfsmake2 --enable-toolchain attr
+ lfsmake2 --enable-toolchain acl
+ lfsmake2 --enable-toolchain sed
+ lfsmake2 --enable-toolchain berkeley
+ lfsmake2 --enable-toolchain coreutils
+ lfsmake2 --enable-toolchain iana-etc
+ lfsmake2 --enable-toolchain m4
+ lfsmake2 --enable-toolchain bison
+ lfsmake2 --enable-toolchain ncurses
+ lfsmake2 --enable-toolchain perl
+ lfsmake2 --enable-toolchain readline
+ lfsmake2 --enable-toolchain bzip2
+ lfsmake2 --enable-toolchain xz
+ lfsmake2 --enable-toolchain lzip
+ lfsmake2 --enable-toolchain pcre
+ lfsmake2 --enable-toolchain pcre2
+ lfsmake2 --enable-toolchain gettext
+ lfsmake2 --enable-toolchain bash
+ lfsmake2 --enable-toolchain diffutils
+ lfsmake2 --enable-toolchain ed
+ lfsmake2 --enable-toolchain findutils
+ lfsmake2 --enable-toolchain flex
+ lfsmake2 --enable-toolchain gawk
+ lfsmake2 --enable-toolchain go
+ lfsmake2 --enable-toolchain grep
+ lfsmake2 --enable-toolchain groff
+ lfsmake2 --enable-toolchain gperf
+ lfsmake2 --enable-toolchain gzip
+ lfsmake2 --enable-toolchain hostname
+ lfsmake2 --enable-toolchain whois
+ lfsmake2 --enable-toolchain kbd
+ lfsmake2 --enable-toolchain less
+ lfsmake2 --enable-toolchain procps
+ lfsmake2 --enable-toolchain make
+ lfsmake2 --enable-toolchain libpipeline
+ lfsmake2 --enable-toolchain man
+ lfsmake2 --enable-toolchain net-tools
+ lfsmake2 --enable-toolchain patch
+ lfsmake2 --enable-toolchain psmisc
+ lfsmake2 --enable-toolchain shadow
+ lfsmake2 --enable-toolchain sysklogd
+ lfsmake2 --enable-toolchain sysvinit
+ lfsmake2 --enable-toolchain tar
+ lfsmake2 --enable-toolchain texinfo
+ lfsmake2 --enable-toolchain util-linux
+ lfsmake2 --enable-toolchain vim
+ lfsmake2 --enable-toolchain e2fsprogs
+ lfsmake2 --enable-toolchain jq
+
+ # From here, build without having the toolchain available
lfsmake2 configroot
lfsmake2 initscripts
lfsmake2 backup
@@ -2038,7 +2067,7 @@ build_system() {
lfsmake2 mcelog
lfsmake2 socat
lfsmake2 libtpms
- lfsmake2 swtpm
+ lfsmake2 --enable-toolchain swtpm # requires expect from the toolchain
lfsmake2 libpciaccess
lfsmake2 ovmf
lfsmake2 libvirt
diff --git a/tools/execute.sh b/tools/execute.sh
index b3bf42f22..f77cea2bd 100755
--- a/tools/execute.sh
+++ b/tools/execute.sh
@@ -22,8 +22,22 @@
# This is a helper script that is called after we have created the new
# namespaces to perform further setup. This will be executed on the host.
-# Bring up the loopback interface
-ip link set lo up &>/dev/null
+set -euo pipefail
-# Execute the given command
-exec "$@"
+main() {
+ local r=0
+
+ # Bring up the loopback interface
+ ip link set lo up &>/dev/null
+
+ # Trap SIGINT & SIGTERM but actually don't do anything
+ trap "" SIGINT SIGTERM
+
+ # Execute the given command and save the return code
+ "$@" || r="${?}"
+
+ # Terminate with the code from the command
+ exit "${r}"
+}
+
+main "$@"
hooks/post-receive
--
IPFire 2.x development tree
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-10-29 11:05 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-10-29 11:05 [git.ipfire.org] IPFire 2.x development tree branch, next, updated. b35d097a0a65ed5cf893a5baacfeab7bbc47c2d1 Michael Tremer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox