I'm doing a similar thing like Diane, and I have a wrapper shell script that goes through the command-line and builds up Ant's command-line.
For example, if -release is present on the command-line, then "-Ddebug.jar=ReleaseLib.jar -Drelease.build=on" is added to the Ant command-line, otherwise "-Ddebug.jar=DebugLib.jar" is added. I can then use the if/unless attributes of the target task with the release.build property to do the debug vs release build compiles. -- Scotte -----Original Message----- From: Diane Holt [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 10, 2000 11:20 PM To: [EMAIL PROTECTED] Subject: RE: [PATCH] New <case> task --- [EMAIL PROTECTED] wrote: > Just curious as to whether there is a specific problem that you are > trying to overcome with the addition of this task. It usually helps me > if I can associate a given solution with the problem it's trying to > overcome. Don't know what Jose Alberto's particular need is, but I can tell you one of the things I'd like it for... I have a property that contains a value of either "true" or "false" -- note: it's not something I can have simply either set or not-set, because the literal value of it is used as the replacement string for a filter token. The token is the value of a boolean in a .java file, and depending on whether it is set to "true" or "false" determines whether the source-tree is being compiled with debug code or without (note: not -g -- it determines whether to include code that's the equivalent of #ifdef DEBUG in C). So, it'd be nice to also be able to use the value of that property to determine what flavor of build this is, and set other things (like the outdir) accordingly. But, having said all that, I should add that I have been trying out the <script> task, and it looks like it would be possible to do that sort of thing with that. On the other hand, it does mean, as Jose Alberto pointed out, having to add in all the optionals for having <script> available (and trying to remember how to even use javascript, which I haven't for months, and back when I did, I only learned it and used it for a couple of weeks, so it's not exactly engrained in my brain just yet :) Diane ===== ([EMAIL PROTECTED]) __________________________________________________ Do You Yahoo!? Get Yahoo! Mail - Free email you can access from anywhere! http://mail.yahoo.com/
