ports: ncurses, so zsh's line editor has a terminal to drive
zsh's configure will happily build without a terminal library -- the probe is AC_SEARCH_LIBS, which is soft -- and produce a shell whose cursor cannot move and whose arrow keys do nothing. ZLE is the reason to want zsh, so this comes first. MIT, so it combines with Apache-2.0 without conditions. Built static, widec (which is what zsh looks for first, and the console's UTF-8 decoder can already take), and --disable-database --with-fallbacks so seven terminal descriptions are compiled into the library. SchOS has no business shipping /usr/share/terminfo, and with the fallbacks the .a is self-contained: verified that no terminfo path strings survive in the binary. Nothing reaches sysroot/ -- a static library is not a file the OS ships -- so `install` means into $(PREFIX). port.mk gains NCURSES beside MUSL for the same reason MUSL is there. tinfotest.c is the acceptance test, and asks the question the build cannot: not "did it link" but "does terminfo work on a SchOS console". It reports TIOCGWINSZ, initialises from the compiled-in fallback, and names every capability ZLE binds. Anything MISSING there is a missing feature in the shell later. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VQ7Qx8E1q1M1bbCq8QLHS2
This commit is contained in:
parent
9d4cdb44fc
commit
d917798090
4 changed files with 246 additions and 2 deletions
|
|
@ -39,6 +39,11 @@ PREFIX := $(PORTDIR)/prefix
|
|||
# fixed location so ports don't need to know where musl's own source lives.
|
||||
MUSL := $(BUILDROOT)/musl/prefix
|
||||
|
||||
# ncurses is the second library other ports link against, so its prefix is
|
||||
# fixed for the same reason musl's is. Unlike every other port it installs
|
||||
# nothing into sysroot/ -- a static library is not a file the OS ships.
|
||||
NCURSES := $(BUILDROOT)/ncurses/prefix
|
||||
|
||||
CC := clang
|
||||
# FS register belongs to the kernel; never let the compiler touch %fs directly.
|
||||
CFLAGS_BT := -fno-stack-protector
|
||||
|
|
|
|||
Loading…
Reference in a new issue