简体   繁体   English

eclipse cdt - 改变项目类型

[英]eclipse cdt - change type of project

I have a bunch of Eclipse projects imported into my workspace. 我将一堆Eclipse项目导入到我的工作区中。 I know how to add a directory for Eclipse to search for headers to resolve symbols. 我知道如何为Eclipse添加目录以搜索解析符号的标头。

However, some of my projects do not allow me to add these directories and I realized that it's because those projects are not the correct type. 但是,我的一些项目不允许我添加这些目录,我意识到这是因为那些项目不是正确的类型。

Right click > Properties on the 'correct' type of project shows an item in the list called " C/C++ Build 右键单击> “正确”类型项目上的属性 ,在列表中显示名为“ C / C ++ Build”的项目

If it has this entry, then in C/C++ General it has an entry called Paths and Symbols wherein I can add necessary include directories so that the indexing works. 如果它有这个条目,那么在C / C ++ General中它有一个名为Paths和Symbols的条目其中我可以添加必要的include目录,以便索引工作。

QUESTION

How do I change the properties of this project so I can use indexing and add directories for indexing? 如何更改此项目的属性,以便我可以使用索引和添加目录进行索引?

I've found one thing that obviously needs to be changed: in the 'correct' project, Right Click > Properties > Builders has two entries: CDT Builder and Scanner Configuration Builder while the 'incorrect' project is missing these two. 我发现有一件事显然需要改变:在'正确'的项目中, 右键单击>属性>构建器有两个条目: CDT Builder扫描仪配置构建器,而'错误'项目缺少这两个。

How do I add them? 我该如何添加它们? Import yields a blank page and New is just as useless. 导入会生成一个空白页面,而New也是无用的。

您可能需要File -> New -> Convert to a C/C++ Project (Adds C/C++ Nature)

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

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