* configure.in: Refine the previous change.
[deliverable/binutils-gdb.git] / gdb / configure.in
index 8cffe3df1c9bc0a9f06304fefadea4f7f0cc49f2..07a289fb00f8876cfe86b2a7b86e9b301fdf7e1f 100644 (file)
@@ -146,6 +146,15 @@ fi
 AC_SEARCH_LIBS(initscr, [ncurses Hcurses curses pdcurses], [],
     [AC_MSG_WARN([no curses library found])])
 
+# Check whether the wborder function is provided by the curses
+# library detected above.  In certain implementations such as
+# the HP/UX Hcurses for instance, this function is provided by an
+# additional library.  So if we did not find this function inside
+# the curses library, try some alternate libraries we know might
+# provide it.
+AC_SEARCH_LIBS(wborder, [cur_colr], [],
+    [AC_MSG_WARN([wborder function not found, tui will be disabled])])
+
 # Enable TUI.
 AC_ARG_ENABLE(tui,
 [  --enable-tui            enable full-screen terminal user interface (TUI)],
@@ -157,12 +166,16 @@ AC_ARG_ENABLE(tui,
   esac],enable_tui=yes)
 if test x"$enable_tui" = xyes; then
   if test -d $srcdir/tui; then
-    if test "$ac_cv_search_initscr" != no; then
+    if test "$ac_cv_search_initscr" != no -a "$ac_cv_search_wborder" != no; then
       CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
       CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
       CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
       CONFIG_INITS="$CONFIG_INITS \$(SUBDIR_TUI_INITS)"
       ENABLE_CFLAGS="$ENABLE_CFLAGS \$(SUBDIR_TUI_CFLAGS)"
+      CONFIG_ALL="${CONFIG_ALL} all-tui"
+      CONFIG_CLEAN="${CONFIG_CLEAN} clean-tui"
+      CONFIG_INSTALL="${CONFIG_INSTALL} install-tui"
+      CONFIG_UNINSTALL="${CONFIG_UNINSTALL} uninstall-tui"
     fi
   fi
 fi
This page took 0.023909 seconds and 4 git commands to generate.