delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/07/14/16:12:34

Message-Id: <m0wnln6-000S1dC@inti.edu.ar>
Comments: Authenticated sender is <salvador AT natacha DOT inti DOT edu DOT ar>
From: "Salvador Eduardo Tropea (SET)" <salvador AT inti DOT edu DOT ar>
Organization: INTI
To: Dino Miniutti <miniutti AT macrae DOT com DOT au>
Date: Mon, 14 Jul 1997 17:28:38 +0000
MIME-Version: 1.0
Subject: Re: Newbie needs help with GDB
CC: djgpp AT delorie DOT com

Dino Miniutti <miniutti AT macrae DOT com DOT au> wrote:

> I'm currently having trouble getting to grips with GDB.
> 
> I start GDB and use the "file" command to load my executable (mass.exe -
> short for masscombat).
> 
> I then try to debug the program by stepping through it, but the problem
> is that when I reach a function that is #included from another of my
> files (masscom.c) I get the message:
> 
> line number 62 is out of range; mass.c has 31 lines.
> 
> So, I was wondering how you actually get GDB to step into functions
> included from other files.
> 
>         Thanks in advance Dino Miniutti.
> 
> PS. Sorry if this was off-topic for this newsgroup, but I didn't know
> where else to ask.
Isn't of topic if you are using the DJGPP package, if not don't read my answer.

That's a limitation of the COFF debug info. DJGPP is configured to generate 
this kind of debug information. You can configure the compiler to produce stabs 
debug info, but for this you'll need to recompile the compiler.

As you say you are a newbie perhaps is better if you simply avoid code in your
includes. If you can't do it read the next.

If you have the time for it go to my home page and get the patchs for gcc 
(Robert Hoehne wrotte the patch), apply it to the files from gcc2721s.zip and 
recompile it. There are a readme to compile the compiler READ IT. One important 
thing is editing the makefile to configure the compiler flags used to compile 
the compiler. Put out the -g and add -O2 or any other optimization switch.


Good luck, SET
------------------------------------ 0 --------------------------------
Visit my home page: http://www.geocities.com/SiliconValley/Vista/6552/
Salvador Eduardo Tropea (SET). (Electronics Engineer)
Address: Curapaligue 2124, Caseros, 3 de Febrero
Buenos Aires, (1678), ARGENTINA
TE: +(541) 759 0013

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019