Hello, I have a few closely related questions:
1. Does CB currently support using environment variables as part of the include/link paths (in terms of using such a path, not in terms of specifying it - I know the latter is not suported through the IDE (right?)).
2. If the answer to 1 is positive, is there a cross-platform syntax to specify the environment variables?
3. What is the syntax to specify the environment variables (if there is one)?
$(SOME_ENV_VAR)
Yiannis.
IMPORTANT NOTE:
With "environment variables" I think Yiannis referred to "Custom variables" specified elsewhere. And (someone correct me if i'm wrong) IIRC, using "real environment variables" wasn't supported in 1.0-finalbeta. It was added later in CVS.
I might be blind but I dont see any option to specify "real environment variables", and I just compiled the CVS version...
In case Im wrong, were can I specify such option?
And last, is this related to the request of someone (who also pointed in the request to a thread where you were in, rickg22) in sf, relating "pre-command line" or something like this?
hmm maybe i was wrong then. Sorry :oops:
Quote1. Does CB currently support using environment variables as part of the include/link paths (in terms of using such a path, not in terms of specifying it - I know the latter is not suported through the IDE (right?)).
This feature was added last week. You can use environment variables anywhere in compiler settings.
Quote2. If the answer to 1 is positive, is there a cross-platform syntax to specify the environment variables?
3. What is the syntax to specify the environment variables (if there is one)?
You can use any of these forms, no matter what platform you work on:
$SOMEVAR
$(SOMEVAR)
${SOMEVAR}
%SOMEVAR%Yiannis.
Yiannis, where exactly, I cant seem to make the PATH env variable to work (I use it inside my app, but I specify some values for it in custom variables and more options in compiler settings but nothing happens)
Maybe I wasn't clear enough:
You cannot set environment variables, only use (aka read) them...
It's not difficult to set env vars too, but what's the point? They 'll only be valid while C::B is running...
[EDIT]: we are talking about the CVS version, right?
Yiannis.
Oh! I get what you mean... and yes, its cvs were talking about
Well, now that we were talking about it, I 've found a bug in the implementation that would allow env vars only in global compiler options.
I 'm fixing it now and I 'm also adding the ability to set env vars :)
Yiannis.
Oh cool, I was actually starting to make a plugin to set environment vars (already have a somewhat implementation in project->set execution parameters), but you're the man.
Please tell me when you're done as Id like to test it!
Cheers
Follow up here (http://www.codeblocks.org/index.php?name=PNphpBB2&file=viewtopic&t=542&start=0&postdays=0&postorder=asc&highlight=).
Yiannis.