NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: segfault in libterminfo with ncurses with nethack



On Sat, 2 Sep 2023, Rhialto wrote:

The current variant which I have committed reads (comments stripped)

USE_NCURSES=            yes
.include "../../mk/curses.buildlink3.mk"
.  if "${CURSES_TYPE}" != "ncurses"
.    include "../../mk/termcap.buildlink3.mk"
.  endif
[...]

I switched to USE_NCURSES because pkglint says not to set PREFER.curses
in the package.

Testing with the other curses can be done by defanging the line
"USE_NCURSES=yes". So far I haven't been able to create a smaller test
case.


Should mk/curses.buildlink3.mk be used like this at all? The first para. in
that file states:

```
# This Makefile fragment is meant to be included by packages that require
# any curses implementation instead of one particular one.  The available
# curses implementations are "curses" if built-in, "ncurses", and
# "pdcurses".
#
# If a package genuinely requires ncurses or pdcurses, then it should
# directly include the appropriate buildlink3.mk instead of this file in
# the package Makefile.
```

That seems sensible. And, the next para. is:

```
# User-settable variables:
#
# CURSES_DEFAULT
#	This value represents the type of curses we wish to use on the
#	system.  Setting this to "curses" means that the system curses
#	implementation is fine.
#
#	Possible: curses, ncurses, ncursesw, pdcurses
#	Default: (depends)
```

So, if you use mk/curses.buildlink3.mk, one should set CURSES_DEFAULT=ncursesw
to compile with ncursesw.

-RVP


Home | Main Index | Thread Index | Old Index