interworking issue with native Windows, depending on terminfo
Takashi Yano
takashi.yano@nifty.ne.jp
Thu Oct 29 02:10:31 GMT 2026
Hi Thomas,
On Tue, 27 Oct 2026 11:32:13 +0100
Thomas Wolff wrote:
> Hi,
> please see
> https://github.com/microsoft/WSL/issues/42032#issuecomment-6432254350
> "cygwin is not providing the native process a proper console when the
> matching terminfo is missing".
>
> If terminfo is not present (e.g. /usr/share/terminfo/78/xterm, or
> xterm-new, or xterm-256color, whichever is set via $TERM), and you run
> wsl.exe, the WSL shell will be in non-interactive/non-pty mode, not show
> a prompt, not handle signals (so, e.g. ^C would exit WSL), etc.
> One use case would be a standalone application with cygwin bundled but
> not terminfo.
> While a standalone package developer will notice this and eventually
> also provide terminfo files, I don't see a logic connection that would
> make pty/console or whatever is missing here depend on terminfo.
wsl.exe needs ConPTY to work. ConPTY needs ESC sequences that are
supported by xterm, vt100, etc.
So cygwin1.dll checks whether the terminal has that capabilities using
terminfo, and if not, does not start ConPTY. In this case, the native
programs run in normal cygwin pty, which is just pipes for the native
programs. This is because wsl does not think it is running in terminal.
--
Takashi Yano <takashi.yano@nifty.ne.jp>
More information about the Cygwin-developers
mailing list