summaryrefslogtreecommitdiff
path: root/Modules/FindCurses.cmake
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2008-04-30 15:42:48 -0400
committerBill Hoffman <bill.hoffman@kitware.com>2008-04-30 15:42:48 -0400
commite29ca248a39ae4b92c8ad600c2a6308954bd3895 (patch)
tree032849e2db676bb58fa968a81ae7c0d227caf26c /Modules/FindCurses.cmake
parenta56e04593adc014ade99af3417137f26195b08c4 (diff)
downloadcmake-e29ca248a39ae4b92c8ad600c2a6308954bd3895.tar.gz
BUG: fix for 6918 ncurses should work without curses
Diffstat (limited to 'Modules/FindCurses.cmake')
-rw-r--r--Modules/FindCurses.cmake6
1 files changed, 5 insertions, 1 deletions
diff --git a/Modules/FindCurses.cmake b/Modules/FindCurses.cmake
index cd170c1268..d64adfebf1 100644
--- a/Modules/FindCurses.cmake
+++ b/Modules/FindCurses.cmake
@@ -70,7 +70,11 @@ ELSE(NOT CURSES_USE_NCURSES)
FIND_PATH(CURSES_NCURSES_INCLUDE_PATH curses.h)
SET(CURSES_INCLUDE_PATH "${CURSES_NCURSES_INCLUDE_PATH}")
- SET(CURSES_LIBRARY "${CURSES_NCURSES_LIBRARY}" CACHE FILEPATH "path to curses")
+ SET(FORCE_ARG "");
+ IF("${CURSES_LIBRARY}" STREQUAL "CURSES_LIBRARY-NOTFOUND")
+ SET(FORCE_ARG "FORCE")
+ ENDIF("${CURSES_LIBRARY}" STREQUAL "CURSES_LIBRARY-NOTFOUND")
+ SET(CURSES_LIBRARY "${CURSES_NCURSES_LIBRARY}" CACHE FILEPATH "path to curses" ${FORCE_ARG})
ENDIF(NOT CURSES_USE_NCURSES)