This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 1/3 v4] Introduce common/errors.h
- From: Gary Benson <gbenson at redhat dot com>
- To: Pedro Alves <palves at redhat dot com>
- Cc: Doug Evans <dje at google dot com>, gdb-patches at sourceware dot org, Tom Tromey <tromey at redhat dot com>
- Date: Fri, 25 Jul 2014 13:14:02 +0100
- Subject: Re: [PATCH 1/3 v4] Introduce common/errors.h
- Authentication-results: sourceware.org; auth=none
- References: <1406206287-6817-1-git-send-email-gbenson at redhat dot com> <1406206287-6817-2-git-send-email-gbenson at redhat dot com> <53D1053E dot 6030902 at redhat dot com> <21457 dot 18385 dot 59886 dot 323894 at ruffy dot mtv dot corp dot google dot com> <20140725083642 dot GA4812 at blade dot nx> <53D22F22 dot 4030101 at redhat dot com> <20140725111653 dot GA6301 at blade dot nx> <53D2438C dot 8040009 at redhat dot com>
Pedro Alves wrote:
> On 07/25/2014 12:16 PM, Gary Benson wrote:
> > Pedro Alves wrote:
> > > On 07/25/2014 09:36 AM, Gary Benson wrote:
> > > > I'm working on this now. My plan is to have
> > > > gdb/common/common-defs.h (which includes config.h and the
> > > > correct gnulib config.h) and have defs.h and server.h include
> > > > common-defs.h as the first line. By the end of that series
> > > > most every file will include defs.h or server.h and no file
> > > > will include config.h.
> > >
> > > I think you meant, that files in gdb will include defs.h, files
> > > in gdbserver will include server.h, and files in the shared
> > > directories will include common-defs.h as the first line.
> >
> > Yes, eventually. I plan to submit an initial series, in which
> > common-defs.h only includes the two config.h files, and any files
> > not including either defs.h or server.h as their first line will
> > be fixed up. If that proves acceptable, I'll submit one or more
> > further series to move the various includes currently common to
> > defs.h and server.h into common-defs.h, and finally something to
> > switch common/target/nat files over to common-defs.h.
>
> Sounds good to me. I've distilled this into the wiki:
>
> https://sourceware.org/gdb/wiki/Common#Header_files_in_common_code_.28defs.h_vs_server.h.2C_etc..29
>
> Please do feel free to edit it / improve it.
>
> (obviously that can evolve if the plan is objected to and changes.)
Perfect, thanks for documenting this.
Cheers,
Gary
--
http://gbenson.net/