Currently I am analysing Pastec; it uses CMake as a build system. To split them up, I wanted to analyse it using the functionality of Eclipse.
Pastec can be built using following order.
$ git clone https://github.com/Visu4link/pastec.git $ mkdir build $ cd build $ cmake ../ $ make
To build Pastec in Eclipse CDT, instead of doing “cmake ..”, following order need to be done. (Debug build)
$ cd build $ cmake -G"Eclipse CDT4 - Unix Makefiles" -D CMAKE_BUILD_TYPE=Debug ..
Then, it can be imported into Eclipse:
- Import project using Menu File->Import
- Select General->Existing projects into workspace:
- Browse where your build tree is and select the root build tree directory(pastec/build). Keep “Copy projects into workspace” unchecked.
- You get a fully functional eclipse project