From 96ec9981bbd23e402401c4e9912014498938fb57 Mon Sep 17 00:00:00 2001 From: Daniel Jacobowitz Date: Sun, 22 Jun 2003 15:21:39 +0000 Subject: [PATCH] * tui-hooks.c: Update include order. * tui.c: Likewise. * tuiCommand.c: Likewise. * tuiData.c: Likewise. * tuiDataWin.c: Likewise. * tuiDisassem.c: Likewise. * tuiGeneralWin.c: Likewise. * tuiIO.c: Likewise. * tuiLayout.c: Likewise. * tuiRegs.c: Likewise. * tuiSource.c: Likewise. * tuiSourceWin.c: Likewise. * tuiStack.c: Likewise. * tuiWin.c: Likewise. --- gdb/tui/ChangeLog | 17 +++++++++++++++++ gdb/tui/tui-hooks.c | 27 +++++++++------------------ gdb/tui/tui.c | 27 +++++++++------------------ gdb/tui/tuiCommand.c | 23 +++++++---------------- gdb/tui/tuiData.c | 21 ++++++--------------- gdb/tui/tuiDataWin.c | 21 ++++++--------------- gdb/tui/tuiDisassem.c | 27 +++++++++------------------ gdb/tui/tuiGeneralWin.c | 21 ++++++--------------- gdb/tui/tuiIO.c | 29 ++++++++++------------------- gdb/tui/tuiLayout.c | 27 +++++++++------------------ gdb/tui/tuiRegs.c | 27 +++++++++------------------ gdb/tui/tuiSource.c | 26 ++++++++------------------ gdb/tui/tuiSourceWin.c | 26 ++++++++------------------ gdb/tui/tuiStack.c | 26 ++++++++------------------ gdb/tui/tuiWin.c | 34 +++++++++++++--------------------- 15 files changed, 134 insertions(+), 245 deletions(-) diff --git a/gdb/tui/ChangeLog b/gdb/tui/ChangeLog index 79a3353e3d..9ab34614aa 100644 --- a/gdb/tui/ChangeLog +++ b/gdb/tui/ChangeLog @@ -1,3 +1,20 @@ +2003-06-22 Daniel Jacobowitz + + * tui-hooks.c: Update include order. + * tui.c: Likewise. + * tuiCommand.c: Likewise. + * tuiData.c: Likewise. + * tuiDataWin.c: Likewise. + * tuiDisassem.c: Likewise. + * tuiGeneralWin.c: Likewise. + * tuiIO.c: Likewise. + * tuiLayout.c: Likewise. + * tuiRegs.c: Likewise. + * tuiSource.c: Likewise. + * tuiSourceWin.c: Likewise. + * tuiStack.c: Likewise. + * tuiWin.c: Likewise. + 2003-06-12 Andreas Schwab * tuiSource.c (tuiVerticalSourceScroll): Use get_frame_pc. diff --git a/gdb/tui/tui-hooks.c b/gdb/tui/tui-hooks.c index 569ab078cf..e00ba85777 100644 --- a/gdb/tui/tui-hooks.c +++ b/gdb/tui/tui-hooks.c @@ -1,6 +1,6 @@ /* GDB hooks for TUI. - Copyright 2001, 2002 Free Software Foundation, Inc. + Copyright 2001, 2002, 2003 Free Software Foundation, Inc. This file is part of GDB. @@ -19,23 +19,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - #include "defs.h" #include "symtab.h" #include "inferior.h" @@ -66,6 +49,14 @@ #include "tuiDataWin.h" #include "tuiSourceWin.h" +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif + int tui_target_has_run = 0; static void (* tui_target_new_objfile_chain) (struct objfile*); diff --git a/gdb/tui/tui.c b/gdb/tui/tui.c index 517cf461cc..7e665d58a7 100644 --- a/gdb/tui/tui.c +++ b/gdb/tui/tui.c @@ -1,6 +1,6 @@ /* General functions for the WDB TUI. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,23 +22,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - #include #include #include @@ -70,6 +53,14 @@ #include "symtab.h" #include "source.h" +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif + /* Tells whether the TUI is active or not. */ int tui_active = 0; static int tui_finish_init = 1; diff --git a/gdb/tui/tuiCommand.c b/gdb/tui/tuiCommand.c index ca3d5318ea..675b34c544 100644 --- a/gdb/tui/tuiCommand.c +++ b/gdb/tui/tuiCommand.c @@ -1,6 +1,6 @@ /* Specific command window processing. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,15 +22,13 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ +#include "defs.h" +#include +#include "tui.h" +#include "tuiData.h" +#include "tuiWin.h" +#include "tuiIO.h" -#include "config.h" #ifdef HAVE_NCURSES_H #include #else @@ -39,13 +37,6 @@ #endif #endif -#include "defs.h" -#include -#include "tui.h" -#include "tuiData.h" -#include "tuiWin.h" -#include "tuiIO.h" - /***************************************** ** STATIC LOCAL FUNCTIONS FORWARD DECLS ** diff --git a/gdb/tui/tuiData.c b/gdb/tui/tuiData.c index 225583ea70..5acc33cc67 100644 --- a/gdb/tui/tuiData.c +++ b/gdb/tui/tuiData.c @@ -1,6 +1,6 @@ /* TUI data manipulation routines. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,15 +22,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ +#include "defs.h" +#include "symtab.h" +#include "tui.h" +#include "tuiData.h" +#include "tuiGeneralWin.h" -#include "config.h" #ifdef HAVE_NCURSES_H #include #else @@ -39,12 +36,6 @@ #endif #endif -#include "defs.h" -#include "symtab.h" -#include "tui.h" -#include "tuiData.h" -#include "tuiGeneralWin.h" - /**************************** ** GLOBAL DECLARATIONS ****************************/ diff --git a/gdb/tui/tuiDataWin.c b/gdb/tui/tuiDataWin.c index e729afc7f7..f3bedd2d6b 100644 --- a/gdb/tui/tuiDataWin.c +++ b/gdb/tui/tuiDataWin.c @@ -1,6 +1,6 @@ /* Data/register window display. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,15 +22,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ +#include "defs.h" +#include "tui.h" +#include "tuiData.h" +#include "tuiGeneralWin.h" +#include "tuiRegs.h" -#include "config.h" #ifdef HAVE_NCURSES_H #include #else @@ -39,12 +36,6 @@ #endif #endif -#include "defs.h" -#include "tui.h" -#include "tuiData.h" -#include "tuiGeneralWin.h" -#include "tuiRegs.h" - /***************************************** ** STATIC LOCAL FUNCTIONS FORWARD DECLS ** diff --git a/gdb/tui/tuiDisassem.c b/gdb/tui/tuiDisassem.c index a8668c4132..e36c5df521 100644 --- a/gdb/tui/tuiDisassem.c +++ b/gdb/tui/tuiDisassem.c @@ -1,6 +1,6 @@ /* Disassembly display. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,23 +22,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - #include "defs.h" #include "symtab.h" #include "breakpoint.h" @@ -55,6 +38,14 @@ #include "tuiStack.h" #include "tui-file.h" +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif + struct tui_asm_line { CORE_ADDR addr; diff --git a/gdb/tui/tuiGeneralWin.c b/gdb/tui/tuiGeneralWin.c index e250ca2ac7..42faf75628 100644 --- a/gdb/tui/tuiGeneralWin.c +++ b/gdb/tui/tuiGeneralWin.c @@ -1,6 +1,6 @@ /* General window behavior. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,15 +22,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ +#include "defs.h" +#include "tui.h" +#include "tuiData.h" +#include "tuiGeneralWin.h" +#include "tuiWin.h" -#include "config.h" #ifdef HAVE_NCURSES_H #include #else @@ -39,12 +36,6 @@ #endif #endif -#include "defs.h" -#include "tui.h" -#include "tuiData.h" -#include "tuiGeneralWin.h" -#include "tuiWin.h" - /*********************** ** PUBLIC FUNCTIONS ***********************/ diff --git a/gdb/tui/tuiIO.c b/gdb/tui/tuiIO.c index f53cef39d2..1a8bbc2037 100644 --- a/gdb/tui/tuiIO.c +++ b/gdb/tui/tuiIO.c @@ -1,6 +1,6 @@ /* TUI support I/O functions. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,24 +22,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - -#include #include "defs.h" #include "terminal.h" #include "target.h" @@ -59,6 +41,15 @@ #include "cli-out.h" #include #include +#include + +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif /* Use definition from readline 4.3. */ #undef CTRL_CHAR diff --git a/gdb/tui/tuiLayout.c b/gdb/tui/tuiLayout.c index cddbd14342..b79bfcb8c2 100644 --- a/gdb/tui/tuiLayout.c +++ b/gdb/tui/tuiLayout.c @@ -1,6 +1,6 @@ /* TUI layout window management. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,23 +22,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - #include "defs.h" #include "command.h" #include "symtab.h" @@ -56,6 +39,14 @@ #include "tuiSourceWin.h" #include "tuiDisassem.h" +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif + /******************************* ** Static Local Decls ********************************/ diff --git a/gdb/tui/tuiRegs.c b/gdb/tui/tuiRegs.c index 61b933444d..9f0b1a4d84 100644 --- a/gdb/tui/tuiRegs.c +++ b/gdb/tui/tuiRegs.c @@ -1,6 +1,6 @@ /* TUI display registers in window. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,23 +22,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - #include "defs.h" #include "tui.h" #include "tuiData.h" @@ -55,6 +38,14 @@ #include "tuiGeneralWin.h" #include "tui-file.h" +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif + /***************************************** ** LOCAL DEFINITIONS ** ******************************************/ diff --git a/gdb/tui/tuiSource.c b/gdb/tui/tuiSource.c index 68e7d9978d..6428130d78 100644 --- a/gdb/tui/tuiSource.c +++ b/gdb/tui/tuiSource.c @@ -1,6 +1,6 @@ /* TUI display source window. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,23 +22,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - #include "defs.h" #include #include "symtab.h" @@ -53,6 +36,13 @@ #include "tuiSourceWin.h" #include "tuiSource.h" +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif /* Function to display source in the source window. */ TuiStatus diff --git a/gdb/tui/tuiSourceWin.c b/gdb/tui/tuiSourceWin.c index cd52333c10..cf5a0793f6 100644 --- a/gdb/tui/tuiSourceWin.c +++ b/gdb/tui/tuiSourceWin.c @@ -1,6 +1,6 @@ /* TUI display source/assembly window. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,23 +22,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - #include "defs.h" #include #include "symtab.h" @@ -56,6 +39,13 @@ #include "tuiSource.h" #include "tuiDisassem.h" +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif /* Function to display the "main" routine. */ void diff --git a/gdb/tui/tuiStack.c b/gdb/tui/tuiStack.c index dca06189d8..a6ad07af1c 100644 --- a/gdb/tui/tuiStack.c +++ b/gdb/tui/tuiStack.c @@ -1,6 +1,6 @@ /* TUI display locator. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -22,23 +22,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - #include "defs.h" #include "symtab.h" #include "breakpoint.h" @@ -56,6 +39,13 @@ #include "tuiSourceWin.h" #include "tui-file.h" +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif /* Get a printable name for the function at the address. The symbol name is demangled if demangling is turned on. diff --git a/gdb/tui/tuiWin.c b/gdb/tui/tuiWin.c index 268562efa3..ecd4920601 100644 --- a/gdb/tui/tuiWin.c +++ b/gdb/tui/tuiWin.c @@ -1,6 +1,6 @@ /* TUI window generic functions. - Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, + Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. Contributed by Hewlett-Packard Company. @@ -27,26 +27,6 @@ Author: Susan B. Macchia */ -/* FIXME: cagney/2002-02-28: The GDB coding standard indicates that - "defs.h" should be included first. Unfortunatly some systems - (currently Debian GNU/Linux) include the via - and they clash with "bfd.h"'s definiton of true/false. The correct - fix is to remove true/false from "bfd.h", however, until that - happens, hack around it by including "config.h" and - first. */ - -#include "config.h" -#ifdef HAVE_NCURSES_H -#include -#else -#ifdef HAVE_CURSES_H -#include -#endif -#endif - -#include -#include -#include #include "defs.h" #include "command.h" #include "symtab.h" @@ -66,6 +46,18 @@ #include "tuiSourceWin.h" #include "tuiDataWin.h" +#ifdef HAVE_NCURSES_H +#include +#else +#ifdef HAVE_CURSES_H +#include +#endif +#endif + +#include +#include +#include + /******************************* ** Static Local Decls ********************************/ -- 2.34.1