This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
patch for aix 4.3.3.07 support
- To: gdb-patches at sources dot redhat dot com
- Subject: patch for aix 4.3.3.07 support
- From: Geoff Keating <geoffk at geoffk dot org>
- Date: Fri, 23 Mar 2001 13:34:53 -0800
- Reply-to: Geoff Keating <geoffk at redhat dot com>
One of the changes in the 4.3.3.07 AIX maintenance release was
this code added to sys/ptrace.h:
/*
* Linux compatibility section.
* Define the Linux __ptrace_request enum. This is not
* ifdef'd because the library wrapper needs to see the enum
* without the _LINUX_SOURCE_COMPAT redefines of the PT_* values.
*/
enum __ptrace_request {
PTRACE_TRACEME,
PTRACE_PEEKTEXT,
PTRACE_PEEKDATA,
PTRACE_PEEKUSER,
PTRACE_POKETEXT,
PTRACE_POKEDATA,
PTRACE_POKEUSER,
PTRACE_CONT,
PTRACE_KILL,
PTRACE_SINGLESTEP,
PTRACE_GETREGS,
PTRACE_SETREGS,
PTRACE_GETFPREGS,
PTRACE_SETFPREGS,
PTRACE_ATTACH,
PTRACE_DETACH,
PTRACE_SYSCALL
};
Of course, these are not the same values as PT_ATTACH and PT_DETACH
(which are 30 and 31 respectively), and these values are not valid
unless you use __linux_ptrace() (which is #defined to be ptrace() if
you supply the right -D flag, which we don't want to do). Happily,
gdb doesn't actually use PTRACE_ATTACH or PTRACE_DETACH anywhere, so
the only immediate problem is the #define.
Tested on powerpc-aix4.3.3; the attach.exp test passed. OK to commit?
--
- Geoffrey Keating <geoffk@geoffk.org>
===File ~/patches/cygnus/gdb-aixptraceattach.patch==========
2001-03-21 Geoffrey Keating <geoffk@redhat.com>
* config/rs6000/nm-rs6000.h (PTRACE_ATTACH): Don't define.
(PTRACE_DETACH): Don't define.
Index: gdb/config/rs6000/nm-rs6000.h
===================================================================
RCS file: /cvs/src/src/gdb/config/rs6000/nm-rs6000.h,v
retrieving revision 1.6
diff -p -u -p -r1.6 nm-rs6000.h
--- nm-rs6000.h 2001/03/06 08:21:35 1.6
+++ nm-rs6000.h 2001/03/23 21:29:05
@@ -23,9 +23,6 @@
#define ATTACH_DETACH
-#define PTRACE_ATTACH PT_ATTACH
-#define PTRACE_DETACH PT_DETACH
-
/* Override copies of {fetch,store}_inferior_registers in infptrace.c. */
#define FETCH_INFERIOR_REGISTERS
============================================================