Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [PATCH 00/13] Include some headers in common-defs.h
@ 2014-07-29 15:11 Gary Benson
  2014-07-29 15:11 ` [PATCH 03/13] Move stdarg.h to common-defs.h Gary Benson
                   ` (14 more replies)
  0 siblings, 15 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:11 UTC (permalink / raw)
  To: gdb-patches

Hi all,

This series builds on my "config.h rationalization" series that is
currently under review [1].

Each patch adds one #include line to common-defs.h and removes all
other inclusions of that file in all files that include either defs.h
or server.h.  Patches 1-11 deal with files that are already included
by both defs.h and server.h; these patches don't really change
anything about the build.  Patches 12 and 13 add gdb_assert.h and
string.h respectively.  These are included by server.h but not by
defs.h, but both are included in hundreds of files so I think they
are good candidates for global inclusion.

There are three more files that are included by both defs.h and
server.h that I have not dealt with in this series.  errno.h and
alloca.h are both handled completely differently by defs.h and
server.h: moving these headers to common-defs.h should be done, but
will require merging the configury.  The final file, print-utils.h,
is included indirectly by both defs.h and server.h but cannot be
merged without some of the "Common code cleanups" series [2].  That
needs some rewriting, so I'll add that to common-defs.h as part of
the next version of that series.

Is this ok to commit?

Thanks,
Gary

--
[1] https://sourceware.org/ml/gdb-patches/2014-07/msg00670.html
[2] https://sourceware.org/ml/gdb-patches/2014-07/msg00427.html


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 03/13] Move stdarg.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
@ 2014-07-29 15:11 ` Gary Benson
  2014-07-29 15:11 ` [PATCH 13/13] Include string.h in common-defs.h Gary Benson
                   ` (13 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:11 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of stdarg.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include stdarg.h.
	* defs.h: Do not include stdarg.h.
	* ada-lang.c: Likewise.
	* common/common-utils.h: Likewise.
	* guile/scm-string.c: Likewise.
	* guile/scm-utils.c: Likewise.
	* m32c-tdep.c: Likewise.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include stdarg.h.
	* nto-low.c: Likewise.
---
 gdb/ChangeLog             |   10 ++++++++++
 gdb/ada-lang.c            |    1 -
 gdb/common/common-defs.h  |    1 +
 gdb/common/common-utils.h |    1 -
 gdb/defs.h                |    2 --
 gdb/gdbserver/ChangeLog   |    5 +++++
 gdb/gdbserver/nto-low.c   |    1 -
 gdb/gdbserver/server.h    |    1 -
 gdb/guile/scm-string.c    |    1 -
 gdb/guile/scm-utils.c     |    1 -
 gdb/m32c-tdep.c           |    3 ---
 11 files changed, 16 insertions(+), 11 deletions(-)

diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
index bf39f6b..5297fd3 100644
--- a/gdb/ada-lang.c
+++ b/gdb/ada-lang.c
@@ -21,7 +21,6 @@
 #include "defs.h"
 #include <string.h>
 #include <ctype.h>
-#include <stdarg.h>
 #include "demangle.h"
 #include "gdb_regex.h"
 #include "frame.h"
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index ed95a36..d227b00 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -29,5 +29,6 @@
 
 #include <stdio.h>
 #include <stdlib.h>
+#include <stdarg.h>
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/common/common-utils.h b/gdb/common/common-utils.h
index f052fed..dff7b53 100644
--- a/gdb/common/common-utils.h
+++ b/gdb/common/common-utils.h
@@ -22,7 +22,6 @@
 
 #include "ansidecl.h"
 #include <stddef.h>
-#include <stdarg.h>
 
 /* If possible, define FUNCTION_NAME, a macro containing the name of
    the function being defined.  Since this macro may not always be
diff --git a/gdb/defs.h b/gdb/defs.h
index 2e1e06b..00cb8e7 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -90,8 +90,6 @@
 #define O_BINARY 0
 #endif
 
-#include <stdarg.h>		/* For va_list.  */
-
 #include "libiberty.h"
 #include "hashtab.h"
 
diff --git a/gdb/gdbserver/nto-low.c b/gdb/gdbserver/nto-low.c
index 3587156..0afaec7 100644
--- a/gdb/gdbserver/nto-low.c
+++ b/gdb/gdbserver/nto-low.c
@@ -28,7 +28,6 @@
 #include <spawn.h>
 #include <sys/procfs.h>
 #include <sys/auxv.h>
-#include <stdarg.h>
 #include <sys/iomgr.h>
 #include <sys/neutrino.h>
 
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index a15ba36..9d7fd99 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -29,7 +29,6 @@
 #include "ansidecl.h"
 #include "version.h"
 
-#include <stdarg.h>
 #ifdef HAVE_ERRNO_H
 #include <errno.h>
 #endif
diff --git a/gdb/guile/scm-string.c b/gdb/guile/scm-string.c
index 3e3e015..975d198 100644
--- a/gdb/guile/scm-string.c
+++ b/gdb/guile/scm-string.c
@@ -21,7 +21,6 @@
    conventions, et.al.  */
 
 #include "defs.h"
-#include <stdarg.h>
 #include "charset.h"
 #include "guile-internal.h"
 
diff --git a/gdb/guile/scm-utils.c b/gdb/guile/scm-utils.c
index 5a17bd9..ada77a3 100644
--- a/gdb/guile/scm-utils.c
+++ b/gdb/guile/scm-utils.c
@@ -21,7 +21,6 @@
    conventions, et.al.  */
 
 #include "defs.h"
-#include <stdarg.h>
 #include <stdint.h>
 #include "gdb_assert.h"
 #include "guile-internal.h"
diff --git a/gdb/m32c-tdep.c b/gdb/m32c-tdep.c
index 2c7dbb8..88f17a9 100644
--- a/gdb/m32c-tdep.c
+++ b/gdb/m32c-tdep.c
@@ -18,9 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-
-#include <stdarg.h>
-
 #include <string.h>
 #include "gdb_assert.h"
 #include "elf-bfd.h"
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 12/13] Include gdb_assert.h in common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
  2014-07-29 15:11 ` [PATCH 03/13] Move stdarg.h to common-defs.h Gary Benson
  2014-07-29 15:11 ` [PATCH 13/13] Include string.h in common-defs.h Gary Benson
@ 2014-07-29 15:11 ` Gary Benson
  2014-07-29 15:11 ` [PATCH 02/13] Move stdlib.h to common-defs.h Gary Benson
                   ` (11 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:11 UTC (permalink / raw)
  To: gdb-patches

This commit includes gdb_assert.h in common-defs.h and removes all
other inclusions.

gdb/
2014-07-29  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include gdb_assert.h.
	* aarch64-tdep.c: Do not include gdb_assert.h.
	* addrmap.c: Likewise.
	* aix-thread.c: Likewise.
	* alpha-linux-tdep.c: Likewise.
	* alpha-mdebug-tdep.c: Likewise.
	* alphanbsd-tdep.c: Likewise.
	* amd64-nat.c: Likewise.
	* amd64-tdep.c: Likewise.
	* amd64bsd-nat.c: Likewise.
	* amd64fbsd-nat.c: Likewise.
	* amd64fbsd-tdep.c: Likewise.
	* amd64nbsd-nat.c: Likewise.
	* amd64nbsd-tdep.c: Likewise.
	* amd64obsd-nat.c: Likewise.
	* amd64obsd-tdep.c: Likewise.
	* arch-utils.c: Likewise.
	* arm-tdep.c: Likewise.
	* armbsd-tdep.c: Likewise.
	* auxv.c: Likewise.
	* bcache.c: Likewise.
	* bfin-tdep.c: Likewise.
	* blockframe.c: Likewise.
	* breakpoint.c: Likewise.
	* bsd-kvm.c: Likewise.
	* bsd-uthread.c: Likewise.
	* buildsym.c: Likewise.
	* c-exp.y: Likewise.
	* c-lang.c: Likewise.
	* charset.c: Likewise.
	* cleanups.c: Likewise.
	* cli-out.c: Likewise.
	* cli/cli-decode.c: Likewise.
	* cli/cli-dump.c: Likewise.
	* cli/cli-logging.c: Likewise.
	* cli/cli-script.c: Likewise.
	* cli/cli-utils.c: Likewise.
	* coffread.c: Likewise.
	* common/common-utils.c: Likewise.
	* common/queue.h: Likewise.
	* common/signals.c: Likewise.
	* common/vec.h: Likewise.
	* complaints.c: Likewise.
	* completer.c: Likewise.
	* corelow.c: Likewise.
	* cp-abi.c: Likewise.
	* cp-name-parser.y: Likewise.
	* cp-namespace.c: Likewise.
	* cp-support.c: Likewise.
	* cris-tdep.c: Likewise.
	* dbxread.c: Likewise.
	* dictionary.c: Likewise.
	* doublest.c: Likewise.
	* dsrec.c: Likewise.
	* dummy-frame.c: Likewise.
	* dwarf2-frame-tailcall.c: Likewise.
	* dwarf2-frame.c: Likewise.
	* dwarf2expr.c: Likewise.
	* dwarf2loc.c: Likewise.
	* dwarf2read.c: Likewise.
	* eval.c: Likewise.
	* event-loop.c: Likewise.
	* exceptions.c: Likewise.
	* expprint.c: Likewise.
	* f-valprint.c: Likewise.
	* fbsd-nat.c: Likewise.
	* findvar.c: Likewise.
	* frame-unwind.c: Likewise.
	* frame.c: Likewise.
	* frv-tdep.c: Likewise.
	* gcore.c: Likewise.
	* gdb-dlfcn.c: Likewise.
	* gdb_bfd.c: Likewise.
	* gdbarch.c: Likewise.
	* gdbarch.sh: Likewise.
	* gdbtypes.c: Likewise.
	* gnu-nat.c: Likewise.
	* gnu-v3-abi.c: Likewise.
	* go-lang.c: Likewise.
	* guile/scm-exception.c: Likewise.
	* guile/scm-gsmob.c: Likewise.
	* guile/scm-lazy-string.c: Likewise.
	* guile/scm-math.c: Likewise.
	* guile/scm-pretty-print.c: Likewise.
	* guile/scm-safe-call.c: Likewise.
	* guile/scm-utils.c: Likewise.
	* guile/scm-value.c: Likewise.
	* h8300-tdep.c: Likewise.
	* hppa-hpux-nat.c: Likewise.
	* hppa-tdep.c: Likewise.
	* hppanbsd-tdep.c: Likewise.
	* hppaobsd-tdep.c: Likewise.
	* i386-darwin-nat.c: Likewise.
	* i386-darwin-tdep.c: Likewise.
	* i386-nto-tdep.c: Likewise.
	* i386-tdep.c: Likewise.
	* i386bsd-nat.c: Likewise.
	* i386fbsd-tdep.c: Likewise.
	* i386gnu-nat.c: Likewise.
	* i386nbsd-tdep.c: Likewise.
	* i386obsd-tdep.c: Likewise.
	* i387-tdep.c: Likewise.
	* ia64-libunwind-tdep.c: Likewise.
	* ia64-tdep.c: Likewise.
	* inf-ptrace.c: Likewise.
	* inf-ttrace.c: Likewise.
	* infcall.c: Likewise.
	* infcmd.c: Likewise.
	* infrun.c: Likewise.
	* inline-frame.c: Likewise.
	* interps.c: Likewise.
	* jv-lang.c: Likewise.
	* jv-typeprint.c: Likewise.
	* linux-fork.c: Likewise.
	* linux-nat.c: Likewise.
	* linux-thread-db.c: Likewise.
	* m32c-tdep.c: Likewise.
	* m32r-linux-nat.c: Likewise.
	* m32r-tdep.c: Likewise.
	* m68k-tdep.c: Likewise.
	* m68kbsd-nat.c: Likewise.
	* m68kbsd-tdep.c: Likewise.
	* m88k-tdep.c: Likewise.
	* machoread.c: Likewise.
	* macroexp.c: Likewise.
	* macrotab.c: Likewise.
	* maint.c: Likewise.
	* mdebugread.c: Likewise.
	* memory-map.c: Likewise.
	* mep-tdep.c: Likewise.
	* mi/mi-common.c: Likewise.
	* microblaze-tdep.c: Likewise.
	* mingw-hdep.c: Likewise.
	* mips-linux-nat.c: Likewise.
	* mips-linux-tdep.c: Likewise.
	* mips-tdep.c: Likewise.
	* mips64obsd-tdep.c: Likewise.
	* mipsnbsd-tdep.c: Likewise.
	* mn10300-linux-tdep.c: Likewise.
	* mn10300-tdep.c: Likewise.
	* moxie-tdep.c: Likewise.
	* mt-tdep.c: Likewise.
	* nat/linux-btrace.c: Likewise.
	* nat/linux-osdata.c: Likewise.
	* nat/linux-ptrace.c: Likewise.
	* nat/mips-linux-watch.c: Likewise.
	* nios2-linux-tdep.c: Likewise.
	* nios2-tdep.c: Likewise.
	* objc-lang.c: Likewise.
	* objfiles.c: Likewise.
	* obsd-nat.c: Likewise.
	* opencl-lang.c: Likewise.
	* osabi.c: Likewise.
	* parse.c: Likewise.
	* ppc-linux-nat.c: Likewise.
	* ppc-sysv-tdep.c: Likewise.
	* ppcfbsd-nat.c: Likewise.
	* ppcfbsd-tdep.c: Likewise.
	* ppcnbsd-nat.c: Likewise.
	* ppcnbsd-tdep.c: Likewise.
	* ppcobsd-nat.c: Likewise.
	* ppcobsd-tdep.c: Likewise.
	* printcmd.c: Likewise.
	* procfs.c: Likewise.
	* prologue-value.c: Likewise.
	* psymtab.c: Likewise.
	* python/py-lazy-string.c: Likewise.
	* python/py-value.c: Likewise.
	* regcache.c: Likewise.
	* reggroups.c: Likewise.
	* registry.c: Likewise.
	* remote-sim.c: Likewise.
	* remote.c: Likewise.
	* rs6000-aix-tdep.c: Likewise.
	* rs6000-tdep.c: Likewise.
	* s390-linux-tdep.c: Likewise.
	* score-tdep.c: Likewise.
	* ser-base.c: Likewise.
	* ser-mingw.c: Likewise.
	* sh-tdep.c: Likewise.
	* sh64-tdep.c: Likewise.
	* solib-darwin.c: Likewise.
	* solib-spu.c: Likewise.
	* solib-svr4.c: Likewise.
	* source.c: Likewise.
	* sparc-nat.c: Likewise.
	* sparc-sol2-tdep.c: Likewise.
	* sparc-tdep.c: Likewise.
	* sparc64-sol2-tdep.c: Likewise.
	* sparc64-tdep.c: Likewise.
	* sparc64fbsd-tdep.c: Likewise.
	* sparc64nbsd-tdep.c: Likewise.
	* sparc64obsd-tdep.c: Likewise.
	* sparcnbsd-tdep.c: Likewise.
	* sparcobsd-tdep.c: Likewise.
	* spu-multiarch.c: Likewise.
	* spu-tdep.c: Likewise.
	* stabsread.c: Likewise.
	* stack.c: Likewise.
	* symfile.c: Likewise.
	* symtab.c: Likewise.
	* target-descriptions.c: Likewise.
	* target-memory.c: Likewise.
	* target.c: Likewise.
	* tic6x-linux-tdep.c: Likewise.
	* tic6x-tdep.c: Likewise.
	* tilegx-linux-nat.c: Likewise.
	* tilegx-tdep.c: Likewise.
	* top.c: Likewise.
	* tramp-frame.c: Likewise.
	* tui/tui-out.c: Likewise.
	* tui/tui-winsource.c: Likewise.
	* ui-out.c: Likewise.
	* user-regs.c: Likewise.
	* utils.c: Likewise.
	* v850-tdep.c: Likewise.
	* valops.c: Likewise.
	* value.c: Likewise.
	* varobj.c: Likewise.
	* vax-nat.c: Likewise.
	* xml-syscall.c: Likewise.
	* xml-tdesc.c: Likewise.
	* xstormy16-tdep.c: Likewise.
	* xtensa-linux-nat.c: Likewise.
	* xtensa-tdep.c: Likewise.

gdb/gdbserver/
2014-07-29  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include gdb_assert.h.
---
 gdb/ChangeLog                |  228 ++++++++++++++++++++++++++++++++++++++++++
 gdb/aarch64-tdep.c           |    1 -
 gdb/addrmap.c                |    2 -
 gdb/aix-thread.c             |    1 -
 gdb/alpha-linux-tdep.c       |    1 -
 gdb/alpha-mdebug-tdep.c      |    1 -
 gdb/alphanbsd-tdep.c         |    1 -
 gdb/amd64-nat.c              |    1 -
 gdb/amd64-tdep.c             |    1 -
 gdb/amd64bsd-nat.c           |    1 -
 gdb/amd64fbsd-nat.c          |    1 -
 gdb/amd64fbsd-tdep.c         |    1 -
 gdb/amd64nbsd-nat.c          |    2 -
 gdb/amd64nbsd-tdep.c         |    2 -
 gdb/amd64obsd-nat.c          |    2 -
 gdb/amd64obsd-tdep.c         |    1 -
 gdb/arch-utils.c             |    1 -
 gdb/arm-tdep.c               |    1 -
 gdb/armbsd-tdep.c            |    1 -
 gdb/auxv.c                   |    1 -
 gdb/bcache.c                 |    1 -
 gdb/bfin-tdep.c              |    1 -
 gdb/blockframe.c             |    1 -
 gdb/breakpoint.c             |    1 -
 gdb/bsd-kvm.c                |    1 -
 gdb/bsd-uthread.c            |    1 -
 gdb/buildsym.c               |    1 -
 gdb/c-exp.y                  |    1 -
 gdb/c-lang.c                 |    1 -
 gdb/charset.c                |    1 -
 gdb/cleanups.c               |    1 -
 gdb/cli-out.c                |    1 -
 gdb/cli/cli-decode.c         |    1 -
 gdb/cli/cli-dump.c           |    1 -
 gdb/cli/cli-logging.c        |    1 -
 gdb/cli/cli-script.c         |    1 -
 gdb/cli/cli-utils.c          |    1 -
 gdb/coffread.c               |    1 -
 gdb/common/common-defs.h     |    1 +
 gdb/common/common-utils.c    |    1 -
 gdb/common/queue.h           |    2 -
 gdb/common/signals.c         |    1 -
 gdb/common/vec.h             |    1 -
 gdb/complaints.c             |    1 -
 gdb/completer.c              |    1 -
 gdb/corelow.c                |    1 -
 gdb/cp-abi.c                 |    1 -
 gdb/cp-name-parser.y         |    1 -
 gdb/cp-namespace.c           |    1 -
 gdb/cp-support.c             |    1 -
 gdb/cris-tdep.c              |    1 -
 gdb/dbxread.c                |    2 -
 gdb/dictionary.c             |    1 -
 gdb/doublest.c               |    1 -
 gdb/dsrec.c                  |    1 -
 gdb/dummy-frame.c            |    1 -
 gdb/dwarf2-frame-tailcall.c  |    1 -
 gdb/dwarf2-frame.c           |    1 -
 gdb/dwarf2expr.c             |    1 -
 gdb/dwarf2loc.c              |    1 -
 gdb/dwarf2read.c             |    1 -
 gdb/eval.c                   |    3 -
 gdb/event-loop.c             |    1 -
 gdb/exceptions.c             |    1 -
 gdb/expprint.c               |    1 -
 gdb/f-valprint.c             |    1 -
 gdb/fbsd-nat.c               |    1 -
 gdb/findvar.c                |    1 -
 gdb/frame-unwind.c           |    1 -
 gdb/frame.c                  |    1 -
 gdb/frv-tdep.c               |    1 -
 gdb/gcore.c                  |    1 -
 gdb/gdb-dlfcn.c              |    2 -
 gdb/gdb_bfd.c                |    1 -
 gdb/gdbarch.c                |    1 -
 gdb/gdbarch.sh               |    1 -
 gdb/gdbserver/ChangeLog      |    4 +
 gdb/gdbserver/server.h       |    2 -
 gdb/gdbtypes.c               |    1 -
 gdb/gnu-nat.c                |    1 -
 gdb/gnu-v3-abi.c             |    1 -
 gdb/go-lang.c                |    1 -
 gdb/guile/scm-exception.c    |    1 -
 gdb/guile/scm-gsmob.c        |    1 -
 gdb/guile/scm-lazy-string.c  |    1 -
 gdb/guile/scm-math.c         |    1 -
 gdb/guile/scm-pretty-print.c |    1 -
 gdb/guile/scm-safe-call.c    |    1 -
 gdb/guile/scm-utils.c        |    1 -
 gdb/guile/scm-value.c        |    1 -
 gdb/h8300-tdep.c             |    1 -
 gdb/hppa-hpux-nat.c          |    1 -
 gdb/hppa-tdep.c              |    1 -
 gdb/hppanbsd-tdep.c          |    1 -
 gdb/hppaobsd-tdep.c          |    1 -
 gdb/i386-darwin-nat.c        |    1 -
 gdb/i386-darwin-tdep.c       |    1 -
 gdb/i386-nto-tdep.c          |    1 -
 gdb/i386-tdep.c              |    1 -
 gdb/i386bsd-nat.c            |    1 -
 gdb/i386fbsd-tdep.c          |    2 -
 gdb/i386gnu-nat.c            |    1 -
 gdb/i386nbsd-tdep.c          |    1 -
 gdb/i386obsd-tdep.c          |    1 -
 gdb/i387-tdep.c              |    1 -
 gdb/ia64-libunwind-tdep.c    |    1 -
 gdb/ia64-tdep.c              |    1 -
 gdb/inf-ptrace.c             |    1 -
 gdb/inf-ttrace.c             |    1 -
 gdb/infcall.c                |    1 -
 gdb/infcmd.c                 |    1 -
 gdb/infrun.c                 |    1 -
 gdb/inline-frame.c           |    2 -
 gdb/interps.c                |    1 -
 gdb/jv-lang.c                |    1 -
 gdb/jv-typeprint.c           |    1 -
 gdb/linux-fork.c             |    1 -
 gdb/linux-nat.c              |    1 -
 gdb/linux-thread-db.c        |    2 -
 gdb/m32c-tdep.c              |    1 -
 gdb/m32r-linux-nat.c         |    1 -
 gdb/m32r-tdep.c              |    2 -
 gdb/m68k-tdep.c              |    1 -
 gdb/m68kbsd-nat.c            |    1 -
 gdb/m68kbsd-tdep.c           |    1 -
 gdb/m88k-tdep.c              |    1 -
 gdb/machoread.c              |    1 -
 gdb/macroexp.c               |    1 -
 gdb/macrotab.c               |    1 -
 gdb/maint.c                  |    1 -
 gdb/mdebugread.c             |    1 -
 gdb/memory-map.c             |    1 -
 gdb/mep-tdep.c               |    2 -
 gdb/mi/mi-common.c           |    1 -
 gdb/microblaze-tdep.c        |    1 -
 gdb/mingw-hdep.c             |    1 -
 gdb/mips-linux-nat.c         |    1 -
 gdb/mips-linux-tdep.c        |    1 -
 gdb/mips-tdep.c              |    1 -
 gdb/mips64obsd-tdep.c        |    1 -
 gdb/mipsnbsd-tdep.c          |    1 -
 gdb/mn10300-linux-tdep.c     |    1 -
 gdb/mn10300-tdep.c           |    1 -
 gdb/moxie-tdep.c             |    2 -
 gdb/mt-tdep.c                |    1 -
 gdb/nat/linux-btrace.c       |    1 -
 gdb/nat/linux-osdata.c       |    1 -
 gdb/nat/linux-ptrace.c       |    1 -
 gdb/nat/mips-linux-watch.c   |    1 -
 gdb/nios2-linux-tdep.c       |    1 -
 gdb/nios2-tdep.c             |    1 -
 gdb/objc-lang.c              |    1 -
 gdb/objfiles.c               |    1 -
 gdb/obsd-nat.c               |    1 -
 gdb/opencl-lang.c            |    1 -
 gdb/osabi.c                  |    1 -
 gdb/parse.c                  |    1 -
 gdb/ppc-linux-nat.c          |    1 -
 gdb/ppc-sysv-tdep.c          |    1 -
 gdb/ppcfbsd-nat.c            |    1 -
 gdb/ppcfbsd-tdep.c           |    1 -
 gdb/ppcnbsd-nat.c            |    2 -
 gdb/ppcnbsd-tdep.c           |    1 -
 gdb/ppcobsd-nat.c            |    1 -
 gdb/ppcobsd-tdep.c           |    1 -
 gdb/printcmd.c               |    1 -
 gdb/procfs.c                 |    1 -
 gdb/prologue-value.c         |    1 -
 gdb/psymtab.c                |    1 -
 gdb/python/py-lazy-string.c  |    1 -
 gdb/python/py-value.c        |    1 -
 gdb/regcache.c               |    1 -
 gdb/reggroups.c              |    1 -
 gdb/registry.c               |    1 -
 gdb/remote-sim.c             |    1 -
 gdb/remote.c                 |    1 -
 gdb/rs6000-aix-tdep.c        |    1 -
 gdb/rs6000-tdep.c            |    1 -
 gdb/s390-linux-tdep.c        |    1 -
 gdb/score-tdep.c             |    1 -
 gdb/ser-base.c               |    1 -
 gdb/ser-mingw.c              |    1 -
 gdb/sh-tdep.c                |    1 -
 gdb/sh64-tdep.c              |    1 -
 gdb/solib-darwin.c           |    2 -
 gdb/solib-spu.c              |    1 -
 gdb/solib-svr4.c             |    2 -
 gdb/source.c                 |    1 -
 gdb/sparc-nat.c              |    1 -
 gdb/sparc-sol2-tdep.c        |    1 -
 gdb/sparc-tdep.c             |    1 -
 gdb/sparc64-sol2-tdep.c      |    2 -
 gdb/sparc64-tdep.c           |    1 -
 gdb/sparc64fbsd-tdep.c       |    1 -
 gdb/sparc64nbsd-tdep.c       |    1 -
 gdb/sparc64obsd-tdep.c       |    2 -
 gdb/sparcnbsd-tdep.c         |    1 -
 gdb/sparcobsd-tdep.c         |    2 -
 gdb/spu-multiarch.c          |    1 -
 gdb/spu-tdep.c               |    1 -
 gdb/stabsread.c              |    2 -
 gdb/stack.c                  |    1 -
 gdb/symfile.c                |    1 -
 gdb/symtab.c                 |    1 -
 gdb/target-descriptions.c    |    1 -
 gdb/target-memory.c          |    2 -
 gdb/target.c                 |    1 -
 gdb/tic6x-linux-tdep.c       |    1 -
 gdb/tic6x-tdep.c             |    1 -
 gdb/tilegx-linux-nat.c       |    1 -
 gdb/tilegx-tdep.c            |    1 -
 gdb/top.c                    |    1 -
 gdb/tramp-frame.c            |    1 -
 gdb/tui/tui-out.c            |    1 -
 gdb/tui/tui-winsource.c      |    1 -
 gdb/ui-out.c                 |    1 -
 gdb/user-regs.c              |    1 -
 gdb/utils.c                  |    1 -
 gdb/v850-tdep.c              |    1 -
 gdb/valops.c                 |    1 -
 gdb/value.c                  |    1 -
 gdb/varobj.c                 |    1 -
 gdb/vax-nat.c                |    1 -
 gdb/xml-syscall.c            |    2 -
 gdb/xml-tdesc.c              |    2 -
 gdb/xstormy16-tdep.c         |    1 -
 gdb/xtensa-linux-nat.c       |    1 -
 gdb/xtensa-tdep.c            |    1 -
 228 files changed, 233 insertions(+), 251 deletions(-)

diff --git a/gdb/aarch64-tdep.c b/gdb/aarch64-tdep.c
index 4abe36e..445d7b9 100644
--- a/gdb/aarch64-tdep.c
+++ b/gdb/aarch64-tdep.c
@@ -49,7 +49,6 @@
 #include "elf-bfd.h"
 #include "elf/aarch64.h"
 
-#include "gdb_assert.h"
 #include "vec.h"
 
 #include "features/aarch64.c"
diff --git a/gdb/addrmap.c b/gdb/addrmap.c
index c942c7b..a5db199 100644
--- a/gdb/addrmap.c
+++ b/gdb/addrmap.c
@@ -21,8 +21,6 @@
 #include "splay-tree.h"
 #include "gdb_obstack.h"
 #include "addrmap.h"
-#include "gdb_assert.h"
-
 
 \f
 /* The "abstract class".  */
diff --git a/gdb/aix-thread.c b/gdb/aix-thread.c
index 3865cba..1eb885b 100644
--- a/gdb/aix-thread.c
+++ b/gdb/aix-thread.c
@@ -40,7 +40,6 @@
      */
 
 #include "defs.h"
-#include "gdb_assert.h"
 #include "gdbthread.h"
 #include "target.h"
 #include "inferior.h"
diff --git a/gdb/alpha-linux-tdep.c b/gdb/alpha-linux-tdep.c
index 52f19d0..3d13a75 100644
--- a/gdb/alpha-linux-tdep.c
+++ b/gdb/alpha-linux-tdep.c
@@ -18,7 +18,6 @@
 
 #include "defs.h"
 #include "frame.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "osabi.h"
 #include "solib-svr4.h"
diff --git a/gdb/alpha-mdebug-tdep.c b/gdb/alpha-mdebug-tdep.c
index 8c29425..4cf0eb9 100644
--- a/gdb/alpha-mdebug-tdep.c
+++ b/gdb/alpha-mdebug-tdep.c
@@ -23,7 +23,6 @@
 #include "symtab.h"
 #include "gdbcore.h"
 #include "block.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "trad-frame.h"
 
diff --git a/gdb/alphanbsd-tdep.c b/gdb/alphanbsd-tdep.c
index 58d9f32..8e237c0 100644
--- a/gdb/alphanbsd-tdep.c
+++ b/gdb/alphanbsd-tdep.c
@@ -27,7 +27,6 @@
 #include "regset.h"
 #include "value.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "alpha-tdep.h"
diff --git a/gdb/amd64-nat.c b/gdb/amd64-nat.c
index 895f861..943f0ec 100644
--- a/gdb/amd64-nat.c
+++ b/gdb/amd64-nat.c
@@ -21,7 +21,6 @@
 #include "gdbarch.h"
 #include "regcache.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "i386-tdep.h"
diff --git a/gdb/amd64-tdep.c b/gdb/amd64-tdep.c
index 45ed97b..173451f 100644
--- a/gdb/amd64-tdep.c
+++ b/gdb/amd64-tdep.c
@@ -37,7 +37,6 @@
 #include "regset.h"
 #include "symfile.h"
 #include "disasm.h"
-#include "gdb_assert.h"
 #include "exceptions.h"
 #include "amd64-tdep.h"
 #include "i387-tdep.h"
diff --git a/gdb/amd64bsd-nat.c b/gdb/amd64bsd-nat.c
index c373a56..f994ec4 100644
--- a/gdb/amd64bsd-nat.c
+++ b/gdb/amd64bsd-nat.c
@@ -24,7 +24,6 @@
 
 /* We include <signal.h> to make sure `struct fxsave64' is defined on
    NetBSD, since NetBSD's <machine/reg.h> needs it.  */
-#include "gdb_assert.h"
 #include <signal.h>
 #include <sys/types.h>
 #include <sys/ptrace.h>
diff --git a/gdb/amd64fbsd-nat.c b/gdb/amd64fbsd-nat.c
index 3650bb5..fd189ec 100644
--- a/gdb/amd64fbsd-nat.c
+++ b/gdb/amd64fbsd-nat.c
@@ -22,7 +22,6 @@
 #include "regcache.h"
 #include "target.h"
 
-#include "gdb_assert.h"
 #include <signal.h>
 #include <sys/types.h>
 #include <sys/ptrace.h>
diff --git a/gdb/amd64fbsd-tdep.c b/gdb/amd64fbsd-tdep.c
index 627ebaf..6ecf20b 100644
--- a/gdb/amd64fbsd-tdep.c
+++ b/gdb/amd64fbsd-tdep.c
@@ -24,7 +24,6 @@
 #include "regcache.h"
 #include "osabi.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "amd64-tdep.h"
diff --git a/gdb/amd64nbsd-nat.c b/gdb/amd64nbsd-nat.c
index a31ee1d..8bce7ee 100644
--- a/gdb/amd64nbsd-nat.c
+++ b/gdb/amd64nbsd-nat.c
@@ -20,8 +20,6 @@
 #include "defs.h"
 #include "target.h"
 
-#include "gdb_assert.h"
-
 #include "nbsd-nat.h"
 #include "amd64-tdep.h"
 #include "amd64-nat.h"
diff --git a/gdb/amd64nbsd-tdep.c b/gdb/amd64nbsd-tdep.c
index ba67602..b48dcc8 100644
--- a/gdb/amd64nbsd-tdep.c
+++ b/gdb/amd64nbsd-tdep.c
@@ -24,8 +24,6 @@
 #include "osabi.h"
 #include "symtab.h"
 
-#include "gdb_assert.h"
-
 #include "amd64-tdep.h"
 #include "nbsd-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/amd64obsd-nat.c b/gdb/amd64obsd-nat.c
index 01253cb..6c43c62 100644
--- a/gdb/amd64obsd-nat.c
+++ b/gdb/amd64obsd-nat.c
@@ -22,8 +22,6 @@
 #include "regcache.h"
 #include "target.h"
 
-#include "gdb_assert.h"
-
 #include "amd64-tdep.h"
 #include "amd64-nat.h"
 #include "obsd-nat.h"
diff --git a/gdb/amd64obsd-tdep.c b/gdb/amd64obsd-tdep.c
index 5a5e209..4cb981f 100644
--- a/gdb/amd64obsd-tdep.c
+++ b/gdb/amd64obsd-tdep.c
@@ -29,7 +29,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "obsd-tdep.h"
diff --git a/gdb/arch-utils.c b/gdb/arch-utils.c
index d8da743..1772033 100644
--- a/gdb/arch-utils.c
+++ b/gdb/arch-utils.c
@@ -26,7 +26,6 @@
 #include "infrun.h"
 #include <string.h>
 #include "regcache.h"
-#include "gdb_assert.h"
 #include "sim-regno.h"
 #include "gdbcore.h"
 #include "osabi.h"
diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
index cb0030c..f9b9175 100644
--- a/gdb/arm-tdep.c
+++ b/gdb/arm-tdep.c
@@ -53,7 +53,6 @@
 #include "coff/internal.h"
 #include "elf/arm.h"
 
-#include "gdb_assert.h"
 #include "vec.h"
 
 #include "record.h"
diff --git a/gdb/armbsd-tdep.c b/gdb/armbsd-tdep.c
index 036db6c..b0c952b 100644
--- a/gdb/armbsd-tdep.c
+++ b/gdb/armbsd-tdep.c
@@ -22,7 +22,6 @@
 #include "regcache.h"
 #include "regset.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "arm-tdep.h"
diff --git a/gdb/auxv.c b/gdb/auxv.c
index 0f322e6..8710d2f 100644
--- a/gdb/auxv.c
+++ b/gdb/auxv.c
@@ -23,7 +23,6 @@
 #include "command.h"
 #include "inferior.h"
 #include "valprint.h"
-#include "gdb_assert.h"
 #include "gdbcore.h"
 #include "observer.h"
 #include "filestuff.h"
diff --git a/gdb/bcache.c b/gdb/bcache.c
index 44530bc..2adfcd4 100644
--- a/gdb/bcache.c
+++ b/gdb/bcache.c
@@ -23,7 +23,6 @@
 #include "gdb_obstack.h"
 #include "bcache.h"
 #include <string.h>		/* For memcpy declaration */
-#include "gdb_assert.h"
 
 /* The type used to hold a single bcache string.  The user data is
    stored in d.data.  Since it can be any type, it needs to have the
diff --git a/gdb/bfin-tdep.c b/gdb/bfin-tdep.c
index 3fa8173..2e5dbde 100644
--- a/gdb/bfin-tdep.c
+++ b/gdb/bfin-tdep.c
@@ -30,7 +30,6 @@
 #include "frame-base.h"
 #include "trad-frame.h"
 #include "dis-asm.h"
-#include "gdb_assert.h"
 #include "sim-regno.h"
 #include "gdb/sim-bfin.h"
 #include "dwarf2-frame.h"
diff --git a/gdb/blockframe.c b/gdb/blockframe.c
index 856b9ef..5de116e 100644
--- a/gdb/blockframe.c
+++ b/gdb/blockframe.c
@@ -29,7 +29,6 @@
 #include "inferior.h"
 #include "annotate.h"
 #include "regcache.h"
-#include "gdb_assert.h"
 #include "dummy-frame.h"
 #include "command.h"
 #include "gdbcmd.h"
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
index 262e992..2fde301 100644
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -48,7 +48,6 @@
 #include "gdb.h"
 #include "ui-out.h"
 #include "cli/cli-script.h"
-#include "gdb_assert.h"
 #include "block.h"
 #include "solib.h"
 #include "solist.h"
diff --git a/gdb/bsd-kvm.c b/gdb/bsd-kvm.c
index 35ecebb..b6e0c31 100644
--- a/gdb/bsd-kvm.c
+++ b/gdb/bsd-kvm.c
@@ -27,7 +27,6 @@
 #include "gdbcore.h"		/* for get_exec_file */
 #include "gdbthread.h"
 
-#include "gdb_assert.h"
 #include <fcntl.h>
 #include <kvm.h>
 #ifdef HAVE_NLIST_H
diff --git a/gdb/bsd-uthread.c b/gdb/bsd-uthread.c
index c73932a..817a14b 100644
--- a/gdb/bsd-uthread.c
+++ b/gdb/bsd-uthread.c
@@ -29,7 +29,6 @@
 #include "symfile.h"
 #include "target.h"
 
-#include "gdb_assert.h"
 #include "gdb_obstack.h"
 
 #include "bsd-uthread.h"
diff --git a/gdb/buildsym.c b/gdb/buildsym.c
index c49ed68..8fc7b75 100644
--- a/gdb/buildsym.c
+++ b/gdb/buildsym.c
@@ -30,7 +30,6 @@
 #include "symfile.h"
 #include "objfiles.h"
 #include "gdbtypes.h"
-#include "gdb_assert.h"
 #include "complaints.h"
 #include <string.h>
 #include "expression.h"		/* For "enum exp_opcode" used by...  */
diff --git a/gdb/c-exp.y b/gdb/c-exp.y
index 0708db3..714e02e 100644
--- a/gdb/c-exp.y
+++ b/gdb/c-exp.y
@@ -50,7 +50,6 @@
 #include "block.h"
 #include "cp-support.h"
 #include "dfp.h"
-#include "gdb_assert.h"
 #include "macroscope.h"
 #include "objc-lang.h"
 #include "typeprint.h"
diff --git a/gdb/c-lang.c b/gdb/c-lang.c
index 765a6b0..e647ff6 100644
--- a/gdb/c-lang.c
+++ b/gdb/c-lang.c
@@ -27,7 +27,6 @@
 #include "c-lang.h"
 #include "valprint.h"
 #include "macroscope.h"
-#include "gdb_assert.h"
 #include "charset.h"
 #include <string.h>
 #include "demangle.h"
diff --git a/gdb/charset.c b/gdb/charset.c
index 3e7a85c..c1c1405 100644
--- a/gdb/charset.c
+++ b/gdb/charset.c
@@ -20,7 +20,6 @@
 #include "defs.h"
 #include "charset.h"
 #include "gdbcmd.h"
-#include "gdb_assert.h"
 #include "gdb_obstack.h"
 #include "gdb_wait.h"
 #include "charset-list.h"
diff --git a/gdb/cleanups.c b/gdb/cleanups.c
index e5291ab..ddf8e5b 100644
--- a/gdb/cleanups.c
+++ b/gdb/cleanups.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include "gdb_assert.h"
 
 /* The cleanup list records things that have to be undone
    if an error happens (descriptors to be closed, memory to be freed, etc.)
diff --git a/gdb/cli-out.c b/gdb/cli-out.c
index eedbd2c..5435385 100644
--- a/gdb/cli-out.c
+++ b/gdb/cli-out.c
@@ -24,7 +24,6 @@
 #include "ui-out.h"
 #include "cli-out.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "vec.h"
 
 typedef struct cli_ui_out_data cli_out_data;
diff --git a/gdb/cli/cli-decode.c b/gdb/cli/cli-decode.c
index 819aea8..43e1bab 100644
--- a/gdb/cli/cli-decode.c
+++ b/gdb/cli/cli-decode.c
@@ -24,7 +24,6 @@
 #include "ui-out.h"
 #include "cli/cli-cmds.h"
 #include "cli/cli-decode.h"
-#include "gdb_assert.h"
 
 /* Prototypes for local functions.  */
 
diff --git a/gdb/cli/cli-dump.c b/gdb/cli/cli-dump.c
index 7929dc1..b643be4 100644
--- a/gdb/cli/cli-dump.c
+++ b/gdb/cli/cli-dump.c
@@ -25,7 +25,6 @@
 #include "cli/cli-cmds.h"
 #include "value.h"
 #include "completer.h"
-#include "gdb_assert.h"
 #include <ctype.h>
 #include "target.h"
 #include "readline/readline.h"
diff --git a/gdb/cli/cli-logging.c b/gdb/cli/cli-logging.c
index aae0039..3b1447a 100644
--- a/gdb/cli/cli-logging.c
+++ b/gdb/cli/cli-logging.c
@@ -21,7 +21,6 @@
 #include "gdbcmd.h"
 #include "ui-out.h"
 #include "interps.h"
-#include "gdb_assert.h"
 
 #include <string.h>
 
diff --git a/gdb/cli/cli-script.c b/gdb/cli/cli-script.c
index fbcc2dd..d3ca9ec 100644
--- a/gdb/cli/cli-script.c
+++ b/gdb/cli/cli-script.c
@@ -30,7 +30,6 @@
 #include "cli/cli-cmds.h"
 #include "cli/cli-decode.h"
 #include "cli/cli-script.h"
-#include "gdb_assert.h"
 
 #include "extension.h"
 #include "interps.h"
diff --git a/gdb/cli/cli-utils.c b/gdb/cli/cli-utils.c
index a0ebc11..3deac36 100644
--- a/gdb/cli/cli-utils.c
+++ b/gdb/cli/cli-utils.c
@@ -21,7 +21,6 @@
 #include "cli/cli-utils.h"
 #include <string.h>
 #include "value.h"
-#include "gdb_assert.h"
 
 #include <ctype.h>
 
diff --git a/gdb/coffread.c b/gdb/coffread.c
index c650d61..9cbe173 100644
--- a/gdb/coffread.c
+++ b/gdb/coffread.c
@@ -37,7 +37,6 @@
 #include "stabsread.h"
 #include "complaints.h"
 #include "target.h"
-#include "gdb_assert.h"
 #include "block.h"
 #include "dictionary.h"
 
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 6a031ec..75a587a 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -38,5 +38,6 @@
 #include "gdb_locale.h"
 #include "ptid.h"
 #include "common-utils.h"
+#include "gdb_assert.h"
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/common/common-utils.c b/gdb/common/common-utils.c
index ab05c9f..3fe9bf9 100644
--- a/gdb/common/common-utils.c
+++ b/gdb/common/common-utils.c
@@ -23,7 +23,6 @@
 #include "defs.h"
 #endif
 
-#include "gdb_assert.h"
 #include <string.h>
 
 /* The xmalloc() (libiberty.h) family of memory management routines.
diff --git a/gdb/common/queue.h b/gdb/common/queue.h
index 34e4db3..7353b27 100644
--- a/gdb/common/queue.h
+++ b/gdb/common/queue.h
@@ -20,8 +20,6 @@
 #ifndef QUEUE_H
 #define QUEUE_H
 
-#include "gdb_assert.h"
-
 /* These macros implement functions and structs for a general queue.
    Macro 'DEFINE_QUEUE_P(TYPEDEF)' is to define the new queue type for
    TYPEDEF', and macro 'DECLARE_QUEUE_P' is to declare external queue
diff --git a/gdb/common/signals.c b/gdb/common/signals.c
index 3c9cd41..d9cacee 100644
--- a/gdb/common/signals.c
+++ b/gdb/common/signals.c
@@ -29,7 +29,6 @@
 #endif
 
 #include "gdb_signals.h"
-#include "gdb_assert.h"
 
 struct gdbarch;
 
diff --git a/gdb/common/vec.h b/gdb/common/vec.h
index 2a39eff..82d4b0d 100644
--- a/gdb/common/vec.h
+++ b/gdb/common/vec.h
@@ -21,7 +21,6 @@
 #define GDB_VEC_H
 
 #include <string.h>
-#include "gdb_assert.h"
 
 /* The macros here implement a set of templated vector types and
    associated interfaces.  These templates are implemented with
diff --git a/gdb/complaints.c b/gdb/complaints.c
index 92a3ef6..704c681 100644
--- a/gdb/complaints.c
+++ b/gdb/complaints.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "complaints.h"
-#include "gdb_assert.h"
 #include "command.h"
 #include "gdbcmd.h"
 
diff --git a/gdb/completer.c b/gdb/completer.c
index 64b146b..44920dd 100644
--- a/gdb/completer.c
+++ b/gdb/completer.c
@@ -22,7 +22,6 @@
 #include "expression.h"
 #include "filenames.h"		/* For DOSish file names.  */
 #include "language.h"
-#include "gdb_assert.h"
 #include "exceptions.h"
 #include "gdb_signals.h"
 
diff --git a/gdb/corelow.c b/gdb/corelow.c
index 0a066f4..650b67c 100644
--- a/gdb/corelow.c
+++ b/gdb/corelow.c
@@ -40,7 +40,6 @@
 #include "symfile.h"
 #include "exec.h"
 #include "readline/readline.h"
-#include "gdb_assert.h"
 #include "exceptions.h"
 #include "solib.h"
 #include "filenames.h"
diff --git a/gdb/cp-abi.c b/gdb/cp-abi.c
index 0bde1c5..c1a0d29 100644
--- a/gdb/cp-abi.c
+++ b/gdb/cp-abi.c
@@ -24,7 +24,6 @@
 #include "exceptions.h"
 #include "gdbcmd.h"
 #include "ui-out.h"
-#include "gdb_assert.h"
 #include <string.h>
 
 static struct cp_abi_ops *find_cp_abi (const char *short_name);
diff --git a/gdb/cp-name-parser.y b/gdb/cp-name-parser.y
index 0caadfa..a0b7f8b 100644
--- a/gdb/cp-name-parser.y
+++ b/gdb/cp-name-parser.y
@@ -37,7 +37,6 @@
 #include "safe-ctype.h"
 #include "demangle.h"
 #include "cp-support.h"
-#include "gdb_assert.h"
 
 /* Bison does not make it easy to create a parser without global
    state, unfortunately.  Here are all the global variables used
diff --git a/gdb/cp-namespace.c b/gdb/cp-namespace.c
index cd57399..c6e1102 100644
--- a/gdb/cp-namespace.c
+++ b/gdb/cp-namespace.c
@@ -23,7 +23,6 @@
 #include "gdb_obstack.h"
 #include "symtab.h"
 #include "symfile.h"
-#include "gdb_assert.h"
 #include "block.h"
 #include "objfiles.h"
 #include "gdbtypes.h"
diff --git a/gdb/cp-support.c b/gdb/cp-support.c
index 5464117..f1dfcfa 100644
--- a/gdb/cp-support.c
+++ b/gdb/cp-support.c
@@ -22,7 +22,6 @@
 #include "cp-support.h"
 #include <string.h>
 #include "demangle.h"
-#include "gdb_assert.h"
 #include "gdbcmd.h"
 #include "dictionary.h"
 #include "objfiles.h"
diff --git a/gdb/cris-tdep.c b/gdb/cris-tdep.c
index 6861e2b..909a227 100644
--- a/gdb/cris-tdep.c
+++ b/gdb/cris-tdep.c
@@ -37,7 +37,6 @@
 #include "osabi.h"
 #include "arch-utils.h"
 #include "regcache.h"
-#include "gdb_assert.h"
 
 #include "objfiles.h"
 
diff --git a/gdb/dbxread.c b/gdb/dbxread.c
index 5171f50..1807094 100644
--- a/gdb/dbxread.c
+++ b/gdb/dbxread.c
@@ -57,8 +57,6 @@
 #include "psympriv.h"
 #include "block.h"
 
-#include "gdb_assert.h"
-
 #include "aout/aout64.h"
 #include "aout/stab_gnu.h"	/* We always use GNU stabs, not
 				   native, now.  */
diff --git a/gdb/dictionary.c b/gdb/dictionary.c
index a24789a..055c87e 100644
--- a/gdb/dictionary.c
+++ b/gdb/dictionary.c
@@ -25,7 +25,6 @@
 #include "gdb_obstack.h"
 #include "symtab.h"
 #include "buildsym.h"
-#include "gdb_assert.h"
 #include "dictionary.h"
 
 /* This file implements dictionaries, which are tables that associate
diff --git a/gdb/doublest.c b/gdb/doublest.c
index a6c11d8..bd4ca6e 100644
--- a/gdb/doublest.c
+++ b/gdb/doublest.c
@@ -26,7 +26,6 @@
 #include "defs.h"
 #include "doublest.h"
 #include "floatformat.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "gdbtypes.h"
 #include <math.h>		/* ldexp */
diff --git a/gdb/dsrec.c b/gdb/dsrec.c
index b782186..c9f8636 100644
--- a/gdb/dsrec.c
+++ b/gdb/dsrec.c
@@ -21,7 +21,6 @@
 #include "srec.h"
 #include <sys/time.h>
 #include <time.h>
-#include "gdb_assert.h"
 #include <string.h>
 #include "gdb_bfd.h"
 
diff --git a/gdb/dummy-frame.c b/gdb/dummy-frame.c
index 35d78e9..d547a63 100644
--- a/gdb/dummy-frame.c
+++ b/gdb/dummy-frame.c
@@ -23,7 +23,6 @@
 #include "regcache.h"
 #include "frame.h"
 #include "inferior.h"
-#include "gdb_assert.h"
 #include "frame-unwind.h"
 #include "command.h"
 #include "gdbcmd.h"
diff --git a/gdb/dwarf2-frame-tailcall.c b/gdb/dwarf2-frame-tailcall.c
index dd69d94..bce4c60 100644
--- a/gdb/dwarf2-frame-tailcall.c
+++ b/gdb/dwarf2-frame-tailcall.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include "gdb_assert.h"
 #include "frame.h"
 #include "dwarf2-frame-tailcall.h"
 #include "dwarf2loc.h"
diff --git a/gdb/dwarf2-frame.c b/gdb/dwarf2-frame.c
index 3e3ba23..01e0670 100644
--- a/gdb/dwarf2-frame.c
+++ b/gdb/dwarf2-frame.c
@@ -33,7 +33,6 @@
 #include "value.h"
 #include "record.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "complaints.h"
diff --git a/gdb/dwarf2expr.c b/gdb/dwarf2expr.c
index 36c9f66..1d39923 100644
--- a/gdb/dwarf2expr.c
+++ b/gdb/dwarf2expr.c
@@ -26,7 +26,6 @@
 #include "gdbcore.h"
 #include "dwarf2.h"
 #include "dwarf2expr.h"
-#include "gdb_assert.h"
 
 /* Local prototypes.  */
 
diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
index b1c7ee1..8f050b8 100644
--- a/gdb/dwarf2loc.c
+++ b/gdb/dwarf2loc.c
@@ -40,7 +40,6 @@
 #include "dwarf2-frame.h"
 
 #include <string.h>
-#include "gdb_assert.h"
 
 extern int dwarf2_always_disassemble;
 
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
index 276d2f1..cb1bd3a 100644
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -73,7 +73,6 @@
 
 #include <fcntl.h>
 #include <string.h>
-#include "gdb_assert.h"
 #include <sys/types.h>
 
 typedef struct symbol *symbolp;
diff --git a/gdb/eval.c b/gdb/eval.c
index 5e64e54..b375850 100644
--- a/gdb/eval.c
+++ b/gdb/eval.c
@@ -40,9 +40,6 @@
 #include "valprint.h"
 #include "gdb_obstack.h"
 #include "objfiles.h"
-
-#include "gdb_assert.h"
-
 #include <ctype.h>
 
 /* This is defined in valops.c */
diff --git a/gdb/event-loop.c b/gdb/event-loop.c
index 5999c97..221dfbc 100644
--- a/gdb/event-loop.c
+++ b/gdb/event-loop.c
@@ -35,7 +35,6 @@
 #include <errno.h>
 #include <sys/time.h>
 #include "exceptions.h"
-#include "gdb_assert.h"
 #include "gdb_select.h"
 #include "observer.h"
 
diff --git a/gdb/exceptions.c b/gdb/exceptions.c
index ddaf250..4efc888 100644
--- a/gdb/exceptions.c
+++ b/gdb/exceptions.c
@@ -24,7 +24,6 @@
 #include "inferior.h"
 #include "annotate.h"
 #include "ui-out.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "serial.h"
 #include "gdbthread.h"
diff --git a/gdb/expprint.c b/gdb/expprint.c
index 7f58e4e..0f87033 100644
--- a/gdb/expprint.c
+++ b/gdb/expprint.c
@@ -29,7 +29,6 @@
 #include <string.h>
 #include "block.h"
 #include "objfiles.h"
-#include "gdb_assert.h"
 #include "valprint.h"
 
 #include <ctype.h>
diff --git a/gdb/f-valprint.c b/gdb/f-valprint.c
index 408c8cc..728bdaf 100644
--- a/gdb/f-valprint.c
+++ b/gdb/f-valprint.c
@@ -34,7 +34,6 @@
 #include "command.h"
 #include "block.h"
 #include "dictionary.h"
-#include "gdb_assert.h"
 #include "exceptions.h"
 
 extern void _initialize_f_valprint (void);
diff --git a/gdb/fbsd-nat.c b/gdb/fbsd-nat.c
index 4e115b2..e4b34f6 100644
--- a/gdb/fbsd-nat.c
+++ b/gdb/fbsd-nat.c
@@ -24,7 +24,6 @@
 #include "regset.h"
 #include "gdbthread.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 #include <sys/types.h>
 #include <sys/procfs.h>
diff --git a/gdb/findvar.c b/gdb/findvar.c
index 9390c8a..465c9cc 100644
--- a/gdb/findvar.c
+++ b/gdb/findvar.c
@@ -26,7 +26,6 @@
 #include "inferior.h"
 #include "target.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "floatformat.h"
 #include "symfile.h"		/* for overlay functions */
 #include "regcache.h"
diff --git a/gdb/frame-unwind.c b/gdb/frame-unwind.c
index fdfea6e..ebc01ff 100644
--- a/gdb/frame-unwind.c
+++ b/gdb/frame-unwind.c
@@ -25,7 +25,6 @@
 #include "value.h"
 #include "regcache.h"
 #include "exceptions.h"
-#include "gdb_assert.h"
 #include "gdb_obstack.h"
 #include "target.h"
 
diff --git a/gdb/frame.c b/gdb/frame.c
index 8a2b8bf..9d8c8b7 100644
--- a/gdb/frame.c
+++ b/gdb/frame.c
@@ -23,7 +23,6 @@
 #include "value.h"
 #include "inferior.h"	/* for inferior_ptid */
 #include "regcache.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "user-regs.h"
 #include "gdb_obstack.h"
diff --git a/gdb/frv-tdep.c b/gdb/frv-tdep.c
index bd4dbdb..349e58d 100644
--- a/gdb/frv-tdep.c
+++ b/gdb/frv-tdep.c
@@ -28,7 +28,6 @@
 #include "frame-base.h"
 #include "trad-frame.h"
 #include "dis-asm.h"
-#include "gdb_assert.h"
 #include "sim-regno.h"
 #include "gdb/sim-frv.h"
 #include "opcodes/frv-desc.h"	/* for the H_SPR_... enums */
diff --git a/gdb/gcore.c b/gdb/gcore.c
index 13be346..d2adfc8 100644
--- a/gdb/gcore.c
+++ b/gdb/gcore.c
@@ -29,7 +29,6 @@
 #include "completer.h"
 #include "gcore.h"
 #include "cli/cli-decode.h"
-#include "gdb_assert.h"
 #include <fcntl.h>
 #include "regcache.h"
 #include "regset.h"
diff --git a/gdb/gdb-dlfcn.c b/gdb/gdb-dlfcn.c
index a808959..3e54f98 100644
--- a/gdb/gdb-dlfcn.c
+++ b/gdb/gdb-dlfcn.c
@@ -18,8 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include "gdb_assert.h"
-
 #include "gdb-dlfcn.h"
 
 #ifdef HAVE_DLFCN_H
diff --git a/gdb/gdb_bfd.c b/gdb/gdb_bfd.c
index 4d4b0a5..fdde3e7 100644
--- a/gdb/gdb_bfd.c
+++ b/gdb/gdb_bfd.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "gdb_bfd.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "ui-out.h"
 #include "gdbcmd.h"
diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c
index fe49987..74caa93 100644
--- a/gdb/gdbarch.c
+++ b/gdb/gdbarch.c
@@ -42,7 +42,6 @@
 
 #include "floatformat.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 #include "reggroups.h"
 #include "osabi.h"
diff --git a/gdb/gdbarch.sh b/gdb/gdbarch.sh
index 13db4d4..9eab8f0 100755
--- a/gdb/gdbarch.sh
+++ b/gdb/gdbarch.sh
@@ -1473,7 +1473,6 @@ cat <<EOF
 
 #include "floatformat.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 #include "reggroups.h"
 #include "osabi.h"
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 5a3f335..2052103 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -134,8 +134,6 @@ extern int handle_target_event (int err, gdb_client_data client_data);
 #include "utils.h"
 #include "debug.h"
 
-#include "gdb_assert.h"
-
 /* Maximum number of bytes to read/write at once.  The value here
    is chosen to fill up a packet (the headers account for the 32).  */
 #define MAXBUFBYTES(N) (((N)-32)/2)
diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
index e99a2f3..54a4e1d 100644
--- a/gdb/gdbtypes.c
+++ b/gdb/gdbtypes.c
@@ -34,7 +34,6 @@
 #include "complaints.h"
 #include "gdbcmd.h"
 #include "cp-abi.h"
-#include "gdb_assert.h"
 #include "hashtab.h"
 #include "exceptions.h"
 #include "cp-support.h"
diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c
index a2de2f1..3eebba5 100644
--- a/gdb/gnu-nat.c
+++ b/gdb/gnu-nat.c
@@ -60,7 +60,6 @@
 #include "gdbcmd.h"
 #include "gdbcore.h"
 #include "gdbthread.h"
-#include "gdb_assert.h"
 #include "gdb_obstack.h"
 
 #include "gnu-nat.h"
diff --git a/gdb/gnu-v3-abi.c b/gdb/gnu-v3-abi.c
index e0be328..5a81213 100644
--- a/gdb/gnu-v3-abi.c
+++ b/gdb/gnu-v3-abi.c
@@ -29,7 +29,6 @@
 #include "exceptions.h"
 #include "typeprint.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 static struct cp_abi_ops gnu_v3_abi_ops;
diff --git a/gdb/go-lang.c b/gdb/go-lang.c
index 42535df..f1a2dba 100644
--- a/gdb/go-lang.c
+++ b/gdb/go-lang.c
@@ -32,7 +32,6 @@
 */
 
 #include "defs.h"
-#include "gdb_assert.h"
 #include "gdb_obstack.h"
 #include <string.h>
 #include "block.h"
diff --git a/gdb/guile/scm-exception.c b/gdb/guile/scm-exception.c
index d1df55b..826e06c 100644
--- a/gdb/guile/scm-exception.c
+++ b/gdb/guile/scm-exception.c
@@ -30,7 +30,6 @@
 
 #include "defs.h"
 #include <signal.h>
-#include "gdb_assert.h"
 #include "guile-internal.h"
 
 /* The <gdb:exception> smob.
diff --git a/gdb/guile/scm-gsmob.c b/gdb/guile/scm-gsmob.c
index 156ca8c..b00d641 100644
--- a/gdb/guile/scm-gsmob.c
+++ b/gdb/guile/scm-gsmob.c
@@ -43,7 +43,6 @@
 
 #include "defs.h"
 #include "hashtab.h"
-#include "gdb_assert.h"
 #include "objfiles.h"
 #include "guile-internal.h"
 
diff --git a/gdb/guile/scm-lazy-string.c b/gdb/guile/scm-lazy-string.c
index a34cb60..88d3004 100644
--- a/gdb/guile/scm-lazy-string.c
+++ b/gdb/guile/scm-lazy-string.c
@@ -26,7 +26,6 @@
 #include "exceptions.h"
 #include "valprint.h"
 #include "language.h"
-#include "gdb_assert.h"
 #include "guile-internal.h"
 
 /* The <gdb:lazy-string> smob.  */
diff --git a/gdb/guile/scm-math.c b/gdb/guile/scm-math.c
index 80e1673..e05f99e 100644
--- a/gdb/guile/scm-math.c
+++ b/gdb/guile/scm-math.c
@@ -27,7 +27,6 @@
 #include "doublest.h" /* Needed by dfp.h.  */
 #include "expression.h" /* Needed by dfp.h.  */
 #include "dfp.h"
-#include "gdb_assert.h"
 #include "symtab.h" /* Needed by language.h.  */
 #include "language.h"
 #include "valprint.h"
diff --git a/gdb/guile/scm-pretty-print.c b/gdb/guile/scm-pretty-print.c
index 79b9e64..5c94c78 100644
--- a/gdb/guile/scm-pretty-print.c
+++ b/gdb/guile/scm-pretty-print.c
@@ -22,7 +22,6 @@
 
 #include "defs.h"
 #include "charset.h"
-#include "gdb_assert.h"
 #include "symtab.h" /* Needed by language.h.  */
 #include "language.h"
 #include "objfiles.h"
diff --git a/gdb/guile/scm-safe-call.c b/gdb/guile/scm-safe-call.c
index 2a69a4f..e07c6c0 100644
--- a/gdb/guile/scm-safe-call.c
+++ b/gdb/guile/scm-safe-call.c
@@ -22,7 +22,6 @@
 
 #include "defs.h"
 #include "filenames.h"
-#include "gdb_assert.h"
 #include "guile-internal.h"
 
 /* Struct to marshall args to scscm_safe_call_body.  */
diff --git a/gdb/guile/scm-utils.c b/gdb/guile/scm-utils.c
index ada77a3..72da867 100644
--- a/gdb/guile/scm-utils.c
+++ b/gdb/guile/scm-utils.c
@@ -22,7 +22,6 @@
 
 #include "defs.h"
 #include <stdint.h>
-#include "gdb_assert.h"
 #include "guile-internal.h"
 
 /* Define VARIABLES in the gdb module.  */
diff --git a/gdb/guile/scm-value.c b/gdb/guile/scm-value.c
index 211ef66..5d88059 100644
--- a/gdb/guile/scm-value.c
+++ b/gdb/guile/scm-value.c
@@ -24,7 +24,6 @@
 #include "arch-utils.h"
 #include "charset.h"
 #include "cp-abi.h"
-#include "gdb_assert.h"
 #include "infcall.h"
 #include "symtab.h" /* Needed by language.h.  */
 #include "language.h"
diff --git a/gdb/h8300-tdep.c b/gdb/h8300-tdep.c
index f847085..0f58553 100644
--- a/gdb/h8300-tdep.c
+++ b/gdb/h8300-tdep.c
@@ -28,7 +28,6 @@
 #include "regcache.h"
 #include "gdbcore.h"
 #include "objfiles.h"
-#include "gdb_assert.h"
 #include "dis-asm.h"
 #include "dwarf2-frame.h"
 #include "frame-base.h"
diff --git a/gdb/hppa-hpux-nat.c b/gdb/hppa-hpux-nat.c
index c38a8c0..65a2b85 100644
--- a/gdb/hppa-hpux-nat.c
+++ b/gdb/hppa-hpux-nat.c
@@ -22,7 +22,6 @@
 #include "regcache.h"
 #include "target.h"
 
-#include "gdb_assert.h"
 #include <sys/ptrace.h>
 #include <sys/utsname.h>
 #include <machine/save_state.h>
diff --git a/gdb/hppa-tdep.c b/gdb/hppa-tdep.c
index e302ebb..73fe540 100644
--- a/gdb/hppa-tdep.c
+++ b/gdb/hppa-tdep.c
@@ -26,7 +26,6 @@
 #include "regcache.h"
 #include "completer.h"
 #include "osabi.h"
-#include "gdb_assert.h"
 #include "arch-utils.h"
 /* For argument passing to the inferior.  */
 #include "symtab.h"
diff --git a/gdb/hppanbsd-tdep.c b/gdb/hppanbsd-tdep.c
index fdc9719..657d4c2 100644
--- a/gdb/hppanbsd-tdep.c
+++ b/gdb/hppanbsd-tdep.c
@@ -25,7 +25,6 @@
 #include "trad-frame.h"
 #include "tramp-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "hppa-tdep.h"
diff --git a/gdb/hppaobsd-tdep.c b/gdb/hppaobsd-tdep.c
index 8dc03a2..eece2d1 100644
--- a/gdb/hppaobsd-tdep.c
+++ b/gdb/hppaobsd-tdep.c
@@ -22,7 +22,6 @@
 #include "regcache.h"
 #include "regset.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "hppa-tdep.h"
diff --git a/gdb/i386-darwin-nat.c b/gdb/i386-darwin-nat.c
index faf901e..f94c053 100644
--- a/gdb/i386-darwin-nat.c
+++ b/gdb/i386-darwin-nat.c
@@ -27,7 +27,6 @@
 #include "objfiles.h"
 #include "gdbcmd.h"
 #include "regcache.h"
-#include "gdb_assert.h"
 #include "i386-tdep.h"
 #include "i387-tdep.h"
 #include "gdbarch.h"
diff --git a/gdb/i386-darwin-tdep.c b/gdb/i386-darwin-tdep.c
index f2c08d7..87f2aff 100644
--- a/gdb/i386-darwin-tdep.c
+++ b/gdb/i386-darwin-tdep.c
@@ -33,7 +33,6 @@
 #include "i386-tdep.h"
 #include "osabi.h"
 #include "ui-out.h"
-#include "gdb_assert.h"
 #include "i386-darwin-tdep.h"
 #include "solib.h"
 #include "solib-darwin.h"
diff --git a/gdb/i386-nto-tdep.c b/gdb/i386-nto-tdep.c
index d005914..57be471 100644
--- a/gdb/i386-nto-tdep.c
+++ b/gdb/i386-nto-tdep.c
@@ -25,7 +25,6 @@
 #include "regcache.h"
 #include "target.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "i386-tdep.h"
diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c
index 5e3cc79..7544f06 100644
--- a/gdb/i386-tdep.c
+++ b/gdb/i386-tdep.c
@@ -45,7 +45,6 @@
 #include "disasm.h"
 #include "remote.h"
 #include "exceptions.h"
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "i386-tdep.h"
diff --git a/gdb/i386bsd-nat.c b/gdb/i386bsd-nat.c
index 4bee159..ec7fd70 100644
--- a/gdb/i386bsd-nat.c
+++ b/gdb/i386bsd-nat.c
@@ -21,7 +21,6 @@
 #include "inferior.h"
 #include "regcache.h"
 
-#include "gdb_assert.h"
 #include <signal.h>
 #include <sys/types.h>
 #include <sys/ptrace.h>
diff --git a/gdb/i386fbsd-tdep.c b/gdb/i386fbsd-tdep.c
index ed6df6b..8942ad3 100644
--- a/gdb/i386fbsd-tdep.c
+++ b/gdb/i386fbsd-tdep.c
@@ -23,8 +23,6 @@
 #include "osabi.h"
 #include "regcache.h"
 
-#include "gdb_assert.h"
-
 #include "i386-tdep.h"
 #include "i387-tdep.h"
 #include "bsd-uthread.h"
diff --git a/gdb/i386gnu-nat.c b/gdb/i386gnu-nat.c
index 23a70b3..fbd3344 100644
--- a/gdb/i386gnu-nat.c
+++ b/gdb/i386gnu-nat.c
@@ -22,7 +22,6 @@
 #include "floatformat.h"
 #include "regcache.h"
 
-#include "gdb_assert.h"
 #include <errno.h>
 #include <string.h>
 
diff --git a/gdb/i386nbsd-tdep.c b/gdb/i386nbsd-tdep.c
index 112f9f2..4b024f5 100644
--- a/gdb/i386nbsd-tdep.c
+++ b/gdb/i386nbsd-tdep.c
@@ -28,7 +28,6 @@
 #include "trad-frame.h"
 #include "tramp-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "i386-tdep.h"
diff --git a/gdb/i386obsd-tdep.c b/gdb/i386obsd-tdep.c
index 8f76e43..acdfc7e 100644
--- a/gdb/i386obsd-tdep.c
+++ b/gdb/i386obsd-tdep.c
@@ -30,7 +30,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "obsd-tdep.h"
diff --git a/gdb/i387-tdep.c b/gdb/i387-tdep.c
index c58a000..1613c2f 100644
--- a/gdb/i387-tdep.c
+++ b/gdb/i387-tdep.c
@@ -27,7 +27,6 @@
 #include "regcache.h"
 #include "value.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "i386-tdep.h"
diff --git a/gdb/ia64-libunwind-tdep.c b/gdb/ia64-libunwind-tdep.c
index fe1fbdc..dec4547 100644
--- a/gdb/ia64-libunwind-tdep.c
+++ b/gdb/ia64-libunwind-tdep.c
@@ -33,7 +33,6 @@
 
 #include <dlfcn.h>
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "ia64-libunwind-tdep.h"
diff --git a/gdb/ia64-tdep.c b/gdb/ia64-tdep.c
index 08eb79d..776a8be 100644
--- a/gdb/ia64-tdep.c
+++ b/gdb/ia64-tdep.c
@@ -30,7 +30,6 @@
 #include "frame-unwind.h"
 #include "doublest.h"
 #include "value.h"
-#include "gdb_assert.h"
 #include "objfiles.h"
 #include "elf/common.h"		/* for DT_PLTGOT value */
 #include "elf-bfd.h"
diff --git a/gdb/inf-ptrace.c b/gdb/inf-ptrace.c
index e1d64f8..c334474 100644
--- a/gdb/inf-ptrace.c
+++ b/gdb/inf-ptrace.c
@@ -25,7 +25,6 @@
 #include "gdbcore.h"
 #include "regcache.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 #include "gdb_ptrace.h"
 #include "gdb_wait.h"
diff --git a/gdb/inf-ttrace.c b/gdb/inf-ttrace.c
index a7c3481..d5075f7 100644
--- a/gdb/inf-ttrace.c
+++ b/gdb/inf-ttrace.c
@@ -30,7 +30,6 @@
 #include "terminal.h"
 #include "target.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 #include <sys/mman.h>
 #include <sys/ttrace.h>
diff --git a/gdb/infcall.c b/gdb/infcall.c
index 5c65bb5..c58295a 100644
--- a/gdb/infcall.c
+++ b/gdb/infcall.c
@@ -24,7 +24,6 @@
 #include "regcache.h"
 #include "inferior.h"
 #include "infrun.h"
-#include "gdb_assert.h"
 #include "block.h"
 #include "gdbcore.h"
 #include "language.h"
diff --git a/gdb/infcmd.c b/gdb/infcmd.c
index 5eb092b..f5f0ebf 100644
--- a/gdb/infcmd.c
+++ b/gdb/infcmd.c
@@ -43,7 +43,6 @@
 #include "block.h"
 #include "solib.h"
 #include <ctype.h>
-#include "gdb_assert.h"
 #include "observer.h"
 #include "target-descriptions.h"
 #include "user-regs.h"
diff --git a/gdb/infrun.c b/gdb/infrun.c
index 33aa674..0614de9 100644
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -46,7 +46,6 @@
 #include "main.h"
 #include "dictionary.h"
 #include "block.h"
-#include "gdb_assert.h"
 #include "mi/mi-common.h"
 #include "event-top.h"
 #include "record.h"
diff --git a/gdb/inline-frame.c b/gdb/inline-frame.c
index 50f492a..cecb2af 100644
--- a/gdb/inline-frame.c
+++ b/gdb/inline-frame.c
@@ -28,8 +28,6 @@
 #include "vec.h"
 #include "frame.h"
 
-#include "gdb_assert.h"
-
 /* We need to save a few variables for every thread stopped at the
    virtual call site of an inlined function.  If there was always a
    "struct thread_info", we could hang it off that; in the mean time,
diff --git a/gdb/interps.c b/gdb/interps.c
index 5a93095..297e498 100644
--- a/gdb/interps.c
+++ b/gdb/interps.c
@@ -37,7 +37,6 @@
 #include "interps.h"
 #include "completer.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "top.h"		/* For command_loop.  */
 #include "exceptions.h"
 #include "continuations.h"
diff --git a/gdb/jv-lang.c b/gdb/jv-lang.c
index 3e5f096..5e6bae3 100644
--- a/gdb/jv-lang.c
+++ b/gdb/jv-lang.c
@@ -35,7 +35,6 @@
 #include "demangle.h"
 #include "dictionary.h"
 #include <ctype.h>
-#include "gdb_assert.h"
 #include "charset.h"
 #include "valprint.h"
 #include "cp-support.h"
diff --git a/gdb/jv-typeprint.c b/gdb/jv-typeprint.c
index df46deb..972edf2 100644
--- a/gdb/jv-typeprint.c
+++ b/gdb/jv-typeprint.c
@@ -29,7 +29,6 @@
 #include "c-lang.h"
 #include "cp-abi.h"
 #include "cp-support.h"
-#include "gdb_assert.h"
 
 /* Local functions */
 
diff --git a/gdb/linux-fork.c b/gdb/linux-fork.c
index b9f8cfb..c9995bf 100644
--- a/gdb/linux-fork.c
+++ b/gdb/linux-fork.c
@@ -25,7 +25,6 @@
 #include "gdbcmd.h"
 #include "infcall.h"
 #include "objfiles.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "linux-fork.h"
 #include "linux-nat.h"
diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
index 8d4251f..703ae07 100644
--- a/gdb/linux-nat.c
+++ b/gdb/linux-nat.c
@@ -25,7 +25,6 @@
 #include "nat/linux-waitpid.h"
 #include <string.h>
 #include "gdb_wait.h"
-#include "gdb_assert.h"
 #ifdef HAVE_TKILL_SYSCALL
 #include <unistd.h>
 #include <sys/syscall.h>
diff --git a/gdb/linux-thread-db.c b/gdb/linux-thread-db.c
index af8232a..8adcb40 100644
--- a/gdb/linux-thread-db.c
+++ b/gdb/linux-thread-db.c
@@ -18,8 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-
-#include "gdb_assert.h"
 #include <dlfcn.h>
 #include "gdb_proc_service.h"
 #include "nat/gdb_thread_db.h"
diff --git a/gdb/m32c-tdep.c b/gdb/m32c-tdep.c
index 88f17a9..2374f36 100644
--- a/gdb/m32c-tdep.c
+++ b/gdb/m32c-tdep.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "elf-bfd.h"
 #include "elf/m32c.h"
 #include "gdb/sim-m32c.h"
diff --git a/gdb/m32r-linux-nat.c b/gdb/m32r-linux-nat.c
index d1efaac..f38cd53 100644
--- a/gdb/m32r-linux-nat.c
+++ b/gdb/m32r-linux-nat.c
@@ -24,7 +24,6 @@
 #include "linux-nat.h"
 #include "target.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 #include <sys/ptrace.h>
 #include <sys/user.h>
diff --git a/gdb/m32r-tdep.c b/gdb/m32r-tdep.c
index 838d3d9..6928c96 100644
--- a/gdb/m32r-tdep.c
+++ b/gdb/m32r-tdep.c
@@ -38,8 +38,6 @@
 #include "dis-asm.h"
 #include "objfiles.h"
 
-#include "gdb_assert.h"
-
 #include "m32r-tdep.h"
 
 /* Local functions */
diff --git a/gdb/m68k-tdep.c b/gdb/m68k-tdep.c
index 6b3f2b1..d3c6d01 100644
--- a/gdb/m68k-tdep.c
+++ b/gdb/m68k-tdep.c
@@ -27,7 +27,6 @@
 #include "gdbcore.h"
 #include "value.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "inferior.h"
 #include "regcache.h"
 #include "arch-utils.h"
diff --git a/gdb/m68kbsd-nat.c b/gdb/m68kbsd-nat.c
index dbd0e15..6ef3b4b 100644
--- a/gdb/m68kbsd-nat.c
+++ b/gdb/m68kbsd-nat.c
@@ -22,7 +22,6 @@
 #include "inferior.h"
 #include "regcache.h"
 
-#include "gdb_assert.h"
 #include <sys/types.h>
 #include <sys/ptrace.h>
 #include <machine/reg.h>
diff --git a/gdb/m68kbsd-tdep.c b/gdb/m68kbsd-tdep.c
index d27beb8..f1f63e1 100644
--- a/gdb/m68kbsd-tdep.c
+++ b/gdb/m68kbsd-tdep.c
@@ -27,7 +27,6 @@
 #include "tramp-frame.h"
 #include "gdbtypes.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "m68k-tdep.h"
diff --git a/gdb/m88k-tdep.c b/gdb/m88k-tdep.c
index 56384a7..3ce292e 100644
--- a/gdb/m88k-tdep.c
+++ b/gdb/m88k-tdep.c
@@ -31,7 +31,6 @@
 #include "trad-frame.h"
 #include "value.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "m88k-tdep.h"
diff --git a/gdb/machoread.c b/gdb/machoread.c
index f5e4a1e..96cc769 100644
--- a/gdb/machoread.c
+++ b/gdb/machoread.c
@@ -28,7 +28,6 @@
 #include "gdbcmd.h"
 #include "gdbcore.h"
 #include "mach-o.h"
-#include "gdb_assert.h"
 #include "aout/stab_gnu.h"
 #include "vec.h"
 #include "psympriv.h"
diff --git a/gdb/macroexp.c b/gdb/macroexp.c
index 30db47a..0faa07f 100644
--- a/gdb/macroexp.c
+++ b/gdb/macroexp.c
@@ -22,7 +22,6 @@
 #include "bcache.h"
 #include "macrotab.h"
 #include "macroexp.h"
-#include "gdb_assert.h"
 #include "c-lang.h"
 
 
diff --git a/gdb/macrotab.c b/gdb/macrotab.c
index 49f00b6..1e02b0a 100644
--- a/gdb/macrotab.c
+++ b/gdb/macrotab.c
@@ -25,7 +25,6 @@
 #include "symfile.h"
 #include "objfiles.h"
 #include "macrotab.h"
-#include "gdb_assert.h"
 #include "bcache.h"
 #include "complaints.h"
 #include "macroexp.h"
diff --git a/gdb/maint.c b/gdb/maint.c
index d4d5810..7fd2d58 100644
--- a/gdb/maint.c
+++ b/gdb/maint.c
@@ -38,7 +38,6 @@
 #include "symfile.h"
 #include "objfiles.h"
 #include "value.h"
-#include "gdb_assert.h"
 #include "top.h"
 #include "timeval-utils.h"
 #include "maint.h"
diff --git a/gdb/mdebugread.c b/gdb/mdebugread.c
index 2e9608b..a6fbd6a 100644
--- a/gdb/mdebugread.c
+++ b/gdb/mdebugread.c
@@ -51,7 +51,6 @@
 #include "complaints.h"
 #include "demangle.h"
 #include "gdb-demangle.h"
-#include "gdb_assert.h"
 #include "block.h"
 #include "dictionary.h"
 #include "mdebugread.h"
diff --git a/gdb/memory-map.c b/gdb/memory-map.c
index 80cd22b..522f16b 100644
--- a/gdb/memory-map.c
+++ b/gdb/memory-map.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "memory-map.h"
-#include "gdb_assert.h"
 #include "exceptions.h"
 
 #include <string.h>
diff --git a/gdb/mep-tdep.c b/gdb/mep-tdep.c
index 28c826e..dd3cc5f 100644
--- a/gdb/mep-tdep.c
+++ b/gdb/mep-tdep.c
@@ -48,8 +48,6 @@
 #include "cgen/bitset.h"
 #include "infcall.h"
 
-#include "gdb_assert.h"
-
 /* Get the user's customized MeP coprocessor register names from
    libopcodes.  */
 #include "opcodes/mep-desc.h"
diff --git a/gdb/mi/mi-common.c b/gdb/mi/mi-common.c
index 91cd35f..2dcdf8d 100644
--- a/gdb/mi/mi-common.c
+++ b/gdb/mi/mi-common.c
@@ -17,7 +17,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include "gdb_assert.h"
 #include "mi-common.h"
 
 static const char * const async_reason_string_lookup[] =
diff --git a/gdb/microblaze-tdep.c b/gdb/microblaze-tdep.c
index 93e93db..80c79f6 100644
--- a/gdb/microblaze-tdep.c
+++ b/gdb/microblaze-tdep.c
@@ -33,7 +33,6 @@
 #include "frame-unwind.h"
 #include "dwarf2-frame.h"
 #include "osabi.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "target-descriptions.h"
 #include "opcodes/microblaze-opcm.h"
diff --git a/gdb/mingw-hdep.c b/gdb/mingw-hdep.c
index 50dc372..c71814f 100644
--- a/gdb/mingw-hdep.c
+++ b/gdb/mingw-hdep.c
@@ -22,7 +22,6 @@
 #include "serial.h"
 #include "event-loop.h"
 
-#include "gdb_assert.h"
 #include "gdb_select.h"
 #include <string.h>
 #include "readline/readline.h"
diff --git a/gdb/mips-linux-nat.c b/gdb/mips-linux-nat.c
index dbd7ae7..88faa1e 100644
--- a/gdb/mips-linux-nat.c
+++ b/gdb/mips-linux-nat.c
@@ -20,7 +20,6 @@
 #include "defs.h"
 #include "command.h"
 #include "gdbcmd.h"
-#include "gdb_assert.h"
 #include "inferior.h"
 #include "mips-tdep.h"
 #include "target.h"
diff --git a/gdb/mips-linux-tdep.c b/gdb/mips-linux-tdep.c
index a975db6..1e81271 100644
--- a/gdb/mips-linux-tdep.c
+++ b/gdb/mips-linux-tdep.c
@@ -24,7 +24,6 @@
 #include "osabi.h"
 #include "mips-tdep.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "frame.h"
 #include "regcache.h"
 #include "trad-frame.h"
diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c
index 9a530a8..bbbf8a2 100644
--- a/gdb/mips-tdep.c
+++ b/gdb/mips-tdep.c
@@ -22,7 +22,6 @@
 
 #include "defs.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "frame.h"
 #include "inferior.h"
 #include "symtab.h"
diff --git a/gdb/mips64obsd-tdep.c b/gdb/mips64obsd-tdep.c
index 6d8b9ee..8a89af1 100644
--- a/gdb/mips64obsd-tdep.c
+++ b/gdb/mips64obsd-tdep.c
@@ -25,7 +25,6 @@
 #include "trad-frame.h"
 #include "tramp-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "obsd-tdep.h"
diff --git a/gdb/mipsnbsd-tdep.c b/gdb/mipsnbsd-tdep.c
index 31b8dca..2b7a1d3 100644
--- a/gdb/mipsnbsd-tdep.c
+++ b/gdb/mipsnbsd-tdep.c
@@ -27,7 +27,6 @@
 #include "value.h"
 #include "osabi.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "nbsd-tdep.h"
diff --git a/gdb/mn10300-linux-tdep.c b/gdb/mn10300-linux-tdep.c
index 1b72efa..cbaa010 100644
--- a/gdb/mn10300-linux-tdep.c
+++ b/gdb/mn10300-linux-tdep.c
@@ -22,7 +22,6 @@
 #include <string.h>
 #include "regcache.h"
 #include "mn10300-tdep.h"
-#include "gdb_assert.h"
 #include "bfd.h"
 #include "elf-bfd.h"
 #include "osabi.h"
diff --git a/gdb/mn10300-tdep.c b/gdb/mn10300-tdep.c
index 10a8262..bc21465 100644
--- a/gdb/mn10300-tdep.c
+++ b/gdb/mn10300-tdep.c
@@ -23,7 +23,6 @@
 #include "gdbtypes.h"
 #include "regcache.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "gdbcore.h"	/* For write_memory_unsigned_integer.  */
 #include "value.h"
 #include "frame.h"
diff --git a/gdb/moxie-tdep.c b/gdb/moxie-tdep.c
index 793e7a4..6d3c130 100644
--- a/gdb/moxie-tdep.c
+++ b/gdb/moxie-tdep.c
@@ -39,8 +39,6 @@
 #include "record.h"
 #include "record-full.h"
 
-#include "gdb_assert.h"
-
 #include "moxie-tdep.h"
 
 /* Local functions.  */
diff --git a/gdb/mt-tdep.c b/gdb/mt-tdep.c
index e3786e8..1904bf8 100644
--- a/gdb/mt-tdep.c
+++ b/gdb/mt-tdep.c
@@ -35,7 +35,6 @@
 #include "inferior.h"
 #include "dwarf2-frame.h"
 #include "infcall.h"
-#include "gdb_assert.h"
 #include "language.h"
 #include "valprint.h"
 
diff --git a/gdb/nat/linux-btrace.c b/gdb/nat/linux-btrace.c
index 84de8a7..baf07e8 100644
--- a/gdb/nat/linux-btrace.c
+++ b/gdb/nat/linux-btrace.c
@@ -26,7 +26,6 @@
 #endif
 
 #include "linux-btrace.h"
-#include "gdb_assert.h"
 #include "regcache.h"
 #include "gdbthread.h"
 #include "gdb_wait.h"
diff --git a/gdb/nat/linux-osdata.c b/gdb/nat/linux-osdata.c
index d9d1325..0ef7fa3 100644
--- a/gdb/nat/linux-osdata.c
+++ b/gdb/nat/linux-osdata.c
@@ -40,7 +40,6 @@
 
 #include "xml-utils.h"
 #include "buffer.h"
-#include "gdb_assert.h"
 #include <dirent.h>
 #include <sys/stat.h>
 #include "filestuff.h"
diff --git a/gdb/nat/linux-ptrace.c b/gdb/nat/linux-ptrace.c
index 24b02b9..8abb842 100644
--- a/gdb/nat/linux-ptrace.c
+++ b/gdb/nat/linux-ptrace.c
@@ -27,7 +27,6 @@
 #include "linux-procfs.h"
 #include "linux-waitpid.h"
 #include "buffer.h"
-#include "gdb_assert.h"
 #include "gdb_wait.h"
 
 #include <stdint.h>
diff --git a/gdb/nat/mips-linux-watch.c b/gdb/nat/mips-linux-watch.c
index ebe5523..ea6e02d 100644
--- a/gdb/nat/mips-linux-watch.c
+++ b/gdb/nat/mips-linux-watch.c
@@ -22,7 +22,6 @@
 #endif
 #include <sys/ptrace.h>
 #include "mips-linux-watch.h"
-#include "gdb_assert.h"
 
 /* Assuming usable watch registers REGS, return the irw_mask of
    register N.  */
diff --git a/gdb/nios2-linux-tdep.c b/gdb/nios2-linux-tdep.c
index 84ab576..2041336 100644
--- a/gdb/nios2-linux-tdep.c
+++ b/gdb/nios2-linux-tdep.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "frame.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "osabi.h"
 #include "solib-svr4.h"
diff --git a/gdb/nios2-tdep.c b/gdb/nios2-tdep.c
index 7b1b640..18a5913 100644
--- a/gdb/nios2-tdep.c
+++ b/gdb/nios2-tdep.c
@@ -38,7 +38,6 @@
 #include "symfile.h"
 #include "arch-utils.h"
 #include "floatformat.h"
-#include "gdb_assert.h"
 #include "infcall.h"
 #include "regset.h"
 #include "target-descriptions.h"
diff --git a/gdb/objc-lang.c b/gdb/objc-lang.c
index 68f0d10..c6d344e 100644
--- a/gdb/objc-lang.c
+++ b/gdb/objc-lang.c
@@ -44,7 +44,6 @@
 #include "block.h"
 #include "infcall.h"
 #include "valprint.h"
-#include "gdb_assert.h"
 #include "cli/cli-utils.h"
 
 #include <ctype.h>
diff --git a/gdb/objfiles.c b/gdb/objfiles.c
index 0a0b1cb..7c6fca8 100644
--- a/gdb/objfiles.c
+++ b/gdb/objfiles.c
@@ -33,7 +33,6 @@
 #include "expression.h"
 #include "parser-defs.h"
 
-#include "gdb_assert.h"
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
diff --git a/gdb/obsd-nat.c b/gdb/obsd-nat.c
index f53e616..e4a98ae 100644
--- a/gdb/obsd-nat.c
+++ b/gdb/obsd-nat.c
@@ -22,7 +22,6 @@
 #include "inferior.h"
 #include "target.h"
 
-#include "gdb_assert.h"
 #include <sys/types.h>
 #include <sys/ptrace.h>
 #include "gdb_wait.h"
diff --git a/gdb/opencl-lang.c b/gdb/opencl-lang.c
index 2dd76fa..96b562d 100644
--- a/gdb/opencl-lang.c
+++ b/gdb/opencl-lang.c
@@ -27,7 +27,6 @@
 #include "language.h"
 #include "varobj.h"
 #include "c-lang.h"
-#include "gdb_assert.h"
 
 extern void _initialize_opencl_language (void);
 
diff --git a/gdb/osabi.c b/gdb/osabi.c
index 5b69eeb..ae4290f 100644
--- a/gdb/osabi.c
+++ b/gdb/osabi.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "osabi.h"
diff --git a/gdb/parse.c b/gdb/parse.c
index 105d0cd..d35eb3a 100644
--- a/gdb/parse.c
+++ b/gdb/parse.c
@@ -46,7 +46,6 @@
 #include "symfile.h"		/* for overlay functions */
 #include "inferior.h"
 #include "doublest.h"
-#include "gdb_assert.h"
 #include "block.h"
 #include "source.h"
 #include "objfiles.h"
diff --git a/gdb/ppc-linux-nat.c b/gdb/ppc-linux-nat.c
index 6e8994e..3da6254 100644
--- a/gdb/ppc-linux-nat.c
+++ b/gdb/ppc-linux-nat.c
@@ -25,7 +25,6 @@
 #include "gdbthread.h"
 #include "gdbcore.h"
 #include "regcache.h"
-#include "gdb_assert.h"
 #include "target.h"
 #include "linux-nat.h"
 
diff --git a/gdb/ppc-sysv-tdep.c b/gdb/ppc-sysv-tdep.c
index 1a880a6..c56164f 100644
--- a/gdb/ppc-sysv-tdep.c
+++ b/gdb/ppc-sysv-tdep.c
@@ -24,7 +24,6 @@
 #include "regcache.h"
 #include "value.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "ppc-tdep.h"
 #include "target.h"
 #include "objfiles.h"
diff --git a/gdb/ppcfbsd-nat.c b/gdb/ppcfbsd-nat.c
index aeb47af..1b27c6b 100644
--- a/gdb/ppcfbsd-nat.c
+++ b/gdb/ppcfbsd-nat.c
@@ -22,7 +22,6 @@
 #include "inferior.h"
 #include "regcache.h"
 
-#include "gdb_assert.h"
 #include <sys/types.h>
 #include <sys/procfs.h>
 #include <sys/ptrace.h>
diff --git a/gdb/ppcfbsd-tdep.c b/gdb/ppcfbsd-tdep.c
index 28f5b7b..21a3bbc 100644
--- a/gdb/ppcfbsd-tdep.c
+++ b/gdb/ppcfbsd-tdep.c
@@ -30,7 +30,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "ppc-tdep.h"
diff --git a/gdb/ppcnbsd-nat.c b/gdb/ppcnbsd-nat.c
index db34538..5c5bb64 100644
--- a/gdb/ppcnbsd-nat.c
+++ b/gdb/ppcnbsd-nat.c
@@ -31,8 +31,6 @@
 #include "inferior.h"
 #include "regcache.h"
 
-#include "gdb_assert.h"
-
 #include "ppc-tdep.h"
 #include "ppcnbsd-tdep.h"
 #include "bsd-kvm.h"
diff --git a/gdb/ppcnbsd-tdep.c b/gdb/ppcnbsd-tdep.c
index 6fe8477..0043994 100644
--- a/gdb/ppcnbsd-tdep.c
+++ b/gdb/ppcnbsd-tdep.c
@@ -27,7 +27,6 @@
 #include "trad-frame.h"
 #include "tramp-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "ppc-tdep.h"
diff --git a/gdb/ppcobsd-nat.c b/gdb/ppcobsd-nat.c
index 9e3e85b..0c82eca 100644
--- a/gdb/ppcobsd-nat.c
+++ b/gdb/ppcobsd-nat.c
@@ -22,7 +22,6 @@
 #include "inferior.h"
 #include "regcache.h"
 
-#include "gdb_assert.h"
 #include <sys/types.h>
 #include <sys/ptrace.h>
 #include <sys/signal.h>
diff --git a/gdb/ppcobsd-tdep.c b/gdb/ppcobsd-tdep.c
index 2cdf687..b3a9677 100644
--- a/gdb/ppcobsd-tdep.c
+++ b/gdb/ppcobsd-tdep.c
@@ -28,7 +28,6 @@
 #include "symtab.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "ppc-tdep.h"
diff --git a/gdb/printcmd.c b/gdb/printcmd.c
index 228d4ad..9154836 100644
--- a/gdb/printcmd.c
+++ b/gdb/printcmd.c
@@ -37,7 +37,6 @@
 #include "objfiles.h"		/* ditto */
 #include "completer.h"		/* for completion functions */
 #include "ui-out.h"
-#include "gdb_assert.h"
 #include "block.h"
 #include "disasm.h"
 #include "dfp.h"
diff --git a/gdb/procfs.c b/gdb/procfs.c
index 5075dcd..40aaed5 100644
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -48,7 +48,6 @@
 #include <ctype.h>
 #include "gdb_bfd.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "inflow.h"
 #include "auxv.h"
 #include "procfs.h"
diff --git a/gdb/prologue-value.c b/gdb/prologue-value.c
index 56b32f4..f82e1a1 100644
--- a/gdb/prologue-value.c
+++ b/gdb/prologue-value.c
@@ -18,7 +18,6 @@
 
 #include "defs.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "prologue-value.h"
 #include "regcache.h"
 
diff --git a/gdb/psymtab.c b/gdb/psymtab.c
index ba6a58a..6c0c880 100644
--- a/gdb/psymtab.c
+++ b/gdb/psymtab.c
@@ -21,7 +21,6 @@
 #include "symtab.h"
 #include "psympriv.h"
 #include "objfiles.h"
-#include "gdb_assert.h"
 #include "block.h"
 #include "filenames.h"
 #include "source.h"
diff --git a/gdb/python/py-lazy-string.c b/gdb/python/py-lazy-string.c
index ac9fc0c..0cec387 100644
--- a/gdb/python/py-lazy-string.c
+++ b/gdb/python/py-lazy-string.c
@@ -24,7 +24,6 @@
 #include "exceptions.h"
 #include "valprint.h"
 #include "language.h"
-#include "gdb_assert.h"
 
 typedef struct {
   PyObject_HEAD
diff --git a/gdb/python/py-value.c b/gdb/python/py-value.c
index 8532da6..bdec389 100644
--- a/gdb/python/py-value.c
+++ b/gdb/python/py-value.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include "gdb_assert.h"
 #include "charset.h"
 #include "value.h"
 #include "exceptions.h"
diff --git a/gdb/regcache.c b/gdb/regcache.c
index 5ee90b0..506067f 100644
--- a/gdb/regcache.c
+++ b/gdb/regcache.c
@@ -24,7 +24,6 @@
 #include "gdbcmd.h"
 #include "regcache.h"
 #include "reggroups.h"
-#include "gdb_assert.h"
 #include <string.h>
 #include "observer.h"
 #include "exceptions.h"
diff --git a/gdb/reggroups.c b/gdb/reggroups.c
index 41ec41a..66b5c78 100644
--- a/gdb/reggroups.c
+++ b/gdb/reggroups.c
@@ -23,7 +23,6 @@
 #include "arch-utils.h"
 #include "reggroups.h"
 #include "gdbtypes.h"
-#include "gdb_assert.h"
 #include "regcache.h"
 #include "command.h"
 #include "gdbcmd.h"		/* For maintenanceprintlist.  */
diff --git a/gdb/registry.c b/gdb/registry.c
index 2fd6033..378c369 100644
--- a/gdb/registry.c
+++ b/gdb/registry.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "registry.h"
-#include "gdb_assert.h"
 #include <string.h>
 
 const struct registry_data *
diff --git a/gdb/remote-sim.c b/gdb/remote-sim.c
index 3acc9da..e652458 100644
--- a/gdb/remote-sim.c
+++ b/gdb/remote-sim.c
@@ -37,7 +37,6 @@
 #include "gdb/remote-sim.h"
 #include "command.h"
 #include "regcache.h"
-#include "gdb_assert.h"
 #include "sim-regno.h"
 #include "arch-utils.h"
 #include "readline/readline.h"
diff --git a/gdb/remote.c b/gdb/remote.c
index 3a05bfd..24ff0c3 100644
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -38,7 +38,6 @@
 #include "remote-notif.h"
 #include "regcache.h"
 #include "value.h"
-#include "gdb_assert.h"
 #include "observer.h"
 #include "solib.h"
 #include "cli/cli-decode.h"
diff --git a/gdb/rs6000-aix-tdep.c b/gdb/rs6000-aix-tdep.c
index 83e881e..3845df8 100644
--- a/gdb/rs6000-aix-tdep.c
+++ b/gdb/rs6000-aix-tdep.c
@@ -21,7 +21,6 @@
 
 #include "defs.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "osabi.h"
 #include "regcache.h"
 #include "regset.h"
diff --git a/gdb/rs6000-tdep.c b/gdb/rs6000-tdep.c
index c4ce51c..41f80d5 100644
--- a/gdb/rs6000-tdep.c
+++ b/gdb/rs6000-tdep.c
@@ -55,7 +55,6 @@
 #include "ppc-tdep.h"
 #include "ppc-ravenscar-thread.h"
 
-#include "gdb_assert.h"
 #include "dis-asm.h"
 
 #include "trad-frame.h"
diff --git a/gdb/s390-linux-tdep.c b/gdb/s390-linux-tdep.c
index ea743b5..d10e47a 100644
--- a/gdb/s390-linux-tdep.c
+++ b/gdb/s390-linux-tdep.c
@@ -39,7 +39,6 @@
 #include "reggroups.h"
 #include "regset.h"
 #include "value.h"
-#include "gdb_assert.h"
 #include "dis-asm.h"
 #include "solib-svr4.h"
 #include "prologue-value.h"
diff --git a/gdb/score-tdep.c b/gdb/score-tdep.c
index c224189..977216d 100644
--- a/gdb/score-tdep.c
+++ b/gdb/score-tdep.c
@@ -22,7 +22,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include "gdb_assert.h"
 #include "inferior.h"
 #include "symtab.h"
 #include "objfiles.h"
diff --git a/gdb/ser-base.c b/gdb/ser-base.c
index b8f7fd2..5f677a9 100644
--- a/gdb/ser-base.c
+++ b/gdb/ser-base.c
@@ -24,7 +24,6 @@
 
 #include "gdb_select.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include <sys/time.h>
 #ifdef USE_WIN32API
 #include <winsock2.h>
diff --git a/gdb/ser-mingw.c b/gdb/ser-mingw.c
index a6469ea..ab4de3b 100644
--- a/gdb/ser-mingw.c
+++ b/gdb/ser-mingw.c
@@ -29,7 +29,6 @@
 #include <unistd.h>
 #include <sys/types.h>
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "command.h"
diff --git a/gdb/sh-tdep.c b/gdb/sh-tdep.c
index 0c1fbed..3290566 100644
--- a/gdb/sh-tdep.c
+++ b/gdb/sh-tdep.c
@@ -33,7 +33,6 @@
 #include "dis-asm.h"
 #include "inferior.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "arch-utils.h"
 #include "floatformat.h"
 #include "regcache.h"
diff --git a/gdb/sh64-tdep.c b/gdb/sh64-tdep.c
index 9f115e0..b2dd3a4 100644
--- a/gdb/sh64-tdep.c
+++ b/gdb/sh64-tdep.c
@@ -33,7 +33,6 @@
 #include "dis-asm.h"
 #include "inferior.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "arch-utils.h"
 #include "regcache.h"
 #include "osabi.h"
diff --git a/gdb/solib-darwin.c b/gdb/solib-darwin.c
index 03b51d5..8782c81 100644
--- a/gdb/solib-darwin.c
+++ b/gdb/solib-darwin.c
@@ -30,8 +30,6 @@
 #include "gdbthread.h"
 #include "gdb_bfd.h"
 
-#include "gdb_assert.h"
-
 #include "solist.h"
 #include "solib.h"
 #include "solib-svr4.h"
diff --git a/gdb/solib-spu.c b/gdb/solib-spu.c
index 1c574b5..b657b7f 100644
--- a/gdb/solib-spu.c
+++ b/gdb/solib-spu.c
@@ -22,7 +22,6 @@
 #include "solib-spu.h"
 #include "gdbcore.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include <sys/stat.h>
 #include "arch-utils.h"
 #include "bfd.h"
diff --git a/gdb/solib-svr4.c b/gdb/solib-svr4.c
index af9d648..0e9f5a3 100644
--- a/gdb/solib-svr4.c
+++ b/gdb/solib-svr4.c
@@ -35,8 +35,6 @@
 #include "gdbthread.h"
 #include "observer.h"
 
-#include "gdb_assert.h"
-
 #include "solist.h"
 #include "solib.h"
 #include "solib-svr4.h"
diff --git a/gdb/source.c b/gdb/source.c
index 14b1f71..5a44bb7 100644
--- a/gdb/source.c
+++ b/gdb/source.c
@@ -26,7 +26,6 @@
 #include "gdbcmd.h"
 #include "frame.h"
 #include "value.h"
-#include "gdb_assert.h"
 #include "filestuff.h"
 
 #include <sys/types.h>
diff --git a/gdb/sparc-nat.c b/gdb/sparc-nat.c
index 22e1e5f..e83e7d1 100644
--- a/gdb/sparc-nat.c
+++ b/gdb/sparc-nat.c
@@ -22,7 +22,6 @@
 #include "regcache.h"
 #include "target.h"
 
-#include "gdb_assert.h"
 #include <signal.h>
 #include <string.h>
 #include <sys/ptrace.h>
diff --git a/gdb/sparc-sol2-tdep.c b/gdb/sparc-sol2-tdep.c
index 4452c00..c23ce2b 100644
--- a/gdb/sparc-sol2-tdep.c
+++ b/gdb/sparc-sol2-tdep.c
@@ -28,7 +28,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "sol2-tdep.h"
diff --git a/gdb/sparc-tdep.c b/gdb/sparc-tdep.c
index e7b3090..b075437 100644
--- a/gdb/sparc-tdep.c
+++ b/gdb/sparc-tdep.c
@@ -35,7 +35,6 @@
 #include "target.h"
 #include "value.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "sparc-tdep.h"
diff --git a/gdb/sparc64-sol2-tdep.c b/gdb/sparc64-sol2-tdep.c
index 507838a..23e943d 100644
--- a/gdb/sparc64-sol2-tdep.c
+++ b/gdb/sparc64-sol2-tdep.c
@@ -26,8 +26,6 @@
 #include "osabi.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
-
 #include "sol2-tdep.h"
 #include "sparc64-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/sparc64-tdep.c b/gdb/sparc64-tdep.c
index 40931d6..abb7350 100644
--- a/gdb/sparc64-tdep.c
+++ b/gdb/sparc64-tdep.c
@@ -34,7 +34,6 @@
 #include "target.h"
 #include "value.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "sparc64-tdep.h"
diff --git a/gdb/sparc64fbsd-tdep.c b/gdb/sparc64fbsd-tdep.c
index fde7815..453f2b4 100644
--- a/gdb/sparc64fbsd-tdep.c
+++ b/gdb/sparc64fbsd-tdep.c
@@ -27,7 +27,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "sparc64-tdep.h"
diff --git a/gdb/sparc64nbsd-tdep.c b/gdb/sparc64nbsd-tdep.c
index b67c762..0d2a4e0 100644
--- a/gdb/sparc64nbsd-tdep.c
+++ b/gdb/sparc64nbsd-tdep.c
@@ -30,7 +30,6 @@
 #include "solib-svr4.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "sparc64-tdep.h"
diff --git a/gdb/sparc64obsd-tdep.c b/gdb/sparc64obsd-tdep.c
index 8cc04f7..9151151 100644
--- a/gdb/sparc64obsd-tdep.c
+++ b/gdb/sparc64obsd-tdep.c
@@ -28,8 +28,6 @@
 #include "objfiles.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
-
 #include "obsd-tdep.h"
 #include "sparc64-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/sparcnbsd-tdep.c b/gdb/sparcnbsd-tdep.c
index b267842..7c4d6ee 100644
--- a/gdb/sparcnbsd-tdep.c
+++ b/gdb/sparcnbsd-tdep.c
@@ -30,7 +30,6 @@
 #include "symtab.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include "sparc-tdep.h"
diff --git a/gdb/sparcobsd-tdep.c b/gdb/sparcobsd-tdep.c
index 10f91fe..89365c4 100644
--- a/gdb/sparcobsd-tdep.c
+++ b/gdb/sparcobsd-tdep.c
@@ -27,8 +27,6 @@
 #include "symtab.h"
 #include "trad-frame.h"
 
-#include "gdb_assert.h"
-
 #include "obsd-tdep.h"
 #include "sparc-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/spu-multiarch.c b/gdb/spu-multiarch.c
index e3285d0..2bce90e 100644
--- a/gdb/spu-multiarch.c
+++ b/gdb/spu-multiarch.c
@@ -22,7 +22,6 @@
 #include "gdbcore.h"
 #include "gdbcmd.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "arch-utils.h"
 #include "observer.h"
 #include "inferior.h"
diff --git a/gdb/spu-tdep.c b/gdb/spu-tdep.c
index 3980fe7..6b46df1 100644
--- a/gdb/spu-tdep.c
+++ b/gdb/spu-tdep.c
@@ -25,7 +25,6 @@
 #include "gdbcmd.h"
 #include "gdbcore.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "frame.h"
 #include "frame-unwind.h"
 #include "frame-base.h"
diff --git a/gdb/stabsread.c b/gdb/stabsread.c
index 592350e..9a25b0c 100644
--- a/gdb/stabsread.c
+++ b/gdb/stabsread.c
@@ -44,8 +44,6 @@
 #include "doublest.h"
 #include "cp-abi.h"
 #include "cp-support.h"
-#include "gdb_assert.h"
-
 #include <ctype.h>
 
 /* Ask stabsread.h to define the vars it normally declares `extern'.  */
diff --git a/gdb/stack.c b/gdb/stack.c
index 3ca4db0..9243f69 100644
--- a/gdb/stack.c
+++ b/gdb/stack.c
@@ -49,7 +49,6 @@
 #include "cli/cli-utils.h"
 #include "objfiles.h"
 
-#include "gdb_assert.h"
 #include <ctype.h>
 #include <string.h>
 
diff --git a/gdb/symfile.c b/gdb/symfile.c
index 42707ac..921c3b8 100644
--- a/gdb/symfile.c
+++ b/gdb/symfile.c
@@ -45,7 +45,6 @@
 #include "bcache.h"
 #include "hashtab.h"
 #include "readline/readline.h"
-#include "gdb_assert.h"
 #include "block.h"
 #include "observer.h"
 #include "exec.h"
diff --git a/gdb/symtab.c b/gdb/symtab.c
index 09f3114..e64d0df 100644
--- a/gdb/symtab.c
+++ b/gdb/symtab.c
@@ -56,7 +56,6 @@
 #include "cp-abi.h"
 #include "cp-support.h"
 #include "observer.h"
-#include "gdb_assert.h"
 #include "solist.h"
 #include "macrotab.h"
 #include "macroscope.h"
diff --git a/gdb/target-descriptions.c b/gdb/target-descriptions.c
index 6b3389a..4570647 100644
--- a/gdb/target-descriptions.c
+++ b/gdb/target-descriptions.c
@@ -31,7 +31,6 @@
 #include "xml-tdesc.h"
 #include "osabi.h"
 
-#include "gdb_assert.h"
 #include "gdb_obstack.h"
 #include "hashtab.h"
 #include "inferior.h"
diff --git a/gdb/target-memory.c b/gdb/target-memory.c
index 583d337..c545909 100644
--- a/gdb/target-memory.c
+++ b/gdb/target-memory.c
@@ -23,8 +23,6 @@
 #include "target.h"
 #include "memory-map.h"
 
-#include "gdb_assert.h"
-
 #include <sys/time.h>
 
 static int
diff --git a/gdb/target.c b/gdb/target.c
index d9b471b..e08a098 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -34,7 +34,6 @@
 #include "dcache.h"
 #include <signal.h>
 #include "regcache.h"
-#include "gdb_assert.h"
 #include "gdbcore.h"
 #include "exceptions.h"
 #include "target-descriptions.h"
diff --git a/gdb/tic6x-linux-tdep.c b/gdb/tic6x-linux-tdep.c
index 1e1aa22..0081769 100644
--- a/gdb/tic6x-linux-tdep.c
+++ b/gdb/tic6x-linux-tdep.c
@@ -24,7 +24,6 @@
 #include "tic6x-tdep.h"
 #include "trad-frame.h"
 #include "tramp-frame.h"
-#include "gdb_assert.h"
 #include "elf-bfd.h"
 #include "elf/tic6x.h"
 
diff --git a/gdb/tic6x-tdep.c b/gdb/tic6x-tdep.c
index 96fa83e..ae3138e 100644
--- a/gdb/tic6x-tdep.c
+++ b/gdb/tic6x-tdep.c
@@ -44,7 +44,6 @@
 #include "linux-tdep.h"
 #include "solib.h"
 #include "objfiles.h"
-#include "gdb_assert.h"
 #include "osabi.h"
 #include "tic6x-tdep.h"
 #include "language.h"
diff --git a/gdb/tilegx-linux-nat.c b/gdb/tilegx-linux-nat.c
index a00f386..80a5e57 100644
--- a/gdb/tilegx-linux-nat.c
+++ b/gdb/tilegx-linux-nat.c
@@ -25,7 +25,6 @@
 
 #include <sys/ptrace.h>
 
-#include "gdb_assert.h"
 #include <string.h>
 
 #include <sys/procfs.h>
diff --git a/gdb/tilegx-tdep.c b/gdb/tilegx-tdep.c
index d2aae95..01742e8 100644
--- a/gdb/tilegx-tdep.c
+++ b/gdb/tilegx-tdep.c
@@ -31,7 +31,6 @@
 #include "dis-asm.h"
 #include "inferior.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "arch-utils.h"
 #include "floatformat.h"
 #include "regcache.h"
diff --git a/gdb/top.c b/gdb/top.c
index 19c88f9..319324f 100644
--- a/gdb/top.c
+++ b/gdb/top.c
@@ -42,7 +42,6 @@
 #include "version.h"
 #include "serial.h"
 #include "doublest.h"
-#include "gdb_assert.h"
 #include "main.h"
 #include "event-loop.h"
 #include "gdbthread.h"
diff --git a/gdb/tramp-frame.c b/gdb/tramp-frame.c
index daa804c..0fd6ddc 100644
--- a/gdb/tramp-frame.c
+++ b/gdb/tramp-frame.c
@@ -26,7 +26,6 @@
 #include "target.h"
 #include "trad-frame.h"
 #include "frame-base.h"
-#include "gdb_assert.h"
 
 struct frame_data
 {
diff --git a/gdb/tui/tui-out.c b/gdb/tui/tui-out.c
index 44f76a2..ff782f6 100644
--- a/gdb/tui/tui-out.c
+++ b/gdb/tui/tui-out.c
@@ -25,7 +25,6 @@
 #include "cli-out.h"
 #include "tui.h"
 #include <string.h>
-#include "gdb_assert.h"
 
 struct tui_ui_out_data
   {
diff --git a/gdb/tui/tui-winsource.c b/gdb/tui/tui-winsource.c
index c641e18..0625206 100644
--- a/gdb/tui/tui-winsource.c
+++ b/gdb/tui/tui-winsource.c
@@ -40,7 +40,6 @@
 
 #include <string.h>
 #include "gdb_curses.h"
-#include "gdb_assert.h"
 
 /* Function to display the "main" routine.  */
 void
diff --git a/gdb/ui-out.c b/gdb/ui-out.c
index 63cbc6e..205af9c 100644
--- a/gdb/ui-out.c
+++ b/gdb/ui-out.c
@@ -25,7 +25,6 @@
 #include "expression.h"		/* For language.h */
 #include "language.h"
 #include "ui-out.h"
-#include "gdb_assert.h"
 
 /* table header structures */
 
diff --git a/gdb/user-regs.c b/gdb/user-regs.c
index db0cac8..f4ec54a 100644
--- a/gdb/user-regs.c
+++ b/gdb/user-regs.c
@@ -23,7 +23,6 @@
 #include "user-regs.h"
 #include "gdbtypes.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "frame.h"
 
 /* A table of user registers.
diff --git a/gdb/utils.c b/gdb/utils.c
index 8af8827..1a71a58 100644
--- a/gdb/utils.c
+++ b/gdb/utils.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "dyn-string.h"
-#include "gdb_assert.h"
 #include <ctype.h>
 #include <string.h>
 #include "gdb_wait.h"
diff --git a/gdb/v850-tdep.c b/gdb/v850-tdep.c
index 27740ca..3e4447a 100644
--- a/gdb/v850-tdep.c
+++ b/gdb/v850-tdep.c
@@ -26,7 +26,6 @@
 #include "gdbtypes.h"
 #include "inferior.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "gdbcore.h"
 #include "arch-utils.h"
 #include "regcache.h"
diff --git a/gdb/valops.c b/gdb/valops.c
index 4164d63..6cd66c7 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -38,7 +38,6 @@
 #include "tracepoint.h"
 #include <errno.h>
 #include <string.h>
-#include "gdb_assert.h"
 #include "observer.h"
 #include "objfiles.h"
 #include "exceptions.h"
diff --git a/gdb/value.c b/gdb/value.c
index 41ca250..90e4bdc 100644
--- a/gdb/value.c
+++ b/gdb/value.c
@@ -30,7 +30,6 @@
 #include "language.h"
 #include "demangle.h"
 #include "doublest.h"
-#include "gdb_assert.h"
 #include "regcache.h"
 #include "block.h"
 #include "dfp.h"
diff --git a/gdb/varobj.c b/gdb/varobj.c
index cf1b8a8..d350234 100644
--- a/gdb/varobj.c
+++ b/gdb/varobj.c
@@ -25,7 +25,6 @@
 #include "block.h"
 #include "valprint.h"
 
-#include "gdb_assert.h"
 #include <string.h>
 #include "gdb_regex.h"
 
diff --git a/gdb/vax-nat.c b/gdb/vax-nat.c
index 9d4caf5..c39ae29 100644
--- a/gdb/vax-nat.c
+++ b/gdb/vax-nat.c
@@ -20,7 +20,6 @@
 #include "defs.h"
 #include "inferior.h"
 
-#include "gdb_assert.h"
 #include <sys/types.h>
 #include <sys/dir.h>
 #include <sys/user.h>
diff --git a/gdb/xml-syscall.c b/gdb/xml-syscall.c
index 31d4ae6..3824468 100644
--- a/gdb/xml-syscall.c
+++ b/gdb/xml-syscall.c
@@ -28,8 +28,6 @@
 
 #include "filenames.h"
 
-#include "gdb_assert.h"
-
 #ifndef HAVE_LIBEXPAT
 
 /* Dummy functions to indicate that there's no support for fetching
diff --git a/gdb/xml-tdesc.c b/gdb/xml-tdesc.c
index 9dcfee4..6e85ebd 100644
--- a/gdb/xml-tdesc.c
+++ b/gdb/xml-tdesc.c
@@ -28,8 +28,6 @@
 
 #include "filenames.h"
 
-#include "gdb_assert.h"
-
 #if !defined(HAVE_LIBEXPAT)
 
 /* Parse DOCUMENT into a target description.  Or don't, since we don't have
diff --git a/gdb/xstormy16-tdep.c b/gdb/xstormy16-tdep.c
index b2686cb..2f38739 100644
--- a/gdb/xstormy16-tdep.c
+++ b/gdb/xstormy16-tdep.c
@@ -30,7 +30,6 @@
 #include "dis-asm.h"
 #include "inferior.h"
 #include <string.h>
-#include "gdb_assert.h"
 #include "arch-utils.h"
 #include "floatformat.h"
 #include "regcache.h"
diff --git a/gdb/xtensa-linux-nat.c b/gdb/xtensa-linux-nat.c
index 9340c62..945f379 100644
--- a/gdb/xtensa-linux-nat.c
+++ b/gdb/xtensa-linux-nat.c
@@ -23,7 +23,6 @@
 #include "inferior.h"
 #include "gdbcore.h"
 #include "regcache.h"
-#include "gdb_assert.h"
 #include "target.h"
 #include "linux-nat.h"
 
diff --git a/gdb/xtensa-tdep.c b/gdb/xtensa-tdep.c
index 432a9de..24ec5f0 100644
--- a/gdb/xtensa-tdep.c
+++ b/gdb/xtensa-tdep.c
@@ -47,7 +47,6 @@
 
 #include "command.h"
 #include "gdbcmd.h"
-#include "gdb_assert.h"
 
 #include "xtensa-isa.h"
 #include "xtensa-tdep.h"
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 13/13] Include string.h in common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
  2014-07-29 15:11 ` [PATCH 03/13] Move stdarg.h to common-defs.h Gary Benson
@ 2014-07-29 15:11 ` Gary Benson
  2014-08-06 17:25   ` Doug Evans
  2014-07-29 15:11 ` [PATCH 12/13] Include gdb_assert.h " Gary Benson
                   ` (12 subsequent siblings)
  14 siblings, 1 reply; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:11 UTC (permalink / raw)
  To: gdb-patches

This commit includes string.h in common-defs.h and removes all other
inclusions.

gdb/
2014-07-29  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include string.h.
	* aarch64-tdep.c: Do not include string.h.
	* ada-exp.y: Likewise.
	* ada-lang.c: Likewise.
	* ada-lex.l: Likewise.
	* ada-typeprint.c: Likewise.
	* ada-valprint.c: Likewise.
	* aix-thread.c: Likewise.
	* alpha-linux-tdep.c: Likewise.
	* alpha-mdebug-tdep.c: Likewise.
	* alpha-nat.c: Likewise.
	* alpha-osf1-tdep.c: Likewise.
	* alpha-tdep.c: Likewise.
	* alphanbsd-tdep.c: Likewise.
	* amd64-dicos-tdep.c: Likewise.
	* amd64-linux-tdep.c: Likewise.
	* amd64-nat.c: Likewise.
	* amd64-sol2-tdep.c: Likewise.
	* amd64fbsd-tdep.c: Likewise.
	* amd64obsd-tdep.c: Likewise.
	* arch-utils.c: Likewise.
	* arm-linux-nat.c: Likewise.
	* arm-linux-tdep.c: Likewise.
	* arm-tdep.c: Likewise.
	* arm-wince-tdep.c: Likewise.
	* armbsd-tdep.c: Likewise.
	* armnbsd-nat.c: Likewise.
	* armnbsd-tdep.c: Likewise.
	* armobsd-tdep.c: Likewise.
	* avr-tdep.c: Likewise.
	* ax-gdb.c: Likewise.
	* ax-general.c: Likewise.
	* bcache.c: Likewise.
	* bfin-tdep.c: Likewise.
	* breakpoint.c: Likewise.
	* build-id.c: Likewise.
	* buildsym.c: Likewise.
	* c-exp.y: Likewise.
	* c-lang.c: Likewise.
	* c-typeprint.c: Likewise.
	* c-valprint.c: Likewise.
	* charset.c: Likewise.
	* cli-out.c: Likewise.
	* cli/cli-cmds.c: Likewise.
	* cli/cli-decode.c: Likewise.
	* cli/cli-dump.c: Likewise.
	* cli/cli-interp.c: Likewise.
	* cli/cli-logging.c: Likewise.
	* cli/cli-script.c: Likewise.
	* cli/cli-setshow.c: Likewise.
	* cli/cli-utils.c: Likewise.
	* coffread.c: Likewise.
	* common/agent.c: Likewise.
	* common/buffer.c: Likewise.
	* common/buffer.h: Likewise.
	* common/common-utils.c: Likewise.
	* common/filestuff.c: Likewise.
	* common/filestuff.c: Likewise.
	* common/format.c: Likewise.
	* common/print-utils.c: Likewise.
	* common/rsp-low.c: Likewise.
	* common/signals.c: Likewise.
	* common/vec.h: Likewise.
	* common/xml-utils.c: Likewise.
	* core-regset.c: Likewise.
	* corefile.c: Likewise.
	* corelow.c: Likewise.
	* cp-abi.c: Likewise.
	* cp-name-parser.y: Likewise.
	* cp-support.c: Likewise.
	* cp-valprint.c: Likewise.
	* cris-tdep.c: Likewise.
	* d-exp.y: Likewise.
	* darwin-nat.c: Likewise.
	* dbxread.c: Likewise.
	* dcache.c: Likewise.
	* demangle.c: Likewise.
	* dicos-tdep.c: Likewise.
	* disasm.c: Likewise.
	* doublest.c: Likewise.
	* dsrec.c: Likewise.
	* dummy-frame.c: Likewise.
	* dwarf2-frame.c: Likewise.
	* dwarf2loc.c: Likewise.
	* dwarf2read.c: Likewise.
	* elfread.c: Likewise.
	* environ.c: Likewise.
	* eval.c: Likewise.
	* event-loop.c: Likewise.
	* exceptions.c: Likewise.
	* exec.c: Likewise.
	* expprint.c: Likewise.
	* f-exp.y: Likewise.
	* f-lang.c: Likewise.
	* f-typeprint.c: Likewise.
	* f-valprint.c: Likewise.
	* fbsd-nat.c: Likewise.
	* findcmd.c: Likewise.
	* findvar.c: Likewise.
	* fork-child.c: Likewise.
	* frame.c: Likewise.
	* frv-linux-tdep.c: Likewise.
	* frv-tdep.c: Likewise.
	* gdb.c: Likewise.
	* gdb_bfd.c: Likewise.
	* gdbarch.c: Likewise.
	* gdbarch.sh: Likewise.
	* gdbtypes.c: Likewise.
	* gnu-nat.c: Likewise.
	* gnu-v2-abi.c: Likewise.
	* gnu-v3-abi.c: Likewise.
	* go-exp.y: Likewise.
	* go-lang.c: Likewise.
	* go32-nat.c: Likewise.
	* guile/guile.c: Likewise.
	* guile/scm-auto-load.c: Likewise.
	* hppa-hpux-tdep.c: Likewise.
	* hppa-linux-nat.c: Likewise.
	* hppanbsd-tdep.c: Likewise.
	* hppaobsd-tdep.c: Likewise.
	* i386-cygwin-tdep.c: Likewise.
	* i386-dicos-tdep.c: Likewise.
	* i386-linux-tdep.c: Likewise.
	* i386-nto-tdep.c: Likewise.
	* i386-sol2-tdep.c: Likewise.
	* i386-tdep.c: Likewise.
	* i386bsd-tdep.c: Likewise.
	* i386gnu-nat.c: Likewise.
	* i386nbsd-tdep.c: Likewise.
	* i386obsd-tdep.c: Likewise.
	* i387-tdep.c: Likewise.
	* ia64-libunwind-tdep.c: Likewise.
	* ia64-linux-nat.c: Likewise.
	* inf-child.c: Likewise.
	* inf-ptrace.c: Likewise.
	* inf-ttrace.c: Likewise.
	* infcall.c: Likewise.
	* infcmd.c: Likewise.
	* inflow.c: Likewise.
	* infrun.c: Likewise.
	* interps.c: Likewise.
	* iq2000-tdep.c: Likewise.
	* irix5-nat.c: Likewise.
	* jv-exp.y: Likewise.
	* jv-lang.c: Likewise.
	* jv-typeprint.c: Likewise.
	* jv-valprint.c: Likewise.
	* language.c: Likewise.
	* linux-fork.c: Likewise.
	* linux-nat.c: Likewise.
	* lm32-tdep.c: Likewise.
	* m2-exp.y: Likewise.
	* m2-typeprint.c: Likewise.
	* m32c-tdep.c: Likewise.
	* m32r-linux-nat.c: Likewise.
	* m32r-linux-tdep.c: Likewise.
	* m32r-rom.c: Likewise.
	* m32r-tdep.c: Likewise.
	* m68hc11-tdep.c: Likewise.
	* m68k-tdep.c: Likewise.
	* m68kbsd-tdep.c: Likewise.
	* m68klinux-nat.c: Likewise.
	* m68klinux-tdep.c: Likewise.
	* m88k-tdep.c: Likewise.
	* machoread.c: Likewise.
	* macrocmd.c: Likewise.
	* main.c: Likewise.
	* mdebugread.c: Likewise.
	* mem-break.c: Likewise.
	* memattr.c: Likewise.
	* memory-map.c: Likewise.
	* mep-tdep.c: Likewise.
	* mi/mi-cmd-break.c: Likewise.
	* mi/mi-cmd-disas.c: Likewise.
	* mi/mi-cmd-env.c: Likewise.
	* mi/mi-cmd-stack.c: Likewise.
	* mi/mi-cmd-var.c: Likewise.
	* mi/mi-cmds.c: Likewise.
	* mi/mi-console.c: Likewise.
	* mi/mi-getopt.c: Likewise.
	* mi/mi-interp.c: Likewise.
	* mi/mi-main.c: Likewise.
	* mi/mi-parse.c: Likewise.
	* microblaze-rom.c: Likewise.
	* microblaze-tdep.c: Likewise.
	* mingw-hdep.c: Likewise.
	* minidebug.c: Likewise.
	* minsyms.c: Likewise.
	* mips-irix-tdep.c: Likewise.
	* mips-linux-tdep.c: Likewise.
	* mips-tdep.c: Likewise.
	* mips64obsd-tdep.c: Likewise.
	* mipsnbsd-tdep.c: Likewise.
	* mipsread.c: Likewise.
	* mn10300-linux-tdep.c: Likewise.
	* mn10300-tdep.c: Likewise.
	* monitor.c: Likewise.
	* moxie-tdep.c: Likewise.
	* mt-tdep.c: Likewise.
	* nat/linux-btrace.c: Likewise.
	* nat/linux-osdata.c: Likewise.
	* nat/linux-procfs.c: Likewise.
	* nat/linux-ptrace.c: Likewise.
	* nat/linux-waitpid.c: Likewise.
	* nbsd-tdep.c: Likewise.
	* nios2-linux-tdep.c: Likewise.
	* nto-procfs.c: Likewise.
	* nto-tdep.c: Likewise.
	* objc-lang.c: Likewise.
	* objfiles.c: Likewise.
	* opencl-lang.c: Likewise.
	* osabi.c: Likewise.
	* osdata.c: Likewise.
	* p-exp.y: Likewise.
	* p-lang.c: Likewise.
	* p-typeprint.c: Likewise.
	* parse.c: Likewise.
	* posix-hdep.c: Likewise.
	* ppc-linux-nat.c: Likewise.
	* ppc-sysv-tdep.c: Likewise.
	* ppcfbsd-tdep.c: Likewise.
	* ppcnbsd-tdep.c: Likewise.
	* ppcobsd-tdep.c: Likewise.
	* printcmd.c: Likewise.
	* procfs.c: Likewise.
	* prologue-value.c: Likewise.
	* python/py-auto-load.c: Likewise.
	* python/py-gdb-readline.c: Likewise.
	* ravenscar-thread.c: Likewise.
	* regcache.c: Likewise.
	* registry.c: Likewise.
	* remote-fileio.c: Likewise.
	* remote-m32r-sdi.c: Likewise.
	* remote-mips.c: Likewise.
	* remote-notif.c: Likewise.
	* remote-sim.c: Likewise.
	* remote.c: Likewise.
	* reverse.c: Likewise.
	* rs6000-aix-tdep.c: Likewise.
	* ser-base.c: Likewise.
	* ser-go32.c: Likewise.
	* ser-mingw.c: Likewise.
	* ser-pipe.c: Likewise.
	* ser-tcp.c: Likewise.
	* ser-unix.c: Likewise.
	* serial.c: Likewise.
	* sh-tdep.c: Likewise.
	* sh64-tdep.c: Likewise.
	* shnbsd-tdep.c: Likewise.
	* skip.c: Likewise.
	* sol-thread.c: Likewise.
	* solib-dsbt.c: Likewise.
	* solib-frv.c: Likewise.
	* solib-osf.c: Likewise.
	* solib-som.c: Likewise.
	* solib-spu.c: Likewise.
	* solib-target.c: Likewise.
	* solib.c: Likewise.
	* somread.c: Likewise.
	* source.c: Likewise.
	* sparc-nat.c: Likewise.
	* sparc-sol2-tdep.c: Likewise.
	* sparc-tdep.c: Likewise.
	* sparc64-tdep.c: Likewise.
	* sparc64fbsd-tdep.c: Likewise.
	* sparc64nbsd-tdep.c: Likewise.
	* sparcnbsd-tdep.c: Likewise.
	* spu-linux-nat.c: Likewise.
	* spu-multiarch.c: Likewise.
	* spu-tdep.c: Likewise.
	* stabsread.c: Likewise.
	* stack.c: Likewise.
	* std-regs.c: Likewise.
	* symfile.c: Likewise.
	* symmisc.c: Likewise.
	* symtab.c: Likewise.
	* target.c: Likewise.
	* thread.c: Likewise.
	* tilegx-linux-nat.c: Likewise.
	* tilegx-tdep.c: Likewise.
	* top.c: Likewise.
	* tracepoint.c: Likewise.
	* tui/tui-command.c: Likewise.
	* tui/tui-data.c: Likewise.
	* tui/tui-disasm.c: Likewise.
	* tui/tui-file.c: Likewise.
	* tui/tui-layout.c: Likewise.
	* tui/tui-out.c: Likewise.
	* tui/tui-regs.c: Likewise.
	* tui/tui-source.c: Likewise.
	* tui/tui-stack.c: Likewise.
	* tui/tui-win.c: Likewise.
	* tui/tui-windata.c: Likewise.
	* tui/tui-winsource.c: Likewise.
	* typeprint.c: Likewise.
	* ui-file.c: Likewise.
	* ui-out.c: Likewise.
	* user-regs.c: Likewise.
	* utils.c: Likewise.
	* v850-tdep.c: Likewise.
	* valarith.c: Likewise.
	* valops.c: Likewise.
	* valprint.c: Likewise.
	* value.c: Likewise.
	* varobj.c: Likewise.
	* vax-tdep.c: Likewise.
	* vaxnbsd-tdep.c: Likewise.
	* vaxobsd-tdep.c: Likewise.
	* windows-nat.c: Likewise.
	* xcoffread.c: Likewise.
	* xml-support.c: Likewise.
	* xstormy16-tdep.c: Likewise.
	* xtensa-linux-nat.c: Likewise.

gdb/gdbserver/
2014-07-29  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include string.h.
	* event-loop.c: Likewise.
	* linux-low.c: Likewise.
	* regcache.c: Likewise.
	* remote-utils.c: Likewise.
	* spu-low.c: Likewise.
	* utils.c: Likewise.
---
 gdb/ChangeLog                |  316 ++++++++++++++++++++++++++++++++++++++++++
 gdb/aarch64-tdep.c           |    1 -
 gdb/ada-exp.y                |    1 -
 gdb/ada-lang.c               |    1 -
 gdb/ada-lex.l                |    2 -
 gdb/ada-typeprint.c          |    1 -
 gdb/ada-valprint.c           |    1 -
 gdb/aix-thread.c             |    1 -
 gdb/alpha-linux-tdep.c       |    1 -
 gdb/alpha-mdebug-tdep.c      |    1 -
 gdb/alpha-nat.c              |    1 -
 gdb/alpha-osf1-tdep.c        |    1 -
 gdb/alpha-tdep.c             |    1 -
 gdb/alphanbsd-tdep.c         |    2 -
 gdb/amd64-dicos-tdep.c       |    1 -
 gdb/amd64-linux-tdep.c       |    2 -
 gdb/amd64-nat.c              |    2 -
 gdb/amd64-sol2-tdep.c        |    2 -
 gdb/amd64fbsd-tdep.c         |    2 -
 gdb/amd64obsd-tdep.c         |    2 -
 gdb/arch-utils.c             |    1 -
 gdb/arm-linux-nat.c          |    1 -
 gdb/arm-linux-tdep.c         |    2 -
 gdb/arm-tdep.c               |    1 -
 gdb/arm-wince-tdep.c         |    2 -
 gdb/armbsd-tdep.c            |    2 -
 gdb/armnbsd-nat.c            |    2 -
 gdb/armnbsd-tdep.c           |    2 -
 gdb/armobsd-tdep.c           |    2 -
 gdb/avr-tdep.c               |    1 -
 gdb/ax-gdb.c                 |    1 -
 gdb/ax-general.c             |    2 -
 gdb/bcache.c                 |    1 -
 gdb/bfin-tdep.c              |    1 -
 gdb/breakpoint.c             |    1 -
 gdb/build-id.c               |    1 -
 gdb/buildsym.c               |    1 -
 gdb/c-exp.y                  |    1 -
 gdb/c-lang.c                 |    1 -
 gdb/c-typeprint.c            |    1 -
 gdb/c-valprint.c             |    1 -
 gdb/charset.c                |    2 -
 gdb/cli-out.c                |    1 -
 gdb/cli/cli-cmds.c           |    1 -
 gdb/cli/cli-decode.c         |    1 -
 gdb/cli/cli-dump.c           |    1 -
 gdb/cli/cli-interp.c         |    1 -
 gdb/cli/cli-logging.c        |    2 -
 gdb/cli/cli-script.c         |    1 -
 gdb/cli/cli-setshow.c        |    1 -
 gdb/cli/cli-utils.c          |    1 -
 gdb/coffread.c               |    2 -
 gdb/common/agent.c           |    2 -
 gdb/common/buffer.c          |    2 -
 gdb/common/buffer.h          |    2 -
 gdb/common/common-defs.h     |    1 +
 gdb/common/common-utils.c    |    2 -
 gdb/common/filestuff.c       |    3 -
 gdb/common/format.c          |    2 -
 gdb/common/print-utils.c     |    2 -
 gdb/common/rsp-low.c         |    2 -
 gdb/common/signals.c         |    1 -
 gdb/common/vec.h             |    2 -
 gdb/common/xml-utils.c       |    2 -
 gdb/core-regset.c            |    1 -
 gdb/corefile.c               |    1 -
 gdb/corelow.c                |    1 -
 gdb/cp-abi.c                 |    2 -
 gdb/cp-name-parser.y         |    2 -
 gdb/cp-support.c             |    1 -
 gdb/cp-valprint.c            |    1 -
 gdb/cris-tdep.c              |    1 -
 gdb/d-exp.y                  |    1 -
 gdb/darwin-nat.c             |    1 -
 gdb/dbxread.c                |    2 -
 gdb/dcache.c                 |    1 -
 gdb/demangle.c               |    2 -
 gdb/dicos-tdep.c             |    1 -
 gdb/disasm.c                 |    1 -
 gdb/doublest.c               |    1 -
 gdb/dsrec.c                  |    1 -
 gdb/dummy-frame.c            |    1 -
 gdb/dwarf2-frame.c           |    2 -
 gdb/dwarf2loc.c              |    2 -
 gdb/dwarf2read.c             |    1 -
 gdb/elfread.c                |    1 -
 gdb/environ.c                |    1 -
 gdb/eval.c                   |    1 -
 gdb/event-loop.c             |    1 -
 gdb/exceptions.c             |    1 -
 gdb/exec.c                   |    2 -
 gdb/expprint.c               |    1 -
 gdb/f-exp.y                  |    1 -
 gdb/f-lang.c                 |    1 -
 gdb/f-typeprint.c            |    2 -
 gdb/f-valprint.c             |    1 -
 gdb/fbsd-nat.c               |    2 -
 gdb/findcmd.c                |    1 -
 gdb/findvar.c                |    1 -
 gdb/fork-child.c             |    1 -
 gdb/frame.c                  |    1 -
 gdb/frv-linux-tdep.c         |    1 -
 gdb/frv-tdep.c               |    1 -
 gdb/gdb.c                    |    1 -
 gdb/gdb_bfd.c                |    1 -
 gdb/gdbarch.c                |    2 -
 gdb/gdbarch.sh               |    2 -
 gdb/gdbserver/ChangeLog      |   10 ++
 gdb/gdbserver/event-loop.c   |    1 -
 gdb/gdbserver/linux-low.c    |    1 -
 gdb/gdbserver/regcache.c     |    2 -
 gdb/gdbserver/remote-utils.c |    2 -
 gdb/gdbserver/server.h       |    2 -
 gdb/gdbserver/spu-low.c      |    1 -
 gdb/gdbserver/utils.c        |    1 -
 gdb/gdbtypes.c               |    1 -
 gdb/gnu-nat.c                |    1 -
 gdb/gnu-v2-abi.c             |    1 -
 gdb/gnu-v3-abi.c             |    2 -
 gdb/go-exp.y                 |    1 -
 gdb/go-lang.c                |    1 -
 gdb/go32-nat.c               |    1 -
 gdb/guile/guile.c            |    1 -
 gdb/guile/scm-auto-load.c    |    1 -
 gdb/hppa-hpux-tdep.c         |    2 -
 gdb/hppa-linux-nat.c         |    1 -
 gdb/hppanbsd-tdep.c          |    2 -
 gdb/hppaobsd-tdep.c          |    2 -
 gdb/i386-cygwin-tdep.c       |    1 -
 gdb/i386-dicos-tdep.c        |    1 -
 gdb/i386-linux-tdep.c        |    2 -
 gdb/i386-nto-tdep.c          |    2 -
 gdb/i386-sol2-tdep.c         |    2 -
 gdb/i386-tdep.c              |    2 -
 gdb/i386bsd-tdep.c           |    2 -
 gdb/i386gnu-nat.c            |    2 -
 gdb/i386nbsd-tdep.c          |    2 -
 gdb/i386obsd-tdep.c          |    2 -
 gdb/i387-tdep.c              |    2 -
 gdb/ia64-libunwind-tdep.c    |    2 -
 gdb/ia64-linux-nat.c         |    1 -
 gdb/inf-child.c              |    1 -
 gdb/inf-ptrace.c             |    2 -
 gdb/inf-ttrace.c             |    2 -
 gdb/infcall.c                |    1 -
 gdb/infcmd.c                 |    1 -
 gdb/inflow.c                 |    2 -
 gdb/infrun.c                 |    1 -
 gdb/interps.c                |    1 -
 gdb/iq2000-tdep.c            |    1 -
 gdb/irix5-nat.c              |    2 -
 gdb/jv-exp.y                 |    1 -
 gdb/jv-lang.c                |    1 -
 gdb/jv-typeprint.c           |    1 -
 gdb/jv-valprint.c            |    2 -
 gdb/language.c               |    2 -
 gdb/linux-fork.c             |    1 -
 gdb/linux-nat.c              |    1 -
 gdb/lm32-tdep.c              |    2 -
 gdb/m2-exp.y                 |    1 -
 gdb/m2-typeprint.c           |    2 -
 gdb/m32c-tdep.c              |    1 -
 gdb/m32r-linux-nat.c         |    2 -
 gdb/m32r-linux-tdep.c        |    2 -
 gdb/m32r-rom.c               |    1 -
 gdb/m32r-tdep.c              |    1 -
 gdb/m68hc11-tdep.c           |    1 -
 gdb/m68k-tdep.c              |    1 -
 gdb/m68kbsd-tdep.c           |    2 -
 gdb/m68klinux-nat.c          |    1 -
 gdb/m68klinux-tdep.c         |    1 -
 gdb/m88k-tdep.c              |    2 -
 gdb/machoread.c              |    2 -
 gdb/macrocmd.c               |    1 -
 gdb/main.c                   |    2 -
 gdb/mdebugread.c             |    1 -
 gdb/mem-break.c              |    3 -
 gdb/memattr.c                |    1 -
 gdb/memory-map.c             |    2 -
 gdb/mep-tdep.c               |    1 -
 gdb/mi/mi-cmd-break.c        |    1 -
 gdb/mi/mi-cmd-disas.c        |    1 -
 gdb/mi/mi-cmd-env.c          |    2 -
 gdb/mi/mi-cmd-stack.c        |    1 -
 gdb/mi/mi-cmd-var.c          |    1 -
 gdb/mi/mi-cmds.c             |    1 -
 gdb/mi/mi-console.c          |    2 -
 gdb/mi/mi-getopt.c           |    2 -
 gdb/mi/mi-interp.c           |    1 -
 gdb/mi/mi-main.c             |    1 -
 gdb/mi/mi-parse.c            |    1 -
 gdb/microblaze-rom.c         |    1 -
 gdb/microblaze-tdep.c        |    1 -
 gdb/mingw-hdep.c             |    1 -
 gdb/minidebug.c              |    1 -
 gdb/minsyms.c                |    1 -
 gdb/mips-irix-tdep.c         |    1 -
 gdb/mips-linux-tdep.c        |    1 -
 gdb/mips-tdep.c              |    1 -
 gdb/mips64obsd-tdep.c        |    2 -
 gdb/mipsnbsd-tdep.c          |    2 -
 gdb/mipsread.c               |    1 -
 gdb/mn10300-linux-tdep.c     |    1 -
 gdb/mn10300-tdep.c           |    1 -
 gdb/monitor.c                |    1 -
 gdb/moxie-tdep.c             |    1 -
 gdb/mt-tdep.c                |    1 -
 gdb/nat/linux-btrace.c       |    1 -
 gdb/nat/linux-osdata.c       |    1 -
 gdb/nat/linux-procfs.c       |    1 -
 gdb/nat/linux-ptrace.c       |    1 -
 gdb/nat/linux-waitpid.c      |    2 -
 gdb/nbsd-tdep.c              |    1 -
 gdb/nios2-linux-tdep.c       |    1 -
 gdb/nto-procfs.c             |    1 -
 gdb/nto-tdep.c               |    1 -
 gdb/objc-lang.c              |    1 -
 gdb/objfiles.c               |    1 -
 gdb/opencl-lang.c            |    1 -
 gdb/osabi.c                  |    2 -
 gdb/osdata.c                 |    1 -
 gdb/p-exp.y                  |    1 -
 gdb/p-lang.c                 |    1 -
 gdb/p-typeprint.c            |    1 -
 gdb/parse.c                  |    1 -
 gdb/posix-hdep.c             |    2 -
 gdb/ppc-linux-nat.c          |    1 -
 gdb/ppc-sysv-tdep.c          |    1 -
 gdb/ppcfbsd-tdep.c           |    2 -
 gdb/ppcnbsd-tdep.c           |    2 -
 gdb/ppcobsd-tdep.c           |    2 -
 gdb/printcmd.c               |    1 -
 gdb/procfs.c                 |    1 -
 gdb/prologue-value.c         |    1 -
 gdb/python/py-auto-load.c    |    1 -
 gdb/python/py-gdb-readline.c |    2 -
 gdb/ravenscar-thread.c       |    1 -
 gdb/regcache.c               |    1 -
 gdb/registry.c               |    2 -
 gdb/remote-fileio.c          |    1 -
 gdb/remote-m32r-sdi.c        |    1 -
 gdb/remote-mips.c            |    1 -
 gdb/remote-notif.c           |    2 -
 gdb/remote-sim.c             |    1 -
 gdb/remote.c                 |    1 -
 gdb/reverse.c                |    1 -
 gdb/rs6000-aix-tdep.c        |    1 -
 gdb/ser-base.c               |    1 -
 gdb/ser-go32.c               |    3 -
 gdb/ser-mingw.c              |    2 -
 gdb/ser-pipe.c               |    1 -
 gdb/ser-tcp.c                |    1 -
 gdb/ser-unix.c               |    1 -
 gdb/serial.c                 |    1 -
 gdb/sh-tdep.c                |    1 -
 gdb/sh64-tdep.c              |    1 -
 gdb/shnbsd-tdep.c            |    2 -
 gdb/skip.c                   |    1 -
 gdb/sol-thread.c             |    1 -
 gdb/solib-dsbt.c             |    1 -
 gdb/solib-frv.c              |    1 -
 gdb/solib-osf.c              |    2 -
 gdb/solib-som.c              |    2 -
 gdb/solib-spu.c              |    1 -
 gdb/solib-target.c           |    2 -
 gdb/solib.c                  |    1 -
 gdb/somread.c                |    1 -
 gdb/source.c                 |    1 -
 gdb/sparc-nat.c              |    1 -
 gdb/sparc-sol2-tdep.c        |    2 -
 gdb/sparc-tdep.c             |    2 -
 gdb/sparc64-tdep.c           |    2 -
 gdb/sparc64fbsd-tdep.c       |    2 -
 gdb/sparc64nbsd-tdep.c       |    2 -
 gdb/sparcnbsd-tdep.c         |    2 -
 gdb/spu-linux-nat.c          |    1 -
 gdb/spu-multiarch.c          |    1 -
 gdb/spu-tdep.c               |    1 -
 gdb/stabsread.c              |    1 -
 gdb/stack.c                  |    2 -
 gdb/std-regs.c               |    3 -
 gdb/symfile.c                |    1 -
 gdb/symmisc.c                |    2 -
 gdb/symtab.c                 |    1 -
 gdb/target.c                 |    1 -
 gdb/thread.c                 |    1 -
 gdb/tilegx-linux-nat.c       |    2 -
 gdb/tilegx-tdep.c            |    1 -
 gdb/top.c                    |    1 -
 gdb/tracepoint.c             |    1 -
 gdb/tui/tui-command.c        |    3 -
 gdb/tui/tui-data.c           |    2 -
 gdb/tui/tui-disasm.c         |    1 -
 gdb/tui/tui-file.c           |    2 -
 gdb/tui/tui-layout.c         |    2 -
 gdb/tui/tui-out.c            |    2 -
 gdb/tui/tui-regs.c           |    1 -
 gdb/tui/tui-source.c         |    2 -
 gdb/tui/tui-stack.c          |    1 -
 gdb/tui/tui-win.c            |    2 -
 gdb/tui/tui-windata.c        |    2 -
 gdb/tui/tui-winsource.c      |    2 -
 gdb/typeprint.c              |    1 -
 gdb/ui-file.c                |    1 -
 gdb/ui-out.c                 |    1 -
 gdb/user-regs.c              |    1 -
 gdb/utils.c                  |    1 -
 gdb/v850-tdep.c              |    1 -
 gdb/valarith.c               |    1 -
 gdb/valops.c                 |    1 -
 gdb/valprint.c               |    1 -
 gdb/value.c                  |    1 -
 gdb/varobj.c                 |    2 -
 gdb/vax-tdep.c               |    2 -
 gdb/vaxnbsd-tdep.c           |    2 -
 gdb/vaxobsd-tdep.c           |    2 -
 gdb/windows-nat.c            |    1 -
 gdb/xcoffread.c              |    2 -
 gdb/xml-support.c            |    2 -
 gdb/xstormy16-tdep.c         |    1 -
 gdb/xtensa-linux-nat.c       |    1 -
 321 files changed, 327 insertions(+), 439 deletions(-)

diff --git a/gdb/aarch64-tdep.c b/gdb/aarch64-tdep.c
index 445d7b9..1898f6b 100644
--- a/gdb/aarch64-tdep.c
+++ b/gdb/aarch64-tdep.c
@@ -24,7 +24,6 @@
 #include "inferior.h"
 #include "gdbcmd.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "dis-asm.h"
 #include "regcache.h"
 #include "reggroups.h"
diff --git a/gdb/ada-exp.y b/gdb/ada-exp.y
index 96188ac..bb1a767 100644
--- a/gdb/ada-exp.y
+++ b/gdb/ada-exp.y
@@ -36,7 +36,6 @@
 %{
 
 #include "defs.h"
-#include <string.h>
 #include <ctype.h>
 #include "expression.h"
 #include "value.h"
diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
index 5297fd3..32f1b39 100644
--- a/gdb/ada-lang.c
+++ b/gdb/ada-lang.c
@@ -19,7 +19,6 @@
 
 
 #include "defs.h"
-#include <string.h>
 #include <ctype.h>
 #include "demangle.h"
 #include "gdb_regex.h"
diff --git a/gdb/ada-lex.l b/gdb/ada-lex.l
index 9632073..c50f5a8 100644
--- a/gdb/ada-lex.l
+++ b/gdb/ada-lex.l
@@ -291,8 +291,6 @@ false		{ return FALSEKEYWORD; }
 %%
 
 #include <ctype.h>
-#include <string.h>
-
 /* Initialize the lexer for processing new expression. */
 
 static void
diff --git a/gdb/ada-typeprint.c b/gdb/ada-typeprint.c
index 09ff744..a43ced7 100644
--- a/gdb/ada-typeprint.c
+++ b/gdb/ada-typeprint.c
@@ -34,7 +34,6 @@
 #include "ada-lang.h"
 
 #include <ctype.h>
-#include <string.h>
 #include <errno.h>
 
 static int print_selected_record_field_types (struct type *, struct type *,
diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
index b7b3a9c..ed1eac4 100644
--- a/gdb/ada-valprint.c
+++ b/gdb/ada-valprint.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include <ctype.h>
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "expression.h"
diff --git a/gdb/aix-thread.c b/gdb/aix-thread.c
index 1eb885b..0dbd9ae 100644
--- a/gdb/aix-thread.c
+++ b/gdb/aix-thread.c
@@ -46,7 +46,6 @@
 #include "regcache.h"
 #include "gdbcmd.h"
 #include "ppc-tdep.h"
-#include <string.h>
 #include "observer.h"
 #include "objfiles.h"
 
diff --git a/gdb/alpha-linux-tdep.c b/gdb/alpha-linux-tdep.c
index 3d13a75..a571fd9 100644
--- a/gdb/alpha-linux-tdep.c
+++ b/gdb/alpha-linux-tdep.c
@@ -18,7 +18,6 @@
 
 #include "defs.h"
 #include "frame.h"
-#include <string.h>
 #include "osabi.h"
 #include "solib-svr4.h"
 #include "symtab.h"
diff --git a/gdb/alpha-mdebug-tdep.c b/gdb/alpha-mdebug-tdep.c
index 4cf0eb9..2f0b30c 100644
--- a/gdb/alpha-mdebug-tdep.c
+++ b/gdb/alpha-mdebug-tdep.c
@@ -23,7 +23,6 @@
 #include "symtab.h"
 #include "gdbcore.h"
 #include "block.h"
-#include <string.h>
 #include "trad-frame.h"
 
 #include "alpha-tdep.h"
diff --git a/gdb/alpha-nat.c b/gdb/alpha-nat.c
index 4739cac..88ff62d 100644
--- a/gdb/alpha-nat.c
+++ b/gdb/alpha-nat.c
@@ -17,7 +17,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "inferior.h"
 #include "gdbcore.h"
 #include "target.h"
diff --git a/gdb/alpha-osf1-tdep.c b/gdb/alpha-osf1-tdep.c
index 43bae95..c88be62 100644
--- a/gdb/alpha-osf1-tdep.c
+++ b/gdb/alpha-osf1-tdep.c
@@ -21,7 +21,6 @@
 #include "gdbcore.h"
 #include "value.h"
 #include "osabi.h"
-#include <string.h>
 #include "objfiles.h"
 
 #include "alpha-tdep.h"
diff --git a/gdb/alpha-tdep.c b/gdb/alpha-tdep.c
index 159a7e9..9e4a8d8 100644
--- a/gdb/alpha-tdep.c
+++ b/gdb/alpha-tdep.c
@@ -31,7 +31,6 @@
 #include "dis-asm.h"
 #include "symfile.h"
 #include "objfiles.h"
-#include <string.h>
 #include "linespec.h"
 #include "regcache.h"
 #include "reggroups.h"
diff --git a/gdb/alphanbsd-tdep.c b/gdb/alphanbsd-tdep.c
index 8e237c0..a4dd6e9 100644
--- a/gdb/alphanbsd-tdep.c
+++ b/gdb/alphanbsd-tdep.c
@@ -27,8 +27,6 @@
 #include "regset.h"
 #include "value.h"
 
-#include <string.h>
-
 #include "alpha-tdep.h"
 #include "alphabsd-tdep.h"
 #include "nbsd-tdep.h"
diff --git a/gdb/amd64-dicos-tdep.c b/gdb/amd64-dicos-tdep.c
index 35d783c..4fc8da5 100644
--- a/gdb/amd64-dicos-tdep.c
+++ b/gdb/amd64-dicos-tdep.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "osabi.h"
-#include <string.h>
 #include "amd64-tdep.h"
 #include "dicos-tdep.h"
 
diff --git a/gdb/amd64-linux-tdep.c b/gdb/amd64-linux-tdep.c
index 9699c12..97a2890 100644
--- a/gdb/amd64-linux-tdep.c
+++ b/gdb/amd64-linux-tdep.c
@@ -33,8 +33,6 @@
 #include "linux-tdep.h"
 #include "i386-xstate.h"
 
-#include <string.h>
-
 #include "amd64-tdep.h"
 #include "solib-svr4.h"
 #include "xml-syscall.h"
diff --git a/gdb/amd64-nat.c b/gdb/amd64-nat.c
index 943f0ec..17552a6 100644
--- a/gdb/amd64-nat.c
+++ b/gdb/amd64-nat.c
@@ -21,8 +21,6 @@
 #include "gdbarch.h"
 #include "regcache.h"
 
-#include <string.h>
-
 #include "i386-tdep.h"
 #include "amd64-tdep.h"
 #include "amd64-nat.h"
diff --git a/gdb/amd64-sol2-tdep.c b/gdb/amd64-sol2-tdep.c
index b76d5f3..beb2007 100644
--- a/gdb/amd64-sol2-tdep.c
+++ b/gdb/amd64-sol2-tdep.c
@@ -26,8 +26,6 @@
 #include "osabi.h"
 #include "symtab.h"
 
-#include <string.h>
-
 #include "sol2-tdep.h"
 #include "amd64-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/amd64fbsd-tdep.c b/gdb/amd64fbsd-tdep.c
index 6ecf20b..07b065a 100644
--- a/gdb/amd64fbsd-tdep.c
+++ b/gdb/amd64fbsd-tdep.c
@@ -24,8 +24,6 @@
 #include "regcache.h"
 #include "osabi.h"
 
-#include <string.h>
-
 #include "amd64-tdep.h"
 #include "bsd-uthread.h"
 #include "solib-svr4.h"
diff --git a/gdb/amd64obsd-tdep.c b/gdb/amd64obsd-tdep.c
index 4cb981f..ef0c0c2 100644
--- a/gdb/amd64obsd-tdep.c
+++ b/gdb/amd64obsd-tdep.c
@@ -29,8 +29,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include <string.h>
-
 #include "obsd-tdep.h"
 #include "amd64-tdep.h"
 #include "i387-tdep.h"
diff --git a/gdb/arch-utils.c b/gdb/arch-utils.c
index 1772033..5ae9fb3 100644
--- a/gdb/arch-utils.c
+++ b/gdb/arch-utils.c
@@ -24,7 +24,6 @@
 #include "gdbcmd.h"
 #include "inferior.h"		/* enum CALL_DUMMY_LOCATION et al.  */
 #include "infrun.h"
-#include <string.h>
 #include "regcache.h"
 #include "sim-regno.h"
 #include "gdbcore.h"
diff --git a/gdb/arm-linux-nat.c b/gdb/arm-linux-nat.c
index 2d2afb2..96c67a8 100644
--- a/gdb/arm-linux-nat.c
+++ b/gdb/arm-linux-nat.c
@@ -19,7 +19,6 @@
 #include "defs.h"
 #include "inferior.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "regcache.h"
 #include "target.h"
 #include "linux-nat.h"
diff --git a/gdb/arm-linux-tdep.c b/gdb/arm-linux-tdep.c
index a96ea3f..26a6b8c 100644
--- a/gdb/arm-linux-tdep.c
+++ b/gdb/arm-linux-tdep.c
@@ -54,8 +54,6 @@
 #include "user-regs.h"
 #include <ctype.h>
 #include "elf/common.h"
-#include <string.h>
-
 extern int arm_apcs_32;
 
 /* Under ARM GNU/Linux the traditional way of performing a breakpoint
diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
index f9b9175..b746eee 100644
--- a/gdb/arm-tdep.c
+++ b/gdb/arm-tdep.c
@@ -26,7 +26,6 @@
 #include "infrun.h"
 #include "gdbcmd.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "dis-asm.h"		/* For register styles.  */
 #include "regcache.h"
 #include "reggroups.h"
diff --git a/gdb/arm-wince-tdep.c b/gdb/arm-wince-tdep.c
index a2a5372..24f0e5b 100644
--- a/gdb/arm-wince-tdep.c
+++ b/gdb/arm-wince-tdep.c
@@ -24,8 +24,6 @@
 #include "target.h"
 #include "frame.h"
 
-#include <string.h>
-
 #include "arm-tdep.h"
 #include "windows-tdep.h"
 
diff --git a/gdb/armbsd-tdep.c b/gdb/armbsd-tdep.c
index b0c952b..62e82b8 100644
--- a/gdb/armbsd-tdep.c
+++ b/gdb/armbsd-tdep.c
@@ -22,8 +22,6 @@
 #include "regcache.h"
 #include "regset.h"
 
-#include <string.h>
-
 #include "arm-tdep.h"
 
 /* Core file support.  */
diff --git a/gdb/armnbsd-nat.c b/gdb/armnbsd-nat.c
index de3f94d..d497b89 100644
--- a/gdb/armnbsd-nat.c
+++ b/gdb/armnbsd-nat.c
@@ -22,8 +22,6 @@
 #include "inferior.h"
 #include "regcache.h"
 #include "target.h"
-
-#include <string.h>
 #include <sys/types.h>
 #include <sys/ptrace.h>
 #include <machine/reg.h>
diff --git a/gdb/armnbsd-tdep.c b/gdb/armnbsd-tdep.c
index 91a9d0d..5f16a02 100644
--- a/gdb/armnbsd-tdep.c
+++ b/gdb/armnbsd-tdep.c
@@ -20,8 +20,6 @@
 #include "defs.h"
 #include "osabi.h"
 
-#include <string.h>
-
 #include "arm-tdep.h"
 #include "solib-svr4.h"
 
diff --git a/gdb/armobsd-tdep.c b/gdb/armobsd-tdep.c
index e4f5948..f4904a3 100644
--- a/gdb/armobsd-tdep.c
+++ b/gdb/armobsd-tdep.c
@@ -22,8 +22,6 @@
 #include "trad-frame.h"
 #include "tramp-frame.h"
 
-#include <string.h>
-
 #include "obsd-tdep.h"
 #include "arm-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/avr-tdep.c b/gdb/avr-tdep.c
index 1f268f2..d2b5f5f 100644
--- a/gdb/avr-tdep.c
+++ b/gdb/avr-tdep.c
@@ -34,7 +34,6 @@
 #include "symfile.h"
 #include "arch-utils.h"
 #include "regcache.h"
-#include <string.h>
 #include "dis-asm.h"
 #include "objfiles.h"
 
diff --git a/gdb/ax-gdb.c b/gdb/ax-gdb.c
index f359317..a60603f 100644
--- a/gdb/ax-gdb.c
+++ b/gdb/ax-gdb.c
@@ -30,7 +30,6 @@
 #include "target.h"
 #include "ax.h"
 #include "ax-gdb.h"
-#include <string.h>
 #include "block.h"
 #include "regcache.h"
 #include "user-regs.h"
diff --git a/gdb/ax-general.c b/gdb/ax-general.c
index 8378ad6..cdb1480 100644
--- a/gdb/ax-general.c
+++ b/gdb/ax-general.c
@@ -25,8 +25,6 @@
 #include "ax.h"
 
 #include "value.h"
-#include <string.h>
-
 #include "user-regs.h"
 
 static void grow_expr (struct agent_expr *x, int n);
diff --git a/gdb/bcache.c b/gdb/bcache.c
index 2adfcd4..ac14ba4 100644
--- a/gdb/bcache.c
+++ b/gdb/bcache.c
@@ -22,7 +22,6 @@
 #include "defs.h"
 #include "gdb_obstack.h"
 #include "bcache.h"
-#include <string.h>		/* For memcpy declaration */
 
 /* The type used to hold a single bcache string.  The user data is
    stored in d.data.  Since it can be any type, it needs to have the
diff --git a/gdb/bfin-tdep.c b/gdb/bfin-tdep.c
index 2e5dbde..4ea5be7 100644
--- a/gdb/bfin-tdep.c
+++ b/gdb/bfin-tdep.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "inferior.h"
 #include "gdbcore.h"
 #include "arch-utils.h"
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
index 2fde301..d45a883 100644
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -36,7 +36,6 @@
 #include "gdbthread.h"
 #include "target.h"
 #include "language.h"
-#include <string.h>
 #include "gdb-demangle.h"
 #include "filenames.h"
 #include "annotate.h"
diff --git a/gdb/build-id.c b/gdb/build-id.c
index 491900b..0f553ce 100644
--- a/gdb/build-id.c
+++ b/gdb/build-id.c
@@ -22,7 +22,6 @@
 #include "elf-bfd.h"
 #include "gdb_bfd.h"
 #include "build-id.h"
-#include <string.h>
 #include "gdb_vecs.h"
 #include "symfile.h"
 #include "objfiles.h"
diff --git a/gdb/buildsym.c b/gdb/buildsym.c
index 8fc7b75..2b00a1a 100644
--- a/gdb/buildsym.c
+++ b/gdb/buildsym.c
@@ -31,7 +31,6 @@
 #include "objfiles.h"
 #include "gdbtypes.h"
 #include "complaints.h"
-#include <string.h>
 #include "expression.h"		/* For "enum exp_opcode" used by...  */
 #include "bcache.h"
 #include "filenames.h"		/* For DOSish file names.  */
diff --git a/gdb/c-exp.y b/gdb/c-exp.y
index 714e02e..56400ce 100644
--- a/gdb/c-exp.y
+++ b/gdb/c-exp.y
@@ -36,7 +36,6 @@
 %{
 
 #include "defs.h"
-#include <string.h>
 #include <ctype.h>
 #include "expression.h"
 #include "value.h"
diff --git a/gdb/c-lang.c b/gdb/c-lang.c
index e647ff6..185b38e 100644
--- a/gdb/c-lang.c
+++ b/gdb/c-lang.c
@@ -28,7 +28,6 @@
 #include "valprint.h"
 #include "macroscope.h"
 #include "charset.h"
-#include <string.h>
 #include "demangle.h"
 #include "cp-abi.h"
 #include "cp-support.h"
diff --git a/gdb/c-typeprint.c b/gdb/c-typeprint.c
index 305f92d..5239505 100644
--- a/gdb/c-typeprint.c
+++ b/gdb/c-typeprint.c
@@ -31,7 +31,6 @@
 #include "typeprint.h"
 #include "cp-abi.h"
 #include "jv-lang.h"
-#include <string.h>
 #include <errno.h>
 #include "cp-support.h"
 
diff --git a/gdb/c-valprint.c b/gdb/c-valprint.c
index f4694b0..19c1cb1 100644
--- a/gdb/c-valprint.c
+++ b/gdb/c-valprint.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "expression.h"
diff --git a/gdb/charset.c b/gdb/charset.c
index c1c1405..0f54393 100644
--- a/gdb/charset.c
+++ b/gdb/charset.c
@@ -27,8 +27,6 @@
 #include "environ.h"
 #include "arch-utils.h"
 #include "gdb_vecs.h"
-
-#include <string.h>
 #include <ctype.h>
 
 #ifdef USE_WIN32API
diff --git a/gdb/cli-out.c b/gdb/cli-out.c
index 5435385..4961d8a 100644
--- a/gdb/cli-out.c
+++ b/gdb/cli-out.c
@@ -23,7 +23,6 @@
 #include "defs.h"
 #include "ui-out.h"
 #include "cli-out.h"
-#include <string.h>
 #include "vec.h"
 
 typedef struct cli_ui_out_data cli_out_data;
diff --git a/gdb/cli/cli-cmds.c b/gdb/cli/cli-cmds.c
index 2e08a5c..b415267 100644
--- a/gdb/cli/cli-cmds.c
+++ b/gdb/cli/cli-cmds.c
@@ -27,7 +27,6 @@
 #include "target.h"	/* For baud_rate, remote_debug and remote_timeout.  */
 #include "gdb_wait.h"	/* For shell escape implementation.  */
 #include "gdb_regex.h"	/* Used by apropos_command.  */
-#include <string.h>
 #include "gdb_vfork.h"
 #include "linespec.h"
 #include "expression.h"
diff --git a/gdb/cli/cli-decode.c b/gdb/cli/cli-decode.c
index 43e1bab..c409d9c 100644
--- a/gdb/cli/cli-decode.c
+++ b/gdb/cli/cli-decode.c
@@ -19,7 +19,6 @@
 #include "symtab.h"
 #include <ctype.h>
 #include "gdb_regex.h"
-#include <string.h>
 #include "completer.h"
 #include "ui-out.h"
 #include "cli/cli-cmds.h"
diff --git a/gdb/cli/cli-dump.c b/gdb/cli/cli-dump.c
index b643be4..c093cd4 100644
--- a/gdb/cli/cli-dump.c
+++ b/gdb/cli/cli-dump.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "cli/cli-decode.h"
 #include "cli/cli-cmds.h"
 #include "value.h"
diff --git a/gdb/cli/cli-interp.c b/gdb/cli/cli-interp.c
index dc09b24..9b2aaaa 100644
--- a/gdb/cli/cli-interp.c
+++ b/gdb/cli/cli-interp.c
@@ -23,7 +23,6 @@
 #include "ui-out.h"
 #include "cli-out.h"
 #include "top.h"		/* for "execute_command" */
-#include <string.h>
 #include "exceptions.h"
 #include "infrun.h"
 #include "observer.h"
diff --git a/gdb/cli/cli-logging.c b/gdb/cli/cli-logging.c
index 3b1447a..ce82b77 100644
--- a/gdb/cli/cli-logging.c
+++ b/gdb/cli/cli-logging.c
@@ -22,8 +22,6 @@
 #include "ui-out.h"
 #include "interps.h"
 
-#include <string.h>
-
 /* These hold the pushed copies of the gdb output files.
    If NULL then nothing has yet been pushed.  */
 struct saved_output_files
diff --git a/gdb/cli/cli-script.c b/gdb/cli/cli-script.c
index d3ca9ec..0f0a97e 100644
--- a/gdb/cli/cli-script.c
+++ b/gdb/cli/cli-script.c
@@ -23,7 +23,6 @@
 #include <ctype.h>
 
 #include "ui-out.h"
-#include <string.h>
 #include "exceptions.h"
 #include "top.h"
 #include "breakpoint.h"
diff --git a/gdb/cli/cli-setshow.c b/gdb/cli/cli-setshow.c
index 0f936a4..a7d0728 100644
--- a/gdb/cli/cli-setshow.c
+++ b/gdb/cli/cli-setshow.c
@@ -19,7 +19,6 @@
 #include "readline/tilde.h"
 #include "value.h"
 #include <ctype.h>
-#include <string.h>
 #include "arch-utils.h"
 #include "observer.h"
 
diff --git a/gdb/cli/cli-utils.c b/gdb/cli/cli-utils.c
index 3deac36..58c08de 100644
--- a/gdb/cli/cli-utils.c
+++ b/gdb/cli/cli-utils.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "cli/cli-utils.h"
-#include <string.h>
 #include "value.h"
 
 #include <ctype.h>
diff --git a/gdb/coffread.c b/gdb/coffread.c
index 9cbe173..ea494f5 100644
--- a/gdb/coffread.c
+++ b/gdb/coffread.c
@@ -25,8 +25,6 @@
 
 #include "bfd.h"
 #include "gdb_obstack.h"
-
-#include <string.h>
 #include <ctype.h>
 
 #include "coff/internal.h"	/* Internal format of COFF symbols in BFD */
diff --git a/gdb/common/agent.c b/gdb/common/agent.c
index 54f861a..3f868ba 100644
--- a/gdb/common/agent.c
+++ b/gdb/common/agent.c
@@ -25,8 +25,6 @@
 #include "infrun.h"
 #include "objfiles.h"
 #endif
-
-#include <string.h>
 #include <unistd.h>
 #include "agent.h"
 #include "filestuff.h"
diff --git a/gdb/common/buffer.c b/gdb/common/buffer.c
index c291b32..4a213b3 100644
--- a/gdb/common/buffer.c
+++ b/gdb/common/buffer.c
@@ -26,8 +26,6 @@
 #include "xml-utils.h"
 #include "buffer.h"
 #include "inttypes.h"
-
-#include <string.h>
 #include <stdint.h>
 
 void
diff --git a/gdb/common/buffer.h b/gdb/common/buffer.h
index 98da0d2..1c748dd 100644
--- a/gdb/common/buffer.h
+++ b/gdb/common/buffer.h
@@ -20,8 +20,6 @@
 #ifndef BUFFER_H
 #define BUFFER_H
 
-#include <string.h>
-
 struct buffer
 {
   char *buffer;
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 75a587a..7c67846 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -31,6 +31,7 @@
 #include <stdlib.h>
 #include <stdarg.h>
 #include <stddef.h>
+#include <string.h>
 #include "ansidecl.h"
 #include "libiberty.h"
 #include "pathmax.h"
diff --git a/gdb/common/common-utils.c b/gdb/common/common-utils.c
index 3fe9bf9..a905d1d 100644
--- a/gdb/common/common-utils.c
+++ b/gdb/common/common-utils.c
@@ -23,8 +23,6 @@
 #include "defs.h"
 #endif
 
-#include <string.h>
-
 /* The xmalloc() (libiberty.h) family of memory management routines.
 
    These are like the ISO-C malloc() family except that they implement
diff --git a/gdb/common/filestuff.c b/gdb/common/filestuff.c
index 4544926..a31ecd7 100644
--- a/gdb/common/filestuff.c
+++ b/gdb/common/filestuff.c
@@ -20,12 +20,9 @@
 #include "server.h"
 #else
 #include "defs.h"
-#include <string.h>
 #endif
 #include "filestuff.h"
 #include "gdb_vecs.h"
-
-#include <string.h>
 #include <fcntl.h>
 #include <unistd.h>
 #include <sys/types.h>
diff --git a/gdb/common/format.c b/gdb/common/format.c
index bddfbc6..247aaff 100644
--- a/gdb/common/format.c
+++ b/gdb/common/format.c
@@ -23,8 +23,6 @@
 #include "defs.h"
 #endif
 
-#include <string.h>
-
 #include "format.h"
 
 struct format_piece *
diff --git a/gdb/common/print-utils.c b/gdb/common/print-utils.c
index 0e612a3..f5bef0a 100644
--- a/gdb/common/print-utils.c
+++ b/gdb/common/print-utils.c
@@ -24,8 +24,6 @@
 #endif
 
 #include "print-utils.h"
-
-#include <string.h>
 #include <stdint.h>
 
 /* Temporary storage using circular buffer.  */
diff --git a/gdb/common/rsp-low.c b/gdb/common/rsp-low.c
index b777716..0263005 100644
--- a/gdb/common/rsp-low.c
+++ b/gdb/common/rsp-low.c
@@ -23,8 +23,6 @@
 #include "defs.h"
 #endif
 
-#include <string.h>
-
 #include "rsp-low.h"
 
 /* See rsp-low.h.  */
diff --git a/gdb/common/signals.c b/gdb/common/signals.c
index d9cacee..13d1e2c 100644
--- a/gdb/common/signals.c
+++ b/gdb/common/signals.c
@@ -21,7 +21,6 @@
 #include "server.h"
 #else
 #include "defs.h"
-#include <string.h>
 #endif
 
 #ifdef HAVE_SIGNAL_H
diff --git a/gdb/common/vec.h b/gdb/common/vec.h
index 82d4b0d..c406c9c 100644
--- a/gdb/common/vec.h
+++ b/gdb/common/vec.h
@@ -20,8 +20,6 @@
 #if !defined (GDB_VEC_H)
 #define GDB_VEC_H
 
-#include <string.h>
-
 /* The macros here implement a set of templated vector types and
    associated interfaces.  These templates are implemented with
    macros, as we're not in C++ land.  The interface functions are
diff --git a/gdb/common/xml-utils.c b/gdb/common/xml-utils.c
index c6ceb69..0f81390 100644
--- a/gdb/common/xml-utils.c
+++ b/gdb/common/xml-utils.c
@@ -25,8 +25,6 @@
 
 #include "xml-utils.h"
 
-#include <string.h>
-
 /* Return a malloc allocated string with special characters from TEXT
    replaced by entity references.  */
 
diff --git a/gdb/core-regset.c b/gdb/core-regset.c
index 21ea889..6edc8c5 100644
--- a/gdb/core-regset.c
+++ b/gdb/core-regset.c
@@ -35,7 +35,6 @@
 
 #include <fcntl.h>
 #include <errno.h>
-#include <string.h>
 #include <time.h>
 #ifdef HAVE_SYS_PROCFS_H
 #include <sys/procfs.h>
diff --git a/gdb/corefile.c b/gdb/corefile.c
index 8a96d75..1eaecb5 100644
--- a/gdb/corefile.c
+++ b/gdb/corefile.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include <errno.h>
 #include <signal.h>
 #include <fcntl.h>
diff --git a/gdb/corelow.c b/gdb/corelow.c
index 650b67c..1c9a93d 100644
--- a/gdb/corelow.c
+++ b/gdb/corelow.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "arch-utils.h"
-#include <string.h>
 #include <errno.h>
 #include <signal.h>
 #include <fcntl.h>
diff --git a/gdb/cp-abi.c b/gdb/cp-abi.c
index c1a0d29..eede3e5 100644
--- a/gdb/cp-abi.c
+++ b/gdb/cp-abi.c
@@ -24,8 +24,6 @@
 #include "exceptions.h"
 #include "gdbcmd.h"
 #include "ui-out.h"
-#include <string.h>
-
 static struct cp_abi_ops *find_cp_abi (const char *short_name);
 
 static struct cp_abi_ops current_cp_abi = { "", NULL };
diff --git a/gdb/cp-name-parser.y b/gdb/cp-name-parser.y
index a0b7f8b..3cceb59 100644
--- a/gdb/cp-name-parser.y
+++ b/gdb/cp-name-parser.y
@@ -32,8 +32,6 @@
 #include "defs.h"
 
 #include <unistd.h>
-#include <string.h>
-
 #include "safe-ctype.h"
 #include "demangle.h"
 #include "cp-support.h"
diff --git a/gdb/cp-support.c b/gdb/cp-support.c
index f1dfcfa..20a4a07 100644
--- a/gdb/cp-support.c
+++ b/gdb/cp-support.c
@@ -20,7 +20,6 @@
 
 #include "defs.h"
 #include "cp-support.h"
-#include <string.h>
 #include "demangle.h"
 #include "gdbcmd.h"
 #include "dictionary.h"
diff --git a/gdb/cp-valprint.c b/gdb/cp-valprint.c
index 3e1d6ed..a8187a1 100644
--- a/gdb/cp-valprint.c
+++ b/gdb/cp-valprint.c
@@ -27,7 +27,6 @@
 #include "gdbcmd.h"
 #include "demangle.h"
 #include "annotate.h"
-#include <string.h>
 #include "c-lang.h"
 #include "target.h"
 #include "cp-abi.h"
diff --git a/gdb/cris-tdep.c b/gdb/cris-tdep.c
index 909a227..aeccb13 100644
--- a/gdb/cris-tdep.c
+++ b/gdb/cris-tdep.c
@@ -42,7 +42,6 @@
 
 #include "solib.h"              /* Support for shared libraries.  */
 #include "solib-svr4.h"
-#include <string.h>
 #include "dis-asm.h"
 
 #include "cris-tdep.h"
diff --git a/gdb/d-exp.y b/gdb/d-exp.y
index e0512eb..cae3419 100644
--- a/gdb/d-exp.y
+++ b/gdb/d-exp.y
@@ -39,7 +39,6 @@
 %{
 
 #include "defs.h"
-#include <string.h>
 #include <ctype.h>
 #include "expression.h"
 #include "value.h"
diff --git a/gdb/darwin-nat.c b/gdb/darwin-nat.c
index 5714288..af4ec01 100644
--- a/gdb/darwin-nat.c
+++ b/gdb/darwin-nat.c
@@ -46,7 +46,6 @@
 #include <sys/types.h>
 #include <unistd.h>
 #include <signal.h>
-#include <string.h>
 #include <ctype.h>
 #include <sys/sysctl.h>
 #include <sys/proc.h>
diff --git a/gdb/dbxread.c b/gdb/dbxread.c
index 1807094..fd7910c 100644
--- a/gdb/dbxread.c
+++ b/gdb/dbxread.c
@@ -31,8 +31,6 @@
    for real.  dbx_psymtab_to_symtab() is the function that does this */
 
 #include "defs.h"
-#include <string.h>
-
 #if defined(__CYGNUSCLIB__)
 #include <sys/types.h>
 #include <fcntl.h>
diff --git a/gdb/dcache.c b/gdb/dcache.c
index 6bf0e91..ef17531 100644
--- a/gdb/dcache.c
+++ b/gdb/dcache.c
@@ -20,7 +20,6 @@
 #include "defs.h"
 #include "dcache.h"
 #include "gdbcmd.h"
-#include <string.h>
 #include "gdbcore.h"
 #include "target-dcache.h"
 #include "inferior.h"
diff --git a/gdb/demangle.c b/gdb/demangle.c
index c6421ee..be46de9 100644
--- a/gdb/demangle.c
+++ b/gdb/demangle.c
@@ -28,8 +28,6 @@
 #include "gdbcmd.h"
 #include "demangle.h"
 #include "gdb-demangle.h"
-#include <string.h>
-
 /* Select the default C++ demangling style to use.  The default is "auto",
    which allows gdb to attempt to pick an appropriate demangling style for
    the executable it has loaded.  It can be set to a specific style ("gnu",
diff --git a/gdb/dicos-tdep.c b/gdb/dicos-tdep.c
index f2964db..5276399 100644
--- a/gdb/dicos-tdep.c
+++ b/gdb/dicos-tdep.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "osabi.h"
-#include <string.h>
 #include "solib.h"
 #include "solib-target.h"
 #include "inferior.h"
diff --git a/gdb/disasm.c b/gdb/disasm.c
index d94225b..6ff3793 100644
--- a/gdb/disasm.c
+++ b/gdb/disasm.c
@@ -21,7 +21,6 @@
 #include "target.h"
 #include "value.h"
 #include "ui-out.h"
-#include <string.h>
 #include "disasm.h"
 #include "gdbcore.h"
 #include "dis-asm.h"
diff --git a/gdb/doublest.c b/gdb/doublest.c
index bd4ca6e..ebcb82f 100644
--- a/gdb/doublest.c
+++ b/gdb/doublest.c
@@ -26,7 +26,6 @@
 #include "defs.h"
 #include "doublest.h"
 #include "floatformat.h"
-#include <string.h>
 #include "gdbtypes.h"
 #include <math.h>		/* ldexp */
 
diff --git a/gdb/dsrec.c b/gdb/dsrec.c
index c9f8636..224bd0e 100644
--- a/gdb/dsrec.c
+++ b/gdb/dsrec.c
@@ -21,7 +21,6 @@
 #include "srec.h"
 #include <sys/time.h>
 #include <time.h>
-#include <string.h>
 #include "gdb_bfd.h"
 
 extern int remote_debug;
diff --git a/gdb/dummy-frame.c b/gdb/dummy-frame.c
index d547a63..a13601b 100644
--- a/gdb/dummy-frame.c
+++ b/gdb/dummy-frame.c
@@ -26,7 +26,6 @@
 #include "frame-unwind.h"
 #include "command.h"
 #include "gdbcmd.h"
-#include <string.h>
 #include "observer.h"
 #include "gdbthread.h"
 
diff --git a/gdb/dwarf2-frame.c b/gdb/dwarf2-frame.c
index 01e0670..f2330d9 100644
--- a/gdb/dwarf2-frame.c
+++ b/gdb/dwarf2-frame.c
@@ -33,8 +33,6 @@
 #include "value.h"
 #include "record.h"
 
-#include <string.h>
-
 #include "complaints.h"
 #include "dwarf2-frame.h"
 #include "ax.h"
diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
index 8f050b8..1056e5d 100644
--- a/gdb/dwarf2loc.c
+++ b/gdb/dwarf2loc.c
@@ -39,8 +39,6 @@
 #include "dwarf2loc.h"
 #include "dwarf2-frame.h"
 
-#include <string.h>
-
 extern int dwarf2_always_disassemble;
 
 static void dwarf_expr_frame_base_1 (struct symbol *framefunc, CORE_ADDR pc,
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
index cb1bd3a..48b18f9 100644
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -72,7 +72,6 @@
 #include "build-id.h"
 
 #include <fcntl.h>
-#include <string.h>
 #include <sys/types.h>
 
 typedef struct symbol *symbolp;
diff --git a/gdb/elfread.c b/gdb/elfread.c
index 085ff47..9b8233c 100644
--- a/gdb/elfread.c
+++ b/gdb/elfread.c
@@ -21,7 +21,6 @@
 
 #include "defs.h"
 #include "bfd.h"
-#include <string.h>
 #include "elf-bfd.h"
 #include "elf/common.h"
 #include "elf/internal.h"
diff --git a/gdb/environ.c b/gdb/environ.c
index d661a01..7edb76e 100644
--- a/gdb/environ.c
+++ b/gdb/environ.c
@@ -20,7 +20,6 @@
 
 #include "defs.h"
 #include "environ.h"
-#include <string.h>
 \f
 
 /* Return a new environment object.  */
diff --git a/gdb/eval.c b/gdb/eval.c
index b375850..de8e8ec 100644
--- a/gdb/eval.c
+++ b/gdb/eval.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "value.h"
diff --git a/gdb/event-loop.c b/gdb/event-loop.c
index 221dfbc..cc2f837 100644
--- a/gdb/event-loop.c
+++ b/gdb/event-loop.c
@@ -31,7 +31,6 @@
 #endif
 
 #include <sys/types.h>
-#include <string.h>
 #include <errno.h>
 #include <sys/time.h>
 #include "exceptions.h"
diff --git a/gdb/exceptions.c b/gdb/exceptions.c
index 4efc888..38e966c 100644
--- a/gdb/exceptions.c
+++ b/gdb/exceptions.c
@@ -24,7 +24,6 @@
 #include "inferior.h"
 #include "annotate.h"
 #include "ui-out.h"
-#include <string.h>
 #include "serial.h"
 #include "gdbthread.h"
 
diff --git a/gdb/exec.c b/gdb/exec.c
index 8b6f588..ce903b0 100644
--- a/gdb/exec.c
+++ b/gdb/exec.c
@@ -38,8 +38,6 @@
 
 #include <fcntl.h>
 #include "readline/readline.h"
-#include <string.h>
-
 #include "gdbcore.h"
 
 #include <ctype.h>
diff --git a/gdb/expprint.c b/gdb/expprint.c
index 0f87033..59fd4e3 100644
--- a/gdb/expprint.c
+++ b/gdb/expprint.c
@@ -26,7 +26,6 @@
 #include "parser-defs.h"
 #include "user-regs.h"		/* For user_reg_map_regnum_to_name.  */
 #include "target.h"
-#include <string.h>
 #include "block.h"
 #include "objfiles.h"
 #include "valprint.h"
diff --git a/gdb/f-exp.y b/gdb/f-exp.y
index c70da17..f229afa 100644
--- a/gdb/f-exp.y
+++ b/gdb/f-exp.y
@@ -43,7 +43,6 @@
 %{
 
 #include "defs.h"
-#include <string.h>
 #include "expression.h"
 #include "value.h"
 #include "parser-defs.h"
diff --git a/gdb/f-lang.c b/gdb/f-lang.c
index bbfd89c..52da04e 100644
--- a/gdb/f-lang.c
+++ b/gdb/f-lang.c
@@ -21,7 +21,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "expression.h"
diff --git a/gdb/f-typeprint.c b/gdb/f-typeprint.c
index 8356aab..534019a 100644
--- a/gdb/f-typeprint.c
+++ b/gdb/f-typeprint.c
@@ -30,8 +30,6 @@
 #include "gdbcore.h"
 #include "target.h"
 #include "f-lang.h"
-
-#include <string.h>
 #include <errno.h>
 
 #if 0				/* Currently unused.  */
diff --git a/gdb/f-valprint.c b/gdb/f-valprint.c
index 728bdaf..c7581a8 100644
--- a/gdb/f-valprint.c
+++ b/gdb/f-valprint.c
@@ -21,7 +21,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "expression.h"
diff --git a/gdb/fbsd-nat.c b/gdb/fbsd-nat.c
index e4b34f6..e9db30e 100644
--- a/gdb/fbsd-nat.c
+++ b/gdb/fbsd-nat.c
@@ -23,8 +23,6 @@
 #include "regcache.h"
 #include "regset.h"
 #include "gdbthread.h"
-
-#include <string.h>
 #include <sys/types.h>
 #include <sys/procfs.h>
 #include <sys/sysctl.h>
diff --git a/gdb/findcmd.c b/gdb/findcmd.c
index 9b1c0a6..3c7b9fb 100644
--- a/gdb/findcmd.c
+++ b/gdb/findcmd.c
@@ -20,7 +20,6 @@
 #include "defs.h"
 #include "arch-utils.h"
 #include <ctype.h>
-#include <string.h>
 #include "gdbcmd.h"
 #include "value.h"
 #include "target.h"
diff --git a/gdb/findvar.c b/gdb/findvar.c
index 465c9cc..41887de 100644
--- a/gdb/findvar.c
+++ b/gdb/findvar.c
@@ -25,7 +25,6 @@
 #include "gdbcore.h"
 #include "inferior.h"
 #include "target.h"
-#include <string.h>
 #include "floatformat.h"
 #include "symfile.h"		/* for overlay functions */
 #include "regcache.h"
diff --git a/gdb/fork-child.c b/gdb/fork-child.c
index 6c42d2e..4c316b1 100644
--- a/gdb/fork-child.c
+++ b/gdb/fork-child.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "inferior.h"
 #include "terminal.h"
 #include "target.h"
diff --git a/gdb/frame.c b/gdb/frame.c
index 9d8c8b7..1f63819 100644
--- a/gdb/frame.c
+++ b/gdb/frame.c
@@ -23,7 +23,6 @@
 #include "value.h"
 #include "inferior.h"	/* for inferior_ptid */
 #include "regcache.h"
-#include <string.h>
 #include "user-regs.h"
 #include "gdb_obstack.h"
 #include "dummy-frame.h"
diff --git a/gdb/frv-linux-tdep.c b/gdb/frv-linux-tdep.c
index fb163a8..02f6b21 100644
--- a/gdb/frv-linux-tdep.c
+++ b/gdb/frv-linux-tdep.c
@@ -30,7 +30,6 @@
 #include "trad-frame.h"
 #include "frame-unwind.h"
 #include "regset.h"
-#include <string.h>
 #include "linux-tdep.h"
 
 /* Define the size (in bytes) of an FR-V instruction.  */
diff --git a/gdb/frv-tdep.c b/gdb/frv-tdep.c
index 349e58d..ce6ad58 100644
--- a/gdb/frv-tdep.c
+++ b/gdb/frv-tdep.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "inferior.h"
 #include "gdbcore.h"
 #include "arch-utils.h"
diff --git a/gdb/gdb.c b/gdb/gdb.c
index 78cfb12..46df20b 100644
--- a/gdb/gdb.c
+++ b/gdb/gdb.c
@@ -18,7 +18,6 @@
 
 #include "defs.h"
 #include "main.h"
-#include <string.h>
 #include "interps.h"
 
 int
diff --git a/gdb/gdb_bfd.c b/gdb/gdb_bfd.c
index fdde3e7..2f3e9ba 100644
--- a/gdb/gdb_bfd.c
+++ b/gdb/gdb_bfd.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "gdb_bfd.h"
-#include <string.h>
 #include "ui-out.h"
 #include "gdbcmd.h"
 #include "hashtab.h"
diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c
index 74caa93..b0ee79d 100644
--- a/gdb/gdbarch.c
+++ b/gdb/gdbarch.c
@@ -41,8 +41,6 @@
 #include "symcat.h"
 
 #include "floatformat.h"
-
-#include <string.h>
 #include "reggroups.h"
 #include "osabi.h"
 #include "gdb_obstack.h"
diff --git a/gdb/gdbarch.sh b/gdb/gdbarch.sh
index 9eab8f0..61d0781 100755
--- a/gdb/gdbarch.sh
+++ b/gdb/gdbarch.sh
@@ -1472,8 +1472,6 @@ cat <<EOF
 #include "symcat.h"
 
 #include "floatformat.h"
-
-#include <string.h>
 #include "reggroups.h"
 #include "osabi.h"
 #include "gdb_obstack.h"
diff --git a/gdb/gdbserver/event-loop.c b/gdb/gdbserver/event-loop.c
index dc1eb41..1513b59 100644
--- a/gdb/gdbserver/event-loop.c
+++ b/gdb/gdbserver/event-loop.c
@@ -22,7 +22,6 @@
 #include "queue.h"
 
 #include <sys/types.h>
-#include <string.h>
 #include <sys/time.h>
 
 #ifdef USE_WIN32API
diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c
index b599bef..74289c0 100644
--- a/gdb/gdbserver/linux-low.c
+++ b/gdb/gdbserver/linux-low.c
@@ -30,7 +30,6 @@
 #include <signal.h>
 #include <sys/ioctl.h>
 #include <fcntl.h>
-#include <string.h>
 #include <unistd.h>
 #include <errno.h>
 #include <sys/syscall.h>
diff --git a/gdb/gdbserver/regcache.c b/gdb/gdbserver/regcache.c
index 5c973b1..db9dad9 100644
--- a/gdb/gdbserver/regcache.c
+++ b/gdb/gdbserver/regcache.c
@@ -21,8 +21,6 @@
 #include "gdbthread.h"
 #include "tdesc.h"
 #include "rsp-low.h"
-#include <string.h>
-
 #ifndef IN_PROCESS_AGENT
 
 struct regcache *
diff --git a/gdb/gdbserver/remote-utils.c b/gdb/gdbserver/remote-utils.c
index 96d6038..f3ae393 100644
--- a/gdb/gdbserver/remote-utils.c
+++ b/gdb/gdbserver/remote-utils.c
@@ -23,8 +23,6 @@
 #include "tdesc.h"
 #include "dll.h"
 #include "rsp-low.h"
-
-#include <string.h>
 #if HAVE_SYS_IOCTL_H
 #include <sys/ioctl.h>
 #endif
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 2052103..1e2c3a1 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -32,8 +32,6 @@
 #endif
 #include <setjmp.h>
 
-#include <string.h>
-
 #ifdef HAVE_ALLOCA_H
 #include <alloca.h>
 #endif
diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c
index ba2780b..cb1ac0d 100644
--- a/gdb/gdbserver/spu-low.c
+++ b/gdb/gdbserver/spu-low.c
@@ -23,7 +23,6 @@
 #include "gdb_wait.h"
 #include <sys/ptrace.h>
 #include <fcntl.h>
-#include <string.h>
 #include <unistd.h>
 #include <errno.h>
 #include <sys/syscall.h>
diff --git a/gdb/gdbserver/utils.c b/gdb/gdbserver/utils.c
index a0febb1..ec37a9b 100644
--- a/gdb/gdbserver/utils.c
+++ b/gdb/gdbserver/utils.c
@@ -17,7 +17,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "server.h"
-#include <string.h>
 #if HAVE_ERRNO_H
 #include <errno.h>
 #endif
diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
index 54a4e1d..63259f0 100644
--- a/gdb/gdbtypes.c
+++ b/gdb/gdbtypes.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "bfd.h"
 #include "symtab.h"
 #include "symfile.h"
diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c
index 3eebba5..d6658c7 100644
--- a/gdb/gnu-nat.c
+++ b/gdb/gnu-nat.c
@@ -27,7 +27,6 @@
 #include <limits.h>
 #include <setjmp.h>
 #include <signal.h>
-#include <string.h>
 #include <sys/ptrace.h>
 
 #include <mach.h>
diff --git a/gdb/gnu-v2-abi.c b/gdb/gnu-v2-abi.c
index 3ca01c3..5e55b67 100644
--- a/gdb/gnu-v2-abi.c
+++ b/gdb/gnu-v2-abi.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "value.h"
diff --git a/gdb/gnu-v3-abi.c b/gdb/gnu-v3-abi.c
index 5a81213..d5ed355 100644
--- a/gdb/gnu-v3-abi.c
+++ b/gdb/gnu-v3-abi.c
@@ -29,8 +29,6 @@
 #include "exceptions.h"
 #include "typeprint.h"
 
-#include <string.h>
-
 static struct cp_abi_ops gnu_v3_abi_ops;
 
 /* A gdbarch key for std::type_info, in the event that it can't be
diff --git a/gdb/go-exp.y b/gdb/go-exp.y
index bab5dde..f9ffbf9 100644
--- a/gdb/go-exp.y
+++ b/gdb/go-exp.y
@@ -52,7 +52,6 @@
 %{
 
 #include "defs.h"
-#include <string.h>
 #include <ctype.h>
 #include "expression.h"
 #include "value.h"
diff --git a/gdb/go-lang.c b/gdb/go-lang.c
index f1a2dba..8cbc234 100644
--- a/gdb/go-lang.c
+++ b/gdb/go-lang.c
@@ -33,7 +33,6 @@
 
 #include "defs.h"
 #include "gdb_obstack.h"
-#include <string.h>
 #include "block.h"
 #include "symtab.h"
 #include "language.h"
diff --git a/gdb/go32-nat.c b/gdb/go32-nat.c
index a8c54fa..75596a2 100644
--- a/gdb/go32-nat.c
+++ b/gdb/go32-nat.c
@@ -100,7 +100,6 @@
 #include "nat/i386-cpuid.h"
 #include "value.h"
 #include "regcache.h"
-#include <string.h>
 #include "top.h"
 #include "cli/cli-utils.h"
 #include "inf-child.h"
diff --git a/gdb/guile/guile.c b/gdb/guile/guile.c
index ff99cdf..575bb6c 100644
--- a/gdb/guile/guile.c
+++ b/gdb/guile/guile.c
@@ -21,7 +21,6 @@
    conventions, et.al.  */
 
 #include "defs.h"
-#include <string.h>
 #include "breakpoint.h"
 #include "cli/cli-cmds.h"
 #include "cli/cli-script.h"
diff --git a/gdb/guile/scm-auto-load.c b/gdb/guile/scm-auto-load.c
index 5b9eb23..b67d8ff 100644
--- a/gdb/guile/scm-auto-load.c
+++ b/gdb/guile/scm-auto-load.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "top.h"
 #include "exceptions.h"
 #include "gdbcmd.h"
diff --git a/gdb/hppa-hpux-tdep.c b/gdb/hppa-hpux-tdep.c
index 588f577..688ac9a 100644
--- a/gdb/hppa-hpux-tdep.c
+++ b/gdb/hppa-hpux-tdep.c
@@ -36,8 +36,6 @@
 #include "regcache.h"
 #include "exceptions.h"
 
-#include <string.h>
-
 #define IS_32BIT_TARGET(_gdbarch) \
 	((gdbarch_tdep (_gdbarch))->bytes_per_address == 4)
 
diff --git a/gdb/hppa-linux-nat.c b/gdb/hppa-linux-nat.c
index 58650d0..6d0de14 100644
--- a/gdb/hppa-linux-nat.c
+++ b/gdb/hppa-linux-nat.c
@@ -20,7 +20,6 @@
 #include "defs.h"
 #include "gdbcore.h"
 #include "regcache.h"
-#include <string.h>
 #include "inferior.h"
 #include "target.h"
 #include "linux-nat.h"
diff --git a/gdb/hppanbsd-tdep.c b/gdb/hppanbsd-tdep.c
index 657d4c2..b3f04c7 100644
--- a/gdb/hppanbsd-tdep.c
+++ b/gdb/hppanbsd-tdep.c
@@ -25,8 +25,6 @@
 #include "trad-frame.h"
 #include "tramp-frame.h"
 
-#include <string.h>
-
 #include "hppa-tdep.h"
 #include "hppabsd-tdep.h"
 
diff --git a/gdb/hppaobsd-tdep.c b/gdb/hppaobsd-tdep.c
index eece2d1..c521359 100644
--- a/gdb/hppaobsd-tdep.c
+++ b/gdb/hppaobsd-tdep.c
@@ -22,8 +22,6 @@
 #include "regcache.h"
 #include "regset.h"
 
-#include <string.h>
-
 #include "hppa-tdep.h"
 #include "hppabsd-tdep.h"
 
diff --git a/gdb/i386-cygwin-tdep.c b/gdb/i386-cygwin-tdep.c
index a23f80e..47c7bde 100644
--- a/gdb/i386-cygwin-tdep.c
+++ b/gdb/i386-cygwin-tdep.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "osabi.h"
-#include <string.h>
 #include "i386-tdep.h"
 #include "windows-tdep.h"
 #include "regset.h"
diff --git a/gdb/i386-dicos-tdep.c b/gdb/i386-dicos-tdep.c
index 5480932..45a7889 100644
--- a/gdb/i386-dicos-tdep.c
+++ b/gdb/i386-dicos-tdep.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "osabi.h"
-#include <string.h>
 #include "dicos-tdep.h"
 
 static void
diff --git a/gdb/i386-linux-tdep.c b/gdb/i386-linux-tdep.c
index 8ab8954..aa60d3a 100644
--- a/gdb/i386-linux-tdep.c
+++ b/gdb/i386-linux-tdep.c
@@ -27,8 +27,6 @@
 #include "osabi.h"
 #include "reggroups.h"
 #include "dwarf2-frame.h"
-#include <string.h>
-
 #include "i386-tdep.h"
 #include "i386-linux-tdep.h"
 #include "linux-tdep.h"
diff --git a/gdb/i386-nto-tdep.c b/gdb/i386-nto-tdep.c
index 57be471..fcb578e 100644
--- a/gdb/i386-nto-tdep.c
+++ b/gdb/i386-nto-tdep.c
@@ -25,8 +25,6 @@
 #include "regcache.h"
 #include "target.h"
 
-#include <string.h>
-
 #include "i386-tdep.h"
 #include "i387-tdep.h"
 #include "nto-tdep.h"
diff --git a/gdb/i386-sol2-tdep.c b/gdb/i386-sol2-tdep.c
index 0795754..fb4dc89 100644
--- a/gdb/i386-sol2-tdep.c
+++ b/gdb/i386-sol2-tdep.c
@@ -21,8 +21,6 @@
 #include "value.h"
 #include "osabi.h"
 
-#include <string.h>
-
 #include "sol2-tdep.h"
 #include "i386-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c
index 7544f06..6a8ed55 100644
--- a/gdb/i386-tdep.c
+++ b/gdb/i386-tdep.c
@@ -45,8 +45,6 @@
 #include "disasm.h"
 #include "remote.h"
 #include "exceptions.h"
-#include <string.h>
-
 #include "i386-tdep.h"
 #include "i387-tdep.h"
 #include "i386-xstate.h"
diff --git a/gdb/i386bsd-tdep.c b/gdb/i386bsd-tdep.c
index fe40aae..6266860 100644
--- a/gdb/i386bsd-tdep.c
+++ b/gdb/i386bsd-tdep.c
@@ -24,8 +24,6 @@
 #include "regcache.h"
 #include "osabi.h"
 
-#include <string.h>
-
 #include "i386-tdep.h"
 
 /* Support for signal handlers.  */
diff --git a/gdb/i386gnu-nat.c b/gdb/i386gnu-nat.c
index fbd3344..94d2a0a 100644
--- a/gdb/i386gnu-nat.c
+++ b/gdb/i386gnu-nat.c
@@ -23,8 +23,6 @@
 #include "regcache.h"
 
 #include <errno.h>
-#include <string.h>
-
 #include <mach.h>
 #include <mach_error.h>
 #include <mach/message.h>
diff --git a/gdb/i386nbsd-tdep.c b/gdb/i386nbsd-tdep.c
index 4b024f5..e0719f4 100644
--- a/gdb/i386nbsd-tdep.c
+++ b/gdb/i386nbsd-tdep.c
@@ -28,8 +28,6 @@
 #include "trad-frame.h"
 #include "tramp-frame.h"
 
-#include <string.h>
-
 #include "i386-tdep.h"
 #include "i387-tdep.h"
 #include "nbsd-tdep.h"
diff --git a/gdb/i386obsd-tdep.c b/gdb/i386obsd-tdep.c
index acdfc7e..2b7d48b 100644
--- a/gdb/i386obsd-tdep.c
+++ b/gdb/i386obsd-tdep.c
@@ -30,8 +30,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include <string.h>
-
 #include "obsd-tdep.h"
 #include "i386-tdep.h"
 #include "i387-tdep.h"
diff --git a/gdb/i387-tdep.c b/gdb/i387-tdep.c
index 1613c2f..07bdba5 100644
--- a/gdb/i387-tdep.c
+++ b/gdb/i387-tdep.c
@@ -27,8 +27,6 @@
 #include "regcache.h"
 #include "value.h"
 
-#include <string.h>
-
 #include "i386-tdep.h"
 #include "i387-tdep.h"
 #include "i386-xstate.h"
diff --git a/gdb/ia64-libunwind-tdep.c b/gdb/ia64-libunwind-tdep.c
index dec4547..bdef72f 100644
--- a/gdb/ia64-libunwind-tdep.c
+++ b/gdb/ia64-libunwind-tdep.c
@@ -33,8 +33,6 @@
 
 #include <dlfcn.h>
 
-#include <string.h>
-
 #include "ia64-libunwind-tdep.h"
 
 #include "complaints.h"
diff --git a/gdb/ia64-linux-nat.c b/gdb/ia64-linux-nat.c
index 3cfbd76..961016b 100644
--- a/gdb/ia64-linux-nat.c
+++ b/gdb/ia64-linux-nat.c
@@ -19,7 +19,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "inferior.h"
 #include "target.h"
 #include "gdbcore.h"
diff --git a/gdb/inf-child.c b/gdb/inf-child.c
index 883ed77..4c45955 100644
--- a/gdb/inf-child.c
+++ b/gdb/inf-child.c
@@ -28,7 +28,6 @@
 #include "symtab.h"
 #include "target.h"
 #include "inferior.h"
-#include <string.h>
 #include <sys/stat.h>
 #include "inf-child.h"
 #include "gdb/fileio.h"
diff --git a/gdb/inf-ptrace.c b/gdb/inf-ptrace.c
index c334474..dd71b3a 100644
--- a/gdb/inf-ptrace.c
+++ b/gdb/inf-ptrace.c
@@ -24,8 +24,6 @@
 #include "terminal.h"
 #include "gdbcore.h"
 #include "regcache.h"
-
-#include <string.h>
 #include "gdb_ptrace.h"
 #include "gdb_wait.h"
 #include <signal.h>
diff --git a/gdb/inf-ttrace.c b/gdb/inf-ttrace.c
index d5075f7..847beb3 100644
--- a/gdb/inf-ttrace.c
+++ b/gdb/inf-ttrace.c
@@ -29,8 +29,6 @@
 #include "inferior.h"
 #include "terminal.h"
 #include "target.h"
-
-#include <string.h>
 #include <sys/mman.h>
 #include <sys/ttrace.h>
 #include <signal.h>
diff --git a/gdb/infcall.c b/gdb/infcall.c
index c58295a..e60d1d4 100644
--- a/gdb/infcall.c
+++ b/gdb/infcall.c
@@ -30,7 +30,6 @@
 #include "objfiles.h"
 #include "gdbcmd.h"
 #include "command.h"
-#include <string.h>
 #include "infcall.h"
 #include "dummy-frame.h"
 #include "ada-lang.h"
diff --git a/gdb/infcmd.c b/gdb/infcmd.c
index f5f0ebf..a8806a3 100644
--- a/gdb/infcmd.c
+++ b/gdb/infcmd.c
@@ -20,7 +20,6 @@
 #include "defs.h"
 #include "arch-utils.h"
 #include <signal.h>
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "frame.h"
diff --git a/gdb/inflow.c b/gdb/inflow.c
index 5f81de2..3295c48 100644
--- a/gdb/inflow.c
+++ b/gdb/inflow.c
@@ -25,8 +25,6 @@
 #include "target.h"
 #include "gdbthread.h"
 #include "observer.h"
-
-#include <string.h>
 #include <signal.h>
 #include <fcntl.h>
 #include "gdb_select.h"
diff --git a/gdb/infrun.c b/gdb/infrun.c
index 0614de9..c18267f 100644
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -20,7 +20,6 @@
 
 #include "defs.h"
 #include "infrun.h"
-#include <string.h>
 #include <ctype.h>
 #include "symtab.h"
 #include "frame.h"
diff --git a/gdb/interps.c b/gdb/interps.c
index 297e498..f6e410c 100644
--- a/gdb/interps.c
+++ b/gdb/interps.c
@@ -36,7 +36,6 @@
 #include "event-top.h"
 #include "interps.h"
 #include "completer.h"
-#include <string.h>
 #include "top.h"		/* For command_loop.  */
 #include "exceptions.h"
 #include "continuations.h"
diff --git a/gdb/iq2000-tdep.c b/gdb/iq2000-tdep.c
index c6b3f3b..52e6526 100644
--- a/gdb/iq2000-tdep.c
+++ b/gdb/iq2000-tdep.c
@@ -28,7 +28,6 @@
 #include "gdbtypes.h"
 #include "value.h"
 #include "dis-asm.h"
-#include <string.h>
 #include "arch-utils.h"
 #include "regcache.h"
 #include "osabi.h"
diff --git a/gdb/irix5-nat.c b/gdb/irix5-nat.c
index 71b88b9..f72f183 100644
--- a/gdb/irix5-nat.c
+++ b/gdb/irix5-nat.c
@@ -28,8 +28,6 @@
 #include "target.h"
 #include "regcache.h"
 #include "procfs.h"
-
-#include <string.h>
 #include <sys/time.h>
 #include <sys/procfs.h>
 #include <setjmp.h>		/* For JB_XXX.  */
diff --git a/gdb/jv-exp.y b/gdb/jv-exp.y
index 0894fad..5ce1715 100644
--- a/gdb/jv-exp.y
+++ b/gdb/jv-exp.y
@@ -36,7 +36,6 @@
 %{
 
 #include "defs.h"
-#include <string.h>
 #include <ctype.h>
 #include "expression.h"
 #include "value.h"
diff --git a/gdb/jv-lang.c b/gdb/jv-lang.c
index 5e6bae3..421e665 100644
--- a/gdb/jv-lang.c
+++ b/gdb/jv-lang.c
@@ -25,7 +25,6 @@
 #include "language.h"
 #include "symfile.h"
 #include "objfiles.h"
-#include <string.h>
 #include "value.h"
 #include "c-lang.h"
 #include "jv-lang.h"
diff --git a/gdb/jv-typeprint.c b/gdb/jv-typeprint.c
index 972edf2..24f62ef 100644
--- a/gdb/jv-typeprint.c
+++ b/gdb/jv-typeprint.c
@@ -24,7 +24,6 @@
 #include "demangle.h"
 #include "gdb-demangle.h"
 #include "jv-lang.h"
-#include <string.h>
 #include "typeprint.h"
 #include "c-lang.h"
 #include "cp-abi.h"
diff --git a/gdb/jv-valprint.c b/gdb/jv-valprint.c
index a7bb494..fd5904b 100644
--- a/gdb/jv-valprint.c
+++ b/gdb/jv-valprint.c
@@ -29,8 +29,6 @@
 #include "jv-lang.h"
 #include "c-lang.h"
 #include "annotate.h"
-#include <string.h>
-
 /* Local functions */
 
 void
diff --git a/gdb/language.c b/gdb/language.c
index 1b65d65..034086d 100644
--- a/gdb/language.c
+++ b/gdb/language.c
@@ -30,8 +30,6 @@
 
 #include "defs.h"
 #include <ctype.h>
-#include <string.h>
-
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "value.h"
diff --git a/gdb/linux-fork.c b/gdb/linux-fork.c
index c9995bf..835e612 100644
--- a/gdb/linux-fork.c
+++ b/gdb/linux-fork.c
@@ -25,7 +25,6 @@
 #include "gdbcmd.h"
 #include "infcall.h"
 #include "objfiles.h"
-#include <string.h>
 #include "linux-fork.h"
 #include "linux-nat.h"
 #include "gdbthread.h"
diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
index 703ae07..7e6787f 100644
--- a/gdb/linux-nat.c
+++ b/gdb/linux-nat.c
@@ -23,7 +23,6 @@
 #include "target.h"
 #include "nat/linux-nat.h"
 #include "nat/linux-waitpid.h"
-#include <string.h>
 #include "gdb_wait.h"
 #ifdef HAVE_TKILL_SYSCALL
 #include <unistd.h>
diff --git a/gdb/lm32-tdep.c b/gdb/lm32-tdep.c
index bdd5477..908abce 100644
--- a/gdb/lm32-tdep.c
+++ b/gdb/lm32-tdep.c
@@ -37,8 +37,6 @@
 #include "reggroups.h"
 #include "opcodes/lm32-desc.h"
 
-#include <string.h>
-
 /* Macros to extract fields from an instruction.  */
 #define LM32_OPCODE(insn)       ((insn >> 26) & 0x3f)
 #define LM32_REG0(insn)         ((insn >> 21) & 0x1f)
diff --git a/gdb/m2-exp.y b/gdb/m2-exp.y
index e98abe2..4ea54be 100644
--- a/gdb/m2-exp.y
+++ b/gdb/m2-exp.y
@@ -38,7 +38,6 @@
 %{
 
 #include "defs.h"
-#include <string.h>
 #include "expression.h"
 #include "language.h"
 #include "value.h"
diff --git a/gdb/m2-typeprint.c b/gdb/m2-typeprint.c
index 3078dad..45bc093 100644
--- a/gdb/m2-typeprint.c
+++ b/gdb/m2-typeprint.c
@@ -31,8 +31,6 @@
 #include "c-lang.h"
 #include "typeprint.h"
 #include "cp-abi.h"
-
-#include <string.h>
 #include <errno.h>
 
 static void m2_print_bounds (struct type *type,
diff --git a/gdb/m32c-tdep.c b/gdb/m32c-tdep.c
index 2374f36..ab123c8 100644
--- a/gdb/m32c-tdep.c
+++ b/gdb/m32c-tdep.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "elf-bfd.h"
 #include "elf/m32c.h"
 #include "gdb/sim-m32c.h"
diff --git a/gdb/m32r-linux-nat.c b/gdb/m32r-linux-nat.c
index f38cd53..2049d6c 100644
--- a/gdb/m32r-linux-nat.c
+++ b/gdb/m32r-linux-nat.c
@@ -23,8 +23,6 @@
 #include "regcache.h"
 #include "linux-nat.h"
 #include "target.h"
-
-#include <string.h>
 #include <sys/ptrace.h>
 #include <sys/user.h>
 #include <sys/procfs.h>
diff --git a/gdb/m32r-linux-tdep.c b/gdb/m32r-linux-tdep.c
index bf1ffff..cf98f69 100644
--- a/gdb/m32r-linux-tdep.c
+++ b/gdb/m32r-linux-tdep.c
@@ -27,8 +27,6 @@
 #include "reggroups.h"
 #include "regset.h"
 
-#include <string.h>
-
 #include "glibc-tdep.h"
 #include "solib-svr4.h"
 #include "symtab.h"
diff --git a/gdb/m32r-rom.c b/gdb/m32r-rom.c
index 0ab252a..5f687b3 100644
--- a/gdb/m32r-rom.c
+++ b/gdb/m32r-rom.c
@@ -34,7 +34,6 @@
 #include "symfile.h"		/* for generic load */
 #include <sys/time.h>
 #include <time.h>		/* for time_t */
-#include <string.h>
 #include "objfiles.h"		/* for ALL_OBJFILES etc.  */
 #include "inferior.h"
 #include <ctype.h>
diff --git a/gdb/m32r-tdep.c b/gdb/m32r-tdep.c
index 6928c96..067ff99 100644
--- a/gdb/m32r-tdep.c
+++ b/gdb/m32r-tdep.c
@@ -25,7 +25,6 @@
 #include "gdbtypes.h"
 #include "gdbcmd.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "value.h"
 #include "inferior.h"
 #include "symfile.h"
diff --git a/gdb/m68hc11-tdep.c b/gdb/m68hc11-tdep.c
index 9b7e1af..bf8ecc2 100644
--- a/gdb/m68hc11-tdep.c
+++ b/gdb/m68hc11-tdep.c
@@ -30,7 +30,6 @@
 #include "gdbtypes.h"
 #include "gdbcmd.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "value.h"
 #include "inferior.h"
 #include "dis-asm.h"  
diff --git a/gdb/m68k-tdep.c b/gdb/m68k-tdep.c
index d3c6d01..6bb7e33 100644
--- a/gdb/m68k-tdep.c
+++ b/gdb/m68k-tdep.c
@@ -26,7 +26,6 @@
 #include "symtab.h"
 #include "gdbcore.h"
 #include "value.h"
-#include <string.h>
 #include "inferior.h"
 #include "regcache.h"
 #include "arch-utils.h"
diff --git a/gdb/m68kbsd-tdep.c b/gdb/m68kbsd-tdep.c
index f1f63e1..6ce12b8 100644
--- a/gdb/m68kbsd-tdep.c
+++ b/gdb/m68kbsd-tdep.c
@@ -27,8 +27,6 @@
 #include "tramp-frame.h"
 #include "gdbtypes.h"
 
-#include <string.h>
-
 #include "m68k-tdep.h"
 #include "solib-svr4.h"
 
diff --git a/gdb/m68klinux-nat.c b/gdb/m68klinux-nat.c
index a512a71..0c122af 100644
--- a/gdb/m68klinux-nat.c
+++ b/gdb/m68klinux-nat.c
@@ -22,7 +22,6 @@
 #include "inferior.h"
 #include "language.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "regcache.h"
 #include "target.h"
 #include "linux-nat.h"
diff --git a/gdb/m68klinux-tdep.c b/gdb/m68klinux-tdep.c
index f6fed38..1aae152 100644
--- a/gdb/m68klinux-tdep.c
+++ b/gdb/m68klinux-tdep.c
@@ -23,7 +23,6 @@
 #include "floatformat.h"
 #include "frame.h"
 #include "target.h"
-#include <string.h>
 #include "gdbtypes.h"
 #include "osabi.h"
 #include "regcache.h"
diff --git a/gdb/m88k-tdep.c b/gdb/m88k-tdep.c
index 3ce292e..7c8506b 100644
--- a/gdb/m88k-tdep.c
+++ b/gdb/m88k-tdep.c
@@ -31,8 +31,6 @@
 #include "trad-frame.h"
 #include "value.h"
 
-#include <string.h>
-
 #include "m88k-tdep.h"
 
 /* Fetch the instruction at PC.  */
diff --git a/gdb/machoread.c b/gdb/machoread.c
index 96cc769..c244b25 100644
--- a/gdb/machoread.c
+++ b/gdb/machoread.c
@@ -34,8 +34,6 @@
 #include "complaints.h"
 #include "gdb_bfd.h"
 
-#include <string.h>
-
 /* If non-zero displays debugging message.  */
 static unsigned int mach_o_debug_level = 0;
 
diff --git a/gdb/macrocmd.c b/gdb/macrocmd.c
index 94a627f..265a2fe 100644
--- a/gdb/macrocmd.c
+++ b/gdb/macrocmd.c
@@ -25,7 +25,6 @@
 #include "cli/cli-utils.h"
 #include "command.h"
 #include "gdbcmd.h"
-#include <string.h>
 #include "linespec.h"
 
 \f
diff --git a/gdb/main.c b/gdb/main.c
index b51ff89..9e05b0f 100644
--- a/gdb/main.c
+++ b/gdb/main.c
@@ -30,8 +30,6 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <ctype.h>
-
-#include <string.h>
 #include "event-loop.h"
 #include "ui-out.h"
 
diff --git a/gdb/mdebugread.c b/gdb/mdebugread.c
index a6fbd6a..eba5298 100644
--- a/gdb/mdebugread.c
+++ b/gdb/mdebugread.c
@@ -55,7 +55,6 @@
 #include "dictionary.h"
 #include "mdebugread.h"
 #include <sys/stat.h>
-#include <string.h>
 #include "psympriv.h"
 #include "source.h"
 
diff --git a/gdb/mem-break.c b/gdb/mem-break.c
index ad7296b..095b81f 100644
--- a/gdb/mem-break.c
+++ b/gdb/mem-break.c
@@ -24,9 +24,6 @@
 #include "breakpoint.h"
 #include "inferior.h"
 #include "target.h"
-#include <string.h>
-
-
 /* Insert a breakpoint on targets that don't have any better
    breakpoint support.  We read the contents of the target location
    and stash it, then overwrite it with a breakpoint instruction.
diff --git a/gdb/memattr.c b/gdb/memattr.c
index 261d34f..25e4554 100644
--- a/gdb/memattr.c
+++ b/gdb/memattr.c
@@ -26,7 +26,6 @@
 #include "value.h"
 #include "language.h"
 #include "vec.h"
-#include <string.h>
 #include "breakpoint.h"
 #include "cli/cli-utils.h"
 
diff --git a/gdb/memory-map.c b/gdb/memory-map.c
index 522f16b..b897d8a 100644
--- a/gdb/memory-map.c
+++ b/gdb/memory-map.c
@@ -21,8 +21,6 @@
 #include "memory-map.h"
 #include "exceptions.h"
 
-#include <string.h>
-
 #if !defined(HAVE_LIBEXPAT)
 
 VEC(mem_region_s) *
diff --git a/gdb/mep-tdep.c b/gdb/mep-tdep.c
index dd3cc5f..b729a95 100644
--- a/gdb/mep-tdep.c
+++ b/gdb/mep-tdep.c
@@ -27,7 +27,6 @@
 #include "gdbtypes.h"
 #include "gdbcmd.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "value.h"
 #include "inferior.h"
 #include "dis-asm.h"
diff --git a/gdb/mi/mi-cmd-break.c b/gdb/mi/mi-cmd-break.c
index 29e3fb3..ce6a093 100644
--- a/gdb/mi/mi-cmd-break.c
+++ b/gdb/mi/mi-cmd-break.c
@@ -23,7 +23,6 @@
 #include "ui-out.h"
 #include "mi-out.h"
 #include "breakpoint.h"
-#include <string.h>
 #include "mi-getopt.h"
 #include "gdb.h"
 #include "exceptions.h"
diff --git a/gdb/mi/mi-cmd-disas.c b/gdb/mi/mi-cmd-disas.c
index 20b3b9f..f56daa5 100644
--- a/gdb/mi/mi-cmd-disas.c
+++ b/gdb/mi/mi-cmd-disas.c
@@ -23,7 +23,6 @@
 #include "value.h"
 #include "mi-cmds.h"
 #include "mi-getopt.h"
-#include <string.h>
 #include "ui-out.h"
 #include "disasm.h"
 
diff --git a/gdb/mi/mi-cmd-env.c b/gdb/mi/mi-cmd-env.c
index 7ec47b3..8c9d170 100644
--- a/gdb/mi/mi-cmd-env.c
+++ b/gdb/mi/mi-cmd-env.c
@@ -30,8 +30,6 @@
 #include "command.h"
 #include "ui-out.h"
 #include "top.h"
-
-#include <string.h>
 #include <sys/stat.h>
 
 static void env_mod_path (char *dirname, char **which_path);
diff --git a/gdb/mi/mi-cmd-stack.c b/gdb/mi/mi-cmd-stack.c
index ac30fca..608dc4e 100644
--- a/gdb/mi/mi-cmd-stack.c
+++ b/gdb/mi/mi-cmd-stack.c
@@ -27,7 +27,6 @@
 #include "block.h"
 #include "stack.h"
 #include "dictionary.h"
-#include <string.h>
 #include "language.h"
 #include "valprint.h"
 #include "exceptions.h"
diff --git a/gdb/mi/mi-cmd-var.c b/gdb/mi/mi-cmd-var.c
index 08a87bf..f2ca326 100644
--- a/gdb/mi/mi-cmd-var.c
+++ b/gdb/mi/mi-cmd-var.c
@@ -27,7 +27,6 @@
 #include "language.h"
 #include "value.h"
 #include <ctype.h>
-#include <string.h>
 #include "mi-getopt.h"
 #include "gdbthread.h"
 #include "mi-parse.h"
diff --git a/gdb/mi/mi-cmds.c b/gdb/mi/mi-cmds.c
index 68f97f6..ded36bf 100644
--- a/gdb/mi/mi-cmds.c
+++ b/gdb/mi/mi-cmds.c
@@ -21,7 +21,6 @@
 #include "defs.h"
 #include "top.h"
 #include "mi-cmds.h"
-#include <string.h>
 #include "mi-main.h"
 
 extern void _initialize_mi_cmds (void);
diff --git a/gdb/mi/mi-console.c b/gdb/mi/mi-console.c
index 0880bd3..790660a 100644
--- a/gdb/mi/mi-console.c
+++ b/gdb/mi/mi-console.c
@@ -26,8 +26,6 @@
 
 #include "defs.h"
 #include "mi-console.h"
-#include <string.h>
-
 static ui_file_fputs_ftype mi_console_file_fputs;
 static ui_file_flush_ftype mi_console_file_flush;
 static ui_file_delete_ftype mi_console_file_delete;
diff --git a/gdb/mi/mi-getopt.c b/gdb/mi/mi-getopt.c
index 952214e..7443633 100644
--- a/gdb/mi/mi-getopt.c
+++ b/gdb/mi/mi-getopt.c
@@ -19,8 +19,6 @@
 
 #include "defs.h"
 #include "mi-getopt.h"
-#include <string.h>
-
 /* See comments about mi_getopt and mi_getopt_silent in mi-getopt.h.
    When there is an unknown option, if ERROR_ON_UNKNOWN is true,
    throw an error, otherwise return -1.  */
diff --git a/gdb/mi/mi-interp.c b/gdb/mi/mi-interp.c
index 1b994e7..3827830 100644
--- a/gdb/mi/mi-interp.c
+++ b/gdb/mi/mi-interp.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "interps.h"
 #include "event-top.h"
 #include "event-loop.h"
diff --git a/gdb/mi/mi-main.c b/gdb/mi/mi-main.c
index 26389f1..59717ca 100644
--- a/gdb/mi/mi-main.c
+++ b/gdb/mi/mi-main.c
@@ -24,7 +24,6 @@
 #include "target.h"
 #include "inferior.h"
 #include "infrun.h"
-#include <string.h>
 #include "exceptions.h"
 #include "top.h"
 #include "gdbthread.h"
diff --git a/gdb/mi/mi-parse.c b/gdb/mi/mi-parse.c
index 161a16a..91f0e8e 100644
--- a/gdb/mi/mi-parse.c
+++ b/gdb/mi/mi-parse.c
@@ -25,7 +25,6 @@
 #include "charset.h"
 
 #include <ctype.h>
-#include <string.h>
 #include "cli/cli-utils.h"
 #include "language.h"
 
diff --git a/gdb/microblaze-rom.c b/gdb/microblaze-rom.c
index 936865c..820e9ef 100644
--- a/gdb/microblaze-rom.c
+++ b/gdb/microblaze-rom.c
@@ -21,7 +21,6 @@
 #include "gdbcore.h"
 #include "target.h"
 #include "monitor.h"
-#include <string.h>
 #include "serial.h"
 #include "regcache.h"
 
diff --git a/gdb/microblaze-tdep.c b/gdb/microblaze-tdep.c
index 80c79f6..6a9f11f 100644
--- a/gdb/microblaze-tdep.c
+++ b/gdb/microblaze-tdep.c
@@ -33,7 +33,6 @@
 #include "frame-unwind.h"
 #include "dwarf2-frame.h"
 #include "osabi.h"
-#include <string.h>
 #include "target-descriptions.h"
 #include "opcodes/microblaze-opcm.h"
 #include "opcodes/microblaze-dis.h"
diff --git a/gdb/mingw-hdep.c b/gdb/mingw-hdep.c
index c71814f..7c6da68 100644
--- a/gdb/mingw-hdep.c
+++ b/gdb/mingw-hdep.c
@@ -23,7 +23,6 @@
 #include "event-loop.h"
 
 #include "gdb_select.h"
-#include <string.h>
 #include "readline/readline.h"
 
 #include <windows.h>
diff --git a/gdb/minidebug.c b/gdb/minidebug.c
index a4907b2..8b1efbc 100644
--- a/gdb/minidebug.c
+++ b/gdb/minidebug.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "gdb_bfd.h"
-#include <string.h>
 #include "symfile.h"
 #include "objfiles.h"
 #include "gdbcore.h"
diff --git a/gdb/minsyms.c b/gdb/minsyms.c
index 6f1fb35..fd7fcd9 100644
--- a/gdb/minsyms.c
+++ b/gdb/minsyms.c
@@ -38,7 +38,6 @@
 
 #include "defs.h"
 #include <ctype.h>
-#include <string.h>
 #include "symtab.h"
 #include "bfd.h"
 #include "filenames.h"
diff --git a/gdb/mips-irix-tdep.c b/gdb/mips-irix-tdep.c
index d11a414..a017e3b 100644
--- a/gdb/mips-irix-tdep.c
+++ b/gdb/mips-irix-tdep.c
@@ -20,7 +20,6 @@
 
 #include "defs.h"
 #include "osabi.h"
-#include <string.h>
 #include "solib.h"
 #include "solib-irix.h"
 #include "elf-bfd.h"
diff --git a/gdb/mips-linux-tdep.c b/gdb/mips-linux-tdep.c
index 1e81271..5639870 100644
--- a/gdb/mips-linux-tdep.c
+++ b/gdb/mips-linux-tdep.c
@@ -23,7 +23,6 @@
 #include "solib-svr4.h"
 #include "osabi.h"
 #include "mips-tdep.h"
-#include <string.h>
 #include "frame.h"
 #include "regcache.h"
 #include "trad-frame.h"
diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c
index bbbf8a2..8165f94 100644
--- a/gdb/mips-tdep.c
+++ b/gdb/mips-tdep.c
@@ -21,7 +21,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "frame.h"
 #include "inferior.h"
 #include "symtab.h"
diff --git a/gdb/mips64obsd-tdep.c b/gdb/mips64obsd-tdep.c
index 8a89af1..e312e51 100644
--- a/gdb/mips64obsd-tdep.c
+++ b/gdb/mips64obsd-tdep.c
@@ -25,8 +25,6 @@
 #include "trad-frame.h"
 #include "tramp-frame.h"
 
-#include <string.h>
-
 #include "obsd-tdep.h"
 #include "mips-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/mipsnbsd-tdep.c b/gdb/mipsnbsd-tdep.c
index 2b7a1d3..f8aa210 100644
--- a/gdb/mipsnbsd-tdep.c
+++ b/gdb/mipsnbsd-tdep.c
@@ -27,8 +27,6 @@
 #include "value.h"
 #include "osabi.h"
 
-#include <string.h>
-
 #include "nbsd-tdep.h"
 #include "mipsnbsd-tdep.h"
 #include "mips-tdep.h"
diff --git a/gdb/mipsread.c b/gdb/mipsread.c
index 090a7e7..d73d34a 100644
--- a/gdb/mipsread.c
+++ b/gdb/mipsread.c
@@ -24,7 +24,6 @@
    mdebugread.c.  */
 
 #include "defs.h"
-#include <string.h>
 #include "bfd.h"
 #include "symtab.h"
 #include "objfiles.h"
diff --git a/gdb/mn10300-linux-tdep.c b/gdb/mn10300-linux-tdep.c
index cbaa010..023c61d 100644
--- a/gdb/mn10300-linux-tdep.c
+++ b/gdb/mn10300-linux-tdep.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "regcache.h"
 #include "mn10300-tdep.h"
 #include "bfd.h"
diff --git a/gdb/mn10300-tdep.c b/gdb/mn10300-tdep.c
index bc21465..a6a0d91 100644
--- a/gdb/mn10300-tdep.c
+++ b/gdb/mn10300-tdep.c
@@ -22,7 +22,6 @@
 #include "dis-asm.h"
 #include "gdbtypes.h"
 #include "regcache.h"
-#include <string.h>
 #include "gdbcore.h"	/* For write_memory_unsigned_integer.  */
 #include "value.h"
 #include "frame.h"
diff --git a/gdb/monitor.c b/gdb/monitor.c
index 94b85d3..b880ff2 100644
--- a/gdb/monitor.c
+++ b/gdb/monitor.c
@@ -43,7 +43,6 @@
 #include "exceptions.h"
 #include <signal.h>
 #include <ctype.h>
-#include <string.h>
 #include <sys/types.h>
 #include "command.h"
 #include "serial.h"
diff --git a/gdb/moxie-tdep.c b/gdb/moxie-tdep.c
index 6d3c130..7926927 100644
--- a/gdb/moxie-tdep.c
+++ b/gdb/moxie-tdep.c
@@ -25,7 +25,6 @@
 #include "gdbtypes.h"
 #include "gdbcmd.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "value.h"
 #include "inferior.h"
 #include "symfile.h"
diff --git a/gdb/mt-tdep.c b/gdb/mt-tdep.c
index 1904bf8..a16af9c 100644
--- a/gdb/mt-tdep.c
+++ b/gdb/mt-tdep.c
@@ -27,7 +27,6 @@
 #include "dis-asm.h"
 #include "arch-utils.h"
 #include "gdbtypes.h"
-#include <string.h>
 #include "regcache.h"
 #include "reggroups.h"
 #include "gdbcore.h"
diff --git a/gdb/nat/linux-btrace.c b/gdb/nat/linux-btrace.c
index baf07e8..19e218e 100644
--- a/gdb/nat/linux-btrace.c
+++ b/gdb/nat/linux-btrace.c
@@ -38,7 +38,6 @@
 #if HAVE_LINUX_PERF_EVENT_H && defined(SYS_perf_event_open)
 
 #include <errno.h>
-#include <string.h>
 #include <stdint.h>
 #include <unistd.h>
 #include <sys/mman.h>
diff --git a/gdb/nat/linux-osdata.c b/gdb/nat/linux-osdata.c
index 0ef7fa3..887e518 100644
--- a/gdb/nat/linux-osdata.c
+++ b/gdb/nat/linux-osdata.c
@@ -28,7 +28,6 @@
 #include <sys/types.h>
 #include <sys/sysinfo.h>
 #include <ctype.h>
-#include <string.h>
 #include <utmp.h>
 #include <time.h>
 #include <unistd.h>
diff --git a/gdb/nat/linux-procfs.c b/gdb/nat/linux-procfs.c
index 1443a88..84fc890 100644
--- a/gdb/nat/linux-procfs.c
+++ b/gdb/nat/linux-procfs.c
@@ -20,7 +20,6 @@
 #include "server.h"
 #else
 #include "defs.h"
-#include <string.h>
 #endif
 
 #include "linux-procfs.h"
diff --git a/gdb/nat/linux-ptrace.c b/gdb/nat/linux-ptrace.c
index 8abb842..b4db862 100644
--- a/gdb/nat/linux-ptrace.c
+++ b/gdb/nat/linux-ptrace.c
@@ -20,7 +20,6 @@
 #include "server.h"
 #else
 #include "defs.h"
-#include <string.h>
 #endif
 
 #include "linux-ptrace.h"
diff --git a/gdb/nat/linux-waitpid.c b/gdb/nat/linux-waitpid.c
index 5159f03..53847ac 100644
--- a/gdb/nat/linux-waitpid.c
+++ b/gdb/nat/linux-waitpid.c
@@ -28,8 +28,6 @@
 #include "linux-waitpid.h"
 #include "gdb_wait.h"
 
-#include <string.h>
-
 /* Print debugging output based on the format string FORMAT and
    its parameters.  */
 
diff --git a/gdb/nbsd-tdep.c b/gdb/nbsd-tdep.c
index b1540e9..93da2c6 100644
--- a/gdb/nbsd-tdep.c
+++ b/gdb/nbsd-tdep.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "solib-svr4.h"
 #include "nbsd-tdep.h"
 
diff --git a/gdb/nios2-linux-tdep.c b/gdb/nios2-linux-tdep.c
index 2041336..b2a3c3e 100644
--- a/gdb/nios2-linux-tdep.c
+++ b/gdb/nios2-linux-tdep.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "frame.h"
-#include <string.h>
 #include "osabi.h"
 #include "solib-svr4.h"
 #include "trad-frame.h"
diff --git a/gdb/nto-procfs.c b/gdb/nto-procfs.c
index 728d6f3..05d0573 100644
--- a/gdb/nto-procfs.c
+++ b/gdb/nto-procfs.c
@@ -32,7 +32,6 @@
 #include <sys/netmgr.h>
 
 #include "exceptions.h"
-#include <string.h>
 #include "gdbcore.h"
 #include "inferior.h"
 #include "target.h"
diff --git a/gdb/nto-tdep.c b/gdb/nto-tdep.c
index 1d0f8a1..fb97a36 100644
--- a/gdb/nto-tdep.c
+++ b/gdb/nto-tdep.c
@@ -21,7 +21,6 @@
 
 #include "defs.h"
 #include <sys/stat.h>
-#include <string.h>
 #include "nto-tdep.h"
 #include "top.h"
 #include "inferior.h"
diff --git a/gdb/objc-lang.c b/gdb/objc-lang.c
index c6d344e..22f6089 100644
--- a/gdb/objc-lang.c
+++ b/gdb/objc-lang.c
@@ -34,7 +34,6 @@
 #include "value.h"
 #include "symfile.h"
 #include "objfiles.h"
-#include <string.h>		/* for strchr */
 #include "target.h"		/* for target_has_execution */
 #include "gdbcore.h"
 #include "gdbcmd.h"
diff --git a/gdb/objfiles.c b/gdb/objfiles.c
index 7c6fca8..2a5c15f 100644
--- a/gdb/objfiles.c
+++ b/gdb/objfiles.c
@@ -37,7 +37,6 @@
 #include <sys/stat.h>
 #include <fcntl.h>
 #include "gdb_obstack.h"
-#include <string.h>
 #include "hashtab.h"
 
 #include "breakpoint.h"
diff --git a/gdb/opencl-lang.c b/gdb/opencl-lang.c
index 96b562d..c9f0476 100644
--- a/gdb/opencl-lang.c
+++ b/gdb/opencl-lang.c
@@ -19,7 +19,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "gdbtypes.h"
 #include "symtab.h"
 #include "expression.h"
diff --git a/gdb/osabi.c b/gdb/osabi.c
index ae4290f..cdba812 100644
--- a/gdb/osabi.c
+++ b/gdb/osabi.c
@@ -19,8 +19,6 @@
 
 #include "defs.h"
 
-#include <string.h>
-
 #include "osabi.h"
 #include "arch-utils.h"
 #include "gdbcmd.h"
diff --git a/gdb/osdata.c b/gdb/osdata.c
index fd00b4e..d8c06ff 100644
--- a/gdb/osdata.c
+++ b/gdb/osdata.c
@@ -22,7 +22,6 @@
 #include "vec.h"
 #include "xml-support.h"
 #include "osdata.h"
-#include <string.h>
 #include "ui-out.h"
 #include "gdbcmd.h"
 
diff --git a/gdb/p-exp.y b/gdb/p-exp.y
index 5bb1864..0aa6f20 100644
--- a/gdb/p-exp.y
+++ b/gdb/p-exp.y
@@ -44,7 +44,6 @@
 %{
 
 #include "defs.h"
-#include <string.h>
 #include <ctype.h>
 #include "expression.h"
 #include "value.h"
diff --git a/gdb/p-lang.c b/gdb/p-lang.c
index 856beb3..98fcc3b 100644
--- a/gdb/p-lang.c
+++ b/gdb/p-lang.c
@@ -20,7 +20,6 @@
 /* This file is derived from c-lang.c */
 
 #include "defs.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "expression.h"
diff --git a/gdb/p-typeprint.c b/gdb/p-typeprint.c
index 2fd0fec..6870cdf 100644
--- a/gdb/p-typeprint.c
+++ b/gdb/p-typeprint.c
@@ -31,7 +31,6 @@
 #include "p-lang.h"
 #include "typeprint.h"
 #include "gdb-demangle.h"
-#include <string.h>
 #include <errno.h>
 #include <ctype.h>
 
diff --git a/gdb/parse.c b/gdb/parse.c
index d35eb3a..334c63a 100644
--- a/gdb/parse.c
+++ b/gdb/parse.c
@@ -32,7 +32,6 @@
 #include "defs.h"
 #include <ctype.h>
 #include "arch-utils.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "frame.h"
diff --git a/gdb/posix-hdep.c b/gdb/posix-hdep.c
index 5209436..1a41e85 100644
--- a/gdb/posix-hdep.c
+++ b/gdb/posix-hdep.c
@@ -20,8 +20,6 @@
 #include "defs.h"
 #include "event-loop.h"
 
-#include <string.h>
-
 #include "gdb_select.h"
 
 /* The strerror() function can return NULL for errno values that are
diff --git a/gdb/ppc-linux-nat.c b/gdb/ppc-linux-nat.c
index 3da6254..0d03936 100644
--- a/gdb/ppc-linux-nat.c
+++ b/gdb/ppc-linux-nat.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "observer.h"
 #include "frame.h"
 #include "inferior.h"
diff --git a/gdb/ppc-sysv-tdep.c b/gdb/ppc-sysv-tdep.c
index c56164f..bf2bcc5 100644
--- a/gdb/ppc-sysv-tdep.c
+++ b/gdb/ppc-sysv-tdep.c
@@ -23,7 +23,6 @@
 #include "inferior.h"
 #include "regcache.h"
 #include "value.h"
-#include <string.h>
 #include "ppc-tdep.h"
 #include "target.h"
 #include "objfiles.h"
diff --git a/gdb/ppcfbsd-tdep.c b/gdb/ppcfbsd-tdep.c
index 21a3bbc..b78ccfc 100644
--- a/gdb/ppcfbsd-tdep.c
+++ b/gdb/ppcfbsd-tdep.c
@@ -30,8 +30,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include <string.h>
-
 #include "ppc-tdep.h"
 #include "ppc64-tdep.h"
 #include "ppcfbsd-tdep.h"
diff --git a/gdb/ppcnbsd-tdep.c b/gdb/ppcnbsd-tdep.c
index 0043994..a5c1e3d 100644
--- a/gdb/ppcnbsd-tdep.c
+++ b/gdb/ppcnbsd-tdep.c
@@ -27,8 +27,6 @@
 #include "trad-frame.h"
 #include "tramp-frame.h"
 
-#include <string.h>
-
 #include "ppc-tdep.h"
 #include "ppcnbsd-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/ppcobsd-tdep.c b/gdb/ppcobsd-tdep.c
index b3a9677..d745dd0 100644
--- a/gdb/ppcobsd-tdep.c
+++ b/gdb/ppcobsd-tdep.c
@@ -28,8 +28,6 @@
 #include "symtab.h"
 #include "trad-frame.h"
 
-#include <string.h>
-
 #include "ppc-tdep.h"
 #include "ppcobsd-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/printcmd.c b/gdb/printcmd.c
index 9154836..2f131ce 100644
--- a/gdb/printcmd.c
+++ b/gdb/printcmd.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "frame.h"
 #include "symtab.h"
 #include "gdbtypes.h"
diff --git a/gdb/procfs.c b/gdb/procfs.c
index 40aaed5..d93843a 100644
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -47,7 +47,6 @@
 #include <signal.h>
 #include <ctype.h>
 #include "gdb_bfd.h"
-#include <string.h>
 #include "inflow.h"
 #include "auxv.h"
 #include "procfs.h"
diff --git a/gdb/prologue-value.c b/gdb/prologue-value.c
index f82e1a1..e3431ff 100644
--- a/gdb/prologue-value.c
+++ b/gdb/prologue-value.c
@@ -17,7 +17,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "prologue-value.h"
 #include "regcache.h"
 
diff --git a/gdb/python/py-auto-load.c b/gdb/python/py-auto-load.c
index 66f7316..24311ff 100644
--- a/gdb/python/py-auto-load.c
+++ b/gdb/python/py-auto-load.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "top.h"
 #include "exceptions.h"
 #include "gdbcmd.h"
diff --git a/gdb/python/py-gdb-readline.c b/gdb/python/py-gdb-readline.c
index b778aa9..b335df9 100644
--- a/gdb/python/py-gdb-readline.c
+++ b/gdb/python/py-gdb-readline.c
@@ -22,8 +22,6 @@
 #include "exceptions.h"
 #include "top.h"
 #include "cli/cli-utils.h"
-#include <string.h>
-
 /* Readline function suitable for PyOS_ReadlineFunctionPointer, which
    is used for Python's interactive parser and raw_input.  In both
    cases, sys_stdin and sys_stdout are always stdin and stdout
diff --git a/gdb/ravenscar-thread.c b/gdb/ravenscar-thread.c
index c4a01a5..acee55e 100644
--- a/gdb/ravenscar-thread.c
+++ b/gdb/ravenscar-thread.c
@@ -26,7 +26,6 @@
 #include "command.h"
 #include "ravenscar-thread.h"
 #include "observer.h"
-#include <string.h>
 #include "gdbcmd.h"
 #include "top.h"
 #include "regcache.h"
diff --git a/gdb/regcache.c b/gdb/regcache.c
index 506067f..f410dc2 100644
--- a/gdb/regcache.c
+++ b/gdb/regcache.c
@@ -24,7 +24,6 @@
 #include "gdbcmd.h"
 #include "regcache.h"
 #include "reggroups.h"
-#include <string.h>
 #include "observer.h"
 #include "exceptions.h"
 #include "remote.h"
diff --git a/gdb/registry.c b/gdb/registry.c
index 378c369..b324613 100644
--- a/gdb/registry.c
+++ b/gdb/registry.c
@@ -19,8 +19,6 @@
 
 #include "defs.h"
 #include "registry.h"
-#include <string.h>
-
 const struct registry_data *
 register_data_with_cleanup (struct registry_data_registry *registry,
 			    registry_data_callback save,
diff --git a/gdb/remote-fileio.c b/gdb/remote-fileio.c
index e20d209..48e1e56 100644
--- a/gdb/remote-fileio.c
+++ b/gdb/remote-fileio.c
@@ -20,7 +20,6 @@
 /* See the GDB User Guide for details of the GDB remote protocol.  */
 
 #include "defs.h"
-#include <string.h>
 #include "gdbcmd.h"
 #include "remote.h"
 #include "gdb/fileio.h"
diff --git a/gdb/remote-m32r-sdi.c b/gdb/remote-m32r-sdi.c
index 38cfba7..c1abb36 100644
--- a/gdb/remote-m32r-sdi.c
+++ b/gdb/remote-m32r-sdi.c
@@ -27,7 +27,6 @@
 #include "infrun.h"
 #include "target.h"
 #include "regcache.h"
-#include <string.h>
 #include "gdbthread.h"
 #include <ctype.h>
 #include <signal.h>
diff --git a/gdb/remote-mips.c b/gdb/remote-mips.c
index 277621d..710ba6a 100644
--- a/gdb/remote-mips.c
+++ b/gdb/remote-mips.c
@@ -30,7 +30,6 @@
 #include "serial.h"
 #include "target.h"
 #include "exceptions.h"
-#include <string.h>
 #include <sys/stat.h>
 #include "gdb_usleep.h"
 #include "regcache.h"
diff --git a/gdb/remote-notif.c b/gdb/remote-notif.c
index 650a0f8..5089100 100644
--- a/gdb/remote-notif.c
+++ b/gdb/remote-notif.c
@@ -41,8 +41,6 @@
 #include "infrun.h"
 #include "gdbcmd.h"
 
-#include <string.h>
-
 int notif_debug = 0;
 
 /* Supported clients of notifications.  */
diff --git a/gdb/remote-sim.c b/gdb/remote-sim.c
index e652458..e26a971 100644
--- a/gdb/remote-sim.c
+++ b/gdb/remote-sim.c
@@ -24,7 +24,6 @@
 #include "inferior.h"
 #include "infrun.h"
 #include "value.h"
-#include <string.h>
 #include <ctype.h>
 #include <fcntl.h>
 #include <signal.h>
diff --git a/gdb/remote.c b/gdb/remote.c
index 24ff0c3..af3394a 100644
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -20,7 +20,6 @@
 /* See the GDB User Guide for details of the GDB remote protocol.  */
 
 #include "defs.h"
-#include <string.h>
 #include <ctype.h>
 #include <fcntl.h>
 #include "inferior.h"
diff --git a/gdb/reverse.c b/gdb/reverse.c
index defa8b6..541355f 100644
--- a/gdb/reverse.c
+++ b/gdb/reverse.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "target.h"
 #include "top.h"
 #include "cli/cli-cmds.h"
diff --git a/gdb/rs6000-aix-tdep.c b/gdb/rs6000-aix-tdep.c
index 3845df8..03dc8c0 100644
--- a/gdb/rs6000-aix-tdep.c
+++ b/gdb/rs6000-aix-tdep.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "osabi.h"
 #include "regcache.h"
 #include "regset.h"
diff --git a/gdb/ser-base.c b/gdb/ser-base.c
index 5f677a9..06efbc1 100644
--- a/gdb/ser-base.c
+++ b/gdb/ser-base.c
@@ -23,7 +23,6 @@
 #include "event-loop.h"
 
 #include "gdb_select.h"
-#include <string.h>
 #include <sys/time.h>
 #ifdef USE_WIN32API
 #include <winsock2.h>
diff --git a/gdb/ser-go32.c b/gdb/ser-go32.c
index 75fb91e..3a3126e 100644
--- a/gdb/ser-go32.c
+++ b/gdb/ser-go32.c
@@ -24,9 +24,6 @@
 #include "defs.h"
 #include "gdbcmd.h"
 #include "serial.h"
-#include <string.h>
-
-
 /*
  * NS16550 UART registers
  */
diff --git a/gdb/ser-mingw.c b/gdb/ser-mingw.c
index ab4de3b..a81208c 100644
--- a/gdb/ser-mingw.c
+++ b/gdb/ser-mingw.c
@@ -29,8 +29,6 @@
 #include <unistd.h>
 #include <sys/types.h>
 
-#include <string.h>
-
 #include "command.h"
 
 void _initialize_ser_windows (void);
diff --git a/gdb/ser-pipe.c b/gdb/ser-pipe.c
index 9568a26..8c22287 100644
--- a/gdb/ser-pipe.c
+++ b/gdb/ser-pipe.c
@@ -29,7 +29,6 @@
 #include <sys/socket.h>
 #include <sys/time.h>
 #include <fcntl.h>
-#include <string.h>
 #include "filestuff.h"
 
 #include <signal.h>
diff --git a/gdb/ser-tcp.c b/gdb/ser-tcp.c
index 5600001..d6df427 100644
--- a/gdb/ser-tcp.c
+++ b/gdb/ser-tcp.c
@@ -53,7 +53,6 @@
 #endif
 
 #include <signal.h>
-#include <string.h>
 #include "gdb_select.h"
 
 #ifndef HAVE_SOCKLEN_T
diff --git a/gdb/ser-unix.c b/gdb/ser-unix.c
index 7e06a72..6389712 100644
--- a/gdb/ser-unix.c
+++ b/gdb/ser-unix.c
@@ -29,7 +29,6 @@
 #include <sys/time.h>
 
 #include "gdb_select.h"
-#include <string.h>
 #include "gdbcmd.h"
 #include "filestuff.h"
 
diff --git a/gdb/serial.c b/gdb/serial.c
index f7e0de5..791f12f 100644
--- a/gdb/serial.c
+++ b/gdb/serial.c
@@ -20,7 +20,6 @@
 #include "defs.h"
 #include <ctype.h>
 #include "serial.h"
-#include <string.h>
 #include "gdbcmd.h"
 #include "cli/cli-utils.h"
 
diff --git a/gdb/sh-tdep.c b/gdb/sh-tdep.c
index 3290566..c8c36db 100644
--- a/gdb/sh-tdep.c
+++ b/gdb/sh-tdep.c
@@ -32,7 +32,6 @@
 #include "value.h"
 #include "dis-asm.h"
 #include "inferior.h"
-#include <string.h>
 #include "arch-utils.h"
 #include "floatformat.h"
 #include "regcache.h"
diff --git a/gdb/sh64-tdep.c b/gdb/sh64-tdep.c
index b2dd3a4..5fe6d87 100644
--- a/gdb/sh64-tdep.c
+++ b/gdb/sh64-tdep.c
@@ -32,7 +32,6 @@
 #include "value.h"
 #include "dis-asm.h"
 #include "inferior.h"
-#include <string.h>
 #include "arch-utils.h"
 #include "regcache.h"
 #include "osabi.h"
diff --git a/gdb/shnbsd-tdep.c b/gdb/shnbsd-tdep.c
index 203cd30..2936661 100644
--- a/gdb/shnbsd-tdep.c
+++ b/gdb/shnbsd-tdep.c
@@ -25,8 +25,6 @@
 #include "value.h"
 #include "osabi.h"
 
-#include <string.h>
-
 #include "sh-tdep.h"
 #include "solib-svr4.h"
 
diff --git a/gdb/skip.c b/gdb/skip.c
index 64a0254..23f1e46 100644
--- a/gdb/skip.c
+++ b/gdb/skip.c
@@ -20,7 +20,6 @@
 #include "value.h"
 #include "valprint.h"
 #include "ui-out.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbcmd.h"
 #include "command.h"
diff --git a/gdb/sol-thread.c b/gdb/sol-thread.c
index 38ca2f6..88293c3 100644
--- a/gdb/sol-thread.c
+++ b/gdb/sol-thread.c
@@ -64,7 +64,6 @@
 #include "solib.h"
 #include "symfile.h"
 #include "observer.h"
-#include <string.h>
 #include "procfs.h"
 #include "symtab.h"
 #include "minsyms.h"
diff --git a/gdb/solib-dsbt.c b/gdb/solib-dsbt.c
index 0217a94..4655c92 100644
--- a/gdb/solib-dsbt.c
+++ b/gdb/solib-dsbt.c
@@ -18,7 +18,6 @@
 
 
 #include "defs.h"
-#include <string.h>
 #include "inferior.h"
 #include "gdbcore.h"
 #include "solib.h"
diff --git a/gdb/solib-frv.c b/gdb/solib-frv.c
index 9724a3c..8e66a87 100644
--- a/gdb/solib-frv.c
+++ b/gdb/solib-frv.c
@@ -18,7 +18,6 @@
 
 
 #include "defs.h"
-#include <string.h>
 #include "inferior.h"
 #include "gdbcore.h"
 #include "solib.h"
diff --git a/gdb/solib-osf.c b/gdb/solib-osf.c
index 404a56b..24915cb 100644
--- a/gdb/solib-osf.c
+++ b/gdb/solib-osf.c
@@ -44,8 +44,6 @@
 
 #include <sys/types.h>
 #include <signal.h>
-#include <string.h>
-
 #include "bfd.h"
 #include "symtab.h"
 #include "symfile.h"
diff --git a/gdb/solib-som.c b/gdb/solib-som.c
index cba50d1..83f2065 100644
--- a/gdb/solib-som.c
+++ b/gdb/solib-som.c
@@ -31,8 +31,6 @@
 #include "solib.h"
 #include "solib-som.h"
 
-#include <string.h>
-
 #undef SOLIB_SOM_DBG 
 
 /* These ought to be defined in some public interface, but aren't.  They
diff --git a/gdb/solib-spu.c b/gdb/solib-spu.c
index b657b7f..41e41b0 100644
--- a/gdb/solib-spu.c
+++ b/gdb/solib-spu.c
@@ -21,7 +21,6 @@
 #include "defs.h"
 #include "solib-spu.h"
 #include "gdbcore.h"
-#include <string.h>
 #include <sys/stat.h>
 #include "arch-utils.h"
 #include "bfd.h"
diff --git a/gdb/solib-target.c b/gdb/solib-target.c
index bb34e4b..fe807ad 100644
--- a/gdb/solib-target.c
+++ b/gdb/solib-target.c
@@ -26,8 +26,6 @@
 #include "vec.h"
 #include "solib-target.h"
 
-#include <string.h>
-
 /* Private data for each loaded library.  */
 struct lm_info
 {
diff --git a/gdb/solib.c b/gdb/solib.c
index c8f141f..90ea454 100644
--- a/gdb/solib.c
+++ b/gdb/solib.c
@@ -21,7 +21,6 @@
 
 #include <sys/types.h>
 #include <fcntl.h>
-#include <string.h>
 #include "symtab.h"
 #include "bfd.h"
 #include "symfile.h"
diff --git a/gdb/somread.c b/gdb/somread.c
index 4a7837e..fcd02bd 100644
--- a/gdb/somread.c
+++ b/gdb/somread.c
@@ -27,7 +27,6 @@
 #include "stabsread.h"
 #include "gdb-stabs.h"
 #include "complaints.h"
-#include <string.h>
 #include "demangle.h"
 #include "som.h"
 #include "libhppa.h"
diff --git a/gdb/source.c b/gdb/source.c
index 5a44bb7..19c2562 100644
--- a/gdb/source.c
+++ b/gdb/source.c
@@ -29,7 +29,6 @@
 #include "filestuff.h"
 
 #include <sys/types.h>
-#include <string.h>
 #include <sys/stat.h>
 #include <fcntl.h>
 #include "gdbcore.h"
diff --git a/gdb/sparc-nat.c b/gdb/sparc-nat.c
index e83e7d1..7c0198d 100644
--- a/gdb/sparc-nat.c
+++ b/gdb/sparc-nat.c
@@ -23,7 +23,6 @@
 #include "target.h"
 
 #include <signal.h>
-#include <string.h>
 #include <sys/ptrace.h>
 #include "gdb_wait.h"
 #ifdef HAVE_MACHINE_REG_H
diff --git a/gdb/sparc-sol2-tdep.c b/gdb/sparc-sol2-tdep.c
index c23ce2b..7a7d3eb 100644
--- a/gdb/sparc-sol2-tdep.c
+++ b/gdb/sparc-sol2-tdep.c
@@ -28,8 +28,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include <string.h>
-
 #include "sol2-tdep.h"
 #include "sparc-tdep.h"
 #include "solib-svr4.h"
diff --git a/gdb/sparc-tdep.c b/gdb/sparc-tdep.c
index b075437..bcd4f6e 100644
--- a/gdb/sparc-tdep.c
+++ b/gdb/sparc-tdep.c
@@ -35,8 +35,6 @@
 #include "target.h"
 #include "value.h"
 
-#include <string.h>
-
 #include "sparc-tdep.h"
 #include "sparc-ravenscar-thread.h"
 
diff --git a/gdb/sparc64-tdep.c b/gdb/sparc64-tdep.c
index abb7350..a1966c5 100644
--- a/gdb/sparc64-tdep.c
+++ b/gdb/sparc64-tdep.c
@@ -34,8 +34,6 @@
 #include "target.h"
 #include "value.h"
 
-#include <string.h>
-
 #include "sparc64-tdep.h"
 
 /* This file implements the SPARC 64-bit ABI as defined by the
diff --git a/gdb/sparc64fbsd-tdep.c b/gdb/sparc64fbsd-tdep.c
index 453f2b4..568db72 100644
--- a/gdb/sparc64fbsd-tdep.c
+++ b/gdb/sparc64fbsd-tdep.c
@@ -27,8 +27,6 @@
 #include "target.h"
 #include "trad-frame.h"
 
-#include <string.h>
-
 #include "sparc64-tdep.h"
 #include "solib-svr4.h"
 
diff --git a/gdb/sparc64nbsd-tdep.c b/gdb/sparc64nbsd-tdep.c
index 0d2a4e0..f7adddb 100644
--- a/gdb/sparc64nbsd-tdep.c
+++ b/gdb/sparc64nbsd-tdep.c
@@ -30,8 +30,6 @@
 #include "solib-svr4.h"
 #include "trad-frame.h"
 
-#include <string.h>
-
 #include "sparc64-tdep.h"
 #include "nbsd-tdep.h"
 
diff --git a/gdb/sparcnbsd-tdep.c b/gdb/sparcnbsd-tdep.c
index 7c4d6ee..4a61cee 100644
--- a/gdb/sparcnbsd-tdep.c
+++ b/gdb/sparcnbsd-tdep.c
@@ -30,8 +30,6 @@
 #include "symtab.h"
 #include "trad-frame.h"
 
-#include <string.h>
-
 #include "sparc-tdep.h"
 #include "nbsd-tdep.h"
 
diff --git a/gdb/spu-linux-nat.c b/gdb/spu-linux-nat.c
index 4841bbe..3803e3d 100644
--- a/gdb/spu-linux-nat.c
+++ b/gdb/spu-linux-nat.c
@@ -20,7 +20,6 @@
 
 #include "defs.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "target.h"
 #include "inferior.h"
 #include "inf-child.h"
diff --git a/gdb/spu-multiarch.c b/gdb/spu-multiarch.c
index 2bce90e..202bfa7 100644
--- a/gdb/spu-multiarch.c
+++ b/gdb/spu-multiarch.c
@@ -21,7 +21,6 @@
 #include "defs.h"
 #include "gdbcore.h"
 #include "gdbcmd.h"
-#include <string.h>
 #include "arch-utils.h"
 #include "observer.h"
 #include "inferior.h"
diff --git a/gdb/spu-tdep.c b/gdb/spu-tdep.c
index 6b46df1..c9af4fd 100644
--- a/gdb/spu-tdep.c
+++ b/gdb/spu-tdep.c
@@ -24,7 +24,6 @@
 #include "gdbtypes.h"
 #include "gdbcmd.h"
 #include "gdbcore.h"
-#include <string.h>
 #include "frame.h"
 #include "frame-unwind.h"
 #include "frame-base.h"
diff --git a/gdb/stabsread.c b/gdb/stabsread.c
index 9a25b0c..87eaed4 100644
--- a/gdb/stabsread.c
+++ b/gdb/stabsread.c
@@ -24,7 +24,6 @@
    Avoid placing any object file format specific code in this file.  */
 
 #include "defs.h"
-#include <string.h>
 #include "bfd.h"
 #include "gdb_obstack.h"
 #include "symtab.h"
diff --git a/gdb/stack.c b/gdb/stack.c
index 9243f69..3fa50b4 100644
--- a/gdb/stack.c
+++ b/gdb/stack.c
@@ -50,8 +50,6 @@
 #include "objfiles.h"
 
 #include <ctype.h>
-#include <string.h>
-
 #include "symfile.h"
 #include "extension.h"
 
diff --git a/gdb/std-regs.c b/gdb/std-regs.c
index a2bb39d..aa2ccca 100644
--- a/gdb/std-regs.c
+++ b/gdb/std-regs.c
@@ -24,9 +24,6 @@
 #include "frame.h"
 #include "gdbtypes.h"
 #include "value.h"
-#include <string.h>
-
-
 static struct value *
 value_of_builtin_frame_fp_reg (struct frame_info *frame, const void *baton)
 {
diff --git a/gdb/symfile.c b/gdb/symfile.c
index 921c3b8..b16abe4 100644
--- a/gdb/symfile.c
+++ b/gdb/symfile.c
@@ -59,7 +59,6 @@
 
 #include <sys/types.h>
 #include <fcntl.h>
-#include <string.h>
 #include <sys/stat.h>
 #include <ctype.h>
 #include <time.h>
diff --git a/gdb/symmisc.c b/gdb/symmisc.c
index de2e166..d6f48db 100644
--- a/gdb/symmisc.c
+++ b/gdb/symmisc.c
@@ -37,8 +37,6 @@
 #include "typeprint.h"
 #include "gdbcmd.h"
 #include "source.h"
-
-#include <string.h>
 #include "readline/readline.h"
 
 #include "psymtab.h"
diff --git a/gdb/symtab.c b/gdb/symtab.c
index e64d0df..ab56892 100644
--- a/gdb/symtab.c
+++ b/gdb/symtab.c
@@ -50,7 +50,6 @@
 
 #include <sys/types.h>
 #include <fcntl.h>
-#include <string.h>
 #include <sys/stat.h>
 #include <ctype.h>
 #include "cp-abi.h"
diff --git a/gdb/target.c b/gdb/target.c
index e08a098..1e0d872 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -21,7 +21,6 @@
 
 #include "defs.h"
 #include <errno.h>
-#include <string.h>
 #include "target.h"
 #include "target-dcache.h"
 #include "gdbcmd.h"
diff --git a/gdb/thread.c b/gdb/thread.c
index e25d563..65890e1 100644
--- a/gdb/thread.c
+++ b/gdb/thread.c
@@ -32,7 +32,6 @@
 #include "gdbcmd.h"
 #include "regcache.h"
 #include "gdb.h"
-#include <string.h>
 #include "btrace.h"
 
 #include <ctype.h>
diff --git a/gdb/tilegx-linux-nat.c b/gdb/tilegx-linux-nat.c
index 80a5e57..1cd21b3 100644
--- a/gdb/tilegx-linux-nat.c
+++ b/gdb/tilegx-linux-nat.c
@@ -25,8 +25,6 @@
 
 #include <sys/ptrace.h>
 
-#include <string.h>
-
 #include <sys/procfs.h>
 
 /* Defines ps_err_e, struct ps_prochandle.  */
diff --git a/gdb/tilegx-tdep.c b/gdb/tilegx-tdep.c
index 01742e8..befab56 100644
--- a/gdb/tilegx-tdep.c
+++ b/gdb/tilegx-tdep.c
@@ -30,7 +30,6 @@
 #include "value.h"
 #include "dis-asm.h"
 #include "inferior.h"
-#include <string.h>
 #include "arch-utils.h"
 #include "floatformat.h"
 #include "regcache.h"
diff --git a/gdb/top.c b/gdb/top.c
index 319324f..fc2b84d 100644
--- a/gdb/top.c
+++ b/gdb/top.c
@@ -61,7 +61,6 @@
 #include <sys/types.h>
 
 #include "event-top.h"
-#include <string.h>
 #include <sys/stat.h>
 #include <ctype.h>
 #include "ui-out.h"
diff --git a/gdb/tracepoint.c b/gdb/tracepoint.c
index cdd395f..f2f662e 100644
--- a/gdb/tracepoint.c
+++ b/gdb/tracepoint.c
@@ -28,7 +28,6 @@
 #include "target.h"
 #include "target-dcache.h"
 #include "language.h"
-#include <string.h>
 #include "inferior.h"
 #include "breakpoint.h"
 #include "tracepoint.h"
diff --git a/gdb/tui/tui-command.c b/gdb/tui/tui-command.c
index ae6bde4..8d0e107 100644
--- a/gdb/tui/tui-command.c
+++ b/gdb/tui/tui-command.c
@@ -28,9 +28,6 @@
 #include "tui/tui-command.h"
 
 #include "gdb_curses.h"
-#include <string.h>
-
-
 /*****************************************
 ** STATIC LOCAL FUNCTIONS FORWARD DECLS    **
 ******************************************/
diff --git a/gdb/tui/tui-data.c b/gdb/tui/tui-data.c
index 4deb006..7e51b3e 100644
--- a/gdb/tui/tui-data.c
+++ b/gdb/tui/tui-data.c
@@ -24,8 +24,6 @@
 #include "tui/tui.h"
 #include "tui/tui-data.h"
 #include "tui/tui-wingeneral.h"
-
-#include <string.h>
 #include "gdb_curses.h"
 
 /****************************
diff --git a/gdb/tui/tui-disasm.c b/gdb/tui/tui-disasm.c
index 8c48d66..1c89a14 100644
--- a/gdb/tui/tui-disasm.c
+++ b/gdb/tui/tui-disasm.c
@@ -27,7 +27,6 @@
 #include "value.h"
 #include "source.h"
 #include "disasm.h"
-#include <string.h>
 #include "tui/tui.h"
 #include "tui/tui-data.h"
 #include "tui/tui-win.h"
diff --git a/gdb/tui/tui-file.c b/gdb/tui/tui-file.c
index 8e84fc5..afbfdec 100644
--- a/gdb/tui/tui-file.c
+++ b/gdb/tui/tui-file.c
@@ -23,8 +23,6 @@
 
 #include "tui.h"
 
-#include <string.h>
-
 /* A ``struct ui_file'' that is compatible with all the legacy
    code.  */
 
diff --git a/gdb/tui/tui-layout.c b/gdb/tui/tui-layout.c
index d037b5a..a59576a 100644
--- a/gdb/tui/tui-layout.c
+++ b/gdb/tui/tui-layout.c
@@ -37,8 +37,6 @@
 #include "tui/tui-winsource.h"
 #include "tui/tui-disasm.h"
 #include "tui/tui-layout.h"
-
-#include <string.h>
 #include "gdb_curses.h"
 
 /*******************************
diff --git a/gdb/tui/tui-out.c b/gdb/tui/tui-out.c
index ff782f6..3408068 100644
--- a/gdb/tui/tui-out.c
+++ b/gdb/tui/tui-out.c
@@ -24,8 +24,6 @@
 #include "ui-out.h"
 #include "cli-out.h"
 #include "tui.h"
-#include <string.h>
-
 struct tui_ui_out_data
   {
     struct cli_ui_out_data base;
diff --git a/gdb/tui/tui-regs.c b/gdb/tui/tui-regs.c
index 2c53e05..c620a9c 100644
--- a/gdb/tui/tui-regs.c
+++ b/gdb/tui/tui-regs.c
@@ -30,7 +30,6 @@
 #include "regcache.h"
 #include "inferior.h"
 #include "target.h"
-#include <string.h>
 #include "tui/tui-layout.h"
 #include "tui/tui-win.h"
 #include "tui/tui-windata.h"
diff --git a/gdb/tui/tui-source.c b/gdb/tui/tui-source.c
index cb40a57..7aceaa8 100644
--- a/gdb/tui/tui-source.c
+++ b/gdb/tui/tui-source.c
@@ -34,8 +34,6 @@
 #include "tui/tui-stack.h"
 #include "tui/tui-winsource.h"
 #include "tui/tui-source.h"
-
-#include <string.h>
 #include "gdb_curses.h"
 
 /* Function to display source in the source window.  */
diff --git a/gdb/tui/tui-stack.c b/gdb/tui/tui-stack.c
index 481d46f..f90dff3 100644
--- a/gdb/tui/tui-stack.c
+++ b/gdb/tui/tui-stack.c
@@ -28,7 +28,6 @@
 #include "target.h"
 #include "top.h"
 #include "gdb-demangle.h"
-#include <string.h>
 #include "source.h"
 #include "tui/tui.h"
 #include "tui/tui-data.h"
diff --git a/gdb/tui/tui-win.c b/gdb/tui/tui-win.c
index a97704d..9c7a23f 100644
--- a/gdb/tui/tui-win.c
+++ b/gdb/tui/tui-win.c
@@ -45,8 +45,6 @@
 #include "tui/tui-win.h"
 
 #include "gdb_curses.h"
-
-#include <string.h>
 #include <ctype.h>
 #include "readline/readline.h"
 
diff --git a/gdb/tui/tui-windata.c b/gdb/tui/tui-windata.c
index 986806f..f06aa32 100644
--- a/gdb/tui/tui-windata.c
+++ b/gdb/tui/tui-windata.c
@@ -25,8 +25,6 @@
 #include "tui/tui-wingeneral.h"
 #include "tui/tui-regs.h"
 #include "tui/tui-windata.h"
-
-#include <string.h>
 #include "gdb_curses.h"
 
 
diff --git a/gdb/tui/tui-winsource.c b/gdb/tui/tui-winsource.c
index 0625206..171b171 100644
--- a/gdb/tui/tui-winsource.c
+++ b/gdb/tui/tui-winsource.c
@@ -37,8 +37,6 @@
 #include "tui/tui-winsource.h"
 #include "tui/tui-source.h"
 #include "tui/tui-disasm.h"
-
-#include <string.h>
 #include "gdb_curses.h"
 
 /* Function to display the "main" routine.  */
diff --git a/gdb/typeprint.c b/gdb/typeprint.c
index 026f3a2..e0b7c44 100644
--- a/gdb/typeprint.c
+++ b/gdb/typeprint.c
@@ -31,7 +31,6 @@
 #include "language.h"
 #include "cp-abi.h"
 #include "typeprint.h"
-#include <string.h>
 #include "exceptions.h"
 #include "valprint.h"
 #include <errno.h>
diff --git a/gdb/ui-file.c b/gdb/ui-file.c
index e59d70b..767b55b 100644
--- a/gdb/ui-file.c
+++ b/gdb/ui-file.c
@@ -22,7 +22,6 @@
 #include "defs.h"
 #include "ui-file.h"
 #include "gdb_obstack.h"
-#include <string.h>
 #include "gdb_select.h"
 #include "filestuff.h"
 
diff --git a/gdb/ui-out.c b/gdb/ui-out.c
index 205af9c..26bd04f 100644
--- a/gdb/ui-out.c
+++ b/gdb/ui-out.c
@@ -21,7 +21,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "expression.h"		/* For language.h */
 #include "language.h"
 #include "ui-out.h"
diff --git a/gdb/user-regs.c b/gdb/user-regs.c
index f4ec54a..35d64ec 100644
--- a/gdb/user-regs.c
+++ b/gdb/user-regs.c
@@ -22,7 +22,6 @@
 #include "defs.h"
 #include "user-regs.h"
 #include "gdbtypes.h"
-#include <string.h>
 #include "frame.h"
 
 /* A table of user registers.
diff --git a/gdb/utils.c b/gdb/utils.c
index 1a71a58..3849128 100644
--- a/gdb/utils.c
+++ b/gdb/utils.c
@@ -20,7 +20,6 @@
 #include "defs.h"
 #include "dyn-string.h"
 #include <ctype.h>
-#include <string.h>
 #include "gdb_wait.h"
 #include "event-top.h"
 #include "exceptions.h"
diff --git a/gdb/v850-tdep.c b/gdb/v850-tdep.c
index 3e4447a..ad1f491 100644
--- a/gdb/v850-tdep.c
+++ b/gdb/v850-tdep.c
@@ -25,7 +25,6 @@
 #include "dwarf2-frame.h"
 #include "gdbtypes.h"
 #include "inferior.h"
-#include <string.h>
 #include "gdbcore.h"
 #include "arch-utils.h"
 #include "regcache.h"
diff --git a/gdb/valarith.c b/gdb/valarith.c
index 4da41cb..d60dedb 100644
--- a/gdb/valarith.c
+++ b/gdb/valarith.c
@@ -24,7 +24,6 @@
 #include "expression.h"
 #include "target.h"
 #include "language.h"
-#include <string.h>
 #include "doublest.h"
 #include "dfp.h"
 #include <math.h>
diff --git a/gdb/valops.c b/gdb/valops.c
index 6cd66c7..5ef763d 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -37,7 +37,6 @@
 #include "dfp.h"
 #include "tracepoint.h"
 #include <errno.h>
-#include <string.h>
 #include "observer.h"
 #include "objfiles.h"
 #include "exceptions.h"
diff --git a/gdb/valprint.c b/gdb/valprint.c
index 8600b34..0ded6b7 100644
--- a/gdb/valprint.c
+++ b/gdb/valprint.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "value.h"
diff --git a/gdb/value.c b/gdb/value.c
index 90e4bdc..8ff5738 100644
--- a/gdb/value.c
+++ b/gdb/value.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "arch-utils.h"
-#include <string.h>
 #include "symtab.h"
 #include "gdbtypes.h"
 #include "value.h"
diff --git a/gdb/varobj.c b/gdb/varobj.c
index d350234..1c4bae9 100644
--- a/gdb/varobj.c
+++ b/gdb/varobj.c
@@ -24,8 +24,6 @@
 #include "gdbcmd.h"
 #include "block.h"
 #include "valprint.h"
-
-#include <string.h>
 #include "gdb_regex.h"
 
 #include "varobj.h"
diff --git a/gdb/vax-tdep.c b/gdb/vax-tdep.c
index 4780c90..0f47002 100644
--- a/gdb/vax-tdep.c
+++ b/gdb/vax-tdep.c
@@ -32,8 +32,6 @@
 #include "trad-frame.h"
 #include "value.h"
 
-#include <string.h>
-
 #include "vax-tdep.h"
 
 /* Return the name of register REGNUM.  */
diff --git a/gdb/vaxnbsd-tdep.c b/gdb/vaxnbsd-tdep.c
index 0e7cdfb..ac48970 100644
--- a/gdb/vaxnbsd-tdep.c
+++ b/gdb/vaxnbsd-tdep.c
@@ -24,8 +24,6 @@
 #include "vax-tdep.h"
 #include "solib-svr4.h"
 
-#include <string.h>
-
 /* NetBSD ELF.  */
 
 static void
diff --git a/gdb/vaxobsd-tdep.c b/gdb/vaxobsd-tdep.c
index 8020161..43c4832 100644
--- a/gdb/vaxobsd-tdep.c
+++ b/gdb/vaxobsd-tdep.c
@@ -27,8 +27,6 @@
 
 #include "vax-tdep.h"
 
-#include <string.h>
-
 /* Signal trampolines.  */
 
 /* Since OpenBSD 3.2, the sigtramp routine is mapped at a random page
diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c
index 5dcd520..73665e5 100644
--- a/gdb/windows-nat.c
+++ b/gdb/windows-nat.c
@@ -50,7 +50,6 @@
 #include "objfiles.h"
 #include "gdb_bfd.h"
 #include "gdb_obstack.h"
-#include <string.h>
 #include "gdbthread.h"
 #include "gdbcmd.h"
 #include <unistd.h>
diff --git a/gdb/xcoffread.c b/gdb/xcoffread.c
index b986dbd..90cc32f 100644
--- a/gdb/xcoffread.c
+++ b/gdb/xcoffread.c
@@ -24,8 +24,6 @@
 #include <sys/types.h>
 #include <fcntl.h>
 #include <ctype.h>
-#include <string.h>
-
 #ifdef HAVE_SYS_FILE_H
 #include <sys/file.h>
 #endif
diff --git a/gdb/xml-support.c b/gdb/xml-support.c
index 5062bc1..531ac10 100644
--- a/gdb/xml-support.c
+++ b/gdb/xml-support.c
@@ -22,8 +22,6 @@
 #include "exceptions.h"
 #include "xml-support.h"
 #include "filestuff.h"
-
-#include <string.h>
 #include "safe-ctype.h"
 
 /* Debugging flag.  */
diff --git a/gdb/xstormy16-tdep.c b/gdb/xstormy16-tdep.c
index 2f38739..af3ff32 100644
--- a/gdb/xstormy16-tdep.c
+++ b/gdb/xstormy16-tdep.c
@@ -29,7 +29,6 @@
 #include "value.h"
 #include "dis-asm.h"
 #include "inferior.h"
-#include <string.h>
 #include "arch-utils.h"
 #include "floatformat.h"
 #include "regcache.h"
diff --git a/gdb/xtensa-linux-nat.c b/gdb/xtensa-linux-nat.c
index 945f379..2d506f7 100644
--- a/gdb/xtensa-linux-nat.c
+++ b/gdb/xtensa-linux-nat.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <string.h>
 #include "frame.h"
 #include "inferior.h"
 #include "gdbcore.h"
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 02/13] Move stdlib.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (2 preceding siblings ...)
  2014-07-29 15:11 ` [PATCH 12/13] Include gdb_assert.h " Gary Benson
@ 2014-07-29 15:11 ` Gary Benson
  2014-07-29 15:13 ` [PATCH 04/13] Move stddef.h " Gary Benson
                   ` (10 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:11 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of stdlib.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include stdlib.h.
	* defs.h: Do not include stdlib.h.
	* addrmap.c: Likewise.
	* bcache.c: Likewise.
	* common/buffer.c: Likewise.
	* common/common-utils.c: Likewise.
	* cp-name-parser.y: Likewise.
	* go32-nat.c: Likewise.
	* mn10300-linux-tdep.c: Likewise.
	* nat/linux-osdata.c: Likewise.
	* tui/tui.c: Likewise.
	* windows-nat.c: Likewise.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include stdlib.h.
	* inferiors.c: Likewise.
	* linux-low.c: Likewise.
	* regcache.c: Likewise.
	* spu-low.c: Likewise.
	* tracepoint.c: Likewise.
	* utils.c: Likewise.
---
 gdb/ChangeLog              |   15 +++++++++++++++
 gdb/addrmap.c              |    3 ---
 gdb/bcache.c               |    1 -
 gdb/common/buffer.c        |    1 -
 gdb/common/common-defs.h   |    1 +
 gdb/common/common-utils.c  |    2 --
 gdb/cp-name-parser.y       |    1 -
 gdb/defs.h                 |    3 ---
 gdb/gdbserver/ChangeLog    |   10 ++++++++++
 gdb/gdbserver/inferiors.c  |    1 -
 gdb/gdbserver/linux-low.c  |    1 -
 gdb/gdbserver/regcache.c   |    2 --
 gdb/gdbserver/server.h     |    1 -
 gdb/gdbserver/spu-low.c    |    1 -
 gdb/gdbserver/tracepoint.c |    1 -
 gdb/gdbserver/utils.c      |    1 -
 gdb/go32-nat.c             |    1 -
 gdb/mn10300-linux-tdep.c   |    2 --
 gdb/nat/linux-osdata.c     |    1 -
 gdb/tui/tui.c              |    1 -
 gdb/windows-nat.c          |    1 -
 21 files changed, 26 insertions(+), 25 deletions(-)

diff --git a/gdb/addrmap.c b/gdb/addrmap.c
index c8fee38..c942c7b 100644
--- a/gdb/addrmap.c
+++ b/gdb/addrmap.c
@@ -18,9 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-
-#include <stdlib.h>
-
 #include "splay-tree.h"
 #include "gdb_obstack.h"
 #include "addrmap.h"
diff --git a/gdb/bcache.c b/gdb/bcache.c
index 99e9184..0c87e2d 100644
--- a/gdb/bcache.c
+++ b/gdb/bcache.c
@@ -26,7 +26,6 @@
 #include "gdb_assert.h"
 
 #include <stddef.h>
-#include <stdlib.h>
 
 /* The type used to hold a single bcache string.  The user data is
    stored in d.data.  Since it can be any type, it needs to have the
diff --git a/gdb/common/buffer.c b/gdb/common/buffer.c
index a50c890..c291b32 100644
--- a/gdb/common/buffer.c
+++ b/gdb/common/buffer.c
@@ -27,7 +27,6 @@
 #include "buffer.h"
 #include "inttypes.h"
 
-#include <stdlib.h>
 #include <string.h>
 #include <stdint.h>
 
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 0fc7af5..ed95a36 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -28,5 +28,6 @@
 #endif
 
 #include <stdio.h>
+#include <stdlib.h>
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/common/common-utils.c b/gdb/common/common-utils.c
index 41ef289..ab05c9f 100644
--- a/gdb/common/common-utils.c
+++ b/gdb/common/common-utils.c
@@ -26,8 +26,6 @@
 #include "gdb_assert.h"
 #include <string.h>
 
-#include <stdlib.h>
-
 /* The xmalloc() (libiberty.h) family of memory management routines.
 
    These are like the ISO-C malloc() family except that they implement
diff --git a/gdb/cp-name-parser.y b/gdb/cp-name-parser.y
index 6a9d13d..3199aff 100644
--- a/gdb/cp-name-parser.y
+++ b/gdb/cp-name-parser.y
@@ -31,7 +31,6 @@
 
 #include "defs.h"
 
-#include <stdlib.h>
 #include <unistd.h>
 #include <string.h>
 
diff --git a/gdb/defs.h b/gdb/defs.h
index 49e45b8..2e1e06b 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -597,9 +597,6 @@ enum gdb_osabi
 
 /* From other system libraries */
 
-#include <stdlib.h>
-
-
 #ifndef atof
 extern double atof (const char *);	/* X3.159-1989  4.10.1.1 */
 #endif
diff --git a/gdb/gdbserver/inferiors.c b/gdb/gdbserver/inferiors.c
index 48d7700..608a997 100644
--- a/gdb/gdbserver/inferiors.c
+++ b/gdb/gdbserver/inferiors.c
@@ -19,7 +19,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "server.h"
-#include <stdlib.h>
 #include "gdbthread.h"
 #include "dll.h"
 
diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c
index 0b9353e..b599bef 100644
--- a/gdb/gdbserver/linux-low.c
+++ b/gdb/gdbserver/linux-low.c
@@ -31,7 +31,6 @@
 #include <sys/ioctl.h>
 #include <fcntl.h>
 #include <string.h>
-#include <stdlib.h>
 #include <unistd.h>
 #include <errno.h>
 #include <sys/syscall.h>
diff --git a/gdb/gdbserver/regcache.c b/gdb/gdbserver/regcache.c
index bed10b4..5c973b1 100644
--- a/gdb/gdbserver/regcache.c
+++ b/gdb/gdbserver/regcache.c
@@ -21,8 +21,6 @@
 #include "gdbthread.h"
 #include "tdesc.h"
 #include "rsp-low.h"
-
-#include <stdlib.h>
 #include <string.h>
 
 #ifndef IN_PROCESS_AGENT
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 743a368..a15ba36 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -30,7 +30,6 @@
 #include "version.h"
 
 #include <stdarg.h>
-#include <stdlib.h>
 #ifdef HAVE_ERRNO_H
 #include <errno.h>
 #endif
diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c
index 67ff147..ba2780b 100644
--- a/gdb/gdbserver/spu-low.c
+++ b/gdb/gdbserver/spu-low.c
@@ -24,7 +24,6 @@
 #include <sys/ptrace.h>
 #include <fcntl.h>
 #include <string.h>
-#include <stdlib.h>
 #include <unistd.h>
 #include <errno.h>
 #include <sys/syscall.h>
diff --git a/gdb/gdbserver/tracepoint.c b/gdb/gdbserver/tracepoint.c
index 7c4b291..31be953 100644
--- a/gdb/gdbserver/tracepoint.c
+++ b/gdb/gdbserver/tracepoint.c
@@ -7110,7 +7110,6 @@ gdb_ust_init (void)
 #endif /* HAVE_UST */
 
 #include <sys/syscall.h>
-#include <stdlib.h>
 
 static void
 gdb_agent_remove_socket (void)
diff --git a/gdb/gdbserver/utils.c b/gdb/gdbserver/utils.c
index b87bcc9..a0febb1 100644
--- a/gdb/gdbserver/utils.c
+++ b/gdb/gdbserver/utils.c
@@ -18,7 +18,6 @@
 
 #include "server.h"
 #include <string.h>
-#include <stdlib.h>
 #if HAVE_ERRNO_H
 #include <errno.h>
 #endif
diff --git a/gdb/go32-nat.c b/gdb/go32-nat.c
index 42133d6..a8c54fa 100644
--- a/gdb/go32-nat.c
+++ b/gdb/go32-nat.c
@@ -105,7 +105,6 @@
 #include "cli/cli-utils.h"
 #include "inf-child.h"
 
-#include <stdlib.h>
 #include <ctype.h>
 #include <errno.h>
 #include <unistd.h>
diff --git a/gdb/mn10300-linux-tdep.c b/gdb/mn10300-linux-tdep.c
index 4377463..1b72efa 100644
--- a/gdb/mn10300-linux-tdep.c
+++ b/gdb/mn10300-linux-tdep.c
@@ -33,8 +33,6 @@
 #include "tramp-frame.h"
 #include "linux-tdep.h"
 
-#include <stdlib.h>
-
 /* Transliterated from <asm-mn10300/elf.h>...  */
 #define MN10300_ELF_NGREG 28
 #define MN10300_ELF_NFPREG 32
diff --git a/gdb/nat/linux-osdata.c b/gdb/nat/linux-osdata.c
index dae637b..d9d1325 100644
--- a/gdb/nat/linux-osdata.c
+++ b/gdb/nat/linux-osdata.c
@@ -28,7 +28,6 @@
 #include <sys/types.h>
 #include <sys/sysinfo.h>
 #include <ctype.h>
-#include <stdlib.h>
 #include <string.h>
 #include <utmp.h>
 #include <time.h>
diff --git a/gdb/tui/tui.c b/gdb/tui/tui.c
index 413ec20..7add8ba 100644
--- a/gdb/tui/tui.c
+++ b/gdb/tui/tui.c
@@ -38,7 +38,6 @@
 #include "symtab.h"
 #include "source.h"
 
-#include <stdlib.h>
 #include <ctype.h>
 #include <signal.h>
 #include <fcntl.h>
diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c
index 3d101a1..5dcd520 100644
--- a/gdb/windows-nat.c
+++ b/gdb/windows-nat.c
@@ -35,7 +35,6 @@
 #include <signal.h>
 #include <sys/types.h>
 #include <fcntl.h>
-#include <stdlib.h>
 #include <windows.h>
 #include <imagehlp.h>
 #include <psapi.h>
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 04/13] Move stddef.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (3 preceding siblings ...)
  2014-07-29 15:11 ` [PATCH 02/13] Move stdlib.h to common-defs.h Gary Benson
@ 2014-07-29 15:13 ` Gary Benson
  2014-07-29 15:14 ` [PATCH 09/13] Move gdb_locale.h " Gary Benson
                   ` (9 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:13 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of stddef.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include stddef.h.
	* defs.h: Do not include stddef.h.
	* common/common-utils.h: Likewise.
	* amd64fbsd-nat.c: Likewise.
	* bcache.c: Likewise.
	* charset.c: Likewise.
	* common/buffer.h: Likewise.
	* common/vec.h: Likewise.
	* i386bsd-nat.c: Likewise.
	* nat/linux-btrace.h: Likewise.
	* ppcfbsd-nat.c: Likewise.
	* ppcnbsd-tdep.h: Likewise.
	* ppcobsd-nat.c: Likewise.
	* ppcobsd-tdep.h: Likewise.
	* python/py-gdb-readline.c: Likewise.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* linux-x86-low.c: Do not include stddef.h.
	* lynx-ppc-low.c: Likewise.
	* tracepoint.c: Likewise.
---
 gdb/ChangeLog                 |   18 ++++++++++++++++++
 gdb/amd64fbsd-nat.c           |    1 -
 gdb/bcache.c                  |    2 --
 gdb/charset.c                 |    1 -
 gdb/common/buffer.h           |    1 -
 gdb/common/common-defs.h      |    1 +
 gdb/common/common-utils.h     |    1 -
 gdb/common/vec.h              |    2 --
 gdb/defs.h                    |    2 --
 gdb/gdbserver/ChangeLog       |    6 ++++++
 gdb/gdbserver/linux-x86-low.c |    1 -
 gdb/gdbserver/lynx-ppc-low.c  |    1 -
 gdb/gdbserver/tracepoint.c    |    1 -
 gdb/i386bsd-nat.c             |    1 -
 gdb/nat/linux-btrace.h        |    1 -
 gdb/ppcfbsd-nat.c             |    1 -
 gdb/ppcnbsd-tdep.h            |    2 --
 gdb/ppcobsd-nat.c             |    1 -
 gdb/ppcobsd-tdep.h            |    2 --
 gdb/python/py-gdb-readline.c  |    2 --
 20 files changed, 25 insertions(+), 23 deletions(-)

diff --git a/gdb/amd64fbsd-nat.c b/gdb/amd64fbsd-nat.c
index 72dc39b..3650bb5 100644
--- a/gdb/amd64fbsd-nat.c
+++ b/gdb/amd64fbsd-nat.c
@@ -24,7 +24,6 @@
 
 #include "gdb_assert.h"
 #include <signal.h>
-#include <stddef.h>
 #include <sys/types.h>
 #include <sys/ptrace.h>
 #include <sys/sysctl.h>
diff --git a/gdb/bcache.c b/gdb/bcache.c
index 0c87e2d..44530bc 100644
--- a/gdb/bcache.c
+++ b/gdb/bcache.c
@@ -25,8 +25,6 @@
 #include <string.h>		/* For memcpy declaration */
 #include "gdb_assert.h"
 
-#include <stddef.h>
-
 /* The type used to hold a single bcache string.  The user data is
    stored in d.data.  Since it can be any type, it needs to have the
    same alignment as the most strict alignment of any type on the host
diff --git a/gdb/charset.c b/gdb/charset.c
index 6f413a2..3e7a85c 100644
--- a/gdb/charset.c
+++ b/gdb/charset.c
@@ -29,7 +29,6 @@
 #include "arch-utils.h"
 #include "gdb_vecs.h"
 
-#include <stddef.h>
 #include <string.h>
 #include <ctype.h>
 
diff --git a/gdb/common/buffer.h b/gdb/common/buffer.h
index c6abc8b..d051bfb 100644
--- a/gdb/common/buffer.h
+++ b/gdb/common/buffer.h
@@ -20,7 +20,6 @@
 #ifndef BUFFER_H
 #define BUFFER_H
 
-#include <stddef.h>
 #include <string.h>
 #include "ansidecl.h"
 
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index d227b00..f1fd363 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -30,5 +30,6 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <stdarg.h>
+#include <stddef.h>
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/common/common-utils.h b/gdb/common/common-utils.h
index dff7b53..4dc4329 100644
--- a/gdb/common/common-utils.h
+++ b/gdb/common/common-utils.h
@@ -21,7 +21,6 @@
 #define COMMON_UTILS_H
 
 #include "ansidecl.h"
-#include <stddef.h>
 
 /* If possible, define FUNCTION_NAME, a macro containing the name of
    the function being defined.  Since this macro may not always be
diff --git a/gdb/common/vec.h b/gdb/common/vec.h
index 7bae2ff..2a39eff 100644
--- a/gdb/common/vec.h
+++ b/gdb/common/vec.h
@@ -20,8 +20,6 @@
 #if !defined (GDB_VEC_H)
 #define GDB_VEC_H
 
-#include <stddef.h>
-
 #include <string.h>
 #include "gdb_assert.h"
 
diff --git a/gdb/defs.h b/gdb/defs.h
index 00cb8e7..58098a9 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -46,8 +46,6 @@
    included, so it's ok to blank out gstdint.h.  */
 #define GCC_GENERATED_STDINT_H 1
 
-#include <stddef.h>
-
 #include <unistd.h>
 
 /* For gnulib's PATH_MAX.  */
diff --git a/gdb/gdbserver/linux-x86-low.c b/gdb/gdbserver/linux-x86-low.c
index 850ed7c..7a8a473 100644
--- a/gdb/gdbserver/linux-x86-low.c
+++ b/gdb/gdbserver/linux-x86-low.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "server.h"
-#include <stddef.h>
 #include <signal.h>
 #include <limits.h>
 #include <inttypes.h>
diff --git a/gdb/gdbserver/lynx-ppc-low.c b/gdb/gdbserver/lynx-ppc-low.c
index d6ead6f..7884f23 100644
--- a/gdb/gdbserver/lynx-ppc-low.c
+++ b/gdb/gdbserver/lynx-ppc-low.c
@@ -19,7 +19,6 @@
 #include "lynx-low.h"
 
 #include <stdint.h>
-#include <stddef.h>
 #include <limits.h>
 #include <sys/ptrace.h>
 
diff --git a/gdb/gdbserver/tracepoint.c b/gdb/gdbserver/tracepoint.c
index 31be953..302b9c7 100644
--- a/gdb/gdbserver/tracepoint.c
+++ b/gdb/gdbserver/tracepoint.c
@@ -26,7 +26,6 @@
 #include <fcntl.h>
 #include <unistd.h>
 #include <sys/time.h>
-#include <stddef.h>
 #include <inttypes.h>
 #include <stdint.h>
 
diff --git a/gdb/i386bsd-nat.c b/gdb/i386bsd-nat.c
index acae6cb..4bee159 100644
--- a/gdb/i386bsd-nat.c
+++ b/gdb/i386bsd-nat.c
@@ -23,7 +23,6 @@
 
 #include "gdb_assert.h"
 #include <signal.h>
-#include <stddef.h>
 #include <sys/types.h>
 #include <sys/ptrace.h>
 #include <machine/reg.h>
diff --git a/gdb/nat/linux-btrace.h b/gdb/nat/linux-btrace.h
index a96d9d1..5faf535 100644
--- a/gdb/nat/linux-btrace.h
+++ b/gdb/nat/linux-btrace.h
@@ -25,7 +25,6 @@
 #include "btrace-common.h"
 #include "vec.h"
 #include "ptid.h"
-#include <stddef.h>
 #include <stdint.h>
 
 #if HAVE_LINUX_PERF_EVENT_H
diff --git a/gdb/ppcfbsd-nat.c b/gdb/ppcfbsd-nat.c
index 079bd12..aeb47af 100644
--- a/gdb/ppcfbsd-nat.c
+++ b/gdb/ppcfbsd-nat.c
@@ -23,7 +23,6 @@
 #include "regcache.h"
 
 #include "gdb_assert.h"
-#include <stddef.h>
 #include <sys/types.h>
 #include <sys/procfs.h>
 #include <sys/ptrace.h>
diff --git a/gdb/ppcnbsd-tdep.h b/gdb/ppcnbsd-tdep.h
index 747b452..6631fc1 100644
--- a/gdb/ppcnbsd-tdep.h
+++ b/gdb/ppcnbsd-tdep.h
@@ -20,8 +20,6 @@
 #ifndef PPCNBSD_TDEP_H
 #define PPCNBSD_TDEP_H
 
-#include <stddef.h>
-
 struct regset;
 
 /* Register offsets for NetBSD/powerpc.  */
diff --git a/gdb/ppcobsd-nat.c b/gdb/ppcobsd-nat.c
index 1aa56d0..9e3e85b 100644
--- a/gdb/ppcobsd-nat.c
+++ b/gdb/ppcobsd-nat.c
@@ -23,7 +23,6 @@
 #include "regcache.h"
 
 #include "gdb_assert.h"
-#include <stddef.h>
 #include <sys/types.h>
 #include <sys/ptrace.h>
 #include <sys/signal.h>
diff --git a/gdb/ppcobsd-tdep.h b/gdb/ppcobsd-tdep.h
index 8c9ac3a..7d8d13e 100644
--- a/gdb/ppcobsd-tdep.h
+++ b/gdb/ppcobsd-tdep.h
@@ -20,8 +20,6 @@
 #ifndef PPCOBSD_TDEP_H
 #define PPCOBSD_TDEP_H
 
-#include <stddef.h>
-
 struct regset;
 struct regcache;
 
diff --git a/gdb/python/py-gdb-readline.c b/gdb/python/py-gdb-readline.c
index e926f8e..b778aa9 100644
--- a/gdb/python/py-gdb-readline.c
+++ b/gdb/python/py-gdb-readline.c
@@ -24,8 +24,6 @@
 #include "cli/cli-utils.h"
 #include <string.h>
 
-#include <stddef.h>
-
 /* Readline function suitable for PyOS_ReadlineFunctionPointer, which
    is used for Python's interactive parser and raw_input.  In both
    cases, sys_stdin and sys_stdout are always stdin and stdout
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 09/13] Move gdb_locale.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (4 preceding siblings ...)
  2014-07-29 15:13 ` [PATCH 04/13] Move stddef.h " Gary Benson
@ 2014-07-29 15:14 ` Gary Benson
  2014-07-29 15:18 ` [PATCH 11/13] Move common-utils.h " Gary Benson
                   ` (8 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:14 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of gdb_locale.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include gdb_locale.h.
	* defs.h: Do not include gdb_locale.h.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include gdb_locale.h.
---
 gdb/ChangeLog            |    5 +++++
 gdb/common/common-defs.h |    1 +
 gdb/defs.h               |    2 --
 gdb/gdbserver/ChangeLog  |    4 ++++
 gdb/gdbserver/server.h   |    1 -
 5 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 9c6001e..c0fbb0d 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -35,5 +35,6 @@
 #include "libiberty.h"
 #include "pathmax.h"
 #include "gdb/signals.h"
+#include "gdb_locale.h"
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/defs.h b/gdb/defs.h
index a5a1204..23f875e 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -50,8 +50,6 @@
 
 #include <fcntl.h>
 
-#include "gdb_locale.h"
-
 #include "gdb_wchar.h"
 
 #include "ui-file.h"
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 98993f0..7c0b80a 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -74,7 +74,6 @@ typedef unsigned char gdb_byte;
 #include "ptid.h"
 #include "buffer.h"
 #include "xml-utils.h"
-#include "gdb_locale.h"
 
 /* FIXME: This should probably be autoconf'd for.  It's an integer type at
    least the size of a (void *).  */
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 05/13] Move ansidecl.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (6 preceding siblings ...)
  2014-07-29 15:18 ` [PATCH 11/13] Move common-utils.h " Gary Benson
@ 2014-07-29 15:18 ` Gary Benson
  2014-07-29 15:35 ` [PATCH 01/13] Move stdio.h " Gary Benson
                   ` (6 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:18 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of ansidecl.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include ansidecl.h.
	* defs.h: Do not include ansidecl.h.
	* common/buffer.h: Likewise.
	* common/common-utils.h: Likewise.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include ansidecl.h.
---
 gdb/ChangeLog             |    7 +++++++
 gdb/common/buffer.h       |    1 -
 gdb/common/common-defs.h  |    1 +
 gdb/common/common-utils.h |    2 --
 gdb/defs.h                |    5 -----
 gdb/gdbserver/ChangeLog   |    4 ++++
 gdb/gdbserver/server.h    |    1 -
 7 files changed, 12 insertions(+), 9 deletions(-)

diff --git a/gdb/common/buffer.h b/gdb/common/buffer.h
index d051bfb..98da0d2 100644
--- a/gdb/common/buffer.h
+++ b/gdb/common/buffer.h
@@ -21,7 +21,6 @@
 #define BUFFER_H
 
 #include <string.h>
-#include "ansidecl.h"
 
 struct buffer
 {
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index f1fd363..8106e68 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -31,5 +31,6 @@
 #include <stdlib.h>
 #include <stdarg.h>
 #include <stddef.h>
+#include "ansidecl.h"
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/common/common-utils.h b/gdb/common/common-utils.h
index 4dc4329..9038bc2 100644
--- a/gdb/common/common-utils.h
+++ b/gdb/common/common-utils.h
@@ -20,8 +20,6 @@
 #ifndef COMMON_UTILS_H
 #define COMMON_UTILS_H
 
-#include "ansidecl.h"
-
 /* If possible, define FUNCTION_NAME, a macro containing the name of
    the function being defined.  Since this macro may not always be
    defined, all uses must be protected by appropriate macro definition
diff --git a/gdb/defs.h b/gdb/defs.h
index 58098a9..b7b6de9 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -53,11 +53,6 @@
 
 #include <fcntl.h>
 
-/* First include ansidecl.h so we can use the various macro definitions
-   here and in all subsequent file inclusions.  */
-
-#include "ansidecl.h"
-
 #include "gdb_locale.h"
 
 #include "gdb_wchar.h"
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 9d7fd99..061cdcd 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -26,7 +26,6 @@
 #endif
 
 #include "libiberty.h"
-#include "ansidecl.h"
 #include "version.h"
 
 #ifdef HAVE_ERRNO_H
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 11/13] Move common-utils.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (5 preceding siblings ...)
  2014-07-29 15:14 ` [PATCH 09/13] Move gdb_locale.h " Gary Benson
@ 2014-07-29 15:18 ` Gary Benson
  2014-07-29 15:18 ` [PATCH 05/13] Move ansidecl.h " Gary Benson
                   ` (7 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:18 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of common-utils.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include common-utils.h.
	* defs.h: Do not include common-utils.h.
	* common/gdb_assert.h: Likewise.
	* darwin-nat.h: Likewise.
	* nat/linux-btrace.c: Likewise.
	* target/waitstatus.h: Likewise.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include common-utils.h.
---
 gdb/ChangeLog            |    9 +++++++++
 gdb/common/common-defs.h |    1 +
 gdb/common/gdb_assert.h  |    2 --
 gdb/darwin-nat.h         |    1 -
 gdb/defs.h               |    2 --
 gdb/gdbserver/ChangeLog  |    4 ++++
 gdb/gdbserver/server.h   |    1 -
 gdb/nat/linux-btrace.c   |    1 -
 gdb/target/waitstatus.h  |    1 -
 9 files changed, 14 insertions(+), 8 deletions(-)

diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 7bf328a..6a031ec 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -37,5 +37,6 @@
 #include "gdb/signals.h"
 #include "gdb_locale.h"
 #include "ptid.h"
+#include "common-utils.h"
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/common/gdb_assert.h b/gdb/common/gdb_assert.h
index 4869fc4..7b795d3 100644
--- a/gdb/common/gdb_assert.h
+++ b/gdb/common/gdb_assert.h
@@ -19,8 +19,6 @@
 #ifndef GDB_ASSERT_H
 #define GDB_ASSERT_H
 
-#include "common-utils.h" /* For FUNCTION_NAME.  */
-
 /* A static assertion.  This will cause a compile-time error if EXPR,
    which must be a compile-time constant, is false.  */
 
diff --git a/gdb/darwin-nat.h b/gdb/darwin-nat.h
index 84f4be1..4f2bebb 100644
--- a/gdb/darwin-nat.h
+++ b/gdb/darwin-nat.h
@@ -18,7 +18,6 @@
 #define __DARWIN_NAT_H__
 
 #include <mach/mach.h>
-#include "common-utils.h" /* For FUNCTION_NAME.  */
 
 /* Describe the mach exception handling state for a task.  This state is saved
    before being changed and restored when a process is detached.
diff --git a/gdb/defs.h b/gdb/defs.h
index 8513606..710298c 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -533,8 +533,6 @@ enum val_prettyformat
 
 extern int longest_to_int (LONGEST);
 
-#include "common-utils.h"
-
 /* * List of known OS ABIs.  If you change this, make sure to update the
    table in osabi.c.  */
 enum gdb_osabi
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index ca2729c..5a3f335 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -131,7 +131,6 @@ extern int handle_target_event (int err, gdb_client_data client_data);
 
 #include "remote-utils.h"
 
-#include "common-utils.h"
 #include "utils.h"
 #include "debug.h"
 
diff --git a/gdb/nat/linux-btrace.c b/gdb/nat/linux-btrace.c
index 188220b..84de8a7 100644
--- a/gdb/nat/linux-btrace.c
+++ b/gdb/nat/linux-btrace.c
@@ -26,7 +26,6 @@
 #endif
 
 #include "linux-btrace.h"
-#include "common-utils.h"
 #include "gdb_assert.h"
 #include "regcache.h"
 #include "gdbthread.h"
diff --git a/gdb/target/waitstatus.h b/gdb/target/waitstatus.h
index c05d651..f818d87 100644
--- a/gdb/target/waitstatus.h
+++ b/gdb/target/waitstatus.h
@@ -20,7 +20,6 @@
 #ifndef WAITSTATUS_H
 #define WAITSTATUS_H
 
-#include "common-utils.h"
 #include "gdb_signals.h"
 
 /* Stuff for target_wait.  */
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 01/13] Move stdio.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (7 preceding siblings ...)
  2014-07-29 15:18 ` [PATCH 05/13] Move ansidecl.h " Gary Benson
@ 2014-07-29 15:35 ` Gary Benson
  2014-07-29 16:02 ` [PATCH 07/13] Move pathmax.h " Gary Benson
                   ` (5 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 15:35 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of stdio.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include stdio.h.
	* defs.h: Do not include stdio.h.
	* ada-lang.c: Likewise.
	* common/buffer.c: Likewise.
	* common/common-utils.c: Likewise.
	* cp-name-parser.y: Likewise.
	* gnu-nat.c: Likewise.
	* go32-nat.c: Likewise.
	* i386gnu-nat.c: Likewise.
	* proc-api.c: Likewise.
	* proc-events.c: Likewise.
	* proc-flags.c: Likewise.
	* proc-why.c: Likewise.
	* python/python-internal.h: Likewise.
	* target-memory.c: Likewise.
	* tui/tui-io.c: Likewise.
	* tui/tui.c: Likewise.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include stdio.h.
	* linux-low.c: Likewise.
	* remote-utils.c: Likewise.
	* spu-low.c: Likewise.
	* utils.c: Likewise.
	* wincecompat.c: Likewise.
---
 gdb/ChangeLog                |   20 ++++++++++++++++++++
 gdb/ada-lang.c               |    1 -
 gdb/common/buffer.c          |    1 -
 gdb/common/common-defs.h     |    2 ++
 gdb/common/common-utils.c    |    1 -
 gdb/cp-name-parser.y         |    1 -
 gdb/defs.h                   |    1 -
 gdb/gdbserver/ChangeLog      |    9 +++++++++
 gdb/gdbserver/linux-low.c    |    1 -
 gdb/gdbserver/remote-utils.c |    1 -
 gdb/gdbserver/server.h       |    1 -
 gdb/gdbserver/spu-low.c      |    1 -
 gdb/gdbserver/utils.c        |    1 -
 gdb/gdbserver/wincecompat.c  |    1 -
 gdb/gnu-nat.c                |    1 -
 gdb/go32-nat.c               |    1 -
 gdb/i386gnu-nat.c            |    1 -
 gdb/proc-api.c               |    1 -
 gdb/proc-events.c            |    1 -
 gdb/proc-flags.c             |    1 -
 gdb/proc-why.c               |    1 -
 gdb/python/python-internal.h |    2 --
 gdb/target-memory.c          |    1 -
 gdb/tui/tui-io.c             |    1 -
 gdb/tui/tui.c                |    1 -
 25 files changed, 31 insertions(+), 23 deletions(-)

diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
index 6956909..bf39f6b 100644
--- a/gdb/ada-lang.c
+++ b/gdb/ada-lang.c
@@ -19,7 +19,6 @@
 
 
 #include "defs.h"
-#include <stdio.h>
 #include <string.h>
 #include <ctype.h>
 #include <stdarg.h>
diff --git a/gdb/common/buffer.c b/gdb/common/buffer.c
index 4d9edb8..a50c890 100644
--- a/gdb/common/buffer.c
+++ b/gdb/common/buffer.c
@@ -29,7 +29,6 @@
 
 #include <stdlib.h>
 #include <string.h>
-#include <stdio.h>
 #include <stdint.h>
 
 void
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 9e397d9..0fc7af5 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -27,4 +27,6 @@
 #include "build-gnulib/config.h"
 #endif
 
+#include <stdio.h>
+
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/common/common-utils.c b/gdb/common/common-utils.c
index 29fe2c5..41ef289 100644
--- a/gdb/common/common-utils.c
+++ b/gdb/common/common-utils.c
@@ -27,7 +27,6 @@
 #include <string.h>
 
 #include <stdlib.h>
-#include <stdio.h>
 
 /* The xmalloc() (libiberty.h) family of memory management routines.
 
diff --git a/gdb/cp-name-parser.y b/gdb/cp-name-parser.y
index 7d9d925..6a9d13d 100644
--- a/gdb/cp-name-parser.y
+++ b/gdb/cp-name-parser.y
@@ -31,7 +31,6 @@
 
 #include "defs.h"
 
-#include <stdio.h>
 #include <stdlib.h>
 #include <unistd.h>
 #include <string.h>
diff --git a/gdb/defs.h b/gdb/defs.h
index 422c4e8..49e45b8 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -28,7 +28,6 @@
 #include "common-defs.h"
 
 #include <sys/types.h>
-#include <stdio.h>
 #include <errno.h>		/* System call error return status.  */
 #include <limits.h>
 #include <stdint.h>
diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c
index 521d9a2..0b9353e 100644
--- a/gdb/gdbserver/linux-low.c
+++ b/gdb/gdbserver/linux-low.c
@@ -24,7 +24,6 @@
 #include "nat/linux-nat.h"
 #include "nat/linux-waitpid.h"
 #include "gdb_wait.h"
-#include <stdio.h>
 #include <sys/ptrace.h>
 #include "nat/linux-ptrace.h"
 #include "nat/linux-procfs.h"
diff --git a/gdb/gdbserver/remote-utils.c b/gdb/gdbserver/remote-utils.c
index 4fcafa0..96d6038 100644
--- a/gdb/gdbserver/remote-utils.c
+++ b/gdb/gdbserver/remote-utils.c
@@ -24,7 +24,6 @@
 #include "dll.h"
 #include "rsp-low.h"
 
-#include <stdio.h>
 #include <string.h>
 #if HAVE_SYS_IOCTL_H
 #include <sys/ioctl.h>
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index ef66a32..743a368 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -30,7 +30,6 @@
 #include "version.h"
 
 #include <stdarg.h>
-#include <stdio.h>
 #include <stdlib.h>
 #ifdef HAVE_ERRNO_H
 #include <errno.h>
diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c
index 9bb0c40..67ff147 100644
--- a/gdb/gdbserver/spu-low.c
+++ b/gdb/gdbserver/spu-low.c
@@ -21,7 +21,6 @@
 #include "server.h"
 
 #include "gdb_wait.h"
-#include <stdio.h>
 #include <sys/ptrace.h>
 #include <fcntl.h>
 #include <string.h>
diff --git a/gdb/gdbserver/utils.c b/gdb/gdbserver/utils.c
index 2d0b331..b87bcc9 100644
--- a/gdb/gdbserver/utils.c
+++ b/gdb/gdbserver/utils.c
@@ -17,7 +17,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "server.h"
-#include <stdio.h>
 #include <string.h>
 #include <stdlib.h>
 #if HAVE_ERRNO_H
diff --git a/gdb/gdbserver/wincecompat.c b/gdb/gdbserver/wincecompat.c
index 68f6aa9..7d45b30 100644
--- a/gdb/gdbserver/wincecompat.c
+++ b/gdb/gdbserver/wincecompat.c
@@ -18,7 +18,6 @@
 
 #include "server.h"
 
-#include <stdio.h>
 #include <windows.h>
 
 void
diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c
index 176f4a1..a2de2f1 100644
--- a/gdb/gnu-nat.c
+++ b/gdb/gnu-nat.c
@@ -27,7 +27,6 @@
 #include <limits.h>
 #include <setjmp.h>
 #include <signal.h>
-#include <stdio.h>
 #include <string.h>
 #include <sys/ptrace.h>
 
diff --git a/gdb/go32-nat.c b/gdb/go32-nat.c
index b2570e8..42133d6 100644
--- a/gdb/go32-nat.c
+++ b/gdb/go32-nat.c
@@ -105,7 +105,6 @@
 #include "cli/cli-utils.h"
 #include "inf-child.h"
 
-#include <stdio.h>		/* might be required for __DJGPP_MINOR__ */
 #include <stdlib.h>
 #include <ctype.h>
 #include <errno.h>
diff --git a/gdb/i386gnu-nat.c b/gdb/i386gnu-nat.c
index d0a610b..23a70b3 100644
--- a/gdb/i386gnu-nat.c
+++ b/gdb/i386gnu-nat.c
@@ -24,7 +24,6 @@
 
 #include "gdb_assert.h"
 #include <errno.h>
-#include <stdio.h>
 #include <string.h>
 
 #include <mach.h>
diff --git a/gdb/proc-api.c b/gdb/proc-api.c
index 2ae7b84..c4aecc4 100644
--- a/gdb/proc-api.c
+++ b/gdb/proc-api.c
@@ -34,7 +34,6 @@
 #define _STRUCTURED_PROC 1
 #endif
 
-#include <stdio.h>
 #include <sys/types.h>
 #include <sys/procfs.h>
 #ifdef HAVE_SYS_PROC_H
diff --git a/gdb/proc-events.c b/gdb/proc-events.c
index 68f004f..bc494c3 100644
--- a/gdb/proc-events.c
+++ b/gdb/proc-events.c
@@ -34,7 +34,6 @@
 #define _STRUCTURED_PROC 1
 #endif
 
-#include <stdio.h>
 #include <sys/types.h>
 #include <sys/procfs.h>
 #ifdef HAVE_SYS_SYSCALL_H
diff --git a/gdb/proc-flags.c b/gdb/proc-flags.c
index 7c37e35..31af26d 100644
--- a/gdb/proc-flags.c
+++ b/gdb/proc-flags.c
@@ -31,7 +31,6 @@
 #define _STRUCTURED_PROC 1
 #endif
 
-#include <stdio.h>
 #include <sys/types.h>
 #include <sys/procfs.h>
 
diff --git a/gdb/proc-why.c b/gdb/proc-why.c
index 72c28e1..c053c9e 100644
--- a/gdb/proc-why.c
+++ b/gdb/proc-why.c
@@ -24,7 +24,6 @@
 #define _STRUCTURED_PROC 1
 #endif
 
-#include <stdio.h>
 #include <sys/types.h>
 #include <sys/procfs.h>
 
diff --git a/gdb/python/python-internal.h b/gdb/python/python-internal.h
index b7298d9..6e7e600 100644
--- a/gdb/python/python-internal.h
+++ b/gdb/python/python-internal.h
@@ -62,8 +62,6 @@
 #define CPYCHECKER_NEGATIVE_RESULT_SETS_EXCEPTION
 #endif
 
-#include <stdio.h>
-
 /* Python 2.4 doesn't include stdint.h soon enough to get {u,}intptr_t
    needed by pyport.h.  */
 #include <stdint.h>
diff --git a/gdb/target-memory.c b/gdb/target-memory.c
index 1c6cd40..583d337 100644
--- a/gdb/target-memory.c
+++ b/gdb/target-memory.c
@@ -25,7 +25,6 @@
 
 #include "gdb_assert.h"
 
-#include <stdio.h>
 #include <sys/time.h>
 
 static int
diff --git a/gdb/tui/tui-io.c b/gdb/tui/tui-io.c
index 75eb4b8..a890678 100644
--- a/gdb/tui/tui-io.c
+++ b/gdb/tui/tui-io.c
@@ -36,7 +36,6 @@
 #include "cli-out.h"
 #include <fcntl.h>
 #include <signal.h>
-#include <stdio.h>
 #include "filestuff.h"
 
 #include "gdb_curses.h"
diff --git a/gdb/tui/tui.c b/gdb/tui/tui.c
index c30b76c..413ec20 100644
--- a/gdb/tui/tui.c
+++ b/gdb/tui/tui.c
@@ -38,7 +38,6 @@
 #include "symtab.h"
 #include "source.h"
 
-#include <stdio.h>
 #include <stdlib.h>
 #include <ctype.h>
 #include <signal.h>
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 07/13] Move pathmax.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (8 preceding siblings ...)
  2014-07-29 15:35 ` [PATCH 01/13] Move stdio.h " Gary Benson
@ 2014-07-29 16:02 ` Gary Benson
  2014-07-29 16:08 ` [PATCH 06/13] Move libiberty.h " Gary Benson
                   ` (4 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 16:02 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of pathmax.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include pathmax.h.
	* defs.h: Do not include pathmax.h.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include pathmax.h.
---
 gdb/ChangeLog            |    5 +++++
 gdb/common/common-defs.h |    1 +
 gdb/defs.h               |    3 ---
 gdb/gdbserver/ChangeLog  |    4 ++++
 gdb/gdbserver/server.h   |    3 ---
 5 files changed, 10 insertions(+), 6 deletions(-)

diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index eedc318..b31b3b8 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -33,5 +33,6 @@
 #include <stddef.h>
 #include "ansidecl.h"
 #include "libiberty.h"
+#include "pathmax.h"
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/defs.h b/gdb/defs.h
index d9775e3..189de74 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -48,9 +48,6 @@
 
 #include <unistd.h>
 
-/* For gnulib's PATH_MAX.  */
-#include "pathmax.h"
-
 #include <fcntl.h>
 
 #include "gdb_locale.h"
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 9ecd9e0..fc973c1 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -32,9 +32,6 @@
 #endif
 #include <setjmp.h>
 
-/* For gnulib's PATH_MAX.  */
-#include "pathmax.h"
-
 #include <string.h>
 
 #ifdef HAVE_ALLOCA_H
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 06/13] Move libiberty.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (9 preceding siblings ...)
  2014-07-29 16:02 ` [PATCH 07/13] Move pathmax.h " Gary Benson
@ 2014-07-29 16:08 ` Gary Benson
  2014-07-29 16:22 ` [PATCH 10/13] Move ptid.h " Gary Benson
                   ` (3 subsequent siblings)
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 16:08 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of libiberty.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include libiberty.h.
	* defs.h: Do not include libiberty.h.
	* common/queue.h: Likewise.
	* cp-name-parser.y: Likewise.
	* mi/mi-cmd-catch.c: Likewise.
	* python/python.c: Likewise.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include libiberty.h.
	* linux-bfin-low.c: Likewise.
---
 gdb/ChangeLog                  |    9 +++++++++
 gdb/common/common-defs.h       |    1 +
 gdb/common/queue.h             |    1 -
 gdb/cp-name-parser.y           |    1 -
 gdb/defs.h                     |    1 -
 gdb/gdbserver/ChangeLog        |    5 +++++
 gdb/gdbserver/linux-bfin-low.c |    1 -
 gdb/gdbserver/server.h         |    1 -
 gdb/mi/mi-cmd-catch.c          |    1 -
 gdb/python/python.c            |    1 -
 10 files changed, 15 insertions(+), 7 deletions(-)

diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 8106e68..eedc318 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -32,5 +32,6 @@
 #include <stdarg.h>
 #include <stddef.h>
 #include "ansidecl.h"
+#include "libiberty.h"
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/common/queue.h b/gdb/common/queue.h
index 4ce53c3..34e4db3 100644
--- a/gdb/common/queue.h
+++ b/gdb/common/queue.h
@@ -20,7 +20,6 @@
 #ifndef QUEUE_H
 #define QUEUE_H
 
-#include "libiberty.h" /* xmalloc */
 #include "gdb_assert.h"
 
 /* These macros implement functions and structs for a general queue.
diff --git a/gdb/cp-name-parser.y b/gdb/cp-name-parser.y
index 3199aff..0caadfa 100644
--- a/gdb/cp-name-parser.y
+++ b/gdb/cp-name-parser.y
@@ -35,7 +35,6 @@
 #include <string.h>
 
 #include "safe-ctype.h"
-#include "libiberty.h"
 #include "demangle.h"
 #include "cp-support.h"
 #include "gdb_assert.h"
diff --git a/gdb/defs.h b/gdb/defs.h
index b7b6de9..d9775e3 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -83,7 +83,6 @@
 #define O_BINARY 0
 #endif
 
-#include "libiberty.h"
 #include "hashtab.h"
 
 /* Rather than duplicate all the logic in BFD for figuring out what
diff --git a/gdb/gdbserver/linux-bfin-low.c b/gdb/gdbserver/linux-bfin-low.c
index 03aa132..4c10cac 100644
--- a/gdb/gdbserver/linux-bfin-low.c
+++ b/gdb/gdbserver/linux-bfin-low.c
@@ -21,7 +21,6 @@
 
 #include "server.h"
 #include "linux-low.h"
-#include "libiberty.h"
 #include <asm/ptrace.h>
 
 /* Defined in auto-generated file reg-bfin.c.  */
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 061cdcd..9ecd9e0 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -25,7 +25,6 @@
 #include "wincecompat.h"
 #endif
 
-#include "libiberty.h"
 #include "version.h"
 
 #ifdef HAVE_ERRNO_H
diff --git a/gdb/mi/mi-cmd-catch.c b/gdb/mi/mi-cmd-catch.c
index 038df59..6c63058 100644
--- a/gdb/mi/mi-cmd-catch.c
+++ b/gdb/mi/mi-cmd-catch.c
@@ -22,7 +22,6 @@
 #include "arch-utils.h"
 #include "breakpoint.h"
 #include "gdb.h"
-#include "libiberty.h"
 #include "ada-lang.h"
 #include "mi-cmds.h"
 #include "mi-getopt.h"
diff --git a/gdb/python/python.c b/gdb/python/python.c
index 369a249..40c4ec9 100644
--- a/gdb/python/python.c
+++ b/gdb/python/python.c
@@ -86,7 +86,6 @@ const struct extension_language_defn extension_language_python =
 \f
 #ifdef HAVE_PYTHON
 
-#include "libiberty.h"
 #include "cli/cli-decode.h"
 #include "charset.h"
 #include "top.h"
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 10/13] Move ptid.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (10 preceding siblings ...)
  2014-07-29 16:08 ` [PATCH 06/13] Move libiberty.h " Gary Benson
@ 2014-07-29 16:22 ` Gary Benson
  2014-07-30  8:29   ` Gary Benson
  2014-07-29 16:22 ` [PATCH 08/13] Move gdb/signals.h " Gary Benson
                   ` (2 subsequent siblings)
  14 siblings, 1 reply; 26+ messages in thread
From: Gary Benson @ 2014-07-29 16:22 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of ptid.h to common-defs.h and removes
all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include ptid.h.
	* defs.h: Do not include ptid.h.
	* common/ptid.c: Likewise.
	* inferior.h: Likewise.
	* infrun.h: Likewise.
	* nat/linux-btrace.h: Likewise.
	* nat/linux-osdata.h: Likewise.
	* target/waitstatus.h: Likewise.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include ptid.h.
	* notif.h: Likewise.
---
 gdb/ChangeLog            |   11 +++++++++++
 gdb/common/common-defs.h |    1 +
 gdb/common/ptid.c        |    1 -
 gdb/defs.h               |    2 --
 gdb/gdbserver/ChangeLog  |    5 +++++
 gdb/gdbserver/notif.h    |    1 -
 gdb/gdbserver/server.h   |    1 -
 gdb/inferior.h           |    2 --
 gdb/infrun.h             |    1 -
 gdb/nat/linux-btrace.h   |    1 -
 gdb/nat/linux-osdata.h   |    2 --
 gdb/target/waitstatus.h  |    1 -
 12 files changed, 17 insertions(+), 12 deletions(-)

diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index c0fbb0d..7bf328a 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -36,5 +36,6 @@
 #include "pathmax.h"
 #include "gdb/signals.h"
 #include "gdb_locale.h"
+#include "ptid.h"
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/common/ptid.c b/gdb/common/ptid.c
index 04fd118..48e76ca 100644
--- a/gdb/common/ptid.c
+++ b/gdb/common/ptid.c
@@ -22,7 +22,6 @@
 #else
 #include "defs.h"
 #endif
-#include "ptid.h"
 
 /* See ptid.h for these.  */
 
diff --git a/gdb/defs.h b/gdb/defs.h
index 23f875e..8513606 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -113,8 +113,6 @@ typedef bfd_vma CORE_ADDR;
 #define max(a, b) ((a) > (b) ? (a) : (b))
 #endif
 
-#include "ptid.h"
-
 /* * Enable xdb commands if set.  */
 extern int xdb_commands;
 
diff --git a/gdb/gdbserver/notif.h b/gdb/gdbserver/notif.h
index 3d233a1..1fc802c 100644
--- a/gdb/gdbserver/notif.h
+++ b/gdb/gdbserver/notif.h
@@ -16,7 +16,6 @@
    You should have received a copy of the GNU General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
-#include "ptid.h"
 #include "server.h"
 #include "target.h"
 #include "queue.h"
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 7c0b80a..ca2729c 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -71,7 +71,6 @@ int vsnprintf(char *str, size_t size, const char *format, va_list ap);
 /* A type used for binary buffers.  */
 typedef unsigned char gdb_byte;
 
-#include "ptid.h"
 #include "buffer.h"
 #include "xml-utils.h"
 
diff --git a/gdb/inferior.h b/gdb/inferior.h
index 668c888..afc29e2 100644
--- a/gdb/inferior.h
+++ b/gdb/inferior.h
@@ -31,8 +31,6 @@ struct ui_out;
 struct terminal_info;
 struct target_desc_info;
 
-#include "ptid.h"
-
 /* For bpstat.  */
 #include "breakpoint.h"
 
diff --git a/gdb/infrun.h b/gdb/infrun.h
index 35b2246..cc9cb33 100644
--- a/gdb/infrun.h
+++ b/gdb/infrun.h
@@ -18,7 +18,6 @@
 #ifndef INFRUN_H
 #define INFRUN_H 1
 
-#include "ptid.h"
 #include "symtab.h"
 
 struct target_waitstatus;
diff --git a/gdb/nat/linux-btrace.h b/gdb/nat/linux-btrace.h
index 5faf535..28a7176 100644
--- a/gdb/nat/linux-btrace.h
+++ b/gdb/nat/linux-btrace.h
@@ -24,7 +24,6 @@
 
 #include "btrace-common.h"
 #include "vec.h"
-#include "ptid.h"
 #include <stdint.h>
 
 #if HAVE_LINUX_PERF_EVENT_H
diff --git a/gdb/nat/linux-osdata.h b/gdb/nat/linux-osdata.h
index e9d4f3c..252f3c9 100644
--- a/gdb/nat/linux-osdata.h
+++ b/gdb/nat/linux-osdata.h
@@ -20,8 +20,6 @@
 #ifndef COMMON_LINUX_OSDATA_H
 #define COMMON_LINUX_OSDATA_H
 
-#include "ptid.h"
-
 extern int linux_common_core_of_thread (ptid_t ptid);
 extern LONGEST linux_common_xfer_osdata (const char *annex, gdb_byte *readbuf,
 					 ULONGEST offset, ULONGEST len);
diff --git a/gdb/target/waitstatus.h b/gdb/target/waitstatus.h
index 32eb5a4..c05d651 100644
--- a/gdb/target/waitstatus.h
+++ b/gdb/target/waitstatus.h
@@ -21,7 +21,6 @@
 #define WAITSTATUS_H
 
 #include "common-utils.h"
-#include "ptid.h"
 #include "gdb_signals.h"
 
 /* Stuff for target_wait.  */
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 08/13] Move gdb/signals.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (11 preceding siblings ...)
  2014-07-29 16:22 ` [PATCH 10/13] Move ptid.h " Gary Benson
@ 2014-07-29 16:22 ` Gary Benson
  2014-07-30 13:35 ` [PATCH 14/13] Move errno.h " Gary Benson
  2014-08-06 17:26 ` [PATCH 00/13] Include some headers in common-defs.h Doug Evans
  14 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-29 16:22 UTC (permalink / raw)
  To: gdb-patches

This commit moves the inclusion of gdb/signals.h to common-defs.h and
removes all other inclusions.

gdb/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include gdb/signals.h.
	* defs.h: Do not include gdb/signals.h.

gdb/gdbserver/
2014-07-28  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include gdb/signals.h.
	* win32-low.c: Likewise.
---
 gdb/ChangeLog             |    5 +++++
 gdb/common/common-defs.h  |    1 +
 gdb/defs.h                |    3 ---
 gdb/gdbserver/ChangeLog   |    5 +++++
 gdb/gdbserver/server.h    |    1 -
 gdb/gdbserver/win32-low.c |    1 -
 6 files changed, 11 insertions(+), 5 deletions(-)

diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index b31b3b8..9c6001e 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -34,5 +34,6 @@
 #include "ansidecl.h"
 #include "libiberty.h"
 #include "pathmax.h"
+#include "gdb/signals.h"
 
 #endif /* COMMON_DEFS_H */
diff --git a/gdb/defs.h b/gdb/defs.h
index 189de74..a5a1204 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -54,9 +54,6 @@
 
 #include "gdb_wchar.h"
 
-/* For ``enum gdb_signal''.  */
-#include "gdb/signals.h"
-
 #include "ui-file.h"
 
 #include "host-defs.h"
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index fc973c1..98993f0 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -84,7 +84,6 @@ typedef long long LONGEST;
 typedef unsigned long long ULONGEST;
 
 #include "regcache.h"
-#include "gdb/signals.h"
 #include "gdb_signals.h"
 #include "target.h"
 #include "mem-break.h"
diff --git a/gdb/gdbserver/win32-low.c b/gdb/gdbserver/win32-low.c
index bc2506c..2242d5c 100644
--- a/gdb/gdbserver/win32-low.c
+++ b/gdb/gdbserver/win32-low.c
@@ -20,7 +20,6 @@
 
 #include "server.h"
 #include "regcache.h"
-#include "gdb/signals.h"
 #include "gdb/fileio.h"
 #include "mem-break.h"
 #include "win32-low.h"
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* Re: [PATCH 10/13] Move ptid.h to common-defs.h
  2014-07-29 16:22 ` [PATCH 10/13] Move ptid.h " Gary Benson
@ 2014-07-30  8:29   ` Gary Benson
  0 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-30  8:29 UTC (permalink / raw)
  To: gdb-patches

Gary Benson wrote:
> This commit moves the inclusion of ptid.h to common-defs.h and
> removes all other inclusions.
> 
> gdb/
> 2014-07-28  Gary Benson  <gbenson@redhat.com>
> 
> 	* common/common-defs.h: Include ptid.h.
> 	* defs.h: Do not include ptid.h.
> 	* common/ptid.c: Likewise.

As per:

Pedro Alves wrote [1]:
> It's a simpler rule if all .c files include their corresponding
> .h file.

I've updated my tree to reinstate '#include "ptid.h"' in ptid.c.
I won't post an updated patch.  Please review this patch as though
the ptid.c change was not there.

Thanks,
Gary

--
[1] https://sourceware.org/ml/gdb-patches/2014-07/msg00745.html


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 14/13] Move errno.h to common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (12 preceding siblings ...)
  2014-07-29 16:22 ` [PATCH 08/13] Move gdb/signals.h " Gary Benson
@ 2014-07-30 13:35 ` Gary Benson
  2014-07-31  8:55   ` Tom Tromey
  2014-08-06 17:26 ` [PATCH 00/13] Include some headers in common-defs.h Doug Evans
  14 siblings, 1 reply; 26+ messages in thread
From: Gary Benson @ 2014-07-30 13:35 UTC (permalink / raw)
  To: gdb-patches

Hi all,

An addendum to my previous series...

This commit moves the inclusion of errno.h to common-defs.h and
removes all other inclusions.  Note that prior to this commit errno.h
was included unconditionally in defs.h, whereas in common-defs.h it is
protected by "#ifdef HAVE_ERRNO_H".  This does not change the status
quo, since presumably every platform on which GDB builds has errno.h.

Is this ok to commit?

Thanks,
Gary

--
gdb/
2014-07-30  Gary Benson  <gbenson@redhat.com>

	* configure.ac (AC_CHECK_HEADERS): Add errno.h.
	* configure: Regenerate.
	* config.in: Likewise.
	* common/common-defs.h: Include errno.h.
	* defs.h: Do not include errno.h.
	* ada-typeprint.c: Likewise.
	* c-typeprint.c: Likewise.
	* core-regset.c: Likewise.
	* corefile.c: Likewise.
	* corelow.c: Likewise.
	* event-loop.c: Likewise.
	* f-typeprint.c: Likewise.
	* gnu-nat.c: Likewise.
	* go32-nat.c: Likewise.
	* i386gnu-nat.c: Likewise.
	* m2-typeprint.c: Likewise.
	* nat/linux-btrace.c: Likewise.
	* p-typeprint.c: Likewise.
	* procfs.c: Likewise.
	* remote-sim.c: Likewise.
	* rs6000-nat.c: Likewise.
	* target.c: Likewise.
	* typeprint.c: Likewise.
	* ui-file.c: Likewise.
	* valops.c: Likewise.
	* valprint.c: Likewise.

gdb/gdbserver/
2014-07-30  Gary Benson  <gbenson@redhat.com>

	* server.h: Do not include errno.h.
	* event-loop.c: Likewise.
	* hostio-errno.c: Likewise.
	* linux-low.c: Likewise.
	* remote-utils.c: Likewise.
	* spu-low.c: Likewise.
	* utils.c: Likewise.
---
 gdb/ChangeLog                |   29 +++++++++++++++++++++++++++++
 gdb/ada-typeprint.c          |    2 --
 gdb/c-typeprint.c            |    1 -
 gdb/common/common-defs.h     |    3 +++
 gdb/config.in                |    3 +++
 gdb/configure                |    2 +-
 gdb/configure.ac             |    2 +-
 gdb/core-regset.c            |    1 -
 gdb/corefile.c               |    1 -
 gdb/corelow.c                |    1 -
 gdb/defs.h                   |    1 -
 gdb/event-loop.c             |    1 -
 gdb/f-typeprint.c            |    1 -
 gdb/gdbserver/ChangeLog      |   10 ++++++++++
 gdb/gdbserver/event-loop.c   |    4 ----
 gdb/gdbserver/hostio-errno.c |    1 -
 gdb/gdbserver/linux-low.c    |    1 -
 gdb/gdbserver/remote-utils.c |    3 ---
 gdb/gdbserver/server.h       |    3 ---
 gdb/gdbserver/spu-low.c      |    1 -
 gdb/gdbserver/utils.c        |    3 ---
 gdb/gnu-nat.c                |    1 -
 gdb/go32-nat.c               |    1 -
 gdb/i386gnu-nat.c            |    1 -
 gdb/m2-typeprint.c           |    1 -
 gdb/nat/linux-btrace.c       |    1 -
 gdb/p-typeprint.c            |    1 -
 gdb/procfs.c                 |    1 -
 gdb/remote-sim.c             |    1 -
 gdb/rs6000-nat.c             |    1 -
 gdb/target.c                 |    1 -
 gdb/typeprint.c              |    1 -
 gdb/ui-file.c                |    2 --
 gdb/valops.c                 |    1 -
 gdb/valprint.c               |    2 --
 35 files changed, 47 insertions(+), 43 deletions(-)

diff --git a/gdb/ada-typeprint.c b/gdb/ada-typeprint.c
index a43ced7..305e39c 100644
--- a/gdb/ada-typeprint.c
+++ b/gdb/ada-typeprint.c
@@ -32,9 +32,7 @@
 #include "c-lang.h"
 #include "typeprint.h"
 #include "ada-lang.h"
-
 #include <ctype.h>
-#include <errno.h>
 
 static int print_selected_record_field_types (struct type *, struct type *,
 					      int, int,
diff --git a/gdb/c-typeprint.c b/gdb/c-typeprint.c
index 5239505..374c90e 100644
--- a/gdb/c-typeprint.c
+++ b/gdb/c-typeprint.c
@@ -31,7 +31,6 @@
 #include "typeprint.h"
 #include "cp-abi.h"
 #include "jv-lang.h"
-#include <errno.h>
 #include "cp-support.h"
 
 static void c_type_print_varspec_prefix (struct type *,
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 7c67846..964b006 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -32,6 +32,9 @@
 #include <stdarg.h>
 #include <stddef.h>
 #include <string.h>
+#ifdef HAVE_ERRNO_H
+#include <errno.h>
+#endif
 #include "ansidecl.h"
 #include "libiberty.h"
 #include "pathmax.h"
diff --git a/gdb/config.in b/gdb/config.in
index fb9b0cd..e592050 100644
--- a/gdb/config.in
+++ b/gdb/config.in
@@ -129,6 +129,9 @@
 /* Define to 1 if you have the <elf_hp.h> header file. */
 #undef HAVE_ELF_HP_H
 
+/* Define to 1 if you have the <errno.h> header file. */
+#undef HAVE_ERRNO_H
+
 /* Define to 1 if your system has the etext variable. */
 #undef HAVE_ETEXT
 
diff --git a/gdb/configure b/gdb/configure
index 809326a..11ff864 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -9417,7 +9417,7 @@ for ac_header in nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
 		  sys/reg.h sys/debugreg.h sys/select.h sys/syscall.h \
 		  termios.h termio.h \
 		  sgtty.h elf_hp.h \
-		  dlfcn.h
+		  dlfcn.h errno.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
diff --git a/gdb/configure.ac b/gdb/configure.ac
index 70d0964..d0916c3 100644
--- a/gdb/configure.ac
+++ b/gdb/configure.ac
@@ -1274,7 +1274,7 @@ AC_CHECK_HEADERS([nlist.h machine/reg.h poll.h sys/poll.h proc_service.h \
 		  sys/reg.h sys/debugreg.h sys/select.h sys/syscall.h \
 		  termios.h termio.h \
 		  sgtty.h elf_hp.h \
-		  dlfcn.h])
+		  dlfcn.h errno.h])
 AC_CHECK_HEADERS(sys/proc.h, [], [],
 [#if HAVE_SYS_PARAM_H
 # include <sys/param.h>
diff --git a/gdb/core-regset.c b/gdb/core-regset.c
index 6edc8c5..bdcb72a 100644
--- a/gdb/core-regset.c
+++ b/gdb/core-regset.c
@@ -34,7 +34,6 @@
 #include "regcache.h"
 
 #include <fcntl.h>
-#include <errno.h>
 #include <time.h>
 #ifdef HAVE_SYS_PROCFS_H
 #include <sys/procfs.h>
diff --git a/gdb/corefile.c b/gdb/corefile.c
index 1eaecb5..2b5ed13 100644
--- a/gdb/corefile.c
+++ b/gdb/corefile.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <errno.h>
 #include <signal.h>
 #include <fcntl.h>
 #include "inferior.h"
diff --git a/gdb/corelow.c b/gdb/corelow.c
index 1c9a93d..b5958d6 100644
--- a/gdb/corelow.c
+++ b/gdb/corelow.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "arch-utils.h"
-#include <errno.h>
 #include <signal.h>
 #include <fcntl.h>
 #ifdef HAVE_SYS_FILE_H
diff --git a/gdb/defs.h b/gdb/defs.h
index 710298c..b7271a7 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -28,7 +28,6 @@
 #include "common-defs.h"
 
 #include <sys/types.h>
-#include <errno.h>		/* System call error return status.  */
 #include <limits.h>
 #include <stdint.h>
 
diff --git a/gdb/event-loop.c b/gdb/event-loop.c
index cc2f837..e40187e 100644
--- a/gdb/event-loop.c
+++ b/gdb/event-loop.c
@@ -31,7 +31,6 @@
 #endif
 
 #include <sys/types.h>
-#include <errno.h>
 #include <sys/time.h>
 #include "exceptions.h"
 #include "gdb_select.h"
diff --git a/gdb/f-typeprint.c b/gdb/f-typeprint.c
index 534019a..7474051 100644
--- a/gdb/f-typeprint.c
+++ b/gdb/f-typeprint.c
@@ -30,7 +30,6 @@
 #include "gdbcore.h"
 #include "target.h"
 #include "f-lang.h"
-#include <errno.h>
 
 #if 0				/* Currently unused.  */
 static void f_type_print_args (struct type *, struct ui_file *);
diff --git a/gdb/gdbserver/event-loop.c b/gdb/gdbserver/event-loop.c
index 1513b59..92c8db0 100644
--- a/gdb/gdbserver/event-loop.c
+++ b/gdb/gdbserver/event-loop.c
@@ -29,10 +29,6 @@
 #include <io.h>
 #endif
 
-#ifdef HAVE_ERRNO_H
-#include <errno.h>
-#endif
-
 #include <unistd.h>
 
 typedef struct gdb_event gdb_event;
diff --git a/gdb/gdbserver/hostio-errno.c b/gdb/gdbserver/hostio-errno.c
index 8817096..f24b51f 100644
--- a/gdb/gdbserver/hostio-errno.c
+++ b/gdb/gdbserver/hostio-errno.c
@@ -22,7 +22,6 @@
    on top of errno.  */
 
 #include "server.h"
-#include <errno.h>
 #include "gdb/fileio.h"
 
 static int
diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c
index 74289c0..f71a4de 100644
--- a/gdb/gdbserver/linux-low.c
+++ b/gdb/gdbserver/linux-low.c
@@ -31,7 +31,6 @@
 #include <sys/ioctl.h>
 #include <fcntl.h>
 #include <unistd.h>
-#include <errno.h>
 #include <sys/syscall.h>
 #include <sched.h>
 #include <ctype.h>
diff --git a/gdb/gdbserver/remote-utils.c b/gdb/gdbserver/remote-utils.c
index f3ae393..327677a 100644
--- a/gdb/gdbserver/remote-utils.c
+++ b/gdb/gdbserver/remote-utils.c
@@ -56,9 +56,6 @@
 #include <arpa/inet.h>
 #endif
 #include <sys/stat.h>
-#if HAVE_ERRNO_H
-#include <errno.h>
-#endif
 
 #if USE_WIN32API
 #include <winsock2.h>
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 1e2c3a1..db6ddde 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -27,9 +27,6 @@
 
 #include "version.h"
 
-#ifdef HAVE_ERRNO_H
-#include <errno.h>
-#endif
 #include <setjmp.h>
 
 #ifdef HAVE_ALLOCA_H
diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c
index cb1ac0d..867f97b 100644
--- a/gdb/gdbserver/spu-low.c
+++ b/gdb/gdbserver/spu-low.c
@@ -24,7 +24,6 @@
 #include <sys/ptrace.h>
 #include <fcntl.h>
 #include <unistd.h>
-#include <errno.h>
 #include <sys/syscall.h>
 #include "filestuff.h"
 #include "hostio.h"
diff --git a/gdb/gdbserver/utils.c b/gdb/gdbserver/utils.c
index ec37a9b..b011637 100644
--- a/gdb/gdbserver/utils.c
+++ b/gdb/gdbserver/utils.c
@@ -17,9 +17,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "server.h"
-#if HAVE_ERRNO_H
-#include <errno.h>
-#endif
 
 #ifdef IN_PROCESS_AGENT
 #  define PREFIX "ipa: "
diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c
index d6658c7..c8164d6 100644
--- a/gdb/gnu-nat.c
+++ b/gdb/gnu-nat.c
@@ -23,7 +23,6 @@
 #include "defs.h"
 
 #include <ctype.h>
-#include <errno.h>
 #include <limits.h>
 #include <setjmp.h>
 #include <signal.h>
diff --git a/gdb/go32-nat.c b/gdb/go32-nat.c
index 75596a2..727f810 100644
--- a/gdb/go32-nat.c
+++ b/gdb/go32-nat.c
@@ -105,7 +105,6 @@
 #include "inf-child.h"
 
 #include <ctype.h>
-#include <errno.h>
 #include <unistd.h>
 #include <sys/utsname.h>
 #include <io.h>
diff --git a/gdb/i386gnu-nat.c b/gdb/i386gnu-nat.c
index 94d2a0a..8fad871 100644
--- a/gdb/i386gnu-nat.c
+++ b/gdb/i386gnu-nat.c
@@ -22,7 +22,6 @@
 #include "floatformat.h"
 #include "regcache.h"
 
-#include <errno.h>
 #include <mach.h>
 #include <mach_error.h>
 #include <mach/message.h>
diff --git a/gdb/m2-typeprint.c b/gdb/m2-typeprint.c
index 45bc093..72c107b 100644
--- a/gdb/m2-typeprint.c
+++ b/gdb/m2-typeprint.c
@@ -31,7 +31,6 @@
 #include "c-lang.h"
 #include "typeprint.h"
 #include "cp-abi.h"
-#include <errno.h>
 
 static void m2_print_bounds (struct type *type,
 			     struct ui_file *stream, int show, int level,
diff --git a/gdb/nat/linux-btrace.c b/gdb/nat/linux-btrace.c
index 19e218e..f6fdbda 100644
--- a/gdb/nat/linux-btrace.c
+++ b/gdb/nat/linux-btrace.c
@@ -37,7 +37,6 @@
 
 #if HAVE_LINUX_PERF_EVENT_H && defined(SYS_perf_event_open)
 
-#include <errno.h>
 #include <stdint.h>
 #include <unistd.h>
 #include <sys/mman.h>
diff --git a/gdb/p-typeprint.c b/gdb/p-typeprint.c
index 6870cdf..b1e16f0 100644
--- a/gdb/p-typeprint.c
+++ b/gdb/p-typeprint.c
@@ -31,7 +31,6 @@
 #include "p-lang.h"
 #include "typeprint.h"
 #include "gdb-demangle.h"
-#include <errno.h>
 #include <ctype.h>
 
 static void pascal_type_print_varspec_suffix (struct type *, struct ui_file *,
diff --git a/gdb/procfs.c b/gdb/procfs.c
index d93843a..3465bc5 100644
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -42,7 +42,6 @@
 #ifdef HAVE_SYS_SYSCALL_H
 #include <sys/syscall.h>
 #endif
-#include <sys/errno.h>
 #include "gdb_wait.h"
 #include <signal.h>
 #include <ctype.h>
diff --git a/gdb/remote-sim.c b/gdb/remote-sim.c
index e26a971..b8974e1 100644
--- a/gdb/remote-sim.c
+++ b/gdb/remote-sim.c
@@ -28,7 +28,6 @@
 #include <fcntl.h>
 #include <signal.h>
 #include <setjmp.h>
-#include <errno.h>
 #include "terminal.h"
 #include "target.h"
 #include "gdbcore.h"
diff --git a/gdb/rs6000-nat.c b/gdb/rs6000-nat.c
index 4ba955c..1b09680 100644
--- a/gdb/rs6000-nat.c
+++ b/gdb/rs6000-nat.c
@@ -46,7 +46,6 @@
 #include <signal.h>
 #include <sys/ioctl.h>
 #include <fcntl.h>
-#include <errno.h>
 
 #include <a.out.h>
 #include <sys/file.h>
diff --git a/gdb/target.c b/gdb/target.c
index ec1db3e..b784b05 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <errno.h>
 #include "target.h"
 #include "target-dcache.h"
 #include "gdbcmd.h"
diff --git a/gdb/typeprint.c b/gdb/typeprint.c
index e0b7c44..3d8620a 100644
--- a/gdb/typeprint.c
+++ b/gdb/typeprint.c
@@ -33,7 +33,6 @@
 #include "typeprint.h"
 #include "exceptions.h"
 #include "valprint.h"
-#include <errno.h>
 #include <ctype.h>
 #include "cli/cli-utils.h"
 #include "extension.h"
diff --git a/gdb/ui-file.c b/gdb/ui-file.c
index 767b55b..49607dc 100644
--- a/gdb/ui-file.c
+++ b/gdb/ui-file.c
@@ -25,8 +25,6 @@
 #include "gdb_select.h"
 #include "filestuff.h"
 
-#include <errno.h>
-
 static ui_file_isatty_ftype null_file_isatty;
 static ui_file_write_ftype null_file_write;
 static ui_file_write_ftype null_file_write_async_safe;
diff --git a/gdb/valops.c b/gdb/valops.c
index 5ef763d..d9ce2f2 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -36,7 +36,6 @@
 #include "cp-support.h"
 #include "dfp.h"
 #include "tracepoint.h"
-#include <errno.h>
 #include "observer.h"
 #include "objfiles.h"
 #include "exceptions.h"
diff --git a/gdb/valprint.c b/gdb/valprint.c
index 0ded6b7..d3ab267 100644
--- a/gdb/valprint.c
+++ b/gdb/valprint.c
@@ -37,8 +37,6 @@
 #include "charset.h"
 #include <ctype.h>
 
-#include <errno.h>
-
 /* Maximum number of wchars returned from wchar_iterate.  */
 #define MAX_WCHARS 4
 
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* Re: [PATCH 14/13] Move errno.h to common-defs.h
  2014-07-30 13:35 ` [PATCH 14/13] Move errno.h " Gary Benson
@ 2014-07-31  8:55   ` Tom Tromey
  2014-07-31  9:57     ` [PATCH 14/13 v2] " Gary Benson
  2014-07-31 10:00     ` [PATCH 14/13] " Pedro Alves
  0 siblings, 2 replies; 26+ messages in thread
From: Tom Tromey @ 2014-07-31  8:55 UTC (permalink / raw)
  To: Gary Benson; +Cc: gdb-patches

>>>>> "Gary" == Gary Benson <gbenson@redhat.com> writes:

Gary> This commit moves the inclusion of errno.h to common-defs.h and
Gary> removes all other inclusions.  Note that prior to this commit errno.h
Gary> was included unconditionally in defs.h, whereas in common-defs.h it is
Gary> protected by "#ifdef HAVE_ERRNO_H".  This does not change the status
Gary> quo, since presumably every platform on which GDB builds has errno.h.

Gary> Is this ok to commit?

Gary> 	* configure.ac (AC_CHECK_HEADERS): Add errno.h.

If a header in common/, nat/, or target/ requires an autoconf define,
then the check should be added to common/common.m4 and then the various
configure scripts rebuilt.

This way we ensure that gdb and gdbserver keep in sync.  There were
problems with this in the past.

I think it's fine to unconditionally include errno.h.  For one thing
some files in gdb did this.  Also I believe it is pulled into gnulib as
a dependency of some other module; though you'd probably want to check
this.

If you go this route then I guess it would be nice to remove errno.h
checks instead.

Tom


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 14/13 v2] Move errno.h to common-defs.h
  2014-07-31  8:55   ` Tom Tromey
@ 2014-07-31  9:57     ` Gary Benson
  2014-07-31 10:19       ` Pedro Alves
  2014-07-31 10:00     ` [PATCH 14/13] " Pedro Alves
  1 sibling, 1 reply; 26+ messages in thread
From: Gary Benson @ 2014-07-31  9:57 UTC (permalink / raw)
  To: gdb-patches; +Cc: Tom Tromey

Tom Tromey wrote:
> >>>>> "Gary" == Gary Benson <gbenson@redhat.com> writes:
> 
> Gary> This commit moves the inclusion of errno.h to common-defs.h
> Gary> and removes all other inclusions.  Note that prior to this
> Gary> commit errno.h was included unconditionally in defs.h, whereas
> Gary> in common-defs.h it is protected by "#ifdef HAVE_ERRNO_H".
> Gary> This does not change the status quo, since presumably every
> Gary> platform on which GDB builds has errno.h.
> 
> Gary> Is this ok to commit?
> 
> Gary> 	* configure.ac (AC_CHECK_HEADERS): Add errno.h.
> 
> If a header in common/, nat/, or target/ requires an autoconf
> define, then the check should be added to common/common.m4 and
> then the various configure scripts rebuilt.
> 
> This way we ensure that gdb and gdbserver keep in sync.  There
> were problems with this in the past.
> 
> I think it's fine to unconditionally include errno.h.  For one thing
> some files in gdb did this.  Also I believe it is pulled into gnulib
> as a dependency of some other module; though you'd probably want to
> check this.
> 
> If you go this route then I guess it would be nice to remove errno.h
> checks instead.

I'll move the check.  There are some Windows CE workarounds for errno
in gdbserver that I don't really want to touch, so keeping the checks
keeps the effect of this change as minimal as possible.

Updated patch inlined below.

Thanks,
Gary

--
gdb/
2014-07-31  Gary Benson  <gbenson@redhat.com>

	* common/common.m4 (AC_CHECK_HEADERS): Add errno.h.
	* configure: Regenerate.
	* config.in: Likewise.
	* common/common-defs.h: Include errno.h.
	* defs.h: Do not include errno.h.
	* ada-typeprint.c: Likewise.
	* c-typeprint.c: Likewise.
	* core-regset.c: Likewise.
	* corefile.c: Likewise.
	* corelow.c: Likewise.
	* event-loop.c: Likewise.
	* f-typeprint.c: Likewise.
	* gnu-nat.c: Likewise.
	* go32-nat.c: Likewise.
	* i386gnu-nat.c: Likewise.
	* m2-typeprint.c: Likewise.
	* nat/linux-btrace.c: Likewise.
	* p-typeprint.c: Likewise.
	* procfs.c: Likewise.
	* remote-sim.c: Likewise.
	* rs6000-nat.c: Likewise.
	* target.c: Likewise.
	* typeprint.c: Likewise.
	* ui-file.c: Likewise.
	* valops.c: Likewise.
	* valprint.c: Likewise.

gdb/gdbserver/
2014-07-31  Gary Benson  <gbenson@redhat.com>

	* configure.ac (AC_CHECK_HEADERS): Remove errno.h.
	* configure: Regenerate.
	* server.h: Do not include errno.h.
	* event-loop.c: Likewise.
	* hostio-errno.c: Likewise.
	* linux-low.c: Likewise.
	* remote-utils.c: Likewise.
	* spu-low.c: Likewise.
	* utils.c: Likewise.
---
 gdb/ChangeLog                |   29 +++++++++++++++++++++++++++++
 gdb/ada-typeprint.c          |    2 --
 gdb/c-typeprint.c            |    1 -
 gdb/common/common-defs.h     |    3 +++
 gdb/common/common.m4         |    2 +-
 gdb/config.in                |    3 +++
 gdb/configure                |    2 +-
 gdb/core-regset.c            |    1 -
 gdb/corefile.c               |    1 -
 gdb/corelow.c                |    1 -
 gdb/defs.h                   |    1 -
 gdb/event-loop.c             |    1 -
 gdb/f-typeprint.c            |    1 -
 gdb/gdbserver/ChangeLog      |   12 ++++++++++++
 gdb/gdbserver/configure      |    4 ++--
 gdb/gdbserver/configure.ac   |    2 +-
 gdb/gdbserver/event-loop.c   |    4 ----
 gdb/gdbserver/hostio-errno.c |    1 -
 gdb/gdbserver/linux-low.c    |    1 -
 gdb/gdbserver/remote-utils.c |    3 ---
 gdb/gdbserver/server.h       |    3 ---
 gdb/gdbserver/spu-low.c      |    1 -
 gdb/gdbserver/utils.c        |    3 ---
 gdb/gnu-nat.c                |    1 -
 gdb/go32-nat.c               |    1 -
 gdb/i386gnu-nat.c            |    1 -
 gdb/m2-typeprint.c           |    1 -
 gdb/nat/linux-btrace.c       |    1 -
 gdb/p-typeprint.c            |    1 -
 gdb/procfs.c                 |    1 -
 gdb/remote-sim.c             |    1 -
 gdb/rs6000-nat.c             |    1 -
 gdb/target.c                 |    1 -
 gdb/typeprint.c              |    1 -
 gdb/ui-file.c                |    2 --
 gdb/valops.c                 |    1 -
 gdb/valprint.c               |    2 --
 37 files changed, 52 insertions(+), 46 deletions(-)

diff --git a/gdb/ada-typeprint.c b/gdb/ada-typeprint.c
index a43ced7..305e39c 100644
--- a/gdb/ada-typeprint.c
+++ b/gdb/ada-typeprint.c
@@ -32,9 +32,7 @@
 #include "c-lang.h"
 #include "typeprint.h"
 #include "ada-lang.h"
-
 #include <ctype.h>
-#include <errno.h>
 
 static int print_selected_record_field_types (struct type *, struct type *,
 					      int, int,
diff --git a/gdb/c-typeprint.c b/gdb/c-typeprint.c
index 5239505..374c90e 100644
--- a/gdb/c-typeprint.c
+++ b/gdb/c-typeprint.c
@@ -31,7 +31,6 @@
 #include "typeprint.h"
 #include "cp-abi.h"
 #include "jv-lang.h"
-#include <errno.h>
 #include "cp-support.h"
 
 static void c_type_print_varspec_prefix (struct type *,
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 7c67846..964b006 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -32,6 +32,9 @@
 #include <stdarg.h>
 #include <stddef.h>
 #include <string.h>
+#ifdef HAVE_ERRNO_H
+#include <errno.h>
+#endif
 #include "ansidecl.h"
 #include "libiberty.h"
 #include "pathmax.h"
diff --git a/gdb/common/common.m4 b/gdb/common/common.m4
index 426df79..d6406ec 100644
--- a/gdb/common/common.m4
+++ b/gdb/common/common.m4
@@ -28,7 +28,7 @@ AC_DEFUN([GDB_AC_COMMON], [
   AC_CHECK_HEADERS(linux/perf_event.h locale.h memory.h signal.h dnl
 		   sys/resource.h sys/socket.h sys/syscall.h dnl
 		   sys/un.h sys/wait.h dnl
-		   thread_db.h wait.h)
+		   thread_db.h wait.h errno.h)
 
   AC_CHECK_FUNCS([fdwalk getrlimit pipe pipe2 socketpair])
 
diff --git a/gdb/config.in b/gdb/config.in
index fb9b0cd..e592050 100644
--- a/gdb/config.in
+++ b/gdb/config.in
@@ -129,6 +129,9 @@
 /* Define to 1 if you have the <elf_hp.h> header file. */
 #undef HAVE_ELF_HP_H
 
+/* Define to 1 if you have the <errno.h> header file. */
+#undef HAVE_ERRNO_H
+
 /* Define to 1 if your system has the etext variable. */
 #undef HAVE_ETEXT
 
diff --git a/gdb/configure b/gdb/configure
index 809326a..caf970f 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -11003,7 +11003,7 @@ $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
   fi
 
 
-  for ac_header in linux/perf_event.h locale.h memory.h signal.h 		   sys/resource.h sys/socket.h sys/syscall.h 		   sys/un.h sys/wait.h 		   thread_db.h wait.h
+  for ac_header in linux/perf_event.h locale.h memory.h signal.h 		   sys/resource.h sys/socket.h sys/syscall.h 		   sys/un.h sys/wait.h 		   thread_db.h wait.h errno.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
diff --git a/gdb/core-regset.c b/gdb/core-regset.c
index 6edc8c5..bdcb72a 100644
--- a/gdb/core-regset.c
+++ b/gdb/core-regset.c
@@ -34,7 +34,6 @@
 #include "regcache.h"
 
 #include <fcntl.h>
-#include <errno.h>
 #include <time.h>
 #ifdef HAVE_SYS_PROCFS_H
 #include <sys/procfs.h>
diff --git a/gdb/corefile.c b/gdb/corefile.c
index 1eaecb5..2b5ed13 100644
--- a/gdb/corefile.c
+++ b/gdb/corefile.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <errno.h>
 #include <signal.h>
 #include <fcntl.h>
 #include "inferior.h"
diff --git a/gdb/corelow.c b/gdb/corelow.c
index 1c9a93d..b5958d6 100644
--- a/gdb/corelow.c
+++ b/gdb/corelow.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "arch-utils.h"
-#include <errno.h>
 #include <signal.h>
 #include <fcntl.h>
 #ifdef HAVE_SYS_FILE_H
diff --git a/gdb/defs.h b/gdb/defs.h
index 710298c..b7271a7 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -28,7 +28,6 @@
 #include "common-defs.h"
 
 #include <sys/types.h>
-#include <errno.h>		/* System call error return status.  */
 #include <limits.h>
 #include <stdint.h>
 
diff --git a/gdb/event-loop.c b/gdb/event-loop.c
index cc2f837..e40187e 100644
--- a/gdb/event-loop.c
+++ b/gdb/event-loop.c
@@ -31,7 +31,6 @@
 #endif
 
 #include <sys/types.h>
-#include <errno.h>
 #include <sys/time.h>
 #include "exceptions.h"
 #include "gdb_select.h"
diff --git a/gdb/f-typeprint.c b/gdb/f-typeprint.c
index 534019a..7474051 100644
--- a/gdb/f-typeprint.c
+++ b/gdb/f-typeprint.c
@@ -30,7 +30,6 @@
 #include "gdbcore.h"
 #include "target.h"
 #include "f-lang.h"
-#include <errno.h>
 
 #if 0				/* Currently unused.  */
 static void f_type_print_args (struct type *, struct ui_file *);
diff --git a/gdb/gdbserver/configure b/gdb/gdbserver/configure
index 5f8dcd2..b341a89 100755
--- a/gdb/gdbserver/configure
+++ b/gdb/gdbserver/configure
@@ -4904,7 +4904,7 @@ $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cach
   cd "$ac_popdir"
 
 
-for ac_header in sgtty.h termio.h termios.h sys/reg.h string.h 		 proc_service.h sys/procfs.h linux/elf.h 		 errno.h fcntl.h signal.h sys/file.h malloc.h 		 sys/ioctl.h netinet/in.h sys/socket.h netdb.h 		 netinet/tcp.h arpa/inet.h
+for ac_header in sgtty.h termio.h termios.h sys/reg.h string.h 		 proc_service.h sys/procfs.h linux/elf.h 		 fcntl.h signal.h sys/file.h malloc.h 		 sys/ioctl.h netinet/in.h sys/socket.h netdb.h 		 netinet/tcp.h arpa/inet.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
@@ -5271,7 +5271,7 @@ $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
   fi
 
 
-  for ac_header in linux/perf_event.h locale.h memory.h signal.h 		   sys/resource.h sys/socket.h sys/syscall.h 		   sys/un.h sys/wait.h 		   thread_db.h wait.h
+  for ac_header in linux/perf_event.h locale.h memory.h signal.h 		   sys/resource.h sys/socket.h sys/syscall.h 		   sys/un.h sys/wait.h 		   thread_db.h wait.h errno.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
diff --git a/gdb/gdbserver/configure.ac b/gdb/gdbserver/configure.ac
index 67866f8..8e5d74f 100644
--- a/gdb/gdbserver/configure.ac
+++ b/gdb/gdbserver/configure.ac
@@ -82,7 +82,7 @@ ACX_CONFIGURE_DIR(["../../libiberty"], ["build-libiberty-gdbserver"])
 
 AC_CHECK_HEADERS(sgtty.h termio.h termios.h sys/reg.h string.h dnl
 		 proc_service.h sys/procfs.h linux/elf.h dnl
-		 errno.h fcntl.h signal.h sys/file.h malloc.h dnl
+		 fcntl.h signal.h sys/file.h malloc.h dnl
 		 sys/ioctl.h netinet/in.h sys/socket.h netdb.h dnl
 		 netinet/tcp.h arpa/inet.h)
 AC_CHECK_FUNCS(pread pwrite pread64 readlink)
diff --git a/gdb/gdbserver/event-loop.c b/gdb/gdbserver/event-loop.c
index 1513b59..92c8db0 100644
--- a/gdb/gdbserver/event-loop.c
+++ b/gdb/gdbserver/event-loop.c
@@ -29,10 +29,6 @@
 #include <io.h>
 #endif
 
-#ifdef HAVE_ERRNO_H
-#include <errno.h>
-#endif
-
 #include <unistd.h>
 
 typedef struct gdb_event gdb_event;
diff --git a/gdb/gdbserver/hostio-errno.c b/gdb/gdbserver/hostio-errno.c
index 8817096..f24b51f 100644
--- a/gdb/gdbserver/hostio-errno.c
+++ b/gdb/gdbserver/hostio-errno.c
@@ -22,7 +22,6 @@
    on top of errno.  */
 
 #include "server.h"
-#include <errno.h>
 #include "gdb/fileio.h"
 
 static int
diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c
index 74289c0..f71a4de 100644
--- a/gdb/gdbserver/linux-low.c
+++ b/gdb/gdbserver/linux-low.c
@@ -31,7 +31,6 @@
 #include <sys/ioctl.h>
 #include <fcntl.h>
 #include <unistd.h>
-#include <errno.h>
 #include <sys/syscall.h>
 #include <sched.h>
 #include <ctype.h>
diff --git a/gdb/gdbserver/remote-utils.c b/gdb/gdbserver/remote-utils.c
index f3ae393..327677a 100644
--- a/gdb/gdbserver/remote-utils.c
+++ b/gdb/gdbserver/remote-utils.c
@@ -56,9 +56,6 @@
 #include <arpa/inet.h>
 #endif
 #include <sys/stat.h>
-#if HAVE_ERRNO_H
-#include <errno.h>
-#endif
 
 #if USE_WIN32API
 #include <winsock2.h>
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 1e2c3a1..db6ddde 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -27,9 +27,6 @@
 
 #include "version.h"
 
-#ifdef HAVE_ERRNO_H
-#include <errno.h>
-#endif
 #include <setjmp.h>
 
 #ifdef HAVE_ALLOCA_H
diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c
index cb1ac0d..867f97b 100644
--- a/gdb/gdbserver/spu-low.c
+++ b/gdb/gdbserver/spu-low.c
@@ -24,7 +24,6 @@
 #include <sys/ptrace.h>
 #include <fcntl.h>
 #include <unistd.h>
-#include <errno.h>
 #include <sys/syscall.h>
 #include "filestuff.h"
 #include "hostio.h"
diff --git a/gdb/gdbserver/utils.c b/gdb/gdbserver/utils.c
index ec37a9b..b011637 100644
--- a/gdb/gdbserver/utils.c
+++ b/gdb/gdbserver/utils.c
@@ -17,9 +17,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "server.h"
-#if HAVE_ERRNO_H
-#include <errno.h>
-#endif
 
 #ifdef IN_PROCESS_AGENT
 #  define PREFIX "ipa: "
diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c
index d6658c7..c8164d6 100644
--- a/gdb/gnu-nat.c
+++ b/gdb/gnu-nat.c
@@ -23,7 +23,6 @@
 #include "defs.h"
 
 #include <ctype.h>
-#include <errno.h>
 #include <limits.h>
 #include <setjmp.h>
 #include <signal.h>
diff --git a/gdb/go32-nat.c b/gdb/go32-nat.c
index 75596a2..727f810 100644
--- a/gdb/go32-nat.c
+++ b/gdb/go32-nat.c
@@ -105,7 +105,6 @@
 #include "inf-child.h"
 
 #include <ctype.h>
-#include <errno.h>
 #include <unistd.h>
 #include <sys/utsname.h>
 #include <io.h>
diff --git a/gdb/i386gnu-nat.c b/gdb/i386gnu-nat.c
index 94d2a0a..8fad871 100644
--- a/gdb/i386gnu-nat.c
+++ b/gdb/i386gnu-nat.c
@@ -22,7 +22,6 @@
 #include "floatformat.h"
 #include "regcache.h"
 
-#include <errno.h>
 #include <mach.h>
 #include <mach_error.h>
 #include <mach/message.h>
diff --git a/gdb/m2-typeprint.c b/gdb/m2-typeprint.c
index 45bc093..72c107b 100644
--- a/gdb/m2-typeprint.c
+++ b/gdb/m2-typeprint.c
@@ -31,7 +31,6 @@
 #include "c-lang.h"
 #include "typeprint.h"
 #include "cp-abi.h"
-#include <errno.h>
 
 static void m2_print_bounds (struct type *type,
 			     struct ui_file *stream, int show, int level,
diff --git a/gdb/nat/linux-btrace.c b/gdb/nat/linux-btrace.c
index 19e218e..f6fdbda 100644
--- a/gdb/nat/linux-btrace.c
+++ b/gdb/nat/linux-btrace.c
@@ -37,7 +37,6 @@
 
 #if HAVE_LINUX_PERF_EVENT_H && defined(SYS_perf_event_open)
 
-#include <errno.h>
 #include <stdint.h>
 #include <unistd.h>
 #include <sys/mman.h>
diff --git a/gdb/p-typeprint.c b/gdb/p-typeprint.c
index 6870cdf..b1e16f0 100644
--- a/gdb/p-typeprint.c
+++ b/gdb/p-typeprint.c
@@ -31,7 +31,6 @@
 #include "p-lang.h"
 #include "typeprint.h"
 #include "gdb-demangle.h"
-#include <errno.h>
 #include <ctype.h>
 
 static void pascal_type_print_varspec_suffix (struct type *, struct ui_file *,
diff --git a/gdb/procfs.c b/gdb/procfs.c
index d93843a..3465bc5 100644
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -42,7 +42,6 @@
 #ifdef HAVE_SYS_SYSCALL_H
 #include <sys/syscall.h>
 #endif
-#include <sys/errno.h>
 #include "gdb_wait.h"
 #include <signal.h>
 #include <ctype.h>
diff --git a/gdb/remote-sim.c b/gdb/remote-sim.c
index e26a971..b8974e1 100644
--- a/gdb/remote-sim.c
+++ b/gdb/remote-sim.c
@@ -28,7 +28,6 @@
 #include <fcntl.h>
 #include <signal.h>
 #include <setjmp.h>
-#include <errno.h>
 #include "terminal.h"
 #include "target.h"
 #include "gdbcore.h"
diff --git a/gdb/rs6000-nat.c b/gdb/rs6000-nat.c
index 4ba955c..1b09680 100644
--- a/gdb/rs6000-nat.c
+++ b/gdb/rs6000-nat.c
@@ -46,7 +46,6 @@
 #include <signal.h>
 #include <sys/ioctl.h>
 #include <fcntl.h>
-#include <errno.h>
 
 #include <a.out.h>
 #include <sys/file.h>
diff --git a/gdb/target.c b/gdb/target.c
index ec1db3e..b784b05 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <errno.h>
 #include "target.h"
 #include "target-dcache.h"
 #include "gdbcmd.h"
diff --git a/gdb/typeprint.c b/gdb/typeprint.c
index e0b7c44..3d8620a 100644
--- a/gdb/typeprint.c
+++ b/gdb/typeprint.c
@@ -33,7 +33,6 @@
 #include "typeprint.h"
 #include "exceptions.h"
 #include "valprint.h"
-#include <errno.h>
 #include <ctype.h>
 #include "cli/cli-utils.h"
 #include "extension.h"
diff --git a/gdb/ui-file.c b/gdb/ui-file.c
index 767b55b..49607dc 100644
--- a/gdb/ui-file.c
+++ b/gdb/ui-file.c
@@ -25,8 +25,6 @@
 #include "gdb_select.h"
 #include "filestuff.h"
 
-#include <errno.h>
-
 static ui_file_isatty_ftype null_file_isatty;
 static ui_file_write_ftype null_file_write;
 static ui_file_write_ftype null_file_write_async_safe;
diff --git a/gdb/valops.c b/gdb/valops.c
index 5ef763d..d9ce2f2 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -36,7 +36,6 @@
 #include "cp-support.h"
 #include "dfp.h"
 #include "tracepoint.h"
-#include <errno.h>
 #include "observer.h"
 #include "objfiles.h"
 #include "exceptions.h"
diff --git a/gdb/valprint.c b/gdb/valprint.c
index 0ded6b7..d3ab267 100644
--- a/gdb/valprint.c
+++ b/gdb/valprint.c
@@ -37,8 +37,6 @@
 #include "charset.h"
 #include <ctype.h>
 
-#include <errno.h>
-
 /* Maximum number of wchars returned from wchar_iterate.  */
 #define MAX_WCHARS 4
 
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* Re: [PATCH 14/13] Move errno.h to common-defs.h
  2014-07-31  8:55   ` Tom Tromey
  2014-07-31  9:57     ` [PATCH 14/13 v2] " Gary Benson
@ 2014-07-31 10:00     ` Pedro Alves
  2014-07-31 14:49       ` [PATCH 14/13 v3] " Gary Benson
  1 sibling, 1 reply; 26+ messages in thread
From: Pedro Alves @ 2014-07-31 10:00 UTC (permalink / raw)
  To: Tom Tromey, Gary Benson; +Cc: gdb-patches

On 07/31/2014 02:46 AM, Tom Tromey wrote:
>>>>>> "Gary" == Gary Benson <gbenson@redhat.com> writes:
> 
> Gary> This commit moves the inclusion of errno.h to common-defs.h and
> Gary> removes all other inclusions.  Note that prior to this commit errno.h
> Gary> was included unconditionally in defs.h, whereas in common-defs.h it is
> Gary> protected by "#ifdef HAVE_ERRNO_H".  This does not change the status
> Gary> quo, since presumably every platform on which GDB builds has errno.h.
> 
> Gary> Is this ok to commit?
> 
> Gary> 	* configure.ac (AC_CHECK_HEADERS): Add errno.h.
> 
> If a header in common/, nat/, or target/ requires an autoconf define,
> then the check should be added to common/common.m4 and then the various
> configure scripts rebuilt.
> 
> This way we ensure that gdb and gdbserver keep in sync.  There were
> problems with this in the past.
> 
> I think it's fine to unconditionally include errno.h.  For one thing
> some files in gdb did this.

That's actually not a good justification.  We should always check the
history of why the check is on the gdb or gdbserver side.  That's
because the set of hosts/ports supported by either side is not a strict
superset of the other side.

The checks for HAVE_ERRNO_H on the gdbserver side were added for the
Windows CE port (as git blame/log will show -- 68070c10).  There's no native
gdb Windows CE, so it didn't need that.  That said, the CE port is broken
for other (similar) reasons.  E.g., the CE port predated use of both libiberty
and gnulib in gdbserver, and libiberty unconditionally includes errno.h as
well, for example.  I don't think we should completely nuke the port because
most of the arch abstractions in the Windows target side are needed for
Windows (NT) on ARM anyway, but it's super fine with me to not have it prevent
modernization of the core code base.  (If someone were to fix the port, she
just somehow come up with an errno.h replacement and make it available to
all of the build, including libiberty, which doesn't use gnulib.)

> Also I believe it is pulled into gnulib as
> a dependency of some other module; though you'd probably want to check
> this.

Yeah, I think so.

> 
> If you go this route then I guess it would be nice to remove errno.h
> checks instead.

Let's do that.

-- 
Thanks,
Pedro Alves


^ permalink raw reply	[flat|nested] 26+ messages in thread

* Re: [PATCH 14/13 v2] Move errno.h to common-defs.h
  2014-07-31  9:57     ` [PATCH 14/13 v2] " Gary Benson
@ 2014-07-31 10:19       ` Pedro Alves
  2014-07-31 15:10         ` Tom Tromey
  0 siblings, 1 reply; 26+ messages in thread
From: Pedro Alves @ 2014-07-31 10:19 UTC (permalink / raw)
  To: Gary Benson, gdb-patches; +Cc: Tom Tromey

On 07/31/2014 09:55 AM, Gary Benson wrote:

> I'll move the check.  There are some Windows CE workarounds for errno
> in gdbserver that I don't really want to touch, so keeping the checks
> keeps the effect of this change as minimal as possible.

(following up on my other email:)

This path is fine with me as well.  Whatever's easier, really.

Thanks,
Pedro Alves


^ permalink raw reply	[flat|nested] 26+ messages in thread

* [PATCH 14/13 v3] Move errno.h to common-defs.h
  2014-07-31 10:00     ` [PATCH 14/13] " Pedro Alves
@ 2014-07-31 14:49       ` Gary Benson
  0 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-07-31 14:49 UTC (permalink / raw)
  To: gdb-patches; +Cc: Tom Tromey, Pedro Alves

Pedro Alves wrote:
> On 07/31/2014 02:46 AM, Tom Tromey wrote:
> > I think it's fine to unconditionally include errno.h.  For one
> > thing some files in gdb did this.
> 
> That's actually not a good justification.  We should always check
> the history of why the check is on the gdb or gdbserver side.
> That's because the set of hosts/ports supported by either side is
> not a strict superset of the other side.
> 
> The checks for HAVE_ERRNO_H on the gdbserver side were added for the
> Windows CE port (as git blame/log will show -- 68070c10).  There's
> no native gdb Windows CE, so it didn't need that.  That said, the CE
> port is broken for other (similar) reasons.  E.g., the CE port
> predated use of both libiberty and gnulib in gdbserver, and
> libiberty unconditionally includes errno.h as well, for example.  I
> don't think we should completely nuke the port because most of the
> arch abstractions in the Windows target side are needed for Windows
> (NT) on ARM anyway, but it's super fine with me to not have it
> prevent modernization of the core code base.  (If someone were to
> fix the port, she just somehow come up with an errno.h replacement
> and make it available to all of the build, including libiberty,
> which doesn't use gnulib.)
>
[snip]
> > If you go this route then I guess it would be nice to remove
> > errno.h checks instead.
> 
> Let's do that.

Ok :)  I had not realized the CE port was broken.  Updated patch
inlined below.

Thanks,
Gary

--
This commit moves the inclusion of errno.h to common-defs.h and
removes all other inclusions.  Note that prior to this commit
server.h included errno.h protected by "#ifdef HAVE_ERRNO_H".
This protection was added with the Windows CE port, which is
currently broken.  Since no other platform needs this, I have
removed the protection and the configury to support it.

gdb/
2014-07-31  Gary Benson  <gbenson@redhat.com>

	* common/common-defs.h: Include errno.h.
	* defs.h: Do not include errno.h.
	* ada-typeprint.c: Likewise.
	* c-typeprint.c: Likewise.
	* core-regset.c: Likewise.
	* corefile.c: Likewise.
	* corelow.c: Likewise.
	* event-loop.c: Likewise.
	* f-typeprint.c: Likewise.
	* gnu-nat.c: Likewise.
	* go32-nat.c: Likewise.
	* i386gnu-nat.c: Likewise.
	* m2-typeprint.c: Likewise.
	* nat/linux-btrace.c: Likewise.
	* p-typeprint.c: Likewise.
	* procfs.c: Likewise.
	* remote-sim.c: Likewise.
	* rs6000-nat.c: Likewise.
	* target.c: Likewise.
	* typeprint.c: Likewise.
	* ui-file.c: Likewise.
	* valops.c: Likewise.
	* valprint.c: Likewise.

gdb/gdbserver/
2014-07-31  Gary Benson  <gbenson@redhat.com>

	* configure.ac (AC_CHECK_HEADERS): Remove errno.h.
	* configure: Regenerate.
	* config.in: Likewise.
	* server.h: Do not include errno.h.
	* event-loop.c: Likewise.
	* hostio-errno.c: Likewise.
	* linux-low.c: Likewise.
	* remote-utils.c: Likewise.
	* spu-low.c: Likewise.
	* utils.c: Likewise.
	* gdbreplay.c: Unconditionally include errno.h.
---
 gdb/ChangeLog                |   26 ++++++++++++++++++++++++++
 gdb/ada-typeprint.c          |    2 --
 gdb/c-typeprint.c            |    1 -
 gdb/common/common-defs.h     |    1 +
 gdb/core-regset.c            |    1 -
 gdb/corefile.c               |    1 -
 gdb/corelow.c                |    1 -
 gdb/defs.h                   |    1 -
 gdb/event-loop.c             |    1 -
 gdb/f-typeprint.c            |    1 -
 gdb/gdbserver/ChangeLog      |   14 ++++++++++++++
 gdb/gdbserver/config.in      |    3 ---
 gdb/gdbserver/configure      |    2 +-
 gdb/gdbserver/configure.ac   |    2 +-
 gdb/gdbserver/event-loop.c   |    4 ----
 gdb/gdbserver/gdbreplay.c    |    2 --
 gdb/gdbserver/hostio-errno.c |    1 -
 gdb/gdbserver/linux-low.c    |    1 -
 gdb/gdbserver/remote-utils.c |    3 ---
 gdb/gdbserver/server.h       |    3 ---
 gdb/gdbserver/spu-low.c      |    1 -
 gdb/gdbserver/utils.c        |    3 ---
 gdb/gnu-nat.c                |    1 -
 gdb/go32-nat.c               |    1 -
 gdb/i386gnu-nat.c            |    1 -
 gdb/m2-typeprint.c           |    1 -
 gdb/nat/linux-btrace.c       |    1 -
 gdb/p-typeprint.c            |    1 -
 gdb/procfs.c                 |    1 -
 gdb/remote-sim.c             |    1 -
 gdb/rs6000-nat.c             |    1 -
 gdb/target.c                 |    1 -
 gdb/typeprint.c              |    1 -
 gdb/ui-file.c                |    2 --
 gdb/valops.c                 |    1 -
 gdb/valprint.c               |    2 --
 36 files changed, 43 insertions(+), 48 deletions(-)

diff --git a/gdb/ada-typeprint.c b/gdb/ada-typeprint.c
index a43ced7..305e39c 100644
--- a/gdb/ada-typeprint.c
+++ b/gdb/ada-typeprint.c
@@ -32,9 +32,7 @@
 #include "c-lang.h"
 #include "typeprint.h"
 #include "ada-lang.h"
-
 #include <ctype.h>
-#include <errno.h>
 
 static int print_selected_record_field_types (struct type *, struct type *,
 					      int, int,
diff --git a/gdb/c-typeprint.c b/gdb/c-typeprint.c
index 5239505..374c90e 100644
--- a/gdb/c-typeprint.c
+++ b/gdb/c-typeprint.c
@@ -31,7 +31,6 @@
 #include "typeprint.h"
 #include "cp-abi.h"
 #include "jv-lang.h"
-#include <errno.h>
 #include "cp-support.h"
 
 static void c_type_print_varspec_prefix (struct type *,
diff --git a/gdb/common/common-defs.h b/gdb/common/common-defs.h
index 7c67846..82290dc 100644
--- a/gdb/common/common-defs.h
+++ b/gdb/common/common-defs.h
@@ -32,6 +32,7 @@
 #include <stdarg.h>
 #include <stddef.h>
 #include <string.h>
+#include <errno.h>
 #include "ansidecl.h"
 #include "libiberty.h"
 #include "pathmax.h"
diff --git a/gdb/core-regset.c b/gdb/core-regset.c
index 6edc8c5..bdcb72a 100644
--- a/gdb/core-regset.c
+++ b/gdb/core-regset.c
@@ -34,7 +34,6 @@
 #include "regcache.h"
 
 #include <fcntl.h>
-#include <errno.h>
 #include <time.h>
 #ifdef HAVE_SYS_PROCFS_H
 #include <sys/procfs.h>
diff --git a/gdb/corefile.c b/gdb/corefile.c
index 983caa9..1617392 100644
--- a/gdb/corefile.c
+++ b/gdb/corefile.c
@@ -18,7 +18,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <errno.h>
 #include <signal.h>
 #include <fcntl.h>
 #include "inferior.h"
diff --git a/gdb/corelow.c b/gdb/corelow.c
index ee0f655..ff4d733 100644
--- a/gdb/corelow.c
+++ b/gdb/corelow.c
@@ -19,7 +19,6 @@
 
 #include "defs.h"
 #include "arch-utils.h"
-#include <errno.h>
 #include <signal.h>
 #include <fcntl.h>
 #ifdef HAVE_SYS_FILE_H
diff --git a/gdb/defs.h b/gdb/defs.h
index 710298c..b7271a7 100644
--- a/gdb/defs.h
+++ b/gdb/defs.h
@@ -28,7 +28,6 @@
 #include "common-defs.h"
 
 #include <sys/types.h>
-#include <errno.h>		/* System call error return status.  */
 #include <limits.h>
 #include <stdint.h>
 
diff --git a/gdb/event-loop.c b/gdb/event-loop.c
index cc2f837..e40187e 100644
--- a/gdb/event-loop.c
+++ b/gdb/event-loop.c
@@ -31,7 +31,6 @@
 #endif
 
 #include <sys/types.h>
-#include <errno.h>
 #include <sys/time.h>
 #include "exceptions.h"
 #include "gdb_select.h"
diff --git a/gdb/f-typeprint.c b/gdb/f-typeprint.c
index 534019a..7474051 100644
--- a/gdb/f-typeprint.c
+++ b/gdb/f-typeprint.c
@@ -30,7 +30,6 @@
 #include "gdbcore.h"
 #include "target.h"
 #include "f-lang.h"
-#include <errno.h>
 
 #if 0				/* Currently unused.  */
 static void f_type_print_args (struct type *, struct ui_file *);
diff --git a/gdb/gdbserver/config.in b/gdb/gdbserver/config.in
index 6ce45a6..216c01d 100644
--- a/gdb/gdbserver/config.in
+++ b/gdb/gdbserver/config.in
@@ -54,9 +54,6 @@
 /* Define if <sys/procfs.h> has elf_fpregset_t. */
 #undef HAVE_ELF_FPREGSET_T
 
-/* Define to 1 if you have the <errno.h> header file. */
-#undef HAVE_ERRNO_H
-
 /* Define to 1 if you have the <fcntl.h> header file. */
 #undef HAVE_FCNTL_H
 
diff --git a/gdb/gdbserver/configure b/gdb/gdbserver/configure
index 5f8dcd2..9c1f9a8 100755
--- a/gdb/gdbserver/configure
+++ b/gdb/gdbserver/configure
@@ -4904,7 +4904,7 @@ $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cach
   cd "$ac_popdir"
 
 
-for ac_header in sgtty.h termio.h termios.h sys/reg.h string.h 		 proc_service.h sys/procfs.h linux/elf.h 		 errno.h fcntl.h signal.h sys/file.h malloc.h 		 sys/ioctl.h netinet/in.h sys/socket.h netdb.h 		 netinet/tcp.h arpa/inet.h
+for ac_header in sgtty.h termio.h termios.h sys/reg.h string.h 		 proc_service.h sys/procfs.h linux/elf.h 		 fcntl.h signal.h sys/file.h malloc.h 		 sys/ioctl.h netinet/in.h sys/socket.h netdb.h 		 netinet/tcp.h arpa/inet.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
diff --git a/gdb/gdbserver/configure.ac b/gdb/gdbserver/configure.ac
index 67866f8..8e5d74f 100644
--- a/gdb/gdbserver/configure.ac
+++ b/gdb/gdbserver/configure.ac
@@ -82,7 +82,7 @@ ACX_CONFIGURE_DIR(["../../libiberty"], ["build-libiberty-gdbserver"])
 
 AC_CHECK_HEADERS(sgtty.h termio.h termios.h sys/reg.h string.h dnl
 		 proc_service.h sys/procfs.h linux/elf.h dnl
-		 errno.h fcntl.h signal.h sys/file.h malloc.h dnl
+		 fcntl.h signal.h sys/file.h malloc.h dnl
 		 sys/ioctl.h netinet/in.h sys/socket.h netdb.h dnl
 		 netinet/tcp.h arpa/inet.h)
 AC_CHECK_FUNCS(pread pwrite pread64 readlink)
diff --git a/gdb/gdbserver/event-loop.c b/gdb/gdbserver/event-loop.c
index 1513b59..92c8db0 100644
--- a/gdb/gdbserver/event-loop.c
+++ b/gdb/gdbserver/event-loop.c
@@ -29,10 +29,6 @@
 #include <io.h>
 #endif
 
-#ifdef HAVE_ERRNO_H
-#include <errno.h>
-#endif
-
 #include <unistd.h>
 
 typedef struct gdb_event gdb_event;
diff --git a/gdb/gdbserver/gdbreplay.c b/gdb/gdbserver/gdbreplay.c
index 706fda6..c70abef 100644
--- a/gdb/gdbserver/gdbreplay.c
+++ b/gdb/gdbserver/gdbreplay.c
@@ -32,9 +32,7 @@
 #if HAVE_FCNTL_H
 #include <fcntl.h>
 #endif
-#if HAVE_ERRNO_H
 #include <errno.h>
-#endif
 #include <stdlib.h>
 #include <string.h>
 #include <unistd.h>
diff --git a/gdb/gdbserver/hostio-errno.c b/gdb/gdbserver/hostio-errno.c
index 8817096..f24b51f 100644
--- a/gdb/gdbserver/hostio-errno.c
+++ b/gdb/gdbserver/hostio-errno.c
@@ -22,7 +22,6 @@
    on top of errno.  */
 
 #include "server.h"
-#include <errno.h>
 #include "gdb/fileio.h"
 
 static int
diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c
index 74289c0..f71a4de 100644
--- a/gdb/gdbserver/linux-low.c
+++ b/gdb/gdbserver/linux-low.c
@@ -31,7 +31,6 @@
 #include <sys/ioctl.h>
 #include <fcntl.h>
 #include <unistd.h>
-#include <errno.h>
 #include <sys/syscall.h>
 #include <sched.h>
 #include <ctype.h>
diff --git a/gdb/gdbserver/remote-utils.c b/gdb/gdbserver/remote-utils.c
index f3ae393..327677a 100644
--- a/gdb/gdbserver/remote-utils.c
+++ b/gdb/gdbserver/remote-utils.c
@@ -56,9 +56,6 @@
 #include <arpa/inet.h>
 #endif
 #include <sys/stat.h>
-#if HAVE_ERRNO_H
-#include <errno.h>
-#endif
 
 #if USE_WIN32API
 #include <winsock2.h>
diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h
index 1e2c3a1..db6ddde 100644
--- a/gdb/gdbserver/server.h
+++ b/gdb/gdbserver/server.h
@@ -27,9 +27,6 @@
 
 #include "version.h"
 
-#ifdef HAVE_ERRNO_H
-#include <errno.h>
-#endif
 #include <setjmp.h>
 
 #ifdef HAVE_ALLOCA_H
diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c
index cb1ac0d..867f97b 100644
--- a/gdb/gdbserver/spu-low.c
+++ b/gdb/gdbserver/spu-low.c
@@ -24,7 +24,6 @@
 #include <sys/ptrace.h>
 #include <fcntl.h>
 #include <unistd.h>
-#include <errno.h>
 #include <sys/syscall.h>
 #include "filestuff.h"
 #include "hostio.h"
diff --git a/gdb/gdbserver/utils.c b/gdb/gdbserver/utils.c
index ec37a9b..b011637 100644
--- a/gdb/gdbserver/utils.c
+++ b/gdb/gdbserver/utils.c
@@ -17,9 +17,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "server.h"
-#if HAVE_ERRNO_H
-#include <errno.h>
-#endif
 
 #ifdef IN_PROCESS_AGENT
 #  define PREFIX "ipa: "
diff --git a/gdb/gnu-nat.c b/gdb/gnu-nat.c
index d6658c7..c8164d6 100644
--- a/gdb/gnu-nat.c
+++ b/gdb/gnu-nat.c
@@ -23,7 +23,6 @@
 #include "defs.h"
 
 #include <ctype.h>
-#include <errno.h>
 #include <limits.h>
 #include <setjmp.h>
 #include <signal.h>
diff --git a/gdb/go32-nat.c b/gdb/go32-nat.c
index 75596a2..727f810 100644
--- a/gdb/go32-nat.c
+++ b/gdb/go32-nat.c
@@ -105,7 +105,6 @@
 #include "inf-child.h"
 
 #include <ctype.h>
-#include <errno.h>
 #include <unistd.h>
 #include <sys/utsname.h>
 #include <io.h>
diff --git a/gdb/i386gnu-nat.c b/gdb/i386gnu-nat.c
index 94d2a0a..8fad871 100644
--- a/gdb/i386gnu-nat.c
+++ b/gdb/i386gnu-nat.c
@@ -22,7 +22,6 @@
 #include "floatformat.h"
 #include "regcache.h"
 
-#include <errno.h>
 #include <mach.h>
 #include <mach_error.h>
 #include <mach/message.h>
diff --git a/gdb/m2-typeprint.c b/gdb/m2-typeprint.c
index 45bc093..72c107b 100644
--- a/gdb/m2-typeprint.c
+++ b/gdb/m2-typeprint.c
@@ -31,7 +31,6 @@
 #include "c-lang.h"
 #include "typeprint.h"
 #include "cp-abi.h"
-#include <errno.h>
 
 static void m2_print_bounds (struct type *type,
 			     struct ui_file *stream, int show, int level,
diff --git a/gdb/nat/linux-btrace.c b/gdb/nat/linux-btrace.c
index 19e218e..f6fdbda 100644
--- a/gdb/nat/linux-btrace.c
+++ b/gdb/nat/linux-btrace.c
@@ -37,7 +37,6 @@
 
 #if HAVE_LINUX_PERF_EVENT_H && defined(SYS_perf_event_open)
 
-#include <errno.h>
 #include <stdint.h>
 #include <unistd.h>
 #include <sys/mman.h>
diff --git a/gdb/p-typeprint.c b/gdb/p-typeprint.c
index 6870cdf..b1e16f0 100644
--- a/gdb/p-typeprint.c
+++ b/gdb/p-typeprint.c
@@ -31,7 +31,6 @@
 #include "p-lang.h"
 #include "typeprint.h"
 #include "gdb-demangle.h"
-#include <errno.h>
 #include <ctype.h>
 
 static void pascal_type_print_varspec_suffix (struct type *, struct ui_file *,
diff --git a/gdb/procfs.c b/gdb/procfs.c
index d93843a..3465bc5 100644
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -42,7 +42,6 @@
 #ifdef HAVE_SYS_SYSCALL_H
 #include <sys/syscall.h>
 #endif
-#include <sys/errno.h>
 #include "gdb_wait.h"
 #include <signal.h>
 #include <ctype.h>
diff --git a/gdb/remote-sim.c b/gdb/remote-sim.c
index 51b3c30..8901548 100644
--- a/gdb/remote-sim.c
+++ b/gdb/remote-sim.c
@@ -28,7 +28,6 @@
 #include <fcntl.h>
 #include <signal.h>
 #include <setjmp.h>
-#include <errno.h>
 #include "terminal.h"
 #include "target.h"
 #include "gdbcore.h"
diff --git a/gdb/rs6000-nat.c b/gdb/rs6000-nat.c
index 4ba955c..1b09680 100644
--- a/gdb/rs6000-nat.c
+++ b/gdb/rs6000-nat.c
@@ -46,7 +46,6 @@
 #include <signal.h>
 #include <sys/ioctl.h>
 #include <fcntl.h>
-#include <errno.h>
 
 #include <a.out.h>
 #include <sys/file.h>
diff --git a/gdb/target.c b/gdb/target.c
index b329a13..2c1d35b 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -20,7 +20,6 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include <errno.h>
 #include "target.h"
 #include "target-dcache.h"
 #include "gdbcmd.h"
diff --git a/gdb/typeprint.c b/gdb/typeprint.c
index e0b7c44..3d8620a 100644
--- a/gdb/typeprint.c
+++ b/gdb/typeprint.c
@@ -33,7 +33,6 @@
 #include "typeprint.h"
 #include "exceptions.h"
 #include "valprint.h"
-#include <errno.h>
 #include <ctype.h>
 #include "cli/cli-utils.h"
 #include "extension.h"
diff --git a/gdb/ui-file.c b/gdb/ui-file.c
index 767b55b..49607dc 100644
--- a/gdb/ui-file.c
+++ b/gdb/ui-file.c
@@ -25,8 +25,6 @@
 #include "gdb_select.h"
 #include "filestuff.h"
 
-#include <errno.h>
-
 static ui_file_isatty_ftype null_file_isatty;
 static ui_file_write_ftype null_file_write;
 static ui_file_write_ftype null_file_write_async_safe;
diff --git a/gdb/valops.c b/gdb/valops.c
index 5ef763d..d9ce2f2 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -36,7 +36,6 @@
 #include "cp-support.h"
 #include "dfp.h"
 #include "tracepoint.h"
-#include <errno.h>
 #include "observer.h"
 #include "objfiles.h"
 #include "exceptions.h"
diff --git a/gdb/valprint.c b/gdb/valprint.c
index 0ded6b7..d3ab267 100644
--- a/gdb/valprint.c
+++ b/gdb/valprint.c
@@ -37,8 +37,6 @@
 #include "charset.h"
 #include <ctype.h>
 
-#include <errno.h>
-
 /* Maximum number of wchars returned from wchar_iterate.  */
 #define MAX_WCHARS 4
 
-- 
1.7.1


^ permalink raw reply	[flat|nested] 26+ messages in thread

* Re: [PATCH 14/13 v2] Move errno.h to common-defs.h
  2014-07-31 10:19       ` Pedro Alves
@ 2014-07-31 15:10         ` Tom Tromey
  0 siblings, 0 replies; 26+ messages in thread
From: Tom Tromey @ 2014-07-31 15:10 UTC (permalink / raw)
  To: Pedro Alves; +Cc: Gary Benson, gdb-patches

>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:

Pedro> On 07/31/2014 09:55 AM, Gary Benson wrote:
>> I'll move the check.  There are some Windows CE workarounds for errno
>> in gdbserver that I don't really want to touch, so keeping the checks
>> keeps the effect of this change as minimal as possible.

Pedro> (following up on my other email:)

Pedro> This path is fine with me as well.  Whatever's easier, really.

Yeah, me too.

Tom


^ permalink raw reply	[flat|nested] 26+ messages in thread

* Re: [PATCH 13/13] Include string.h in common-defs.h
  2014-07-29 15:11 ` [PATCH 13/13] Include string.h in common-defs.h Gary Benson
@ 2014-08-06 17:25   ` Doug Evans
  2014-08-07  8:13     ` Gary Benson
  0 siblings, 1 reply; 26+ messages in thread
From: Doug Evans @ 2014-08-06 17:25 UTC (permalink / raw)
  To: Gary Benson; +Cc: gdb-patches

Gary Benson writes:
 > This commit includes string.h in common-defs.h and removes all other
 > inclusions.
 > 
 > gdb/
 > 2014-07-29  Gary Benson  <gbenson@redhat.com>
 > 
 > 	* common/common-defs.h: Include string.h.
 > 	* aarch64-tdep.c: Do not include string.h.
 > 	* ada-exp.y: Likewise.
 > 	* ada-lang.c: Likewise.
 > 	* ada-lex.l: Likewise.
 > 	* ada-typeprint.c: Likewise.
 > 	* ada-valprint.c: Likewise.
 > 	* aix-thread.c: Likewise.
 > 	* alpha-linux-tdep.c: Likewise.
 > 	* alpha-mdebug-tdep.c: Likewise.
 > 	* alpha-nat.c: Likewise.
 > 	* alpha-osf1-tdep.c: Likewise.
 > 	* alpha-tdep.c: Likewise.
 > 	* alphanbsd-tdep.c: Likewise.
 > 	* amd64-dicos-tdep.c: Likewise.
 > 	* amd64-linux-tdep.c: Likewise.
 > 	* amd64-nat.c: Likewise.
 > 	* amd64-sol2-tdep.c: Likewise.
 > 	* amd64fbsd-tdep.c: Likewise.
 > 	* amd64obsd-tdep.c: Likewise.
 > 	* arch-utils.c: Likewise.
 > 	* arm-linux-nat.c: Likewise.
 > 	* arm-linux-tdep.c: Likewise.
 > 	* arm-tdep.c: Likewise.
 > 	* arm-wince-tdep.c: Likewise.
 > 	* armbsd-tdep.c: Likewise.
 > 	* armnbsd-nat.c: Likewise.
 > 	* armnbsd-tdep.c: Likewise.
 > 	* armobsd-tdep.c: Likewise.
 > 	* avr-tdep.c: Likewise.
 > 	* ax-gdb.c: Likewise.
 > 	* ax-general.c: Likewise.
 > 	* bcache.c: Likewise.
 > 	* bfin-tdep.c: Likewise.
 > 	* breakpoint.c: Likewise.
 > 	* build-id.c: Likewise.
 > 	* buildsym.c: Likewise.
 > 	* c-exp.y: Likewise.
 > 	* c-lang.c: Likewise.
 > 	* c-typeprint.c: Likewise.
 > 	* c-valprint.c: Likewise.
 > 	* charset.c: Likewise.
 > 	* cli-out.c: Likewise.
 > 	* cli/cli-cmds.c: Likewise.
 > 	* cli/cli-decode.c: Likewise.
 > 	* cli/cli-dump.c: Likewise.
 > 	* cli/cli-interp.c: Likewise.
 > 	* cli/cli-logging.c: Likewise.
 > 	* cli/cli-script.c: Likewise.
 > 	* cli/cli-setshow.c: Likewise.
 > 	* cli/cli-utils.c: Likewise.
 > 	* coffread.c: Likewise.
 > 	* common/agent.c: Likewise.
 > 	* common/buffer.c: Likewise.
 > 	* common/buffer.h: Likewise.
 > 	* common/common-utils.c: Likewise.
 > 	* common/filestuff.c: Likewise.
 > 	* common/filestuff.c: Likewise.
 > 	* common/format.c: Likewise.
 > 	* common/print-utils.c: Likewise.
 > 	* common/rsp-low.c: Likewise.
 > 	* common/signals.c: Likewise.
 > 	* common/vec.h: Likewise.
 > 	* common/xml-utils.c: Likewise.
 > 	* core-regset.c: Likewise.
 > 	* corefile.c: Likewise.
 > 	* corelow.c: Likewise.
 > 	* cp-abi.c: Likewise.
 > 	* cp-name-parser.y: Likewise.
 > 	* cp-support.c: Likewise.
 > 	* cp-valprint.c: Likewise.
 > 	* cris-tdep.c: Likewise.
 > 	* d-exp.y: Likewise.
 > 	* darwin-nat.c: Likewise.
 > 	* dbxread.c: Likewise.
 > 	* dcache.c: Likewise.
 > 	* demangle.c: Likewise.
 > 	* dicos-tdep.c: Likewise.
 > 	* disasm.c: Likewise.
 > 	* doublest.c: Likewise.
 > 	* dsrec.c: Likewise.
 > 	* dummy-frame.c: Likewise.
 > 	* dwarf2-frame.c: Likewise.
 > 	* dwarf2loc.c: Likewise.
 > 	* dwarf2read.c: Likewise.
 > 	* elfread.c: Likewise.
 > 	* environ.c: Likewise.
 > 	* eval.c: Likewise.
 > 	* event-loop.c: Likewise.
 > 	* exceptions.c: Likewise.
 > 	* exec.c: Likewise.
 > 	* expprint.c: Likewise.
 > 	* f-exp.y: Likewise.
 > 	* f-lang.c: Likewise.
 > 	* f-typeprint.c: Likewise.
 > 	* f-valprint.c: Likewise.
 > 	* fbsd-nat.c: Likewise.
 > 	* findcmd.c: Likewise.
 > 	* findvar.c: Likewise.
 > 	* fork-child.c: Likewise.
 > 	* frame.c: Likewise.
 > 	* frv-linux-tdep.c: Likewise.
 > 	* frv-tdep.c: Likewise.
 > 	* gdb.c: Likewise.
 > 	* gdb_bfd.c: Likewise.
 > 	* gdbarch.c: Likewise.
 > 	* gdbarch.sh: Likewise.
 > 	* gdbtypes.c: Likewise.
 > 	* gnu-nat.c: Likewise.
 > 	* gnu-v2-abi.c: Likewise.
 > 	* gnu-v3-abi.c: Likewise.
 > 	* go-exp.y: Likewise.
 > 	* go-lang.c: Likewise.
 > 	* go32-nat.c: Likewise.
 > 	* guile/guile.c: Likewise.
 > 	* guile/scm-auto-load.c: Likewise.
 > 	* hppa-hpux-tdep.c: Likewise.
 > 	* hppa-linux-nat.c: Likewise.
 > 	* hppanbsd-tdep.c: Likewise.
 > 	* hppaobsd-tdep.c: Likewise.
 > 	* i386-cygwin-tdep.c: Likewise.
 > 	* i386-dicos-tdep.c: Likewise.
 > 	* i386-linux-tdep.c: Likewise.
 > 	* i386-nto-tdep.c: Likewise.
 > 	* i386-sol2-tdep.c: Likewise.
 > 	* i386-tdep.c: Likewise.
 > 	* i386bsd-tdep.c: Likewise.
 > 	* i386gnu-nat.c: Likewise.
 > 	* i386nbsd-tdep.c: Likewise.
 > 	* i386obsd-tdep.c: Likewise.
 > 	* i387-tdep.c: Likewise.
 > 	* ia64-libunwind-tdep.c: Likewise.
 > 	* ia64-linux-nat.c: Likewise.
 > 	* inf-child.c: Likewise.
 > 	* inf-ptrace.c: Likewise.
 > 	* inf-ttrace.c: Likewise.
 > 	* infcall.c: Likewise.
 > 	* infcmd.c: Likewise.
 > 	* inflow.c: Likewise.
 > 	* infrun.c: Likewise.
 > 	* interps.c: Likewise.
 > 	* iq2000-tdep.c: Likewise.
 > 	* irix5-nat.c: Likewise.
 > 	* jv-exp.y: Likewise.
 > 	* jv-lang.c: Likewise.
 > 	* jv-typeprint.c: Likewise.
 > 	* jv-valprint.c: Likewise.
 > 	* language.c: Likewise.
 > 	* linux-fork.c: Likewise.
 > 	* linux-nat.c: Likewise.
 > 	* lm32-tdep.c: Likewise.
 > 	* m2-exp.y: Likewise.
 > 	* m2-typeprint.c: Likewise.
 > 	* m32c-tdep.c: Likewise.
 > 	* m32r-linux-nat.c: Likewise.
 > 	* m32r-linux-tdep.c: Likewise.
 > 	* m32r-rom.c: Likewise.
 > 	* m32r-tdep.c: Likewise.
 > 	* m68hc11-tdep.c: Likewise.
 > 	* m68k-tdep.c: Likewise.
 > 	* m68kbsd-tdep.c: Likewise.
 > 	* m68klinux-nat.c: Likewise.
 > 	* m68klinux-tdep.c: Likewise.
 > 	* m88k-tdep.c: Likewise.
 > 	* machoread.c: Likewise.
 > 	* macrocmd.c: Likewise.
 > 	* main.c: Likewise.
 > 	* mdebugread.c: Likewise.
 > 	* mem-break.c: Likewise.
 > 	* memattr.c: Likewise.
 > 	* memory-map.c: Likewise.
 > 	* mep-tdep.c: Likewise.
 > 	* mi/mi-cmd-break.c: Likewise.
 > 	* mi/mi-cmd-disas.c: Likewise.
 > 	* mi/mi-cmd-env.c: Likewise.
 > 	* mi/mi-cmd-stack.c: Likewise.
 > 	* mi/mi-cmd-var.c: Likewise.
 > 	* mi/mi-cmds.c: Likewise.
 > 	* mi/mi-console.c: Likewise.
 > 	* mi/mi-getopt.c: Likewise.
 > 	* mi/mi-interp.c: Likewise.
 > 	* mi/mi-main.c: Likewise.
 > 	* mi/mi-parse.c: Likewise.
 > 	* microblaze-rom.c: Likewise.
 > 	* microblaze-tdep.c: Likewise.
 > 	* mingw-hdep.c: Likewise.
 > 	* minidebug.c: Likewise.
 > 	* minsyms.c: Likewise.
 > 	* mips-irix-tdep.c: Likewise.
 > 	* mips-linux-tdep.c: Likewise.
 > 	* mips-tdep.c: Likewise.
 > 	* mips64obsd-tdep.c: Likewise.
 > 	* mipsnbsd-tdep.c: Likewise.
 > 	* mipsread.c: Likewise.
 > 	* mn10300-linux-tdep.c: Likewise.
 > 	* mn10300-tdep.c: Likewise.
 > 	* monitor.c: Likewise.
 > 	* moxie-tdep.c: Likewise.
 > 	* mt-tdep.c: Likewise.
 > 	* nat/linux-btrace.c: Likewise.
 > 	* nat/linux-osdata.c: Likewise.
 > 	* nat/linux-procfs.c: Likewise.
 > 	* nat/linux-ptrace.c: Likewise.
 > 	* nat/linux-waitpid.c: Likewise.
 > 	* nbsd-tdep.c: Likewise.
 > 	* nios2-linux-tdep.c: Likewise.
 > 	* nto-procfs.c: Likewise.
 > 	* nto-tdep.c: Likewise.
 > 	* objc-lang.c: Likewise.
 > 	* objfiles.c: Likewise.
 > 	* opencl-lang.c: Likewise.
 > 	* osabi.c: Likewise.
 > 	* osdata.c: Likewise.
 > 	* p-exp.y: Likewise.
 > 	* p-lang.c: Likewise.
 > 	* p-typeprint.c: Likewise.
 > 	* parse.c: Likewise.
 > 	* posix-hdep.c: Likewise.
 > 	* ppc-linux-nat.c: Likewise.
 > 	* ppc-sysv-tdep.c: Likewise.
 > 	* ppcfbsd-tdep.c: Likewise.
 > 	* ppcnbsd-tdep.c: Likewise.
 > 	* ppcobsd-tdep.c: Likewise.
 > 	* printcmd.c: Likewise.
 > 	* procfs.c: Likewise.
 > 	* prologue-value.c: Likewise.
 > 	* python/py-auto-load.c: Likewise.
 > 	* python/py-gdb-readline.c: Likewise.
 > 	* ravenscar-thread.c: Likewise.
 > 	* regcache.c: Likewise.
 > 	* registry.c: Likewise.
 > 	* remote-fileio.c: Likewise.
 > 	* remote-m32r-sdi.c: Likewise.
 > 	* remote-mips.c: Likewise.
 > 	* remote-notif.c: Likewise.
 > 	* remote-sim.c: Likewise.
 > 	* remote.c: Likewise.
 > 	* reverse.c: Likewise.
 > 	* rs6000-aix-tdep.c: Likewise.
 > 	* ser-base.c: Likewise.
 > 	* ser-go32.c: Likewise.
 > 	* ser-mingw.c: Likewise.
 > 	* ser-pipe.c: Likewise.
 > 	* ser-tcp.c: Likewise.
 > 	* ser-unix.c: Likewise.
 > 	* serial.c: Likewise.
 > 	* sh-tdep.c: Likewise.
 > 	* sh64-tdep.c: Likewise.
 > 	* shnbsd-tdep.c: Likewise.
 > 	* skip.c: Likewise.
 > 	* sol-thread.c: Likewise.
 > 	* solib-dsbt.c: Likewise.
 > 	* solib-frv.c: Likewise.
 > 	* solib-osf.c: Likewise.
 > 	* solib-som.c: Likewise.
 > 	* solib-spu.c: Likewise.
 > 	* solib-target.c: Likewise.
 > 	* solib.c: Likewise.
 > 	* somread.c: Likewise.
 > 	* source.c: Likewise.
 > 	* sparc-nat.c: Likewise.
 > 	* sparc-sol2-tdep.c: Likewise.
 > 	* sparc-tdep.c: Likewise.
 > 	* sparc64-tdep.c: Likewise.
 > 	* sparc64fbsd-tdep.c: Likewise.
 > 	* sparc64nbsd-tdep.c: Likewise.
 > 	* sparcnbsd-tdep.c: Likewise.
 > 	* spu-linux-nat.c: Likewise.
 > 	* spu-multiarch.c: Likewise.
 > 	* spu-tdep.c: Likewise.
 > 	* stabsread.c: Likewise.
 > 	* stack.c: Likewise.
 > 	* std-regs.c: Likewise.
 > 	* symfile.c: Likewise.
 > 	* symmisc.c: Likewise.
 > 	* symtab.c: Likewise.
 > 	* target.c: Likewise.
 > 	* thread.c: Likewise.
 > 	* tilegx-linux-nat.c: Likewise.
 > 	* tilegx-tdep.c: Likewise.
 > 	* top.c: Likewise.
 > 	* tracepoint.c: Likewise.
 > 	* tui/tui-command.c: Likewise.
 > 	* tui/tui-data.c: Likewise.
 > 	* tui/tui-disasm.c: Likewise.
 > 	* tui/tui-file.c: Likewise.
 > 	* tui/tui-layout.c: Likewise.
 > 	* tui/tui-out.c: Likewise.
 > 	* tui/tui-regs.c: Likewise.
 > 	* tui/tui-source.c: Likewise.
 > 	* tui/tui-stack.c: Likewise.
 > 	* tui/tui-win.c: Likewise.
 > 	* tui/tui-windata.c: Likewise.
 > 	* tui/tui-winsource.c: Likewise.
 > 	* typeprint.c: Likewise.
 > 	* ui-file.c: Likewise.
 > 	* ui-out.c: Likewise.
 > 	* user-regs.c: Likewise.
 > 	* utils.c: Likewise.
 > 	* v850-tdep.c: Likewise.
 > 	* valarith.c: Likewise.
 > 	* valops.c: Likewise.
 > 	* valprint.c: Likewise.
 > 	* value.c: Likewise.
 > 	* varobj.c: Likewise.
 > 	* vax-tdep.c: Likewise.
 > 	* vaxnbsd-tdep.c: Likewise.
 > 	* vaxobsd-tdep.c: Likewise.
 > 	* windows-nat.c: Likewise.
 > 	* xcoffread.c: Likewise.
 > 	* xml-support.c: Likewise.
 > 	* xstormy16-tdep.c: Likewise.
 > 	* xtensa-linux-nat.c: Likewise.
 > [... zoinks! :-) ...]

Fwiw, I'd be happy with replacing all of this with:

	* common/common-defs.h: Include string.h.
	All other uses deleted.

[and similarly elsewhere]

No need to go back and change anything though.
Just my $0.02.
Some may have a rule to write this as you've done,
but I think this is another case where we're bogging
ourselves down in pedantic administrivia.

[Patch is ok with me, btw.]


^ permalink raw reply	[flat|nested] 26+ messages in thread

* Re: [PATCH 00/13] Include some headers in common-defs.h
  2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
                   ` (13 preceding siblings ...)
  2014-07-30 13:35 ` [PATCH 14/13] Move errno.h " Gary Benson
@ 2014-08-06 17:26 ` Doug Evans
  2014-08-07  8:15   ` Gary Benson
  14 siblings, 1 reply; 26+ messages in thread
From: Doug Evans @ 2014-08-06 17:26 UTC (permalink / raw)
  To: Gary Benson; +Cc: gdb-patches

Gary Benson writes:
 > Hi all,
 > 
 > This series builds on my "config.h rationalization" series that is
 > currently under review [1].
 > 
 > Each patch adds one #include line to common-defs.h and removes all
 > other inclusions of that file in all files that include either defs.h
 > or server.h.  Patches 1-11 deal with files that are already included
 > by both defs.h and server.h; these patches don't really change
 > anything about the build.  Patches 12 and 13 add gdb_assert.h and
 > string.h respectively.  These are included by server.h but not by
 > defs.h, but both are included in hundreds of files so I think they
 > are good candidates for global inclusion.
 > 
 > There are three more files that are included by both defs.h and
 > server.h that I have not dealt with in this series.  errno.h and
 > alloca.h are both handled completely differently by defs.h and
 > server.h: moving these headers to common-defs.h should be done, but
 > will require merging the configury.  The final file, print-utils.h,
 > is included indirectly by both defs.h and server.h but cannot be
 > merged without some of the "Common code cleanups" series [2].  That
 > needs some rewriting, so I'll add that to common-defs.h as part of
 > the next version of that series.
 > 
 > Is this ok to commit?
 > 
 > Thanks,
 > Gary
 > 
 > --
 > [1] https://sourceware.org/ml/gdb-patches/2014-07/msg00670.html
 > [2] https://sourceware.org/ml/gdb-patches/2014-07/msg00427.html

LGTM


^ permalink raw reply	[flat|nested] 26+ messages in thread

* Re: [PATCH 13/13] Include string.h in common-defs.h
  2014-08-06 17:25   ` Doug Evans
@ 2014-08-07  8:13     ` Gary Benson
  0 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-08-07  8:13 UTC (permalink / raw)
  To: Doug Evans; +Cc: gdb-patches

Doug Evans wrote:
> Gary Benson writes:
> > This commit includes string.h in common-defs.h and removes all
> > other inclusions.
> > 
> > gdb/
> > 2014-07-29  Gary Benson  <gbenson@redhat.com>
> > 
> > 	* common/common-defs.h: Include string.h.
> > 	* aarch64-tdep.c: Do not include string.h.
> > 	* ada-exp.y: Likewise.
[snip]
> > 	* xtensa-linux-nat.c: Likewise.
> > [... zoinks! :-) ...]
> 
> Fwiw, I'd be happy with replacing all of this with:
> 
> 	* common/common-defs.h: Include string.h.
> 	All other uses deleted.
> 
> [and similarly elsewhere]
> 
> No need to go back and change anything though.
> Just my $0.02.
> Some may have a rule to write this as you've done,
> but I think this is another case where we're bogging
> ourselves down in pedantic administrivia.

Ok, I'll do that next time.

Cheers,
Gary

-- 
http://gbenson.net/


^ permalink raw reply	[flat|nested] 26+ messages in thread

* Re: [PATCH 00/13] Include some headers in common-defs.h
  2014-08-06 17:26 ` [PATCH 00/13] Include some headers in common-defs.h Doug Evans
@ 2014-08-07  8:15   ` Gary Benson
  0 siblings, 0 replies; 26+ messages in thread
From: Gary Benson @ 2014-08-07  8:15 UTC (permalink / raw)
  To: Doug Evans; +Cc: gdb-patches

Doug Evans wrote:
> Gary Benson writes:
> > This series builds on my "config.h rationalization" series that is
> > currently under review [1].
> > 
> > Each patch adds one #include line to common-defs.h and removes all
> > other inclusions of that file in all files that include either
> > defs.h or server.h.  Patches 1-11 deal with files that are already
> > included by both defs.h and server.h; these patches don't really
> > change anything about the build.  Patches 12 and 13 add
> > gdb_assert.h and string.h respectively.  These are included by
> > server.h but not by defs.h, but both are included in hundreds of
> > files so I think they are good candidates for global inclusion.
> > 
> > There are three more files that are included by both defs.h and
> > server.h that I have not dealt with in this series.  errno.h and
> > alloca.h are both handled completely differently by defs.h and
> > server.h: moving these headers to common-defs.h should be done,
> > but will require merging the configury.  The final file,
> > print-utils.h, is included indirectly by both defs.h and server.h
> > but cannot be merged without some of the "Common code cleanups"
> > series [2].  That needs some rewriting, so I'll add that to
> > common-defs.h as part of the next version of that series.
> > 
> > Is this ok to commit?
> > 
> > Thanks,
> > Gary
> > 
> > --
> > [1] https://sourceware.org/ml/gdb-patches/2014-07/msg00670.html
> > [2] https://sourceware.org/ml/gdb-patches/2014-07/msg00427.html
> 
> LGTM

Pushed.  Thank you for the review!

Cheers,
Gary

-- 
http://gbenson.net/


^ permalink raw reply	[flat|nested] 26+ messages in thread

end of thread, other threads:[~2014-08-07  8:15 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-29 15:11 [PATCH 00/13] Include some headers in common-defs.h Gary Benson
2014-07-29 15:11 ` [PATCH 03/13] Move stdarg.h to common-defs.h Gary Benson
2014-07-29 15:11 ` [PATCH 13/13] Include string.h in common-defs.h Gary Benson
2014-08-06 17:25   ` Doug Evans
2014-08-07  8:13     ` Gary Benson
2014-07-29 15:11 ` [PATCH 12/13] Include gdb_assert.h " Gary Benson
2014-07-29 15:11 ` [PATCH 02/13] Move stdlib.h to common-defs.h Gary Benson
2014-07-29 15:13 ` [PATCH 04/13] Move stddef.h " Gary Benson
2014-07-29 15:14 ` [PATCH 09/13] Move gdb_locale.h " Gary Benson
2014-07-29 15:18 ` [PATCH 11/13] Move common-utils.h " Gary Benson
2014-07-29 15:18 ` [PATCH 05/13] Move ansidecl.h " Gary Benson
2014-07-29 15:35 ` [PATCH 01/13] Move stdio.h " Gary Benson
2014-07-29 16:02 ` [PATCH 07/13] Move pathmax.h " Gary Benson
2014-07-29 16:08 ` [PATCH 06/13] Move libiberty.h " Gary Benson
2014-07-29 16:22 ` [PATCH 10/13] Move ptid.h " Gary Benson
2014-07-30  8:29   ` Gary Benson
2014-07-29 16:22 ` [PATCH 08/13] Move gdb/signals.h " Gary Benson
2014-07-30 13:35 ` [PATCH 14/13] Move errno.h " Gary Benson
2014-07-31  8:55   ` Tom Tromey
2014-07-31  9:57     ` [PATCH 14/13 v2] " Gary Benson
2014-07-31 10:19       ` Pedro Alves
2014-07-31 15:10         ` Tom Tromey
2014-07-31 10:00     ` [PATCH 14/13] " Pedro Alves
2014-07-31 14:49       ` [PATCH 14/13 v3] " Gary Benson
2014-08-06 17:26 ` [PATCH 00/13] Include some headers in common-defs.h Doug Evans
2014-08-07  8:15   ` Gary Benson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox