visual studio 开发linux程序

时间:2021-12-29 06:48:45

VisualGDB支持Linux的原理是,通过ssh连接到Linux系统上通过ssh给linux下达命令 . (类似visualgdb的有windgb  ,这2个都是商业软件。)

Visual GDB把GDB调试工具集成到visual studio 开发环境中,在调试过程中,可以使用visual studio原有的单步执行、设定断定等快捷键,还可以在visual GDB session的窗口中输入GDB的调试命令,集成了visualGDB之后还可以在程序执行的过程中用鼠标悬停的方式查看和修改变量的值,这样在不改变调试习惯的同时还可以使用GDB强大的调试功能,很不错。

http://visualgdb.com/documentation/linux

官方的linux工具:

Visual C++ for Linux Development

https://blogs.msdn.microsoft.com/vcblog/2016/03/30/visual-c-for-linux-development/

https://visualstudiogallery.msdn.microsoft.com/725025cf-7067-45c2-8d01-1e0fd359ae6e

目标机要安装gdb+gdbserver

 visualgdb教程:http://visualgdb.com/tutorials/linux/
我新建一个工程使用:
 visual studio 开发linux程序
visual studio 开发linux程序
从上面可以看到就是把windows上面的文件通过scp copy到远程主机上。
As the same source code will be edited under Windows and then compiled under Linux, VisualGDB will need to keep the sources synchronized. The easiest way is to use automatic file uploading via SSH. Alternatively, VisualGDB can setup shared folders (that would require root password).
visual studio 开发linux程序
他是怎么实现提示提示的,可以看到是通过下载linux下面的头文件来实现的。会把linux下面的.h文件缓存到windows上面。
Press Finish to complete the wizard. If you are setting up your first project using this Linux machine, VisualGDB will make local caches of the include directories to make them available through IntelliSens 。
http://www.cnblogs.com/hbccdf/p/use_vs_and_visualgdb_develope_linux_app.html