开源开发

发布于 2024-09-04 23:26:29 字数 257 浏览 3 评论 0原文

我是Fedora12(GNOME)用户。我最近开始在 Linux 上进行开发。大多数 Linux 系统应用程序/实用程序都是用 c/c++ 编写的。我面临的问题是如何将下载的源代码与某些 IDE(例如 Anjuta 等)集成。

简而言之,我想知道使用 IDE 对现有源代码进行开发的最佳方法是什么。

我们以 GRUB2(v1.97.1) 为例。我下载了源代码,现在我想研究/自定义/增强/向此代码添加新内容,所以我希望所有源文件都应该以结构/分层方式可见,以便于开发?

I am a Fedora12(GNOME) user. I recently started development in Linux. Most of the Linux system applications/utilities are written in c/c++. The problem i am facing is that how to integrate a downloaded source code with some IDE(e.g, Anjuta etc).

In simple words i want to know that, what is the best way to start development on some existing source code using an IDE.

Lets take the example of GRUB2(v1.97.1). I downloaded the source code and now i want to study/customize/enhance/add new things to this code, so i want all the source files should be visible in a structural/hierarchical way for the ease of development?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

爱本泡沫多脆弱 2024-09-11 23:26:29

这取决于您使用的 IDE。我认为最简单的配置是 Eclipse(最新版本有一个相当不错的 C++ 插件),尽管它有很多问题。只需创建一个新项目即可。您应该创建一个 C++ Makefile 项目,因为它使用现有的 Makefile,而在标准 C++ 项目中,Eclipse 将管理自己的 Makefile。将项目基目录设置为程序的基目录,并告诉它不要创建任何新文件。

另一个选择是 KDevelop。我对它了解不多,但它原生支持 Automake 和 CMake,以及许多其他 Linux 下开发时使用的工具。它也有很多错误。

如果你是一个足够顽固的极客,并且有耐心配置它,gvim 也可以成为一个可用的 IDE。我认为有几个用于此目的的插件,尽管我只将其用于基本的文本编辑。

It depends on what IDE you are using. I think the simplest one to configure is Eclipse (the newest version has a pretty decent C++ plugin), despite many of its problems. Just create a new project. You should create a C++ Makefile project, because it uses an existing Makefile, while the in standard C++ project, Eclipse will manage its own Makefile. Set the project base directory to the base directory of your program, and tell it not to create any new files.

Another option is KDevelop. I don't know much about it, but it natively supports Automake and CMake, and many other tools that are used in development under Linux. It also has a lot of bugs.

If you are a hard enough geek, and have the patience to configure it, gvim can be made a usable IDE, too. I think there are several plugins for this purpose, though I only used it for basic text editing.

琉璃梦幻 2024-09-11 23:26:29

所以我希望所有源文件都应该以结构/分层方式可见,以便于开发?

创建一个项目并导入所有文件。绑定键盘快捷键以使用 makefile 进行构建。使用 makefile 进行编译可能是最好的选择,因为对于像 grub 这样的重要应用程序来说,构建过程中有很多逻辑,这些应用程序很可能不会与任何 IDE 进行 1:1 映射。

so i want all the source files should be visible in a structural/hierarchical way for the ease of development?

Create a project and import all the files. Bind a keyboard shortcut to build using the makefile. Using the makefile for compilation is probably the best because there is a lot of logic that goes into the build process for nontrivial applications like grub that most likely will not map 1:1 with any IDE.

萌面超妹 2024-09-11 23:26:29

我想你应该寻找自动工具和文本编辑器。寻找 IDE 是浪费时间。

I guess you should look for autotools and a text editor. Looking for an IDE is wasting your time.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文