Mail Archives: djgpp/2003/01/07/05:52:47
On Thursday 02 January 2003 13:02, Richard Dawe wrote:
> Hello.
>
> andris AT hal DOT astr DOT lu DOT lv wrote:
> [snip]
>
> > I didn't have enough time to try to dig into more details and to find
> > where something is wrong in debug info. I only modify GDB not to generate
> > internal error in this case. Of course it's ugly, but I don't think that
> > there is another way before GCC is fixed.
>
> Yes, a work-around seems like the best way right now.
>
> > Unfortunatelly I don't have a workaround patch here around me now. So I
> > can send it only after I return to Finland next week (I'm currently in
> > Latvia for Christmass and New Year holydays)
>
> Since gdb 5.1.1 and 5.2.1 exhibit the same problem, I decided that the port
> of gdb 5.3 should be released anyway. When you get back, I'd be happy to do
> a new release of the port with your patch. Have a good holiday!
This problem were not present in 5.1.1 and 5.2.1.
I'm back in Finland, so can send patch I applied for gdb-5.3 prereleases. I put #ifdef __DJGPP__
there although I reproduced the same problem also under Linux when -imacros were used.
Andris
--- gdb+dejagnu-5.2.90_20020927/gdb/macrotab.c~1 2002-07-29 22:55:26.000000000 +0000
+++ gdb+dejagnu-5.2.90_20020927/gdb/macrotab.c 2002-09-28 16:24:58.000000000 +0000
@@ -272,7 +272,14 @@
{
/* They can't both be from #included files. Then we shouldn't
have walked up this far. */
+ /* FIXME: Workaround for GCC bug: it misinterprets include from line 1
+ as from line2 when -imacros is used (in this case both lines
+ could be 2) AP, 2002/09/28 */
+#if defined(__DJGPP__)
+ gdb_assert (! included1 || ! included2 || line1==2);
+#else
gdb_assert (! included1 || ! included2);
+#endif
/* Any #included position comes after a non-#included position
with the same line number in the #including file. */
- Raw text -