This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: GDB 6.5 RTEMS patch


Daniel Jacobowitz wrote:

On Thu, Jul 13, 2006 at 03:41:19PM -0500, Joel Sherrill wrote:


diff -uNr /home/joel/tools-original/gdb-6.5/bfd/sysdep.h gdb-6.5/bfd/sysdep.h
--- /home/joel/tools-original/gdb-6.5/bfd/sysdep.h	2005-05-05 13:51:14.000000000 -0500
+++ gdb-6.5/bfd/sysdep.h	2006-07-13 10:00:00.000000000 -0500
@@ -135,7 +135,7 @@
#endif

#if !HAVE_DECL_STRSTR
-extern char *strstr ();
+/* extern char *strstr (); */
#endif

#ifdef HAVE_FTELLO



What's this for? Shouldn't be necessary, of course.





Yep. That's looks like junk leftover.


I can tell you what used to be there. :) We build RPMs on RH73 so all subsequent RH and
Fedora Core versions can use them. There are a lot of gcc versions installed into /opt
in that environment and some gcc version wouldn't build gdb and failed at that line for
reasons I could never explain. That is a leftover hack that should be ignored. I am sorry for \
leaving it in there.


diff -uNr /home/joel/tools-original/gdb-6.5/sim/erc32/exec.c gdb-6.5/sim/erc32/exec.c
--- /home/joel/tools-original/gdb-6.5/sim/erc32/exec.c	2005-03-07 05:09:05.000000000 -0600
+++ gdb-6.5/sim/erc32/exec.c	2006-07-13 10:00:00.000000000 -0500
@@ -1713,7 +1713,7 @@
    	    sregs->fdp[rs2 | 1] = sregs->fs[rs2 & ~1];
    	    sregs->fdp[rs2 & ~1] = sregs->fs[rs2 | 1];
    default:
-      ;
+      break;
    }
#endif

@@ -1886,7 +1886,7 @@
sregs->fs[rd & ~1] = sregs->fdp[rd | 1];
sregs->fs[rd | 1] = sregs->fdp[rd & ~1];
default:
- ;
+ break;
}
#endif
if (sregs->fpstate == FP_EXC_PE) {



Are you sure these are still needed? I thought that "default: }" was
bad, but "default: ;}" was fine.


Checking all the gcc's I have installed, that does seem to be the case. Adding the
";" let's gcc know default wasn't a label.


But why wouldn't you want an explicit break?

--joel


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]