From 63d5c71bc992550edac170a02f530bc20c98fd14 Mon Sep 17 00:00:00 2001 From: Mark Kettenis Date: Sun, 26 Sep 2004 18:42:30 +0000 Subject: * amd64-nat.h: Update copyright year. (amd64bsd_target): New prototype. * amd64bsd-nat.c: Include "target.h" and "inf-ptrace.h". (amd64bsd_target): New function. (amd64bsd_fetch_inferior_registers): Rename from fetch_inferior_registers. Make static. (amd64bsd_store_inferior_registers): Rename from store_inferior_registers. Make static. * amd64fbsd-nat.c: Include "target.h" and "fbsd-nat.h". (_initialize_amd64fbsd_nat): Construct and add target vector. * amd64nbsd-nat.o: Include "target.h". (_initialize_amd64nbsd_nat): Construct and add target vector. * amd64obsd-nat.c: Include "target.h". (_initialize_amd64obsd_nat): Construct and add target vector. * config/i386/nm-fbsd64.h (CHILD_PID_TO_EXEC_FILE): Remove define. * config/i386/fbsd64.mh (NATDEPFILES): Remove infptrace.o, inftarg.o and fbsd-proc.o. Add inf-child.o, inf-ptrace.o and fbsd-nat.o. * config/i386/nbsd64.mh, config/i386/obsd64.mh (NATDEPFILES): Remove infptrace.o and inftarg.o. Add inf-child.o and inf-ptrace.o. * Makefile.in (amd64bsd-nat.o, amd64fbsd-nat.o, amd64nbsd-nat.o) (amd64obsd-nat.o): Update dependencies. --- gdb/amd64fbsd-nat.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'gdb/amd64fbsd-nat.c') diff --git a/gdb/amd64fbsd-nat.c b/gdb/amd64fbsd-nat.c index caeaee9a75a..b7787612ac7 100644 --- a/gdb/amd64fbsd-nat.c +++ b/gdb/amd64fbsd-nat.c @@ -22,6 +22,7 @@ #include "defs.h" #include "inferior.h" #include "regcache.h" +#include "target.h" #include "gdb_assert.h" #include @@ -31,6 +32,7 @@ #include #include +#include "fbsd-nat.h" #include "amd64-tdep.h" #include "amd64-nat.h" @@ -138,11 +140,22 @@ void _initialize_amd64fbsd_nat (void); void _initialize_amd64fbsd_nat (void) { + struct target_ops *t; int offset; amd64_native_gregset32_reg_offset = amd64fbsd32_r_reg_offset; amd64_native_gregset64_reg_offset = amd64fbsd64_r_reg_offset; + /* Add some extra features to the common *BSD/i386 target. */ + t = amd64bsd_target (); + 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; + add_target (t); + + /* Support debugging kernel virtual memory images. */ + bsd_kvm_add_target (amd64fbsd_supply_pcb); + /* To support the recognition of signal handlers, i386bsd-tdep.c hardcodes some constants. Inclusion of this file means that we are compiling a native debugger, which means that we can use the @@ -219,7 +232,4 @@ Please report this to .", amd64fbsd_sigtramp_end_addr = ps_strings; } } - - /* Support debugging kernel virtual memory images. */ - bsd_kvm_add_target (amd64fbsd_supply_pcb); } -- cgit v1.2.1