将qtcreator与Makefile项目一起使用 [英] Use qtcreator with makefile project

查看:439
本文介绍了将qtcreator与Makefile项目一起使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个makefile项目.我知道在Eclipse CDT中可以加载makefile项目.

I have a makefile project. I know that in Eclipse CDT is possible to load makefile project.

是否可以将其加载到qtcreator中?

Is it possibile to load it in qtcreator?

推荐答案

如Greenflow所述,Qt Creator可以导入现有项目,但它甚至不依赖于Makefile的存在.导入现有项目所需要做的就是指定项目源所在的高级文件夹(包括子目录中的源)并为项目设置一些名称-Qt Creator将用于的名称显示其名称. Qt Creator还会询问您哪些文件应包含在项目中,但是同样,它只是用于在项目树中显示源,而不是用于构建. Qt Creator默认情况下在指定的构建目录中使用make工具构建项目,但是您可以覆盖此设置.例如,在我工作的公司中,我们有一个自定义构建系统和一个自定义构建工具.因此,当我将某些项目导入到Qt Creator中时,我使用源代码指定目录,设置一些名称,指定构建目录,使用我们的自定义工具覆盖默认的make生成工具,并在文件.includes中添加一些包含路径(如果需要) ,在文件.config中指定宏并开发内容,仅此而已.

As Greenflow mentioned, Qt Creator can import existing project but it doesn't even depend on the existence of the Makefile. All you need to do for import of the existing project is specify the high-level folder in which the sources of the project are located (including sources in subdirectories) and set some name for the project - the name which Qt Creator will use to display its name. Qt Creator also asks you which files should be included to the project but again, it is simply for the display of sources in the project tree, not for build. Qt Creator uses make tool in the specified build directory by default to build your project but you can override this setting. For example, in the company I work for we have a custom build system and a custom build tool. So when I import some project into Qt Creator, I specify the directory with sources, set some name, specify build directory, override the default make build tool by our custom one, add some include paths to file .includes, if necessary, specify macros in file .config and develop things, that's just it.

您可以查看有关Qt CreatorImport existing project功能的更多详细信息此处.

You can see more detailed information about Import existing project feature of Qt Creator here.

这篇关于将qtcreator与Makefile项目一起使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆