bug-gdb
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

partial fix for Tru64 5.1


From: Dave Love
Subject: partial fix for Tru64 5.1
Date: 02 Nov 2001 12:36:13 +0000
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.0.107

This change, against a 20011007 snapshot, allows gdb to build on a
Tru64 (OSF) 5.1 system.  The system headers have changed compared with
5.0a.  I don't know whether alpha/coreregs.h is present on other
systems, hence the autoconf test.

It doesn't yet run properly -- `Error reading symbol table: File truncated'.
I'll try to debug that.

2001-11-01  Dave Love  <address@hidden>

        Account for a change from OSF 5.0a to 5.1.

        * configure.in: Test for alpha/coreregs.h.

        * alpha-nat.c <HAVE_ALPHA_COREREGS_H>: Include alpha/coreregs.h,
        not machine/reg.h.
        (fetch_osf_core_registers) <NCF_REGS>: Use CF_ macros, not EF_
        ones.

===================================================================
RCS file: configure.in,v
retrieving revision 1.1
diff -u -r1.1 configure.in
--- configure.in        2001/11/01 15:09:25     1.1
+++ configure.in        2001/11/01 15:09:33
@@ -124,7 +124,7 @@
        term.h termio.h termios.h unistd.h wait.h sys/wait.h \
        wchar.h wctype.h asm/debugreg.h sys/debugreg.h sys/select.h \
        time.h sys/file.h sys/ioctl.h sys/user.h sys/fault.h sys/syscall.h \
-       dirent.h sys/ndir.h sys/dir.h ndir.h \
+       dirent.h sys/ndir.h sys/dir.h ndir.h alpha/coreregs.h \
        curses.h ncurses.h \
        poll.h sys/poll.h)
 AC_HEADER_STAT
===================================================================
RCS file: alpha-nat.c,v
retrieving revision 1.1
diff -u -r1.1 alpha-nat.c
--- alpha-nat.c 2001/11/01 14:38:10     1.1
+++ alpha-nat.c 2001/11/01 14:58:27
@@ -29,7 +29,11 @@
 #include <asm/reg.h>
 #include <alpha/ptrace.h>
 #else
-#include <machine/reg.h>
+# ifdef HAVE_ALPHA_COREREGS_H
+#  include <alpha/coreregs.h>
+# else
+#  include <machine/reg.h>
+# endif
 #endif
 #include <sys/user.h>
 
@@ -97,6 +101,18 @@
      The floating point register values are garbage in OSF/1.2 core files.  */
   static int core_reg_mapping[NUM_REGS] =
   {
+#ifdef NCF_REGS                        /* defined in OSF 5.1 */
+#define CFL (NCF_REGS)
+    CF_V0, CF_T0, CF_T1, CF_T2, CF_T3, CF_T4, CF_T5, CF_T6,
+    CF_T7, CF_S0, CF_S1, CF_S2, CF_S3, CF_S4, CF_S5, CF_S6,
+    CF_A0, CF_A1, CF_A2, CF_A3, CF_A4, CF_A5, CF_T8, CF_T9,
+    CF_T10, CF_T11, CF_RA, CF_T12, CF_AT, CF_GP, CF_SP, -1,
+    CFL + 0, CFL + 1, CFL + 2, CFL + 3, CFL + 4, CFL + 5, CFL + 6, CFL + 7,
+    CFL + 8, CFL + 9, CFL + 10, CFL + 11, CFL + 12, CFL + 13, CFL + 14, CFL + 
15,
+    CFL + 16, CFL + 17, CFL + 18, CFL + 19, CFL + 20, CFL + 21, CFL + 22, CFL 
+ 23,
+    CFL + 24, CFL + 25, CFL + 26, CFL + 27, CFL + 28, CFL + 29, CFL + 30, CFL 
+ 31,
+    CF_PC, -1
+#else
 #define EFL (EF_SIZE / 8)
     EF_V0, EF_T0, EF_T1, EF_T2, EF_T3, EF_T4, EF_T5, EF_T6,
     EF_T7, EF_S0, EF_S1, EF_S2, EF_S3, EF_S4, EF_S5, EF_S6,
@@ -107,6 +123,7 @@
     EFL + 16, EFL + 17, EFL + 18, EFL + 19, EFL + 20, EFL + 21, EFL + 22, EFL 
+ 23,
     EFL + 24, EFL + 25, EFL + 26, EFL + 27, EFL + 28, EFL + 29, EFL + 30, EFL 
+ 31,
     EF_PC, -1
+#endif
   };
   static char zerobuf[MAX_REGISTER_RAW_SIZE] =
   {0};



reply via email to

[Prev in Thread] Current Thread [Next in Thread]