views:

454

answers:

3

I have a legacy C++ project on Linux which uses the typical:

./configure
make
make install

to build and install. I would really like to build it instead with an IDE like Eclipse.

Is this doable? Is there something in Eclipse that can parse the original Makefile(s) and turn it into an Eclipse project?

+1  A: 

Using Eclipse with the CDT plugin will allow you to use it for C/C++ projects, and you can tell it to use Makefiles to build your project. You just have to set up a Makefile project. You might have to tell it to let you manage the Makefiles rather than have it do it - I don't remember off the top of my head - but there should be no problem in setting up Eclipse to use pre-existing Makefiles to build a pre-existing project. I've done it before.

You will have to tell it where the include directories are and what macros to assume are defined for things like code completion to work correctly (I don't know of any way for Eclipse to figure that out for you), so there is definitely some set up that you'll have to do. But it definitely works.

Just grab the C++ version of Eclipse from their site (it comes with all of the appropriate C/C++ plugins so that you don't have to track them down), and you can look at the CDT site for documentation, frequently asked questions, etc.

Edit: I don't know how well you can get it to work with configure though. That's not something that I've tried. Makefiles work just fine though.

Jonathan M Davis
+1  A: 

If the project is not too big or too complex. You might do better to just start a new C++ project in Eclipse. Then import the various source and header files into the project.

makewrite
+1  A: 

see article: Build UNIX software with Eclipse
http://www.ibm.com/developerworks/aix/library/au-unix-eclipse/index.html
Bringing legacy code into a modern IDE Chris Herborth ([email protected])

Jacky