ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Diane Holt <>
Subject RE: Need help running Ant under cygwin on Win2k
Date Wed, 19 Jun 2002 21:48:49 GMT
--- Chris Bailey <> wrote:
> Putting it in the path is not really acceptable.

That's why I also suggested using <env> instead, so you could include the
dir the script lives in when you run your <exec>.

To make the whole thing platform-independent, you'd want to set up a
<path> based on where the script lives plus your PATH env var (so you'd
need to do a <property environment=.../>), then <pathconvert> that <path>
into a property, and reference that property in the 'value' for the <env>.
For example:

  <property name="filename" value="src/lib/foo.a"/>
  <property environment="env"/>
  <path id="path" path="${env.PATH}:${env.TEMP}/bin"/>
  <target name="main">
    <pathconvert pathsep="${path.separator}" refid="path"
    <exec executable="sh">
      <arg line='-c " ${filename}"'/>
      <env key="PATH" value="${path}"/>



Do You Yahoo!?
Yahoo! - Official partner of 2002 FIFA World Cup

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message