Skip to content

Create standard devices for command line runs#2724

Merged
tbodt merged 2 commits intoish-app:masterfrom
siraben:siraben/cli-standard-devices
May 3, 2026
Merged

Create standard devices for command line runs#2724
tbodt merged 2 commits intoish-app:masterfrom
siraben:siraben/cli-standard-devices

Conversation

@siraben
Copy link
Copy Markdown
Contributor

@siraben siraben commented Apr 27, 2026

Summary

Create standard /dev nodes during command-line emulator startup.

The iOS app startup already creates /dev/ptmx, but the CLI path only mounted
devpts at /dev/pts. Static i386 tmux could start and parse commands, but
failed when creating the first pane because forkpty could not open the pty
master:

create window failed: fork failed: No such file or directory

This moves the existing standard device-node setup into shared kernel init code
and calls it from both app and CLI startup. The CLI path now gets /dev/ptmx
before mounting devpts, without duplicating the app's /dev setup list.

Validation

  • ninja -C build
  • Removed /dev/ptmx from the Alpine test filesystem, then confirmed the
    rebuilt CLI emulator recreated it on startup.
  • Ran static i386 tmux in Alpine:
    • tmux -V
    • tmux -h
    • tmux -L final-smoke -f /dev/null new-session -d /bin/true

Comment thread kernel/init.c Outdated
Comment thread kernel/init.c Outdated
@tbodt
Copy link
Copy Markdown
Member

tbodt commented May 1, 2026

theoretically the correct solution is to create an implementation of devtmpfs instead of creating device nodes like this. (i don't think I knew about devtmpfs at the time)

@tbodt tbodt force-pushed the siraben/cli-standard-devices branch from f4787cf to 1b79c93 Compare May 3, 2026 15:08
@tbodt tbodt merged commit af9315a into ish-app:master May 3, 2026
6 checks passed
@siraben siraben deleted the siraben/cli-standard-devices branch May 3, 2026 16:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants