简体   繁体   English

Eclipse CDT的GHS .gpj项目

[英]GHS .gpj project to Eclipse CDT

I have searched for a while on this and have not found a good answer for it. 我已经搜索了一段时间,并没有找到一个很好的答案。 (I am currently talking with GHS Support about this but wanted to post here to see if anyone had any experience with this. I will post an update after talking more with GHS.) (我目前正在与GHS支持部门讨论此问题,但希望在此发帖,看看是否有人对此有任何经验。我将在与GHS进行更多讨论后发布更新。)

I am developing an embedded application using the Green Hills Software MULTI IDE and compiler. 我正在使用Green Hills Software MULTI IDE和编译器开发嵌入式应用程序。 This is a C++ project. 这是一个C ++项目。 I am trying to port an existing .gpj project for use in Eclipse so I can take advantage of the development tools in Eclipse CDT. 我正在尝试移植现有的.gpj项目以便在Eclipse中使用,这样我就可以利用Eclipse CDT中的开发工具了。 Has anyone had any experience doing this and could provide tips on it? 有没有人有这方面的经验并可以提供相关的提示?

I of course want to develop in Eclipse and still compile with the GHS compiler with all of the options in my current .gpj file. 我当然希望在Eclipse中开发,并且仍然使用GHS编译器编译我当前的.gpj文件中的所有选项。 Currently I have just had both applications open and have been developing the source in a separate Eclipse project and then compiling in the MULTI project manager with my current .gpj project. 目前我刚刚打开了这两个应用程序,并且已经在一个单独的Eclipse项目中开发了源代码,然后使用我当前的.gpj项目在MULTI项目管理器中进行编译。

This is discussed briefly here but no solutions are provided: https://www.eclipse.org/forums/index.php/t/210115/ 这里将简要讨论,但没有提供解决方案: https//www.eclipse.org/forums/index.php/t/210115/

EDIT: I am open to any suggestions for using modern editors in the MULTI Project Manager (it doesn't have to be the Eclipse CDT). 编辑:我对在MULTI项目管理器中使用现代编辑器的任何建议持开放态度(它不一定是Eclipse CDT)。 The main development tools needed are autocomplete of existing variables and going to the definition of classes and variables. 所需的主要开发工具是现有变量的自动完成,并转到类和变量的定义。

The solution that worked best for our group was to create Eclipse C++ projects that mimicked the settings in the .gpj project. 最适合我们小组的解决方案是创建模仿.gpj项目中的设置的Eclipse C ++项目。 To do this the source files were imported, the include paths set, the pre-processor directives were defined, and then the index was built. 为此,导入源文件,设置包含路径,定义预处理器指令,然后构建索引。 This way we could develop in Eclipse with all of the great tools it has. 这样我们就可以在Eclipse中使用它拥有的所有优秀工具进行开发。 We also set up a Build Target to use the MULTI compiler and build the .gpj project through gbuild and have output in the Eclipse console. 我们还设置了一个Build Target来使用MULTI编译器并通过gbuild构建.gpj项目并在Eclipse控制台中输出。 (see the figure below) (见下图)

图1

I talked with a support engineer at GHS and he did not recommend using the plug-in for Eclipse to integrate their compiler into Eclipse (our development has used many .gpj projects and we wanted to keep building our projects from the settings in the .gpj projects). 我与GHS的支持工程师讨论过,他不建议使用Eclipse的插件将他们的编译器集成到Eclipse中(我们的开发使用了很多.gpj项目,我们希望继续从.gpj中的设置构建项目)项目)。 He also did not recommend using gbuild to convert the .gpj into a makefile (he said the conversion is not always the best). 他也不建议使用gbuild将.gpj转换为makefile(他说转换并不总是最好的)。

There are ways to change the default text editor in MULTI to something like Sublime Text, but creating an Eclipse project from the settings in our .gpj project has worked the best for us. 有一些方法可以将MULTI中的默认文本编辑器更改为Sublime Text,但是从.gpj项目中的设置创建Eclipse项目对我们来说是最好的。 We have done this process manually, and of course it could be automated with enough time. 我们已经手动完成了这个过程,当然它可以在足够的时间内实现自动化。

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

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