From mboxrd@z Thu Jan 1 00:00:00 1970 From: Keith Seitz To: Paul_Heijman@eu.omron.com Cc: insight@sourceware.cygnus.com Subject: Re: Insight exits abrupt when trying to view in ASM or MIXED mode. Date: Thu, 18 May 2000 08:55:00 -0000 Message-id: <3924126C.D7063160@firetalk.com> References: <412568E3.005B3A0E.00@eu.omron.com> X-SW-Source: 2000-q2/msg00194.html Paul_Heijman@eu.omron.com wrote: > > >When you say that you load the ".cof" file, are you loading symbols only > >or the executable with symbols? (Are you using Insight's > >File->Open/console window's "file" command or using the console command > >"add-symbol-file"?) > > I load the symbol file from the commandline: > GDB --baud=38400 -d=//O/Alt/Fwk/new/src -s=//O/Alt/Fwk/new/bin/framewrk.cof > -readnow > > The .cof file contains code information and also the symbol table. The file may contain code and symbols, but using "-s=..." will cause gdb to ONLY read symbols. This is why gdbtk was failing to disassemble anything. > The cases that I tried were when connected to the target. When not connected, i > don't manage to see any code, source nor assembly. It would make sense that you could not disassemble (and maybe even not see source). Like I said before, if you are not attached to a remote target, gdb (and gdbtk) will look at the code you've loaded to do disassembly. Since you didn't load any code, gdb couldn't show you anything. > I can look to the assembly code now, like you said I opened the cof-file > manually with File->Open. > After I connected to the target I could see the ASM-source! Cool! Not bad for my first guess. :-) > > Does this mean it will never work through the commandline ? > I also didn't provide the source-path in the commandline, so at the moment I > don't see the C-source. > No, you should be able to invoke gdb/Insight passing the file on the command line: $ gdb [args, sans the -s one] myExecutable.cof In general, the use of "add-symbol-file" and the "-s" command line flag should be used to read ADDITIONAL symbols into gdb. (Purists will say that this is not true, and they are correct. However, my experience with gdb, this advice has never failed.) Keith -- Why chat when you can Firetalk? Firetalk ID: Keith (10320) www.firetalk.com