This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: gdb/gdbserver not responding with cygwin


On 19 April 2007 17:13, Doug Schaefer wrote:

> Charles Wilson wrote:
>> [added cygwin to CC list; note cygwinners: original newgroup is members
>> only, 

  I wouldn't beloing to any newsgroup that would have /me/ for a member!

>> Doug Schaefer wrote:
>>> As with all things cygwin these days, they changed something that
>>> breaks the CDT and they don't care. We do have a bug open on that. I
>>> don't have the number handy, but it is a known problem that we'll have
>>> to figure out for CDT 4.
>> 
>> Doug, that's not a fair characterization. AFAIK, there are two main
>> issues with cygwin (well, any windows) gdb and CDT:
> 
> That's true. I've been frustrated with trying to get cygwin tools
> working with CDT and unfortunate let my emotions get the best of me :).
> I apologize.

  That's good of you.  Saves me from having to get all sarcastic on yer ass,
anyway!

> I think that's the main issue we're running into with gdb at least.
> There is a bug in the CDT database where we are discussing alternatives.
> 
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=179150
> 
> In the end, I think we need to handle the cygwin environment as a
> specific host type and ensure our integrations know about it. That way
> we can continue to interact with Windows tools as they need and cygwin
> tools as they need.

  This thread (this one right here that's just arrived at cygwin-l) doesn't
actually say anything about what the problem is/was.  I took a quick google
and found there's about a dozen cdt lists.  It wasn't on the first couple I
glanced at, so perhaps a link or something would be handy?

  However, I do have one perhaps-relevant datapoint for you: a colleague of
mine upgraded his cygwin toolchain to 1.5.23 just recently, and debugging from
within Eclipse stopped working:  the entire gui, as well as the inferior task,
hung up solid (hung in the not-responding, not pumping windows message queue,
not redrawing, hourglass-cursor forever sense of the word).  He downgraded his
installed cygwin gdb to the previous release version (20041228-3) and it
started working again.

>> However, that having been said...because gcc, gdb/insight, and cygwin
>> all seem to work as expected in standalone mode, there's not much that
>> the cygwin developers can do.  I don't know of anyone who has tried to
>> use gdbserver under cygwin...and from my investigation, it does not
>> appear that gdbserver was ever supported by an official cygwin gdb
>> release. It'd be great if it were, but...missing features are not bugs,
>> much as we'd like to see those features and have them work properly.
> 
> gdbserver is very linux specific. I think the issue is arising from
> running cygwin gdb to connect to a gdbserver on a remote linux machine.
> But we are having similar issues just running gdb locally.

  It may appear similar, but isn't it a bit risky to try and infer that it is
the same problem in each of these two very different use-cases?  (Note that,
as mentioned before, I haven't yet seen anything to tell me what the actual
trouble /is/ yet...)

>> Now, concerning DOS-style paths.  This was discussed (briefly) here
>> http://www.cygwin.com/ml/cygwin/2006-07/msg00257.html
>> 
>> It occurs to me, however, that the following is not obvious to someone
>> who is unversed in Eclipse/CDT -- but I've never seen it mentioned in
>> the complaints about "cygwin" and CDT:  it is very very common for "you
>> guys" to use the MinGW compiler with the Cygwin debugger.  THAT is not
>> an officially supported use case, even if it MAY have worked in the past
>> (and is probably the reason why cygwin-gdb gets confused by the
>> mingw-gcc-inserted C:-style paths).
> 
> Actually the file path issue came up in a recent release of cygwin make
> where DOS file paths are no longer supported. That is a separate issue
> from the gdb one mentioned.

>> Note also that the latest gdb from cygwin is 06 Jul 2006, and the gdb
>> from mingw is 'current:20030511, contributed:20050924,
>> snapshot:20051117' -- which perhaps explains why many people are using
>> cygwin's gdb with mingw's compilers: our gdb is newer, even if both
>> projects' versions lag behind cvs HEAD and are missing ALL of the
>> patches above...
> 
> Yes, I need to find out what's happening with mingw's gdb. It does seem
> to be stale and in need of attention.

  Trying to launch a win32 app from a cygwin app from a win32 non-console app
is a pretty tricky corner case.  It would really be better all round to use
mingw make and mingw compilers and debuggers with mingw-targeted programs and
cygwin make and cygwin compilers and debuggers only for cygwin-targeted
programs.  Interworking mixed sets of tools and targets is not guaranteed to
work and not high on my personal agenda to make work.

>> Now, on the other hand, if cygwin-gcc-based CDT projects using the
>> cygwin-provided gdb are having path issues, the first question I'd ask
>> is "why is cygwin-gcc putting DOS-style paths into the debug info" and
>> NOT "why can't cygwin-gdb understand DOS-style paths".  Cause the former
>> is a *bug*, the second is a missing, and perhaps desired, feature.

  If cygwin gcc is invoked with a DOS path such as "C:\\foo\\bar.c" or
"C:/foo/bar.c" on the commandline, that is what it puts into the debug info.
It's preserved literally.

  Anyway, I don't use Eclipse, but a lot of my colleagues do, and anything I
can do to make debugging smoother with it would be appreciated by them.  Can
someone please explain the problem to me exactly in terms of 1) what target
the debuggee is compiled for 2) what version of gdb is being launched to debug
it 3) what kind of dos/unix paths and commandlines are used when compiling and
when invoking the debugger?

    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]