Debugging Vim with Gdb in terminal from within Vim

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Debugging Vim with Gdb in terminal from within Vim

Ni Va
Hi all,


I attempt to use gdb in order to debug vim with gdb from gvim under windows 10 as advised by Bram in this video :
https://www.youtube.com/watch?v=fI181d1ujcc min 28:14.

Versions of :

1. gvim : 32 bit 8.1.542 build with make_msvc.bat under windows 10
2. gdb  : 4.7.1.2 from mingw configured x86_64-w64-mingw32.




In the terminal window, from vim src dir, I type gdb vim and gdb says no debugging symbols found. (see joined PNG)


How to tell gdb the symbols source dir and happen to set breakpoint in vim source code ?

Thank you
NiVa

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

Capture.PNG (75K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Debugging Vim with Gdb in terminal from within Vim

Ni Va
Le samedi 24 novembre 2018 16:26:18 UTC+1, Ni Va a écrit :

> Hi all,
>
>
> I attempt to use gdb in order to debug vim with gdb from gvim under windows 10 as advised by Bram in this video :
> https://www.youtube.com/watch?v=fI181d1ujcc min 28:14.
>
> Versions of :
>
> 1. gvim : 32 bit 8.1.542 build with make_msvc.bat under windows 10
> 2. gdb  : 4.7.1.2 from mingw configured x86_64-w64-mingw32.
>
>
>
>
> In the terminal window, from vim src dir, I type gdb vim and gdb says no debugging symbols found. (see joined PNG)
>
>
> How to tell gdb the symbols source dir and happen to set breakpoint in vim source code ?
>
> Thank you
> NiVa
Note that I call make_msvc.mak with DEBUG=YES

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Debugging Vim with Gdb in terminal from within Vim

Bram Moolenaar

Ni Va wrote:

> Le samedi 24 novembre 2018 16:26:18 UTC+1, Ni Va a écrit :
> > Hi all,
> >
> >
> > I attempt to use gdb in order to debug vim with gdb from gvim under windows 10 as advised by Bram in this video :
> > https://www.youtube.com/watch?v=fI181d1ujcc min 28:14.
> >
> > Versions of :
> >
> > 1. gvim : 32 bit 8.1.542 build with make_msvc.bat under windows 10
> > 2. gdb  : 4.7.1.2 from mingw configured x86_64-w64-mingw32.
> >
> >
> >
> >
> > In the terminal window, from vim src dir, I type gdb vim and gdb says no debugging symbols found. (see joined PNG)
> >
> >
> > How to tell gdb the symbols source dir and happen to set breakpoint in vim source code ?
> >
> > Thank you
> > NiVa
>
> Note that I call make_msvc.mak with DEBUG=YES

You can only use gdb with a binary that was build with gcc.  It does not
work when it was built with MSVC.  Unfortunately...

Thus you need to build with MinGW or cygwin.

--
BEDEVERE: Look!  It's the old man from scene 24 - what's he Doing here?
ARTHUR:   He is the keeper of the Bridge.  He asks each traveler five
          questions ...
GALAHAD:  Three questions.
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

 /// Bram Moolenaar -- [hidden email] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Debugging Vim with Gdb in terminal from within Vim

Ni Va
Le dimanche 25 novembre 2018 02:19:26 UTC+1, Bram Moolenaar a écrit :

> Ni Va wrote:
>
> > Le samedi 24 novembre 2018 16:26:18 UTC+1, Ni Va a écrit :
> > > Hi all,
> > >
> > >
> > > I attempt to use gdb in order to debug vim with gdb from gvim under windows 10 as advised by Bram in this video :
> > > https://www.youtube.com/watch?v=fI181d1ujcc min 28:14.
> > >
> > > Versions of :
> > >
> > > 1. gvim : 32 bit 8.1.542 build with make_msvc.bat under windows 10
> > > 2. gdb  : 4.7.1.2 from mingw configured x86_64-w64-mingw32.
> > >
> > >
> > >
> > >
> > > In the terminal window, from vim src dir, I type gdb vim and gdb says no debugging symbols found. (see joined PNG)
> > >
> > >
> > > How to tell gdb the symbols source dir and happen to set breakpoint in vim source code ?
> > >
> > > Thank you
> > > NiVa
> >
> > Note that I call make_msvc.mak with DEBUG=YES
>
> You can only use gdb with a binary that was build with gcc.  It does not
> work when it was built with MSVC.  Unfortunately...
>
> Thus you need to build with MinGW or cygwin.
>
> --
> BEDEVERE: Look!  It's the old man from scene 24 - what's he Doing here?
> ARTHUR:   He is the keeper of the Bridge.  He asks each traveler five
>           questions ...
> GALAHAD:  Three questions.
>                  "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
>
>  /// Bram Moolenaar -- [hidden email] -- http://www.Moolenaar.net   \\\
> ///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
> \\\  an exciting new programming language -- http://www.Zimbu.org        ///
>  \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///
Thank you,
so I will retry, with RUBY support (dll) not as advised by Ken...

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.