简体   繁体   English

OSDEV 有 IDE 吗?

[英]Is there any IDE for OSDEV?

Is there any IDE to create operating systems in C/C++/Assembly?有没有 IDE 可以用 C/C++/Assembly 创建操作系统? If there, please tell me how to setup it for OSDEV or point me to a good tutorial.如果有,请告诉我如何为 OSDEV 设置它或为我指点一个好的教程。

Thanks谢谢

To my knowledge there really aren't any IDEs specifically geared toward operating systems development, although there are several options available for the languages most commonly used for such work.据我所知,确实没有任何专门针对操作系统开发的 IDE,尽管对于最常用于此类工作的语言有几种可用的选项。 In general there's not much of a difference between OSDev and any other kind of C/C++/Assembly development, so any ordinary IDE equipped for those languages should suffice.一般来说,OSDev 与任何其他类型的 C/C++/Assembly 开发之间没有太大区别,因此为这些语言配备的任何普通 IDE 就足够了。 My personal favorite is Eclipse CDT , which, like other Eclipse products, can be extended with plugins for Assembly development, etc.我个人最喜欢的是Eclipse CDT ,它与其他 Eclipse 产品一样,可以通过插件进行扩展以进行程序集开发等。

Some other IDEs worth mentioning are Code::Blocks , CLion , or even command-line text editors like vim and nano .其他一些值得一提的 IDE 是Code::BlocksCLion ,甚至是vimnano等命令行文本编辑器。 Whatever you are most comfortable with for other C/C++ development should work just fine for OS development.无论您对其他 C/C++ 开发最熟悉什么,都应该适用于操作系统开发。

Where OSDev and ordinary C/C++ development may differ, however, is in the build process.凡OSDev和普通的C / C ++开发可能会有所不同,但是,在构建过程中。 Usually a C/C++ project is compiled into a binary file which is then executed on the machine, while a kernel image will be designed to either function as a mountable boot drive, or be loaded by another bootloader.通常,一个 C/C++ 项目被编译成一个二进制文件,然后在机器上执行,而内核映像将被设计为用作可安装的引导驱动器,或者由另一个引导加载程序加载。 This requires more than just compilation, and as far as I know, there aren't any IDEs which will immediately support, for example, creating a disk image from compiled code.这需要的不仅仅是编译,据我所知,没有任何 IDE 可以立即支持,例如,从编译代码创建磁盘映像。 For this, I recommend GNU make, which can run Makefiles that contain the steps to incrementally build and run your operating system.为此,我推荐 GNU make,它可以运行包含增量构建和运行操作系统步骤的 Makefile。 A good resource for learning about how to write makefiles can be found here , with the official manual serving as extra guidance.可以在此处找到学习如何编写 makefile 的良好资源,官方手册可作为额外指导。

In short, any functional C/C++ IDE will suffice for OS development, while a slightly more complex build system will be required to actually run/test your operating system.简而言之,任何功能性 C/C++ IDE 都足以进行操作系统开发,而实际运行/测试操作系统则需要稍微复杂的构建系统。

Not exactly.不完全是。 This is why I perfer to use code editors over ides like visual studio (not visual studio code just visual studio) or eclipse IDE unless I want to write java code of course.这就是为什么我更喜欢使用代码编辑器而不是像 visual studio(不是 visual studio code 只是 visual studio)或 eclipse IDE 之类的 ide,当然除非我想编写 java 代码。 IDE's tend to try and correct you and try to predict errors for you before you even compile. IDE 倾向于尝试纠正您,甚至在您编译之前就尝试为您预测错误。 Since your most likely gonna use assembly and freestanding C or C++ (no libraries) The IDE may try and think ahead of you.由于您最有可能使用汇编和独立式 C 或 C++(无库) IDE 可能会尝试先于您思考。 Most code editors wouldn't do that.大多数代码编辑器不会那样做。

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

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