Page 1 of 1

Macro in project's environement

Posted: Wed Sep 07, 2011 10:45 pm
by VRH
Hi,

I use Codelite 3.0.5051, self build on a linux (x86_64) workstation

I have a custom makefile project

I would like to define an environnement variable in the project, using a macro.

so I try this :

Code: Select all

MYVAR=$(ProjectName)-$(ConfigurationName)
but when I build the project, the value of MYVAR is -

Setting a variable without macro is working fine.
Also, if a try :

Code: Select all

MYVAR=$(ANOTHERVAR)
where ANOTHERVAR is defined in codelite environement, MYVAR has the good value.

Did I make something wrong ?
Is there a bug ?

Re: Macro in project's environement

Posted: Wed Sep 07, 2011 11:57 pm
by eranif
Atm, the project macros and environment variables are two different entities
If you need the macros to be accessible in the project environment variable text area, please submit a feature request

Eran

Re: Macro in project's environement

Posted: Thu Sep 08, 2011 2:05 pm
by josee
Hi,

I'm also using a custom makefile.
And to build the correct version I enter into 'project settings -> Custom Build' something like 'make $(ProjectName)_$(ConfigurationName)'.
So there is no need for an environment variable.

See also the picture:
Bildschirmfoto-testunit Project Settings.png

Re: Macro in project's environement

Posted: Fri Sep 09, 2011 11:00 pm
by VRH
Ok, so macro in environnement form are not supported, i will post a demand as soon as I will have time.

@josee
I understand what you proposed, but I really need that to build my project.
I post only an example, environnement variables are used a lot in my makefiles, build scripts.
I can't define a specific rules for doing what I need, and other member of the project use different IDE, so it's hard to rewrite every thing for my need.