Page 1 of 1

Makefile CMakeLists.txt

Posted: Thu Sep 06, 2012 6:14 pm
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.

Re: Makefile CMakeLists.txt

Posted: Thu Sep 06, 2012 6:31 pm
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