> -----Original Message----- > From: David W Forslund [mailto:[EMAIL PROTECTED] > The reason is fairly simple. When a single environment variable is > used for an exec task, all the environment must passed. If you only > want to add to CLASSPATH, you have to know what to use for PATH, when > you have no intent to change it. Otherwise, there is no PATH variable > in the environment as a side effect of changing some other environment > variable.
No, I understand the mechanics; I'm arguing the approach (which is kind of off topic, so let's take this private if need be). When do you use the PATH variable in a build? If you use it to pick up your java executable, your C compiler, etc. then you don't know conclusively what tools you're using to build your project. If you are running a task that relies on an exec, and that exec is making use of the PATH variable (however it gets passed in), then what it's picking up is not reproducible. Short version: always use full paths to executables when building software projects. My make- and buildfiles for example always do whatever they can to ensure that PATH is set to the empty set. Cheers, Laird
