[Scons-users] Running all external commands under a wrapper

Mats Wichmann mats at wichmann.us
Mon May 4 09:24:11 EDT 2020


On 5/3/20 9:19 AM, Andrew C. Morrow wrote:

> - We probably want, at some point, to not need to shell out at all, for
> commands that don't need shell behavior. But I still would want the
> icerun wrapper in play.

this has frustrated me for a while... on Windows, firing off a shell
when you don't need a shell is a performance hit that we don't need.  we
*do* use features of cmd occasionally through (COPY).

in addition, the way this is wired up frustrated me trying to
experimentally move away from using os.spawnve. I should probably try to
get back to that at some point.

> I wonder if something else is required entirely, like an
> EXTERNAL_COMMAND_WRAPPERS list, which, abusing some notation, gets
> expanded like:
> 
> $SPAWN($SHELL $EXTERNAL_COMMAND_WRAPPERS $COMMAND)
> 
> Then, I could just say:
> 
> env.PrependUnique(EXTERNAL_COMMAND_WRAPPERS=['icerun'])

sounds like a reasonable desire to me.



More information about the Scons-users mailing list