Hi, as a matter of good programming practice, you should compile with all warnings on.
Then, change the code so that no warnings are generated. Yes, this is a pain (fixing all those seemingly silly warnings) but you end up with better quality code. Further, there are times when a warning points out a code flaw. Consequently, the compile line should be gcc -g -Wall -o program program.c Derek. ========================================================================= On Thu, 10 Jun 2004, stm23 wrote: > hi steve, thanx for the help, its very much appreciated. i used your command: > > gcc -g -o program program.c > > before running ddd > > i had been using the command: gcc -o program program.c > > so it would seem that the -g option is the key! > > thanx again > sam > > >===== Original Message From [EMAIL PROTECTED] ===== > >stm23 wrote: > > > >>hi, sorry i already was using ddd program & (not ddd program.c & - as i had > >>mistakenly stated). i wish it were that simple :) > >> > >> > >> > >>>The debugger works on the compiled program, not the source. You need to > >>>run it against program, not program.c > >>> > >>> > >> > >> > >> > >> > >>>===== Original Message From [EMAIL PROTECTED] ===== > >>>stm23 wrote: > >>> > >>> > >>> > >>>hi, i'm trying to use ddd to debug my c file program.c. when i attempt to > >>>start ddd eg: > >>> > >>> ddd program.c & > >>> > >>>i get an error message in the ddd window: > >>> > >>> DDD No Source > >>> /mnt/FAT23/mydocs/sysdeps/i386/elf/start.S: No such file or directory > >>> > >>>i've checked & this file doesn't exist. why can't ddd accept my file > >>>program.c as the source. i've tryed googling a solution but to no avail. > >>>any1 experienced something similar, or know how to help me. i'd really > >>>appreciate it :) > >>>cheers, sam > >>> > >>> > >>> > >>> > >>> > >>> > >>> > >>>The debugger works on the compiled program, not the source. You need to > >>>run it against program, not program.c > >>> > >>>hth, > >>> > >>>Steve > >>> > >>> > >> > >> > >> > >> > >> > >are you using gcc -g -o program program.c ? > > > >Steve > > > -- Derek Smithies Ph.D. This PC runs pine on linux for email IndraNet Technologies Ltd. If you find a virus apparently from me, it has Email: [EMAIL PROTECTED] forged the e-mail headers on someone else's machine ph +64 3 365 6485 Please do not notify me when (apparently) receiving a Web: http://www.indranet-technologies.com/ windows virus from me......
