This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: sun compiler and gdb
- From: Sergio Durigan Junior <sergiodj at redhat dot com>
- To: Tomasz Grobelny <tomasz at grobelny dot oswiecenia dot net>
- Cc: <gdb at sourceware dot org>
- Date: Thu, 03 May 2012 03:49:41 -0300
- Subject: Re: sun compiler and gdb
- References: <25b0084e43f4d35410c8dff55a3be61d@192.168.5.248>
On Thursday, May 03 2012, Tomasz Grobelny wrote:
> Hi all,
> Should it be possible to debug C++ programs compiled using sun compiler
> using GDB? If so which debug format should I use? Which versions of the
> compiler/gdb support such a scenario? Currently the situation looks like
> this (which does not look very promising):
Indeed. In a quick search using Google, I found some links reporting
that the compiler is kind of broken, probably when it comes to DWARF
generation. Anyway, by reading this link:
http://netbeans.org/bugzilla/show_bug.cgi?id=89876
especifically in comment #8, I saw that you can try enabling some
options in your C++ compiler:
-Qoption cg -h_gcc -xO0 -g
Also, I saw that passing `-xs' to the compiler might help a bit. But
overall, AFAIU, you don't have many options here, unfortunately.
However, I'm definitely not an expert in the platform, so maybe someone
more experienced will show up and help you further.
Good luck.
--
Sergio