Makefile CMakeLists.txt

General questions regarding the usage of CodeLite
danielk1bg
CodeLite Curious
Posts: 1
Joined: Thu Sep 06, 2012 6:11 pm
Genuine User: Yes
IDE Question: C++
Contact:

Makefile CMakeLists.txt

Post by danielk1bg »

Hello,
I would like to import a makefile (generated by cmake) or directly a CmakeLists.txt file. Is that possible in CodeLite?

Thanks.
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Makefile CMakeLists.txt

Post by eranif »

Depends on your definition for "Import"

If by "import" you refer to "I want to use my own makefile instead of the ones generated by codelite" then yes, you can do it

To do this:
    • Right click on the project, and select 'Settings...'
    • Select the entry 'Customize'
    • Enable this tab by clicking the 'Enable Custom Build'
    • Enter targets or use the existing ones (Build, Clean, Rebuild etc)
    • for example, double click on the 'Build' entry and type 'make' this will tell codelite to simply run 'make' when user hit the build icon (little hammer) in the toolbar
Note that this tab simply maps between various "Targets" and the actual command
If you are also want to run cmake from within codelite, you can also add new target for this

All these targets are accessible from the project context menu (right click it) -> Custom Build Targets

there is also this page on the wiki:
http://codelite.org/LiteEditor/CustomMakefiles
Its a bit outdated (mainly the Project Settings dialog UI was changed), but it gives a good explanation of how to use this

Eran
Make sure you have read the HOW TO POST thread
Post Reply