ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <k...@panix.com>
Subject Conditionally setting code variables
Date Wed, 19 Jun 2002 14:26:53 GMT




I'm still making the mental migration from C++/make to Java/Ant.  With
C++/make, I could have the conditional execution of make be in synch
with the conditional compilation of the source code, with tricks like
this:

# in makefile:
ifdef DEBUG
  DBG_FLGS='-g -DDEBUG'
else
  DBG_FLGS=
endif

foo: foo.o
	cc -o foo $(DBG_FLGS) foo.o


...and in the source file

...
#ifdef DEBUG
       /* print diagnostics */
#endif

etc.

Can I do the same thing using Java/Ant?

Thanks!

kj

--
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