This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: GDB 6.8.92 available for testing
- From: Andreas Schwab <schwab at redhat dot com>
- To: Ralf Corsepius <ralf dot corsepius at rtems dot org>
- Cc: Joel Brobecker <brobecker at adacore dot com>, gdb at sourceware dot org, Jan Kratochvil <jan dot kratochvil at redhat dot com>, Tom Tromey <tromey at redhat dot com>, gdb-patches at gnu dot org
- Date: Thu, 01 Oct 2009 10:58:14 +0200
- Subject: Re: GDB 6.8.92 available for testing
- References: <20090930204828.GB31446@adacore.com> <4AC41F44.1040502@rtems.org>
Ralf Corsepius <ralf.corsepius@rtems.org> writes:
> --enable-system-readline also is still broken (Jan, please submit your
> gdb-readline-6.0.patch you have applied to Fedora's gdb).
Here is the patch I've been using for the openSUSE package. I have
renamed the uses of readline_echoing_p to _rl_echoing_p to emphasize its
internal nature (future readline versions may even stop exporting it).
Andreas.
2009-10-01 Andreas Schwab <schwab@redhat.com>
* tui/tui-io.c (tui_rl_display_match_list): Use _rl_echoing_p
instead of readline_echoing_p for version 6 or later of
libreadline.
--- gdb/tui/tui-io.c.orig 2009-03-10 11:34:01.000000000 +0100
+++ gdb/tui/tui-io.c 2009-03-10 11:34:45.000000000 +0100
@@ -512,8 +512,13 @@ tui_rl_display_match_list (char **matche
void
tui_setup_io (int mode)
{
+#if RL_VERSION_MAJOR >= 6
+ extern int _rl_echoing_p;
+#else
extern int readline_echoing_p;
-
+#define _rl_echoing_p readline_echoing_p
+#endif
+
if (mode)
{
/* Redirect readline to TUI. */
@@ -522,12 +527,12 @@ tui_setup_io (int mode)
tui_old_rl_prep_terminal = rl_prep_term_function;
tui_old_rl_getc_function = rl_getc_function;
tui_old_rl_outstream = rl_outstream;
- tui_old_readline_echoing_p = readline_echoing_p;
+ tui_old_readline_echoing_p = _rl_echoing_p;
rl_redisplay_function = tui_redisplay_readline;
rl_deprep_term_function = tui_deprep_terminal;
rl_prep_term_function = tui_prep_terminal;
rl_getc_function = tui_getc;
- readline_echoing_p = 0;
+ _rl_echoing_p = 0;
rl_outstream = tui_rl_outstream;
rl_prompt = 0;
rl_completion_display_matches_hook = tui_rl_display_match_list;
@@ -564,7 +569,7 @@ tui_setup_io (int mode)
rl_getc_function = tui_old_rl_getc_function;
rl_outstream = tui_old_rl_outstream;
rl_completion_display_matches_hook = 0;
- readline_echoing_p = tui_old_readline_echoing_p;
+ _rl_echoing_p = tui_old_readline_echoing_p;
rl_already_prompted = 0;
/* Save tty for SIGCONT. */
--
Andreas Schwab, schwab@redhat.com
GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 5EC7 45C6 250E 6F00 984E
"And now for something completely different."