Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [PATCH 0/9][gdbserver] Split server.h.
@ 2013-09-03 20:26 Pedro Alves
  2013-09-03 20:26 ` [PATCH 1/9] [gdbserver] Delete _ macro (gettext) Pedro Alves
                   ` (9 more replies)
  0 siblings, 10 replies; 22+ messages in thread
From: Pedro Alves @ 2013-09-03 20:26 UTC (permalink / raw)
  To: gdb-patches

The recurring theme of doing:

 #ifdef GDBSERVER
 #include "server.h"
 #else
 #include "defs.h"
 #endif

in common/ code is a bit annoying.  I think we'll end up proving a
defs.h in gdbserver, and we'll want to share as much with gdb's as
possible.

I considered just renaming server.h to defs.h, but looking at
server.h, I think it's better to first split out things that don't
really need to be there.  Now that gdbserver's Makefile does automatic
dependency tracking, it's easy enough to split the parts that actually
define interfaces of specific modules to their own files.  This series
does that.  Some of the new headers remain included in server.h (at
least for now), for they define things that are truly used throughout
the code, and I was hating the fact that I was ending up adding
#include remote-utils.h throughout in a previous attempt, with "utils"
being yet another kitchensink, which I prefer avoiding.  Still, I
think it still makes things clearer this way.

I think we should do the same on the gdb side too.

Tested on x86_64 Fedora 17.  I'll apply it tomorrow, barring comments.

Pedro Alves (9):
  [gdbserver] Delete _ macro (gettext).
  [gdbserver] Split a new remote-utils.h file out of server.h.
  [gdbserver] Split a new utils.h file out of server.h.
  [gdbserver] Split a new tracepoint.h file out of server.h.
  [gdbserver] Split a new ax.h file out of server.h.
  [gdbserver] Split a new inferiors.h file out of server.h.
  [gdbserver] Split a new dll.h file out of server.h.
  [gdbserver] Split a new event-loop.h file out of server.h.
  [gdbserver] Split a new hostio.h file out of server.h.

 gdb/gdbserver/ax.c            |   1 +
 gdb/gdbserver/ax.h            |  57 +++++++
 gdb/gdbserver/dll.c           |   1 +
 gdb/gdbserver/dll.h           |  35 ++++
 gdb/gdbserver/event-loop.h    |  36 ++++
 gdb/gdbserver/gdbthread.h     |   1 +
 gdb/gdbserver/hostio.c        |   1 +
 gdb/gdbserver/hostio.h        |  28 +++
 gdb/gdbserver/inferiors.c     |   1 +
 gdb/gdbserver/inferiors.h     | 114 +++++++++++++
 gdb/gdbserver/linux-low.c     |   2 +
 gdb/gdbserver/linux-x86-low.c |   2 +
 gdb/gdbserver/remote-utils.c  |   2 +
 gdb/gdbserver/remote-utils.h  |  85 ++++++++++
 gdb/gdbserver/server.c        |   3 +
 gdb/gdbserver/server.h        | 385 +-----------------------------------------
 gdb/gdbserver/target.c        |   1 +
 gdb/gdbserver/target.h        |   1 +
 gdb/gdbserver/tracepoint.c    |   1 +
 gdb/gdbserver/tracepoint.h    | 132 +++++++++++++++
 gdb/gdbserver/utils.h         |  32 ++++
 21 files changed, 541 insertions(+), 380 deletions(-)
 create mode 100644 gdb/gdbserver/dll.h
 create mode 100644 gdb/gdbserver/event-loop.h
 create mode 100644 gdb/gdbserver/hostio.h
 create mode 100644 gdb/gdbserver/inferiors.h
 create mode 100644 gdb/gdbserver/remote-utils.h
 create mode 100644 gdb/gdbserver/tracepoint.h
 create mode 100644 gdb/gdbserver/utils.h

-- 
1.7.11.7


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

end of thread, other threads:[~2013-09-06 10:09 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-03 20:26 [PATCH 0/9][gdbserver] Split server.h Pedro Alves
2013-09-03 20:26 ` [PATCH 1/9] [gdbserver] Delete _ macro (gettext) Pedro Alves
2013-09-03 20:26 ` [PATCH 7/9] [gdbserver] Split a new dll.h file out of server.h Pedro Alves
2013-09-05 20:50   ` Pedro Alves
2013-09-03 20:26 ` [PATCH 8/9] [gdbserver] Split a new event-loop.h " Pedro Alves
2013-09-03 20:26 ` [PATCH 5/9] [gdbserver] Split a new ax.h " Pedro Alves
2013-09-05 20:49   ` [PATCH 5/9] [gdbserver] Move bytecode compilation bits from server.h to ax.h. (was: Re: [PATCH 5/9] [gdbserver] Split a new ax.h file out of server.h.) Pedro Alves
2013-09-03 20:26 ` [PATCH 2/9] [gdbserver] Split a new remote-utils.h file out of server.h Pedro Alves
2013-09-03 20:26 ` [PATCH 3/9] [gdbserver] Split a new utils.h " Pedro Alves
2013-09-03 20:26 ` [PATCH 4/9] [gdbserver] Split a new tracepoint.h " Pedro Alves
2013-09-03 20:26 ` [PATCH 9/9] [gdbserver] Split a new hostio.h " Pedro Alves
2013-09-05 20:50   ` Pedro Alves
2013-09-03 20:54 ` [PATCH 6/9] [gdbserver] Split a new inferiors.h " Pedro Alves
2013-09-05 20:47 ` [COMMIT] Re: [PATCH 0/9][gdbserver] Split server.h Pedro Alves
2013-09-05 22:22   ` Pedro Alves
2013-09-05 23:52     ` Joel Brobecker
2013-09-06  5:47     ` Eli Zaretskii
2013-09-06  6:51       ` Ricard Wanderlof
2013-09-06  7:42         ` Eli Zaretskii
2013-09-06  9:36       ` Pedro Alves
2013-09-06 10:05         ` Agovic, Sanimir
2013-09-06 10:09           ` Pedro Alves

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