logo

live-bootstrap

Mirror of <https://github.com/fosslinux/live-bootstrap>
commit: c64367f60885e94b1f494838fa6649c144d08a90
parent 07d4408fb6fde056147d0292b193543801ec3c6c
Author: fosslinux <fosslinux@aussies.space>
Date:   Fri, 14 Jan 2022 21:57:47 +1100

Merge /usr/sbin and /usr/bin

Required for some stupid build system (and is also better for us).

Diffstat:

Msysa/run.sh4+---
Msysa/util-linux-2.19.1/util-linux-2.19.1.sh6++----
Msysb/run.sh2--
Msysc/run.sh3+--
4 files changed, 4 insertions(+), 11 deletions(-)

diff --git a/sysa/run.sh b/sysa/run.sh @@ -14,14 +14,12 @@ set -e export PREFIX=/usr export SOURCES=/after -mkdir -p "${PREFIX}/sbin" -export PATH="${PREFIX}/bin:${PREFIX}/sbin" create_sysb() { # Copy everything in echo "Creating sysb rootfs" mkdir -p /sysb/usr - for d in bin include lib libexec sbin share; do + for d in bin include lib libexec share; do # Minimise RAM (storage) use - use hard links cp -rl "${PREFIX}/${d}" "/sysb/usr/${d}" done diff --git a/sysa/util-linux-2.19.1/util-linux-2.19.1.sh b/sysa/util-linux-2.19.1/util-linux-2.19.1.sh @@ -2,6 +2,7 @@ # # SPDX-License-Identifier: GPL-3.0-or-later + src_prepare() { default @@ -9,13 +10,10 @@ src_prepare() { AUTOPOINT=true autoreconf -fi } -# --target=i386-unknown-linux-gnu \ -# --host=i386-unknown-linux-gnu \ -# --build=i386-unknown-linux-gnu \ src_configure() { ./configure --prefix=${PREFIX} \ --bindir="${PREFIX}/bin" \ - --sbindir="${PREFIX}/sbin" \ + --sbindir="${PREFIX}/bin" \ --libdir="${PREFIX}/lib/musl" \ --disable-libuuid \ --without-ncurses \ diff --git a/sysb/run.sh b/sysb/run.sh @@ -11,8 +11,6 @@ set -e # shellcheck source=/dev/null . bootstrap.cfg -export PATH=/usr/bin:/usr/sbin - # Unload the current kernel before things go weird kexec -u diff --git a/sysc/run.sh b/sysc/run.sh @@ -22,9 +22,8 @@ create_fhs() { for d in bin lib sbin; do ln -s "usr/${d}" "/${d}" done - # Make sbin a symlink to bin mv /usr/sbin/* /usr/bin/ - rmdir /usr/sbin + rm -r /sbin /usr/sbin ln -s bin /usr/sbin ln -s bin /sbin mkdir /etc /proc /run /sys /tmp /var