setSet: Add ncurses to link-line if available
Resolves potential issue linking with readline on systems where readline has ncurses support enabled. Resolves bug-report https://bugs.openfoam.org/view.php?id=2642
This commit is contained in:
@ -6,14 +6,20 @@ cd ${0%/*} || exit 1 # Run from this directory
|
||||
|
||||
unset COMP_FLAGS LINK_FLAGS
|
||||
|
||||
#
|
||||
# use readline if available
|
||||
#
|
||||
# Use readline if available
|
||||
if [ -f /usr/include/readline/readline.h ]
|
||||
then
|
||||
echo " found <readline/readline.h> -- enabling readline support."
|
||||
export COMP_FLAGS="-DHAS_READLINE"
|
||||
export LINK_FLAGS="-lreadline"
|
||||
|
||||
# readline may require ncurses
|
||||
if [ -f /usr/include/ncurses/ncurses.h ]
|
||||
then
|
||||
echo " found <ncurses/ncurses.h> -- maybe required by readline."
|
||||
export LINK_FLAGS="-lreadline -lncurses"
|
||||
else
|
||||
export LINK_FLAGS="-lreadline"
|
||||
fi
|
||||
fi
|
||||
|
||||
wmake $targetType
|
||||
|
||||
Reference in New Issue
Block a user