diff options
Diffstat (limited to 'packages/gdb/7.11.1')
-rw-r--r-- | packages/gdb/7.11.1/0004-include-order.patch | 43 | ||||
-rw-r--r-- | packages/gdb/7.11.1/0005-include-gregset.h.patch | 73 |
2 files changed, 116 insertions, 0 deletions
diff --git a/packages/gdb/7.11.1/0004-include-order.patch b/packages/gdb/7.11.1/0004-include-order.patch new file mode 100644 index 0000000..c2f5952 --- /dev/null +++ b/packages/gdb/7.11.1/0004-include-order.patch @@ -0,0 +1,43 @@ +commit 5a6c3296a7a90694ad4042f6256f3da6d4fa4ee8 +Author: James Clarke <jrtc27@jrtc27.com> +Date: Fri Jan 19 17:22:49 2018 +0000 + + 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. + +--- + gdb/nat/linux-ptrace.c | 2 -- + gdb/nat/linux-ptrace.h | 1 + + 2 files changed, 1 insertion(+), 2 deletions(-) + +--- 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" + + /* Stores the ptrace options supported by the running kernel. + A value of -1 means we did not check for features yet. A value +--- 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__)) diff --git a/packages/gdb/7.11.1/0005-include-gregset.h.patch b/packages/gdb/7.11.1/0005-include-gregset.h.patch new file mode 100644 index 0000000..9a588ba --- /dev/null +++ b/packages/gdb/7.11.1/0005-include-gregset.h.patch @@ -0,0 +1,73 @@ +commit 31925464a80970e37c06192a0c49f8948a2f5da0 +Author: Matthew Wahab <matthew.wahab@arm.com> +Date: Mon Aug 15 13:09:04 2016 +0100 + + [GDB] Fix builds broken by proc-service changes. + + GLIBC BZ#20311 introduced a change to install proc_service.h so that gdb + didn't have to use the version it embeds in gdb_proc_service.h. The + embedded version is guarded by HAVE_PROC_SERVICE_H and + gdb_proc_service.h has a number other of includes and definitions, all + of which are uncondional except for an include for gregset.h. This is + only included if HAVE_PROC_SERIVCE_H is not defined. + + This causes a build failure when cross compiling gdb with the latest + glibc because type definitions in gregset are used independently of + HAVE_PROC_SERIVCE_H. In particular, they are used in gdb_proc_service.h + when PRFPREGSET_T_BROKEN is set. + + The error messages on the failure are + ---- + binutils-gdb/gdb/gdb_proc_service.h:173:9: error: ‘gdb_fpregset_t’ does + not name a type; did you mean ‘elf_fpregset_t’? + typedef gdb_fpregset_t gdb_prfpregset_t; + ^~~~~~~~~~~~~~ + elf_fpregset_t + + binutils-gdb/gdb/gdb_proc_service.h:173:9: error: ‘gdb_fpregset_t’ does + not name a type; did you mean ‘elf_fpregset_t’? + typedef gdb_fpregset_t gdb_prfpregset_t; + ^~~~~~~~~~~~~~ + elf_fpregset_t + + binutils-gdb/gdb/proc-service.c:218:15: error: ‘gdb_prfpregset_t’ does + not name a type; did you mean ‘gdb_fpregset_t’? + const gdb_prfpregset_t *fpregset) + ^~~~~~~~~~~~~~~~ + gdb_fpregset_t + ---- + + This patch moves the include for gregset.h to before the code guarded by + HAVE_PROC_SERIVCE_H, so that it is always included. This is enough to + fix the build. + + 2016-08-15 Matthew Wahab <matthew.wahab@arm.com> + + PR gdb/20457 + * gdb_proc_service.h: Add an include of gregset.h + [!HAVE_PROC_SERVICE_H]: Remove the include of gregset.h. + +--- + gdb/gdb_proc_service.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +--- a/gdb/gdb_proc_service.h ++++ b/gdb/gdb_proc_service.h +@@ -21,6 +21,8 @@ + + #include <sys/types.h> + ++#include "gregset.h" ++ + #ifdef HAVE_PROC_SERVICE_H + + /* glibc's proc_service.h doesn't wrap itself with extern "C". Need +@@ -60,8 +62,6 @@ + #include <sys/procfs.h> + #endif + +-#include "gregset.h" +- + EXTERN_C_PUSH + + /* Functions in this interface return one of these status codes. */ |