Commit d9889e00 authored by Brad King's avatar Brad King
Browse files

Merge branch 'ncurses-tinfo' into release

parents 9cb46775 1f646c6c
......@@ -40,7 +40,7 @@ find_library(CURSES_CURSES_LIBRARY NAMES curses )
find_library(CURSES_NCURSES_LIBRARY NAMES ncurses )
set(CURSES_USE_NCURSES FALSE)
if(CURSES_NCURSES_LIBRARY AND NOT CURSES_CURSES_LIBRARY)
if(CURSES_NCURSES_LIBRARY AND ((NOT CURSES_CURSES_LIBRARY) OR CURSES_NEED_NCURSES))
set(CURSES_USE_NCURSES TRUE)
endif()
# http://cygwin.com/ml/cygwin-announce/2010-01/msg00002.html
......@@ -135,10 +135,20 @@ else()
CACHE FILEPATH "The curses library" ${FORCE_IT})
endif()
CHECK_LIBRARY_EXISTS("${CURSES_NCURSES_LIBRARY}"
cbreak "" CURSES_NCURSES_HAS_CBREAK)
if(NOT CURSES_NCURSES_HAS_CBREAK)
find_library(CURSES_EXTRA_LIBRARY tinfo HINTS "${_cursesLibDir}")
find_library(CURSES_EXTRA_LIBRARY tinfo )
CHECK_LIBRARY_EXISTS("${CURSES_EXTRA_LIBRARY}"
cbreak "" CURSES_TINFO_HAS_CBREAK)
endif()
endif()
find_library(CURSES_EXTRA_LIBRARY cur_colr HINTS "${_cursesLibDir}")
find_library(CURSES_EXTRA_LIBRARY cur_colr )
if (NOT CURSES_TINFO_HAS_CBREAK)
find_library(CURSES_EXTRA_LIBRARY cur_colr HINTS "${_cursesLibDir}")
find_library(CURSES_EXTRA_LIBRARY cur_colr )
endif()
find_library(CURSES_FORM_LIBRARY form HINTS "${_cursesLibDir}")
find_library(CURSES_FORM_LIBRARY form )
......@@ -182,5 +192,7 @@ mark_as_advanced(
CURSES_INCLUDE_DIR
CURSES_CURSES_HAS_WSYNCUP
CURSES_NCURSES_HAS_WSYNCUP
CURSES_NCURSES_HAS_CBREAK
CURSES_TINFO_HAS_CBREAK
)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment