1
0
mirror of https://github.com/systemd/systemd synced 2025-10-06 00:13:24 +02:00

mkosi: support the case /sbin/init is an absolute symbolic link

In that case, the link points to the host file, thus we cannot update
the file.
This commit is contained in:
Yu Watanabe
2025-09-14 12:13:20 +09:00
parent f8d5efc703
commit 97eeecaa3c

View File

@@ -3,6 +3,8 @@ set -e
# We don't use mkosi.extra because /usr/sbin could be a symlink and cp doesn't handle that properly until # We don't use mkosi.extra because /usr/sbin could be a symlink and cp doesn't handle that properly until
# coreutils 9.5 or newer. # coreutils 9.5 or newer.
mkdir -p "$BUILDROOT/sbin"
rm -f "$BUILDROOT/sbin/init"
cat >"$BUILDROOT/sbin/init" <<EOF cat >"$BUILDROOT/sbin/init" <<EOF
#!/bin/bash #!/bin/bash
echo "Hello from dummy init, beautiful day, innit?" echo "Hello from dummy init, beautiful day, innit?"