blob: ef97de777223dc830c0b68edac4ebd2cd57177a7 [file] [log] [blame]
Brad Bishop00111322018-04-01 22:23:53 -04001From b033a9663053eed87cb572397176747b88e9a699 Mon Sep 17 00:00:00 2001
2From: James Clarke <jrtc27@jrtc27.com>
3Date: Fri, 19 Jan 2018 17:22:49 +0000
4Subject: [PATCH] gdb: Fix ia64 defining TRAP_HWBKPT before including
5 gdb_wait.h
6MIME-Version: 1.0
7Content-Type: text/plain; charset=UTF-8
8Content-Transfer-Encoding: 8bit
9
10On ia64, gdb_wait.h eventually includes siginfo-consts-arch.h, which
11contains an enum with TRAP_HWBKPT, along with a #define. Thus we cannot
12define TRAP_HWBKPT to 4 beforehand, and so gdb_wait.h must be included
13earlier; include it from linux-ptrace.h so it can never come afterwards.
14
15gdb/ChangeLog:
16
17 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
18 gdb_ptrace.h, and move including gdb_wait.h ...
19 * nat/linux-ptrace.h: ... to here.
20
21Upstream-Status: Accepted [https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commit;h=5a6c3296a7a90694ad4042f6256f3da6d4fa4ee8]
22
23Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org>
24---
25 gdb/nat/linux-ptrace.c | 2 --
26 gdb/nat/linux-ptrace.h | 1 +
27 2 files changed, 1 insertion(+), 2 deletions(-)
28
29diff --git a/gdb/nat/linux-ptrace.c b/gdb/nat/linux-ptrace.c
30index 3265b16..559c2de 100644
31--- a/gdb/nat/linux-ptrace.c
32+++ b/gdb/nat/linux-ptrace.c
33@@ -21,8 +21,6 @@
34 #include "linux-procfs.h"
35 #include "linux-waitpid.h"
36 #include "buffer.h"
37-#include "gdb_wait.h"
38-#include "gdb_ptrace.h"
39 #ifdef HAVE_SYS_PROCFS_H
40 #include <sys/procfs.h>
41 #endif
42diff --git a/gdb/nat/linux-ptrace.h b/gdb/nat/linux-ptrace.h
43index 5954945..6faa89b 100644
44--- a/gdb/nat/linux-ptrace.h
45+++ b/gdb/nat/linux-ptrace.h
46@@ -21,6 +21,7 @@
47 struct buffer;
48
49 #include "nat/gdb_ptrace.h"
50+#include "gdb_wait.h"
51
52 #ifdef __UCLIBC__
53 #if !(defined(__UCLIBC_HAS_MMU__) || defined(__ARCH_HAS_MMU__))
54--
552.7.4
56