* "Junk at end of arguments." when setting breakpoint @ 2008-06-12 20:43 Dean Tsai 2008-06-12 20:57 ` Michael Snyder 0 siblings, 1 reply; 12+ messages in thread From: Dean Tsai @ 2008-06-12 20:43 UTC (permalink / raw) To: gdb Got a question about using gdb. It is probably something really straightforward so all you experts please help~ When I issue a breakpoint with "b filename:linenumber", I got the "Junk at end of arguments." error. What does that mean? And what may have caused it? I have been using gdb for the last few months on a linux machine, and I didn't have this problem. But I couldn't get it to work on my new machine, MacBookPro 10.5 Leopard, running GNU gdb 6.3.50-20050815 (Apple version gdb-768). Thanks in advance, -Dean ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-12 20:43 "Junk at end of arguments." when setting breakpoint Dean Tsai @ 2008-06-12 20:57 ` Michael Snyder 2008-06-12 21:04 ` Dean Tsai 0 siblings, 1 reply; 12+ messages in thread From: Michael Snyder @ 2008-06-12 20:57 UTC (permalink / raw) To: Dean Tsai; +Cc: gdb On Thu, 2008-06-12 at 16:43 -0400, Dean Tsai wrote: > Got a question about using gdb. It is probably something really > straightforward so all you experts please help~ > > When I issue a breakpoint with "b filename:linenumber", I got the > "Junk at end of arguments." error. What does that mean? And what may > have caused it? I have been using gdb for the last few months on a > linux machine, and I didn't have this problem. But I couldn't get it > to work on my new machine, MacBookPro 10.5 Leopard, running GNU gdb > 6.3.50-20050815 (Apple version gdb-768). It probably means that gdb mis-parsed the "filename:linenumber" argument. Can you show us specifically what that was? ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-12 20:57 ` Michael Snyder @ 2008-06-12 21:04 ` Dean Tsai 2008-06-12 21:07 ` Michael Snyder 0 siblings, 1 reply; 12+ messages in thread From: Dean Tsai @ 2008-06-12 21:04 UTC (permalink / raw) To: Michael Snyder; +Cc: gdb Hi Michael, I am not sure exactly what you meant, but this is what I did to create the problem (see below). 42init.c actually resides in ./Source/ but I don't think it matter, does it? Thanks! -Dean LM220008151:42_SDP_tmp dtsai$ gdb 42 GNU gdb 6.3.50-20050815 (Apple version gdb-768) (Tue Oct 2 04:07:49 UTC 2007) Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i386-apple-darwin"...Reading symbols for shared libraries ...... done (gdb) b 42init.c:14 Junk at end of arguments. (gdb) pwd Working directory /Users/dtsai/work/42_SDP_tmp. (gdb) ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-12 21:04 ` Dean Tsai @ 2008-06-12 21:07 ` Michael Snyder 2008-06-12 21:22 ` Dean Tsai 0 siblings, 1 reply; 12+ messages in thread From: Michael Snyder @ 2008-06-12 21:07 UTC (permalink / raw) To: Dean Tsai; +Cc: gdb On Thu, 2008-06-12 at 17:04 -0400, Dean Tsai wrote: > Hi Michael, > > I am not sure exactly what you meant, but this is what I did to create > the problem (see below). 42init.c actually resides in ./Source/ but I > don't think it matter, does it? > Dean, Just a guess here, but could you try renaming 42init.c to some name that doesn't begin with a numeral? Wondering if gdb is trying to parse it as a number... If that does turn out to make a difference, you've got a genuine bug and we'll undertake to fix it. ;-) > LM220008151:42_SDP_tmp dtsai$ gdb 42 > > GNU gdb 6.3.50-20050815 (Apple version gdb-768) (Tue Oct 2 04:07:49 UTC 2007) > Copyright 2004 Free Software Foundation, Inc. > GDB is free software, covered by the GNU General Public License, and you are > welcome to change it and/or distribute copies of it under certain conditions. > Type "show copying" to see the conditions. > There is absolutely no warranty for GDB. Type "show warranty" for details. > This GDB was configured as "i386-apple-darwin"...Reading symbols for > shared libraries ...... done > > (gdb) b 42init.c:14 > Junk at end of arguments. > > (gdb) pwd > Working directory /Users/dtsai/work/42_SDP_tmp. > > (gdb) ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-12 21:07 ` Michael Snyder @ 2008-06-12 21:22 ` Dean Tsai 2008-06-12 21:42 ` Nick Roberts 2008-06-13 6:42 ` Eli Zaretskii 0 siblings, 2 replies; 12+ messages in thread From: Dean Tsai @ 2008-06-12 21:22 UTC (permalink / raw) To: Michael Snyder; +Cc: gdb Unfortunately Michael, changing the leading filename to string didn't help. I have changed 42init.c to tmp42init.c, changed my Makefile, make clean, make...etc. The same problem persists. Would the following offer you additional insights? b filename:functionname works!! (gdb) b 42init.c:InitSim Breakpoint 1 at 0x10b90: file 42init.c, line 19. (gdb) b 42init.c:19 Junk at end of arguments. (gdb) Any other ideas?! Thanks again! -Dean On Thu, Jun 12, 2008 at 5:06 PM, Michael Snyder <msnyder@specifix.com> wrote: > On Thu, 2008-06-12 at 17:04 -0400, Dean Tsai wrote: >> Hi Michael, >> >> I am not sure exactly what you meant, but this is what I did to create >> the problem (see below). 42init.c actually resides in ./Source/ but I >> don't think it matter, does it? >> > > Dean, > > Just a guess here, but could you try renaming 42init.c to > some name that doesn't begin with a numeral? > > Wondering if gdb is trying to parse it as a number... > > If that does turn out to make a difference, you've got a > genuine bug and we'll undertake to fix it. ;-) > > >> LM220008151:42_SDP_tmp dtsai$ gdb 42 >> >> GNU gdb 6.3.50-20050815 (Apple version gdb-768) (Tue Oct 2 04:07:49 UTC 2007) >> Copyright 2004 Free Software Foundation, Inc. >> GDB is free software, covered by the GNU General Public License, and you are >> welcome to change it and/or distribute copies of it under certain conditions. >> Type "show copying" to see the conditions. >> There is absolutely no warranty for GDB. Type "show warranty" for details. >> This GDB was configured as "i386-apple-darwin"...Reading symbols for >> shared libraries ...... done >> >> (gdb) b 42init.c:14 >> Junk at end of arguments. >> >> (gdb) pwd >> Working directory /Users/dtsai/work/42_SDP_tmp. >> >> (gdb) > > ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-12 21:22 ` Dean Tsai @ 2008-06-12 21:42 ` Nick Roberts 2008-06-13 6:42 ` Eli Zaretskii 1 sibling, 0 replies; 12+ messages in thread From: Nick Roberts @ 2008-06-12 21:42 UTC (permalink / raw) To: Dean Tsai; +Cc: Michael Snyder, gdb Dean Tsai writes: > Unfortunately Michael, changing the leading filename to string didn't > help. I have changed 42init.c to tmp42init.c, changed my Makefile, > make clean, make...etc. The same problem persists. > > Would the following offer you additional insights? b > filename:functionname works!! > > (gdb) b 42init.c:InitSim > Breakpoint 1 at 0x10b90: file 42init.c, line 19. > (gdb) b 42init.c:19 > Junk at end of arguments. > (gdb) > > Any other ideas?! Thanks again! You need to post a small reproducible testcase to see if the problem happens with FSF GDB. Apple have their own version of GDB. They sometimes read this list but if it's an Apple only problem, you might have better luck posting to one of their lists at http://lists.apple.com/index.html. -- Nick http://www.inet.net.nz/~nickrob ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-12 21:22 ` Dean Tsai 2008-06-12 21:42 ` Nick Roberts @ 2008-06-13 6:42 ` Eli Zaretskii 2008-06-13 13:01 ` Dean Tsai 1 sibling, 1 reply; 12+ messages in thread From: Eli Zaretskii @ 2008-06-13 6:42 UTC (permalink / raw) To: Dean Tsai; +Cc: msnyder, gdb > Date: Thu, 12 Jun 2008 17:22:03 -0400 > From: "Dean Tsai" <dctsai.work@gmail.com> > Cc: gdb@sourceware.org > > Unfortunately Michael, changing the leading filename to string didn't > help. I have changed 42init.c to tmp42init.c, changed my Makefile, > make clean, make...etc. The same problem persists. > > Would the following offer you additional insights? b > filename:functionname works!! > > (gdb) b 42init.c:InitSim > Breakpoint 1 at 0x10b90: file 42init.c, line 19. > (gdb) b 42init.c:19 > Junk at end of arguments. > (gdb) > > Any other ideas?! Thanks again! Does the below work as well? (gdb) b '42init.c:19' ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-13 6:42 ` Eli Zaretskii @ 2008-06-13 13:01 ` Dean Tsai 2008-06-13 15:04 ` Eli Zaretskii ` (2 more replies) 0 siblings, 3 replies; 12+ messages in thread From: Dean Tsai @ 2008-06-13 13:01 UTC (permalink / raw) To: Eli Zaretskii; +Cc: msnyder, gdb Hi Eli and others, No, quotation marks don't help either. I dont know what it is telling me that the file cannot be found?! Here are a series of cases I tried. Notice 1) I have changed 42init.c to FTinit.c and 2) b filename:functionname works so I know the file exist in my program... please help :( I have a similar post on mac xcode mailling list. I will share any findings there. Thanks! -Dean LM220008151:42_SDP_tmp dtsai$ gdb 42 GNU gdb 6.3.50-20050815 (Apple version gdb-768) (Tue Oct 2 04:07:49 UTC 2007) Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i386-apple-darwin"...Reading symbols for shared libraries ...... done (gdb) b FTinit.c:InitSim Breakpoint 1 at 0x10b90: file FTinit.c, line 19. (gdb) b FTinit.c:19 Junk at end of arguments. (gdb) b 'FTinit.c:19' Function "19'" not defined in file FTinit.c. Make breakpoint pending on future shared library load? (y or [n]) (gdb) b "FTinit.c:19" Junk at end of arguments. (gdb) b '"FTinit.c":19' No source file named "FTinit.c". Make breakpoint pending on future shared library load? (y or [n]) (gdb) b "'FTinit.c':19" No source file named 'FTinit.c'. Make breakpoint pending on future shared library load? (y or [n]) (gdb) On Fri, Jun 13, 2008 at 2:40 AM, Eli Zaretskii <eliz@gnu.org> wrote: >> Date: Thu, 12 Jun 2008 17:22:03 -0400 >> From: "Dean Tsai" <dctsai.work@gmail.com> >> Cc: gdb@sourceware.org >> >> Unfortunately Michael, changing the leading filename to string didn't >> help. I have changed 42init.c to tmp42init.c, changed my Makefile, >> make clean, make...etc. The same problem persists. >> >> Would the following offer you additional insights? b >> filename:functionname works!! >> >> (gdb) b 42init.c:InitSim >> Breakpoint 1 at 0x10b90: file 42init.c, line 19. >> (gdb) b 42init.c:19 >> Junk at end of arguments. >> (gdb) >> >> Any other ideas?! Thanks again! > > Does the below work as well? > > (gdb) b '42init.c:19' > ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-13 13:01 ` Dean Tsai @ 2008-06-13 15:04 ` Eli Zaretskii 2008-06-13 15:58 ` Stan Shebs 2008-06-13 18:55 ` Michael Snyder 2 siblings, 0 replies; 12+ messages in thread From: Eli Zaretskii @ 2008-06-13 15:04 UTC (permalink / raw) To: Dean Tsai; +Cc: msnyder, gdb > Date: Fri, 13 Jun 2008 09:01:39 -0400 > From: "Dean Tsai" <dctsai.work@gmail.com> > Cc: msnyder@specifix.com, gdb@sourceware.org > > No, quotation marks don't help either. I dont know what it is telling > me that the file cannot be found?! > Here are a series of cases I tried. Notice 1) I have changed 42init.c > to FTinit.c and 2) b filename:functionname works so I know the file > exist in my program... please help :( > > I have a similar post on mac xcode mailling list. I will share any > findings there. Sounds like a problem specific to the Apple version. I've never seen such problems in GDB 6.3. ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-13 13:01 ` Dean Tsai 2008-06-13 15:04 ` Eli Zaretskii @ 2008-06-13 15:58 ` Stan Shebs 2008-06-13 18:55 ` Michael Snyder 2 siblings, 0 replies; 12+ messages in thread From: Stan Shebs @ 2008-06-13 15:58 UTC (permalink / raw) To: Dean Tsai; +Cc: Eli Zaretskii, msnyder, gdb Dean Tsai wrote: > Hi Eli and others, > > No, quotation marks don't help either. I dont know what it is telling > me that the file cannot be found?! > Here are a series of cases I tried. Notice 1) I have changed 42init.c > to FTinit.c and 2) b filename:functionname works so I know the file > exist in my program... please help :( > This is most likely a bug specific to Apple's GDB, since they've made changes in that area, although it seems that Apple's own GDBers are mystified by this one, and can't reproduce it with their own examples. I think you're going to need to send them your program; if the normal filename is still causing complaints, I'm thinking there is some kind of data corruption or some such, maybe nothing to do with the filename. In any case, Apple's GDB is so different from FSF GDB that you really need to work with the Apple folks to get a resolution on this one. Stan ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-13 13:01 ` Dean Tsai 2008-06-13 15:04 ` Eli Zaretskii 2008-06-13 15:58 ` Stan Shebs @ 2008-06-13 18:55 ` Michael Snyder 2008-06-13 19:33 ` Dean Tsai 2 siblings, 1 reply; 12+ messages in thread From: Michael Snyder @ 2008-06-13 18:55 UTC (permalink / raw) To: Dean Tsai; +Cc: gdb On Fri, 2008-06-13 at 09:01 -0400, Dean Tsai wrote: > Hi Eli and others, > > No, quotation marks don't help either. I dont know what it is telling > me that the file cannot be found?! > Here are a series of cases I tried. Notice 1) I have changed 42init.c > to FTinit.c and 2) b filename:functionname works so I know the file > exist in my program... please help :( OK, I have one more idea, but it's a crazy one. Would you try this please? break FTinit:19 ^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: "Junk at end of arguments." when setting breakpoint 2008-06-13 18:55 ` Michael Snyder @ 2008-06-13 19:33 ` Dean Tsai 0 siblings, 0 replies; 12+ messages in thread From: Dean Tsai @ 2008-06-13 19:33 UTC (permalink / raw) To: Michael Snyder; +Cc: gdb Hi Mike, Nope, no such luck :( People on the apple list stop responding too... This is a sad day. -Dean (gdb) break FTinit:19 No source file named FTinit. Make breakpoint pending on future shared library load? (y or [n]) (gdb) break FTinit.c:19 Junk at end of arguments. (gdb) On Fri, Jun 13, 2008 at 2:55 PM, Michael Snyder <msnyder@specifix.com> wrote: > On Fri, 2008-06-13 at 09:01 -0400, Dean Tsai wrote: >> Hi Eli and others, >> >> No, quotation marks don't help either. I dont know what it is telling >> me that the file cannot be found?! >> Here are a series of cases I tried. Notice 1) I have changed 42init.c >> to FTinit.c and 2) b filename:functionname works so I know the file >> exist in my program... please help :( > > OK, I have one more idea, but it's a crazy one. > Would you try this please? > > break FTinit:19 > > > > ^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2008-06-13 19:33 UTC | newest] Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2008-06-12 20:43 "Junk at end of arguments." when setting breakpoint Dean Tsai 2008-06-12 20:57 ` Michael Snyder 2008-06-12 21:04 ` Dean Tsai 2008-06-12 21:07 ` Michael Snyder 2008-06-12 21:22 ` Dean Tsai 2008-06-12 21:42 ` Nick Roberts 2008-06-13 6:42 ` Eli Zaretskii 2008-06-13 13:01 ` Dean Tsai 2008-06-13 15:04 ` Eli Zaretskii 2008-06-13 15:58 ` Stan Shebs 2008-06-13 18:55 ` Michael Snyder 2008-06-13 19:33 ` Dean Tsai
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox