]> git.ipfire.org Git - thirdparty/util-linux.git/commit
lib/colors: use libtinfo to check terminal capability
authorKarel Zak <kzak@redhat.com>
Fri, 27 Feb 2015 12:57:34 +0000 (13:57 +0100)
committerKarel Zak <kzak@redhat.com>
Fri, 27 Feb 2015 12:57:34 +0000 (13:57 +0100)
commit4310faf9507b863adf0d735564f28db5c68ca600
treee60620d3a69b9566e9e214cc316ccf2525bc116d
parentf5cd0f62314db4cdb5deb5a9a8421de88f042237
lib/colors: use libtinfo to check terminal capability

The current implementation assumes that all terminals supports colors
and users are forcet to use terminal-colors.d/ to disable colors for
some terminals.

This patch checks for maximal supported colors for the current
terminal and colors are automatically disabled for terminals like
vt100.

The patch moves lib/colors.c from libcommon.la to libtcolors.la to
avoid collisions with another utils.

Signed-off-by: Karel Zak <kzak@redhat.com>
configure.ac
disk-utils/Makemodule.am
lib/Makemodule.am
lib/colors.c
libsmartcols/src/Makemodule.am
misc-utils/Makemodule.am
sys-utils/Makemodule.am
text-utils/Makemodule.am