Closed GaryAitken closed 6 years ago
The xjc goal has two parameters:
sources
for XSD files which defaults to src/main/xsd
xjcSources
for XJB binding files which defaults to src/main/xjb
The message is about the second parameter. I think the message is confusing and should not be written as INFO output, maybe at DEBUG.
The plugin seems to resolve relative paths against the project's base directory. For your example, the source file should be configured as src/main/xsd/Foo.xsd
.
Actually, Example 6 on the same side documents the XJB files, default directory as well as provides examples from POM and XJB files.
The default source directory for the xjc goal appears to be "src/main/xjb", not "src/main/xsd". If a single file is specified in with no path, e.g. "Foo.xsd", the file is treated as non-existent with the INFO messages:
[INFO] Ignored given or default sources [Foo.xsd], since it is not an existent file or directory.
[INFO] Ignored given or default xjbSources [/home/user/project/src/main/xjb], since it is not an existent file or directory.
[INFO] No changes detected in schema or binding files - skipping JAXB generation.
The examples page for the plugin
http://www.mojohaus.org/jaxb2-maven-plugin/Documentation/v2.2/example_xjc_basic.html
states that the default directory is "src/main/xsd" under "Example 4".