This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
[COMMIT] Fix TUI build on Ultrix
- From: Mark Kettenis <kettenis at gnu dot org>
- To: gdb-patches at sources dot redhat dot com
- Date: Sat, 25 Sep 2004 11:19:01 +0200 (CEST)
- Subject: [COMMIT] Fix TUI build on Ultrix
On Ultrix mvwaddstr is a macro, so the check failed. Also wborder()
is lacking, but box() is a suitable replacement, although it provides
a bit less control how things look.
Committed,
Mark
Index: ChangeLog
from Mark Kettenis <kettenis@gnu.org>
* configure.in: Check for waddstr instead of mvwaddstr when
searching for curses library. Check for wborder.
* configure, config.in: Regenerate.
* tui/tui-wingeneral.c (box_win): Use box if wborder isn't
available.
Index: configure.in
===================================================================
RCS file: /cvs/src/src/gdb/configure.in,v
retrieving revision 1.172
diff -u -p -r1.172 configure.in
--- configure.in 18 Sep 2004 18:45:55 -0000 1.172
+++ configure.in 25 Sep 2004 09:11:34 -0000
@@ -195,7 +195,7 @@ 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_mvwaddstr" != no; then
+ if test "$ac_cv_search_waddstr" != no; then
CONFIG_OBS="$CONFIG_OBS \$(SUBDIR_TUI_OBS)"
CONFIG_DEPS="$CONFIG_DEPS \$(SUBDIR_TUI_DEPS)"
CONFIG_SRCS="$CONFIG_SRCS \$(SUBDIR_TUI_SRCS)"
@@ -341,9 +341,9 @@ AC_SEARCH_LIBS(socketpair, socket)
# search /usr/local/include, if ncurses is installed in /usr/local. A
# default installation of ncurses on alpha*-dec-osf* will lead to such
# a situation.
-AC_SEARCH_LIBS(mvwaddstr, [ncurses cursesX curses])
+AC_SEARCH_LIBS(waddstr, [ncurses cursesX curses])
-if test "$ac_cv_search_mvwaddstr" = no; then
+if test "$ac_cv_search_waddstr" = no; then
AC_MSG_WARN([no curses library found])
fi
@@ -467,6 +467,7 @@ AC_CHECK_FUNCS(sigaction sigprocmask sig
AC_CHECK_FUNCS(socketpair)
AC_CHECK_FUNCS(syscall)
AC_CHECK_FUNCS(ttrace)
+AC_CHECK_FUNCS(wborder)
# Check the return and argument types of ptrace. No canned test for
# this, so roll our own.
Index: tui/tui-wingeneral.c
===================================================================
RCS file: /cvs/src/src/gdb/tui/tui-wingeneral.c,v
retrieving revision 1.8
diff -u -p -r1.8 tui-wingeneral.c
--- tui/tui-wingeneral.c 10 Feb 2004 19:08:19 -0000 1.8
+++ tui/tui-wingeneral.c 25 Sep 2004 09:11:35 -0000
@@ -94,10 +94,14 @@ box_win (struct tui_gen_win_info * win_i
attrs = tui_border_attrs;
wattron (win, attrs);
+#ifdef HAVE_WBORDER
wborder (win, tui_border_vline, tui_border_vline,
tui_border_hline, tui_border_hline,
tui_border_ulcorner, tui_border_urcorner,
tui_border_llcorner, tui_border_lrcorner);
+#else
+ box (win, tui_border_vline, tui_border_hline);
+#endif
if (win_info->title)
mvwaddstr (win, 0, 3, win_info->title);
wattroff (win, attrs);