Page 1 of 1

Using existing makefiles

Posted: Sat Dec 05, 2009 2:11 am
by remo.d
I understand that CodeLite is able to use existing makefiles but I've not been able to understand how to do it in my case.

My project contains a libraries and many executables stored in different directories.:

Code: Select all

  O
  |
  +-- examples
  |       +----- pmx
  |       |         +---- pmx.c
  |       |         +---- makefile
  |       |
  |       +----- unc
  |       |         +---- makefile
  |       |         +---- unc.c
  |     ....
  |       
  +-- src
  |    +--- tbl.h
  |    +--- tbl.c
  |    +--- makefile
  | 
The makefiles are rather complex and behaves depending on the directory I'm in when I launch the "make" process. I currently use pspad on Windows that allows me to start "make" passing the proper argument (e.g. "make release" or "make debug") and using the right directory depending on the file I'm editing.

Is it possible to do something similar with CodeLite? I'd like to swith from an editor (even if good as PsPad) to a real IDE like CodeLite with all the integrated facilies (the debugger and the identifiers crossrerence, mainly).

I wouldn't want to have to revisit the entire building process as the current one is only dependent on gnu-make.

Re: Using existing makefiles

Posted: Sat Dec 05, 2009 5:49 pm
by eranif
This is currently not possible in the released version (2.0.3365)

This is possible using the trunk version of codelite. You can use the '$(CurrentFilePath)' macro as the working directory under the 'Custom Build' tab in the 'Project Settings'
This will set to the working directory to $(CurrentFilePath) before executing the command under the 'Build/Clean/Rebuild/Compile Single File commands

Eran

Re: Using existing makefiles

Posted: Sat Dec 05, 2009 11:03 pm
by remo.d
Thank you Eran, I'll keep an eye on next release then.

Remo.D