Skip to content
This repository has been archived by the owner on Sep 8, 2020. It is now read-only.

Mac - default OS X ncurses has wide-char support, but htop looks for ncursesw #301

Closed
edrozenberg opened this issue Nov 3, 2015 · 5 comments

Comments

@edrozenberg
Copy link

In Homebrew/legacy-homebrew#45197 Misty Demeo writes that the Mac's default ncurses does provide wide-char support, but since htop specifically looks for ncursesw, it requires an additional installation that should not be necessary. Pasting Misty's comments below:

"I think it should be possible to get unicode support enabled without a duplicate ncurses. OS X's ncurses does have wide-character support, even though it doesn't install an ncursesw; I see that htop's configure.ac just checks to see the library name, rather than for function availability, so it's mistakenly rejecting OS X's ncurses."

I'm not very knowledgeable about this issue myself so hoping the htop developers have a better sense of the meaning of all this :). It looks like Mac's default ncurses (as of OS X 10.11 at least) is version 5.x, whereas htop references ncurses version 6.x, not sure if this is relevant or not.

@edrozenberg
Copy link
Author

This issue is mainly relevant for the homebrew project - homebrew does not want any package to depend on installing duplicate libraries, such as having to install a second ncurses/ncursesw library when the Mac already ships with ncurses. Outside of homebrew it's not a problem - I installed a duplicate ncurses/ncursesw package and htop compiled fine with it.

@mdogan
Copy link

mdogan commented Nov 22, 2015

Looks like this issue is fixed by commit: 3471415

Htop is now compiling on OS X 10.11 without any additional dependency.

@edrozenberg
Copy link
Author

@mdogan Thanks for the heads up, confirmed that commit has fixed the issue, great news.

Confirmed via:

Uninstalled duplicate homebrew ncurses:

brew uninstall ncurses

Downloaded latest htop github source

Compiled latest github source:

./autogen.sh
./configure --enable-unicode
make

Compilation worked fine, no errors. The relevant config lines related to ncurses:

checking for addnwstr in -lncursesw6... no
checking for addnwstr in -lncursesw... no
checking for addnwstr in -lncurses... yes
checking ncursesw/curses.h usability... no
checking ncursesw/curses.h presence... no
checking for ncursesw/curses.h... no
checking ncurses/ncurses.h usability... no
checking ncurses/ncurses.h presence... no
checking for ncurses/ncurses.h... no
checking ncurses/curses.h usability... no
checking ncurses/curses.h presence... no
checking for ncurses/curses.h... no
checking ncurses.h usability... yes
checking ncurses.h presence... yes
checking for ncurses.h... yes

@skabashnyuk
Copy link

any plans for a new release?

@hishamhm
Copy link
Owner

@skabashnyuk, yes! my goal is to do it before the end of the year :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants