简体   繁体   English

适用于 Linux 的良好 C++ 调试/IDE 环境?

[英]Good C++ Debugging/IDE Environment for Linux?

I have a friend who is trying to make the switch to Linux, but is hung up on the apparent lack of debugging/IDE environments for C++, especially as they relate to template programming.我有一个朋友正在尝试切换到 Linux,但是因为 C++ 明显缺乏调试/IDE 环境而挂断了电话,尤其是当它们与模板编程有关时。 He has been using visual studio for years and is maybe a little spoiled by their awesome IDE.他多年来一直在使用 Visual Studio,可能被他们出色的 IDE 宠坏了。 Does anyone have any good suggestions for an environment where he can, under Linux, develop and debug with all of the usual things (Breakpoints, line highlighting for compilation errors, step in/over/out/etc, etc) that he's accustomed to?有没有人对他可以在 Linux 下使用他习惯的所有常见事物(断点、编译错误的行突出显示、步入/结束/退出/等)进行开发和调试的环境有什么好的建议? Thanks!谢谢!

Eclipse + CDT怎么样?

Although many people think of it as a Java IDE, he could try NetBeans . 尽管许多人将其视为Java IDE,但他可以尝试使用NetBeans I've used it on Windows for C and C++ development without a problem, and I know NetBeans is supported on Linux, so it would be worth a shot. 我已经在Windows上使用它进行C和C ++开发而没有任何问题,我知道Linux上支持NetBeans,因此值得一试。

It looks like most of the features he wants are included in the C/C++ development toolkit , including integration with GDB, a profiler, and more. 看起来他想要的大部分功能都包含在C / C ++开发工具包中 ,包括与GDB,分析器等的集成。

Visual Studio is good, indeed. 确实,Visual Studio很好。

On the free side: 在自由方面:

Qt Creator is getting quite good too, it's worth a try. Qt Creator也变得非常好,值得一试。 There are advantageous by-products coming from the Qt framework: 有来自Qt框架的有利副产品:

  • huge library - not only to build GUI applications but for other domains as well 庞大的库 - 不仅可以构建GUI应用程序,还可以构建其他域
  • portability on multiple platforms 多平台上的可移植性

A version 1.3 beta is available as a preview of the upcoming release but the current 1.2.1 is already all you need to manage projects. 版本1.3 beta可作为即将发布的版本的预览版,但目前的1.2.1已经是管理项目所需的全部内容。

Eclipse has already been mentioned, it's a very good environment offering many plug-ins (Mylyn, SVN, ...). 已经提到过Eclipse,它是一个非常好的环境,提供了许多插件(Mylyn,SVN,...)。

MonoDevelop somewhat supports C++ (more and more, I didn't check the latest version). MonoDevelop有点支持C ++(越来越多,我没有检查最新版本)。

I've used Eclipse for C/C++ and it's pretty useful. 我已经将Eclipse用于C / C ++,它非常有用。 It's also used at ACM ICPC World Finals http://cm.baylor.edu/welcome.icpc 它也用于ACM ICPC世界总决赛http://cm.baylor.edu/welcome.icpc

I'd recommand Code::Blocks (but use a nighty build ). 我建议使用 Code :: Blocks(但是使用一个nighty build )。 It can be coupled with gdb to enable step by step debugging and all that stuff. 它可以与gdb结合使用,以实现逐步调试和所有这些功能。

About 7 years ago I used KDevelop that was shipped with KDE. 大约7年前,我使用了随KDE一起提供的KDevelop I found it quite good back than, and I hope it also improved with the time. 我发现它比它好,我希望它随着时间的推移而改善。 I found it quite comparable to VC++ 6 at this time. 我发现它目前与VC ++ 6相当。

It also contains Qt support, if you are in need for some GUI toolkit. 如果您需要一些GUI工具包,它还包含Qt支持。

我没有亲自探索它,但Emacs有一个C ++开发插件,看起来非常像一个完整的IDE。

Not exactly an IDE but SublimeText 2/3 is available on Linux now. 不完全是IDE,但SublimeText 2/3现在可以在Linux上使用。 There may be a debugger plugin for it too, who knows. 可能还有一个调试器插件,谁知道呢。

Edit 编辑

Here's a gdb plugin for SublimeText 这是 SublimeText的gdb插件

Depends, Code::Blocks is good, Eclipse is very nice too, but you will need a very good computer. 取决于, Code :: Blocks很好, Eclipse也很好,但你需要一台非常好的电脑。 In my opinion the best choice iss gcc, gdb and ViM or Gedit. 在我看来,最好的选择是gcc,gdb和ViM或Gedit。

我的工作伙伴使用Eclipse + Scons,他们也使用Valgrind(拼写?)来跟踪内存泄漏等。

Many of the IDE features you listed were debugger features. 您列出的许多IDE功能都是调试器功能。 The ddd (Data Display Debugger) debugger is quite a nice GUI wrapper for gdb, allowing graphical representation of data structures, a non-crappy source listing window (ie. unlike the l command of gdb where you don't get context), and also allows you to use any and all native gdb commands directly if desired. ddd(数据显示调试器)调试器是gdb的一个很好的GUI包装器,允许数据结构的图形表示,一个非糟糕的源列表窗口(即不像你没有上下文的gdb的l命令),以及还允许您根据需要直接使用任何和所有本机gdb命令。

Have a look at CodeLite. 看看CodeLite。 It's available for Ubuntu and Fedora out of the box and even for Windows and Mac. 它适用于Ubuntu和Fedora开箱即用,甚至适用于Windows和Mac。 So you can have the same IDE on different platforms. 因此,您可以在不同平台上拥有相同的IDE。

We tried Eclipse and NetBeans but left them due to their huge CPU and memory usage. 我们尝试了Eclipse和NetBeans,但由于它们的CPU和内存使用量很大而留下了它们。 We have a development server and all the developers connect to it via RDC. 我们有一个开发服务器,所有开发人员都通过RDC连接到它。 Thats why these IDEs miserably failed in our model. 这就是为什么这些IDE在我们的模型中失败了。

So, we looked for some native IDE. 所以,我们寻找一些原生IDE。 Found CodeBlocks to be very good and super fast. 发现CodeBlocks非常好,超级快。 We sort of settled on it but later found CodeLite and liked it better than CodeBlocks. 我们已经确定了它,但后来发现CodeLite并且比CodeBlocks更喜欢它。

I just seeing this question after 12+ years.我在 12 年后才看到这个问题。 AnyHow I just writing my answer.无论如何,我只是写下我的答案。 I personally use Quincy IDE for C and C++ development.我个人使用 Quincy IDE 进行 C 和 C++ 开发。 it is very lite weight and debugging watch list is very much good and easy to use.它的重量很轻,调试监视列表非常好且易于使用。 I'm just attaching the link to the site.我只是附上网站的链接。 try it.试试看。

But you have to install it with wine.但是你必须用wine安装它。

Quincy <-- Click here昆西 <-- 点击这里

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM