From: asmwarrior <asmwarrior@gmail.com>
To: Keith Seitz <keiths@redhat.com>
Cc: gdb@sourceware.org,
MinGW Users List <mingw-users@lists.sourceforge.net>
Subject: Re: setting a breakpoint on a dll, relative path or absolute path issue
Date: Sun, 12 Jun 2011 03:56:00 -0000 [thread overview]
Message-ID: <4DF43971.8090404@gmail.com> (raw)
In-Reply-To: <4DF3A114.8040709@redhat.com>
On 2011-6-12 1:08, Keith Seitz wrote:
> On 06/11/2011 12:52 AM, asmwarrior wrote:
>> Can you give me a direction that I can dig into the gdb's source?
>
> This is almost certainly PR 12843:
>
> http://sourceware.org/bugzilla/show_bug.cgi?id=12843
>
> This was caused, I believe, by this patch hunk (for locate_first_half in
> linespec.c), which I committed for c++/12750 on 2011-05-31:
>
> @@ -1160,13 +1207,11 @@ locate_first_half (char **argptr, int
> *is_quote_enclosed
> break;
> }
> /* Check for the end of the first half of the linespec. End of
> - line, a tab, a double colon or the last single colon, or a
> - space. But if enclosed in double quotes we do not break on
> - enclosed spaces. */
> + line, a tab, a colon or a space. But if enclosed in double
> + quotes we do not break on enclosed spaces. */
> if (!*p
> || p[0] == '\t'
> - || ((p[0] == ':')
> - && ((p[1] == ':') || (strchr (p + 1, ':') == NULL)))
> + || (p[0] == ':')
> || ((p[0] == ' ') && !*is_quote_enclosed))
> break;
> if (p[0] == '.' && strchr (p, ':') == NULL)
>
> I am intending to get to this, but it will probably not be until later
> this coming week.
>
> Keith
>
Hi, Keith, thanks for the reply. I have reverted the patch hunk in the
locate_first_half function and build gdb again, now, I can set
breakpoint like:
> break
"E:/code/cb/test_code/debug_wx_library/debug_wx_libraryMain.cpp:101"
Breakpoint 1 at 0x401d09: file
E:\code\cb\test_code\debug_wx_library\debug_wx_libraryMain.cpp, line 101.
So, the PR 12843 can be solved.
---------------------------------------------------------------
But what I have mentioned in my OP is another issue about setting
breakpoint, that is:
gdb failed on setting a breakpoint on a shared dll(the dll is build with
the relative paths)
break "E:/code/cb/wx/wxWidgets-2.8.12/src/common/string.cpp:164"
No source file named E:/code/cb/wx/wxWidgets-2.8.12/src/common/string.cpp.
Breakpoint 2 ("E:/code/cb/wx/wxWidgets-2.8.12/src/common/string.cpp:164)
pending.
------------------------------------------------------------------
But the breakpoint can be set by using two ways below:
> break ../../src/common/string.cpp:164
Breakpoint 3 at 0x66d89f44: file ../../src/common/string.cpp, line 164.
>>>>>>cb_gdb:
> break
E:\code\cb\wx\wxWidgets-2.8.12\build\msw/../../src/common/string.cpp:164
Breakpoint 4 at 0x66d89f44: file ../../src/common/string.cpp, line 164.
-------------------------------------------------------------------
What I expect is the let the first way work.
So, I would like to find some gdb source snippet which handle the file
path match algorithm, so that all the three methods can work. Can you
give me a direction?
thanks.
asmwarrior
ollydbg from code::blocks' forum
next prev parent reply other threads:[~2011-06-12 3:56 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-11 7:49 asmwarrior
2011-06-11 17:56 ` Keith Seitz
2011-06-12 3:56 ` asmwarrior [this message]
2011-06-12 7:45 ` asmwarrior
2011-06-12 7:56 ` Jan Kratochvil
2011-06-12 8:06 ` asmwarrior
2011-06-12 16:22 ` [Mingw-users] " Earnie
2011-06-12 16:51 ` Eli Zaretskii
2011-06-12 16:54 ` Jan Kratochvil
[not found] ` <4DF37ADA.3070905@users.sourceforge.net>
2011-06-12 8:15 ` asmwarrior
[not found] ` <4DF4513A.3090902__7466.60719528354$1307866544$gmane$org@gmail.com>
2011-06-13 6:33 ` Asm warrior
2011-06-13 17:02 ` Eli Zaretskii
2011-06-14 3:14 ` Asm warrior
2011-06-14 3:49 ` Asm warrior
2011-06-14 4:22 ` Jeffrey Walton
2011-06-14 5:27 ` setting a breakpoint on a dll, relative path or absolute path issue[solved with a patch] asmwarrior
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4DF43971.8090404@gmail.com \
--to=asmwarrior@gmail.com \
--cc=gdb@sourceware.org \
--cc=keiths@redhat.com \
--cc=mingw-users@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).