From: James Clarke Date: Fri, 19 Jan 2018 17:22:49 +0000 (+0000) Subject: gdb: Fix ia64 defining TRAP_HWBKPT before including gdb_wait.h X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5a6c3296a7a90694ad4042f6256f3da6d4fa4ee8;p=binutils-gdb.git gdb: Fix ia64 defining TRAP_HWBKPT before including gdb_wait.h On ia64, gdb_wait.h eventually includes siginfo-consts-arch.h, which contains an enum with TRAP_HWBKPT, along with a #define. Thus we cannot define TRAP_HWBKPT to 4 beforehand, and so gdb_wait.h must be included earlier; include it from linux-ptrace.h so it can never come afterwards. gdb/ChangeLog: * nat/linux-ptrace.c: Remove unnecessary reinclusion of gdb_ptrace.h, and move including gdb_wait.h ... * nat/linux-ptrace.h: ... to here. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 5467e89c604..e274caa4255 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2018-01-19 James Clarke + + * nat/linux-ptrace.c: Remove unnecessary reinclusion of + gdb_ptrace.h, and move including gdb_wait.h ... + * nat/linux-ptrace.h: ... to here. + 2018-01-19 Simon Marchi * inf-ptrace.c (inf_ptrace_detach): Adjust call to diff --git a/gdb/nat/linux-ptrace.c b/gdb/nat/linux-ptrace.c index 5c4ddc95909..1f21ef03a39 100644 --- a/gdb/nat/linux-ptrace.c +++ b/gdb/nat/linux-ptrace.c @@ -21,8 +21,6 @@ #include "linux-procfs.h" #include "linux-waitpid.h" #include "buffer.h" -#include "gdb_wait.h" -#include "gdb_ptrace.h" #ifdef HAVE_SYS_PROCFS_H #include #endif diff --git a/gdb/nat/linux-ptrace.h b/gdb/nat/linux-ptrace.h index 60967a3b6aa..dc180fbf82a 100644 --- a/gdb/nat/linux-ptrace.h +++ b/gdb/nat/linux-ptrace.h @@ -21,6 +21,7 @@ struct buffer; #include "nat/gdb_ptrace.h" +#include "gdb_wait.h" #ifdef __UCLIBC__ #if !(defined(__UCLIBC_HAS_MMU__) || defined(__ARCH_HAS_MMU__))