[Scons-users] dependencies when you define environment variables
Gary Oberbrunner
garyo at oberbrunner.com
Thu Jul 19 10:49:42 EDT 2012
On Thu, Jul 19, 2012 at 4:44 AM, TOM TANNER (BLOOMBERG/ LONDON)
<ttanner2 at bloomberg.net> wrote:
> On the whole, that (adding the thing to the builder /call/) is rather unfortunate as it means the client needs to know something of how the builder is implemented and it means if we replace a toolchain with another toolchain that behaves slightly differently we need to go and find all the clients thereof and replace the calls.
>
> Yes, I know I'm being picky. But my experience is that little things like that can trip people up and cause embarassing problems later on down the line, and hiding 'implementation details' like that would seem to be a good thing to do.
Not being picky at all. What you say makes total sense; I was just
explaining what you can do today (vs. changes we could make in the
future).
I think what you'd like is for env[ENV] variable values to go through
the construction-variable substitution process, so you could set
env['ENV']['FOO'] to "$SOURCE abc" and it would dynamically pick up
the source each time the builder runs. Maybe it could be enabled as
an option per-builder or something (we couldn't do it all the time,
since it would produce pretty odd results if you happen to have a $ in
any env var, and anyway it'd be slow).
As an alternative, what if emitters could alter the env's construction
vars the same way they modify the target and source lists? That would
fill your need as well.
Could you submit an enhancement request to Tigris?
--
Gary
More information about the Scons-users
mailing list