]> granicus.if.org Git - strace/commitdiff
2004-03-01 Roland McGrath <roland@redhat.com>
authorRoland McGrath <roland@redhat.com>
Mon, 1 Mar 2004 21:29:24 +0000 (21:29 +0000)
committerRoland McGrath <roland@redhat.com>
Mon, 1 Mar 2004 21:29:24 +0000 (21:29 +0000)
* process.c (struct_user_offsets) [LINUX && IA64]: Conditionalize
PT_AR_CSD and PT_AR_SSD uses in case of older kernel headers.
* configure.ac: Check for `struct pt_all_user_regs'
and `struct ia64_fpreg' in <sys/ptrace.h>.
* util.c, process.c, syscall.c: Work around conflicts between
<sys/ptrace.h> and <linux/ptrace.h> for defining those types.

process.c

index 48237c3f718d9eab311dc9160858e6a3b1d8097b..464ef27a331e94331eaa269635ea44166c5e4205 100644 (file)
--- a/process.c
+++ b/process.c
 
 #ifdef HAVE_LINUX_PTRACE_H
 #undef PTRACE_SYSCALL
+# ifdef HAVE_STRUCT_IA64_FPREG
+#  define ia64_fpreg XXX_ia64_fpreg
+# endif
+# ifdef HAVE_STRUCT_PT_ALL_USER_REGS
+#  define pt_all_user_regs XXX_pt_all_user_regs
+# endif
 #include <linux/ptrace.h>
+# undef ia64_fpreg
+# undef pt_all_user_regs
 #endif
 
 #ifdef HAVE_LINUX_FUTEX_H
@@ -2459,7 +2467,12 @@ struct xlat struct_user_offsets[] = {
        { PT_AR_CCV, "ar.ccv" }, { PT_AR_FPSR, "ar.fpsr" },
        { PT_B0, "b0" }, { PT_B7, "b7" }, { PT_F6, "f6" },
        { PT_F7, "f7" }, { PT_F8, "f8" }, { PT_F9, "f9" },
-       { PT_AR_CSD, "ar.csd" }, { PT_AR_SSD, "ar.ssd" },
+# ifdef PT_AR_CSD
+       { PT_AR_CSD, "ar.csd" },
+# endif
+# ifdef PT_AR_SSD
+       { PT_AR_SSD, "ar.ssd" },
+# endif
        { PT_DBR, "dbr" }, { PT_IBR, "ibr" }, { PT_PMD, "pmd" },
 #else /* !IA64 */
 #ifdef I386