aboutsummaryrefslogtreecommitdiffstats
path: root/devel/gdb/files/patch-gdb-amd64fbsd-nat.c
diff options
context:
space:
mode:
authorscheidell <scheidell@FreeBSD.org>2012-02-25 19:57:56 +0800
committerscheidell <scheidell@FreeBSD.org>2012-02-25 19:57:56 +0800
commit38ab23a72e09f54062951499211d04ef2f3afc3e (patch)
treeeb1d9a6109796cbc6b4e796f9251665c04d4ec61 /devel/gdb/files/patch-gdb-amd64fbsd-nat.c
parent98fcd8cf5ce2fd4eff6fac32ad96884f399f8f57 (diff)
downloadfreebsd-ports-gnome-38ab23a72e09f54062951499211d04ef2f3afc3e.tar.gz
freebsd-ports-gnome-38ab23a72e09f54062951499211d04ef2f3afc3e.tar.zst
freebsd-ports-gnome-38ab23a72e09f54062951499211d04ef2f3afc3e.zip
- Adds HW watchpoint support for amd64, closing ports/160930 (thanks to Ben Morrow)
- Adds a symbolic link executable with the version suffix to support tools without debugger configuration (like devel/nemiver) - Bump PORTREVISION due to track changes to options and pkg-plist PR: ports/165357 Submitted by: Luca Pizzamiglio <luca.pizzamiglio@gmail.com> (maintainer) Approved by: gabor (mentor, implicit)
Diffstat (limited to 'devel/gdb/files/patch-gdb-amd64fbsd-nat.c')
-rw-r--r--devel/gdb/files/patch-gdb-amd64fbsd-nat.c35
1 files changed, 32 insertions, 3 deletions
diff --git a/devel/gdb/files/patch-gdb-amd64fbsd-nat.c b/devel/gdb/files/patch-gdb-amd64fbsd-nat.c
index e2a759a084a5..12723c3af44b 100644
--- a/devel/gdb/files/patch-gdb-amd64fbsd-nat.c
+++ b/devel/gdb/files/patch-gdb-amd64fbsd-nat.c
@@ -1,5 +1,5 @@
---- gdb/amd64fbsd-nat.c.orig 2010-10-13 14:53:14.425152000 -0400
-+++ gdb/amd64fbsd-nat.c 2010-10-13 15:15:01.080198000 -0400
+--- gdb/amd64fbsd-nat.c.orig 2010-02-03 15:30:25.000000000 +0000
++++ gdb/amd64fbsd-nat.c 2011-09-23 03:08:51.942111416 +0100
@@ -27,6 +27,7 @@
#include <signal.h>
#include <stddef.h>
@@ -8,7 +8,16 @@
#include <sys/ptrace.h>
#include <sys/sysctl.h>
#include <machine/reg.h>
-@@ -92,6 +93,47 @@
+@@ -34,6 +35,8 @@
+ #include "fbsd-nat.h"
+ #include "amd64-tdep.h"
+ #include "amd64-nat.h"
++#include "amd64bsd-nat.h"
++#include "i386-nat.h"
+
+
+ /* Offset in `struct reg' where MEMBER is stored. */
+@@ -92,6 +95,47 @@
};
@@ -56,3 +65,23 @@
/* Support for debugging kernel virtual memory images. */
#include <sys/types.h>
+@@ -155,6 +199,19 @@
+
+ /* Add some extra features to the common *BSD/i386 target. */
+ t = amd64bsd_target ();
++
++#ifdef HAVE_PT_GETDBREGS
++
++ i386_use_watchpoints (t);
++
++ i386_dr_low.set_control = amd64bsd_dr_set_control;
++ i386_dr_low.set_addr = amd64bsd_dr_set_addr;
++ i386_dr_low.reset_addr = amd64bsd_dr_reset_addr;
++ i386_dr_low.get_status = amd64bsd_dr_get_status;
++ i386_set_debug_register_length (8);
++
++#endif /* HAVE_PT_GETDBREGS */
++
+ t->to_pid_to_exec_file = fbsd_pid_to_exec_file;
+ t->to_find_memory_regions = fbsd_find_memory_regions;
+ t->to_make_corefile_notes = fbsd_make_corefile_notes;