How to use external makefile in Eclipse

可紊 提交于 2019-12-18 12:52:14

问题


I have a source code of an OpenSource project which I get from SVN. I was able to run autogen --> configure --> and make successfully (through the terminal). But I want to build the same project with Eclipse, and I can't port manually those source files to eclipse though. So, How can I set Eclipse to use external make files ? can anyone please help me ? Thanks.


回答1:


Ok, I got it, It was straightforward. Just go to project properties --> C/C++ Build --> Make file generation --> and untick "Generate Make files automatically". In additionally you may have to set the Build location also.




回答2:


This might vary with different versions. The one I use is Eclipse 3.5 with CDT 6, and it is quite straightforward:

New Project -> C++ Project -> Makefile Project -> Empty project

Untick the 'Use default location' and provide the location where the root of your project and Makefile reside.

I found it misleading at first, and had a couple of dry runs in copied directories to make sure that the 'Empty project' would not clear the Makefile, but the fact is that the option name is probably misleading as 'Empty' stands for CDT will not create a Makefile for you (but won't delete an existing version either)



来源:https://stackoverflow.com/questions/2550628/how-to-use-external-makefile-in-eclipse

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!