This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin for Android App Development and have Peter Sommerhoff on-line!
See this thread for details.
Win a copy of Kotlin for Android App Development this week in the Kotlin 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
  • Liutauras Vilda
  • Devaka Cooray
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Junilu Lacar
  • Paul Clapham
  • Knute Snortum
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • salvin francis
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Frits Walraven
  • Ganesh Patekar

Ant and Jaxb not playing nicely together  RSS feed

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm an ant neophyte so I may be asking an obvious question but I'm not able to get xjc tasks to run within ant.

This is an inherited project so I've got an ant file that I really know nothing about. That and I've never really used jaxb much either so

I've checked that xjc is actually working on the .xsd files so I don't think xjc it self is the problem.

The error I'm currently getting is


And the target that it fails on is


I'm not sure what other information might be useful in figuring out what I'm doing wrong. Google only seems to return the excerpt of code where the error message was added to make the error more 'understandable'.

Thanks in advance,

TK
 
author
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I can only guess:

- for javac, the "target" option actually expects the version of the Java specification to use

- for xjc, they might have used "target" to mean the target directory, but to reduce confusion, perhaps they changed the name to "destdir"?

So what I would try is using destdir instead of target.
 
Tj Kendon
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, that solves the problem exactly. I had assumed that it was talking about the ant target and not the target attribute inside the target.

Thank you!
 
Tj Kendon
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That solves the problem. Thank you.

I had been assuming that the error was relating to the ant 'target' and not the target attribute.

Much appreciated.

-tk
 
Ilja Preuss
author
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You're welcome!
 
All of the world's problems can be solved in a garden - Geoff Lawton. Tiny ad:
RavenDB is an Open Source NoSQL Database that’s fully transactional (ACID) across your database
https://coderanch.com/t/704633/RavenDB-Open-Source-NoSQL-Database
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!