<div dir="ltr"><span style="font-family:arial,sans-serif;font-size:13px">Thanks for reply.</span><div><span style="font-family:arial,sans-serif;font-size:13px"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px">I have added</span><span style="font-family:arial,sans-serif;font-size:13px"> "CFLAGS='-Og -ggdb3' CXXFLAGS='-Og -ggdb3'" into configure file and ran </span><div>
<div><span style="font-family:arial,sans-serif;font-size:13px">"</span><span style="font-family:arial,sans-serif;font-size:13px">./configure --enable-debug" ; make; make install</span></div><div><span style="font-family:arial,sans-serif;font-size:13px"><br>
</span></div><div><span style="font-family:arial,sans-serif;font-size:13px">but still it did not step into driver.</span></div></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Jun 4, 2014 at 1:09 PM, Ian Romanick <span dir="ltr"><<a href="mailto:idr@freedesktop.org" target="_blank">idr@freedesktop.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="">On 06/04/2014 11:14 AM, roshan chaudhari wrote:<br>
</div><div class="">> Hello,<br>
>         I just cloned the mesa driver from git repository. I am trying<br>
> to debug the opengl application with mesa driver. I am not sure which<br>
> flag to enable for debugging and where, I built a driver with<br>
> -enable-debug in Makefile and added --DEBUG in CFLAGS in Makefile but<br>
> still when I try to step into driver code it does not allow me. I am<br>
> doing it with gdb in ubuntu.<br>
<br>
</div>Modifying the CFLAGS in the Makefile is likely to cause problems.<br>
Instead, try<br>
<br>
CFLAGS='-Og -ggdb3' CXXFLAGS='-Og -ggdb3' ./configure --enable-debug <your other configure options><br>
<br>
If your version of GCC is too old, you will need to use -O0 instead<br>
of -Og.<br>
<br>
That should be sufficient.  You can verify this by doing<br>
<br>
    gdb $(which glxgears)<br>
<br>
Then, at the gdb prompt,<br>
<br>
    break _mesa_Clear<br>
<br>
It will ask<br>
<br>
    Function "_mesa_Clear" not defined.<br>
    Make breakpoint pending on future shared library load? (y or [n])<br>
<br>
Answer 'y'.  Then,<br>
<br>
    run<br>
<br>
If it stops in _mesa_Clear, you're good to go.<br>
<div class=""><br>
> Can anyone please help me with that?<br>
><br>
> --<br>
><br>
> Thanks,<br>
> Roshan<br>
><br>
</div>> _______________________________________________<br>
> mesa-dev mailing list<br>
> <a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
> <a href="http://lists.freedesktop.org/mailman/listinfo/mesa-dev" target="_blank">http://lists.freedesktop.org/mailman/listinfo/mesa-dev</a><br>
<br>
</blockquote></div><br></div>