This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v2 01/13] btrace: add struct btrace_data


On 11/20/2014 10:47 AM, Markus Metzger wrote:

> diff --git a/gdb/common/btrace-common.c b/gdb/common/btrace-common.c
> new file mode 100644
> index 0000000..869d0cb
> --- /dev/null
> +++ b/gdb/common/btrace-common.c
> @@ -0,0 +1,82 @@
> +/* Copyright (C) 2014 Free Software Foundation, Inc.
> +
> +   Contributed by Intel Corp. <markus.t.metzger@intel.com>
> +
> +   This file is part of GDB.
> +
> +   This program is free software; you can redistribute it and/or modify
> +   it under the terms of the GNU General Public License as published by
> +   the Free Software Foundation; either version 3 of the License, or
> +   (at your option) any later version.
> +
> +   This program is distributed in the hope that it will be useful,
> +   but WITHOUT ANY WARRANTY; without even the implied warranty of
> +   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
> +   GNU General Public License for more details.
> +
> +   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 "btrace-common.h"

https://sourceware.org/gdb/wiki/Internals%20GDB-C-Coding-Standards#Include_Files

 "All .c files under gdb/common/, gdb/nat/ and gdb/target/ must include common-defs.h
 as their first non-comment line."

> diff --git a/gdb/common/btrace-common.h b/gdb/common/btrace-common.h
> index 339e684..27e7a95 100644
> --- a/gdb/common/btrace-common.h
> +++ b/gdb/common/btrace-common.h
> @@ -26,6 +26,7 @@
>     inferior.  For presentation purposes, the branch trace is represented as a
>     list of sequential control-flow blocks, one such list per thread.  */
>  
> +#include "common-defs.h"
>  #include "vec.h"

 "No .h file should include defs.h, server.h or common-defs.h."

Thanks,
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]