ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <k...@panix.com>
Subject Target/flag inconsistency resolution
Date Thu, 27 Jun 2002 13:02:15 GMT




I want ant to ignore the value of a certain flag whenever a particular
target is being built.  E.g., consider this:

  <target name="baz" depends="dist">
  // yadda-yadda-yadda
  </target>

  <target name="dist" depends="foo">
  // yadda-yadda-yadda
  </target>

  <target name="foo" unless="nofoo">
  // but the value of nofoo should be ignored if we are in the
  // process of building baz!
  // yadda-yadda-yadda
  </target>

When I execute plain old "ant" I get foo first and then dist; and when
I execute "ant -Dnofoo=true", I get just dist.  This is fine.  But if
I execute "ant baz -Dnofoo=1", I want to ignore the -Dnofoo=1 flag and
build foo anyway.  In other words the target baz is inconsistent with
a non-null nofoo, and this inconsistency should be resolved in favor
of unsetting nofoo.  How can I implement this?

Thanks!

kynn

P.S. Please Cc: me in replies.

--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


Mime
View raw message