0
votes

I am adding feature to a library which I initially built as, cmake-> make-> make install.

But, while adding the feature (a new .cpp and .h file), a tutorial uses eclipse to build the project as,

cmake -G"Eclipse CDT4 - Unix Makefiles" and build the project in Eclipse.

What is the purpose of using Eclipse to build the project, is it possible to build without using eclipse?

2
You can still use normal makefiles, or any other build-system and environment supported by your version of CMake. The writer of the tutorial probably just likes to use Eclipse as an IDE.Some programmer dude

2 Answers

2
votes

This will re-generate the eclipse project configuration from Cmakefiles, to include the new files you added. If you are NOT using eclipse to develop, no need to do it at all, you can use standard makefiles.

You dont even need to use cmake again, just a make rebuild_cache; make; make install should work fine.

1
votes

There is no specific reason that you need Eclipse. If you just want the makefile, you can do:

cmake -G"Unix Makefiles"

To see all the other options do:

cmake -help