From da59e08184255e09e51e54bb356e4448d33b2245 Mon Sep 17 00:00:00 2001 From: Jason Molenda Date: Tue, 1 Feb 2000 03:19:29 +0000 Subject: import gdb-2000-01-31 snapshot --- gdb/main.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) (limited to 'gdb/main.c') diff --git a/gdb/main.c b/gdb/main.c index 1eb36ae..7ccc47f 100644 --- a/gdb/main.c +++ b/gdb/main.c @@ -33,6 +33,11 @@ #include "gdb_string.h" #include "event-loop.h" +#if defined (TUI) || defined (GDBTK) +/* FIXME: cagney/2000-01-31: This #include is to allow older code such + as that found in the TUI to continue to build. */ +#include "tui/tui-file.h" +#endif /* If nonzero, display time usage both at startup and for each command. */ @@ -187,17 +192,19 @@ captured_main (void *data) getcwd (gdb_dirbuf, sizeof (gdb_dirbuf)); current_directory = gdb_dirbuf; -#if 0 - /* not yet */ - gdb_stdout = stdio_fileopen (stdout); - gdb_stderr = stdio_fileopen (stderr); - gdb_stdlog = gdb_stderr; /* for moment */ - gdb_stdtarg = gdb_stderr; /* for moment */ -#else +#if defined (TUI) || defined (GDBTK) + /* Older code uses the tui_file and fputs_unfiltered_hook(). It + should be using a customized GDB_FILE object and re-initializing + within its own _initialize function. */ gdb_stdout = tui_fileopen (stdout); gdb_stderr = tui_fileopen (stderr); gdb_stdlog = gdb_stdout; /* for moment */ gdb_stdtarg = gdb_stderr; /* for moment */ +#else + gdb_stdout = stdio_fileopen (stdout); + gdb_stderr = stdio_fileopen (stderr); + gdb_stdlog = gdb_stderr; /* for moment */ + gdb_stdtarg = gdb_stderr; /* for moment */ #endif /* initialize error() */ -- cgit v1.1