[gdb/build] Remove dependency on _rl_term_autowrap
commit14e61dbbbbb50e2b48834ba489942931514e7ff5
authorTom de Vries <tdevries@suse.de>
Sat, 16 Dec 2023 09:39:17 +0000 (16 10:39 +0100)
committerTom de Vries <tdevries@suse.de>
Sat, 16 Dec 2023 09:39:17 +0000 (16 10:39 +0100)
treea2edd6badb675373ce2b2657b67a276e438aca56
parent86a6f9a9fb112614c15cc17630b29fbc62d3bca5
[gdb/build] Remove dependency on _rl_term_autowrap

Commit deb1ba4e38b ("[gdb/tui] Fix TUI resizing for TERM=ansi") introduced a
dependency on readline private variable _rl_term_autowrap.

There is precedent for this, but it's something we want to get rid of
(PR build/10723).

Remove the dependency on _rl_term_autowrap, and instead calculate
readline_hidden_cols by comparing the environment variable COLS with cols as
returned by rl_get_screen_size.

Tested on x86_64-linux.

Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=10723
gdb/utils.c