Current-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Help with libcurses and lynx under NetBSD-9 and -current?
In article <alpine.NEB.2.22.394.2101270901410.7671%faeroes.freeshell.org@localhost>,
RVP <rvp%SDF.ORG@localhost> wrote:
>This might be due to the fact that window(1) relies on setting a
>custom TERMCAP environment variable to inform programs running
>under it of the term. capabilities it supports, and the curses
>library no longer makes use of that.
>
>With ncurses, building it with the `--enable-termcap' option
>makes it use the TERMCAP variable if it set in the environment.
>
>The ncurses(w) in pkgsrc is not built with that option, so, I
>compiled the latest ncurses from source with that option added
>and lynx -show_cursor worked just fine under window(1).
>
>-RVP
I think we can make our libterminfo do the same by shuffling a few ifdefs
around :-)
christos
Index: term.c
===================================================================
RCS file: /cvsroot/src/lib/libterminfo/term.c,v
retrieving revision 1.34
diff -u -u -r1.34 term.c
--- term.c 5 Apr 2020 14:53:39 -0000 1.34
+++ term.c 27 Jan 2021 17:51:27 -0000
@@ -368,7 +368,6 @@
return _ti_dbgetterm(term, e, name, flags);
c = NULL;
-#ifdef TERMINFO_COMPILE
if (e == NULL && (c = getenv("TERMCAP")) != NULL) {
if (*c != '\0' && *c != '/') {
c = strdup(c);
@@ -379,6 +378,10 @@
}
}
+#ifndef TERMINFO_COMPILE
+ if (e != NULL && *e == '/')
+ return _ti_dbgetterm(term, e, name, flags);
+#else
if (e != NULL) {
TIC *tic;
Home |
Main Index |
Thread Index |
Old Index