diff options
author | Mark Kettenis <kettenis@gnu.org> | 2000-03-05 22:57:06 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@gnu.org> | 2000-03-05 22:57:06 +0000 |
commit | f60300e72ce53498ec2d4e517360a1023485dbcc (patch) | |
tree | 69fae9e86849e077046b3b41c64dd6b4524218fa /gdb/configure.in | |
parent | 04cd15b61dc18a77b8a7359805400caa21f4189e (diff) | |
download | gdb-f60300e72ce53498ec2d4e517360a1023485dbcc.zip gdb-f60300e72ce53498ec2d4e517360a1023485dbcc.tar.gz gdb-f60300e72ce53498ec2d4e517360a1023485dbcc.tar.bz2 |
2000-03-05 Mark Kettenis <kettenis@gnu.org>
Allow GDB to run on Linux 2.0 again.
* config.in: Add HAVE_PTRACE_GETREGS.
* configure.in: Check if <sys/ptrace.h> defines PTRACE_GETREGS.
* configure: Regenerated.
* config/i386/nm-linux.h (CANNOT_FETCH_REGISTER,
CANNOT_STORE_REGISTER): New defines.
* i386-linux-nat.c (have_ptrace_getregs): New variable.
(PTRACE_XFER_TYPE, CANNOT_FETCH_REGISTER, fetch_register,
old_fetch_inferior_registers, CANNOT_STORE_REGISTER,
store_register, old_store_inferior_registers): Copied over from
`inptrace.c' as a temporary measure.
(fetch_regs, store_regs, fetch_fpregs, store_fpregs):
Conditionalize on HAVE_PTRACE_GETREGS. Define stubs if
HAVE_PTRACE_GETREGS isn't defined.
(fetch_regs): Reset `have_ptrace_getregs' if ptrace call fails
with EIO.
(fetch_inferior_registers, store_inferior_registers): Fall back on
the method use in `infptrace.c' (by calling
old_fetch_inferior_registers and old_store_inferior_registers) if
`have_ptrace_getregs' isn't set.
Diffstat (limited to 'gdb/configure.in')
-rw-r--r-- | gdb/configure.in | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/gdb/configure.in b/gdb/configure.in index ec4ac63..331f189 100644 --- a/gdb/configure.in +++ b/gdb/configure.in @@ -101,6 +101,18 @@ AC_C_CONST AC_CHECK_FUNCS(setpgid sbrk sigaction isascii bzero bcopy btowc poll sigprocmask) AC_FUNC_ALLOCA +dnl See if ptrace.h provides the PTRACE_GETREGS request. +AC_MSG_CHECKING(for PTRACE_GETREGS) +AC_CACHE_VAL(gdb_cv_have_ptrace_getregs, +[AC_TRY_COMPILE([#include <sys/ptrace.h>], + [PTRACE_GETREGS;], + [gdb_cv_have_ptrace_getregs=yes], + [gdb_cv_have_ptrace_getregs=no])]) +AC_MSG_RESULT($gdb_cv_have_ptrace_getregs) +if test $gdb_cv_have_ptrace_getregs = yes; then + AC_DEFINE(HAVE_PTRACE_GETREGS) +fi + dnl See if ptrace.h provides the PTRACE_GETXFPREGS request. dnl PTRACE_GETXFPREGS is a Cygnus invention, since we wrote our own dnl Linux kernel patch for SSE support. That patch may or may not |