import existing C++ code and its Makefile in Eclipse (Linux)

Cuma catatan doank biar gampang nyari kalo bsok lupa.. 😀 kbetulan lagi pengen nyobain ngutak-ngatik source code punya orang.. kbetulan jg lagi pengen ngrasain make Eclipse di Linux..

1. Create a new project, File > New > C++ Project.

2. C++ Project window will appear.

a. Give the project name same as the existing C++ code’s folder.

b. in Project Type column, select Makefile project > Empty project.

c. select the compiler type in the Toolchain column.

d. click Next and then Finish.

3. Now you will see new project in Project Explorer box.

a. Right click on it and Refresh.

b. Now all the cpp and Makefile will appear in the box.

4. Now we need to set the builder setting

a. Go to Project > Properties.

b. click C/C++ Build.

c. in Builder Setting tab, uncheck the Use default build command and Generate Makefiles automatically boxes.

d. in Behaviour tab, uncheck the Build on resource save (Auto build). If you have additional option in compiling, you may add it in the checked Build (Incremental build).

e. click Apply and OK.

5. Now you can try compile your project, go to Project > Build Project. Then you can try Run your project.

6. If you have additional argument, you can set it in Run > Run Configurations.. > Argument tab

Images for your reference,[slideshow]

Leave a Reply

Your email address will not be published. Required fields are marked *