aboutsummaryrefslogtreecommitdiffhomepage
path: root/cmd
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-11-07 21:43:34 +0900
committerOphestra <cat@gensokyo.uk>2026-11-07 21:43:34 +0900
commit085498b62ca37414d7c97fca9063526032c1f36e (patch)
treeb7b6a4a892a152636d1b0887d8d247367db5586f /cmd
parent1db0148a5087ed77c40440c1c9035dcc51b894e8 (diff)
cmd/earlyinit: make compatibility symlinks
Legacy software like the X server hardcodes a FHS path to the shell. Since Rosa OS does not mount over /, this has to be created during boot. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'cmd')
-rw-r--r--cmd/earlyinit/main.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/cmd/earlyinit/main.go b/cmd/earlyinit/main.go
index a7591af8..fff80bd8 100644
--- a/cmd/earlyinit/main.go
+++ b/cmd/earlyinit/main.go
@@ -274,6 +274,12 @@ func main() {
mustMountSystem(ctx, s, devpath)
}
+ // make legacy software (e.g. Xwayland) happy
+ must(os.Mkdir("/bin", 0555))
+ must(os.Symlink("../system/bin/sh", "/bin/sh"))
+ must(os.MkdirAll("/usr/bin", 0555))
+ must(os.Symlink("../../system/bin/env", "/usr/bin/env"))
+
if slices.Contains(flags, flag9P) {
// avoid having to wait for the uevent loop
modprobe("-a", "9p", "9pnet_virtio", "virtio_pci")