<div dir="ltr">Sorry wrong ML :(.</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Jul 19, 2013 at 4:36 PM, Nicolas Desprès <span dir="ltr"><<a href="mailto:nicolas.despres@gmail.com" target="_blank">nicolas.despres@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div><br></div><div>In Unix shell we can do that:</div><div>$ VAR=foo cmd in out</div><div><br></div>

<div>This way the environment variable is only set in the environment of the process of the command and not the in current shell like when using the "export" built-in.</div>
<div><br></div><div>I would like to be able to do the same for a custom command in CMake. Ideally I was looking for something like that:</div><div><br></div><div>add_custom_command(</div><div>
  OUTPUT out</div><div>  COMMAND cmd in out</div><div>  DEPENDS in</div><div>  ENVIRONMENT VAR foo</div><div>  )</div><div><br></div><div>Any idea?</div><div><br></div><div>
Cheers,</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>-- <br></div><div>Nicolas Desprès<br>
</div></font></span></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>Nicolas Desprès<br>
</div>