Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Issues with an acquired build.xml

 
High Plains Drifter
Posts: 7289
Netbeans IDE VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm trying to play with a few betas I came across recently, which require me to know more about ANT than how to run it.

I've installed this download on Windows and Solaris both. I was able to build on Windows, albeit with lots of warnings and minor failures. On Solaris, however, I'm getting the error 'Unexpected element "condition"'

Elsewhere I learned condition tags have to be nested in target tags -- fine. In this build.xml, the condition tag that excepted clearly is not. I don't know what to do about that, other than comment it out and hope for the best.

But...how did I build on Windows then? Are there different ANT differents or interpreters that might allow an unnested condition?
 
Saloon Keeper
Posts: 22256
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ant's been around quite a while and seen quite a few changes. So I'd do a quick version check.

It's possible (though probably not in good taste) to create an external task named "condition". Maybe someone did and it wasn't installed on the failing system. Since literally "condition" is a test, not an action, it really shouldn't be a task-level tag. Although I have vague memories of doing something similar long ago.

I've created Ant scripts that when run on Windows created JAR files, when run on Solaris created Solaris packages and when run on Linux created RPM install packages. I have full confidence in its portability.
 
Michael Ernest
High Plains Drifter
Posts: 7289
Netbeans IDE VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Tim.

All I wanted to do was run Fortress, a language under development at Sun. To do that, I gotta install Cygwin or build a Solaris box, so I go Cygwin. Then I need subversion to check it out, then I need Ant to build it. And of course every tool along the way has some obscure need or complaint to track down...

Sigh.
 
Michael Ernest
High Plains Drifter
Posts: 7289
Netbeans IDE VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just an update; I re-read the docs and discovered I needed Ant 1.5. I updated to 1.7, corrected a few environment variables, et voila. Thanks Tim.
 
Hey, I'm supposed to be the guide! Wait up! No fair! You have the tiny ad!
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic