title: XJC is generating wrong namespace in package-info.java
body: <p>the approach is to generate java classes by xsd using jaxb2-maven-plugin.</p>
  
  <p>The pom:</p>
  
  <pre><code>        &lt;plugin&gt;
              &lt;groupId&gt;org.codehaus.mojo&lt;/groupId&gt;
              &lt;artifactId&gt;jaxb2-maven-plugin&lt;/artifactId&gt;
              &lt;version&gt;1.5&lt;/version&gt;
              &lt;executions&gt;
                  &lt;execution&gt;
                      &lt;goals&gt;
                          &lt;goal&gt;xjc&lt;/goal&gt;
                      &lt;/goals&gt;
                  &lt;/execution&gt;
              &lt;/executions&gt;
              &lt;configuration&gt;
                  &lt;packageName&gt;${project.groupId}.model&lt;/packageName&gt;
                  &lt;extension&gt;true&lt;/extension&gt;
                  &lt;arguments&gt;-b ${resource.dir}/jaxbbindings.xsd -Xannotate&lt;/arguments&gt;
                  &lt;outputDirectory&gt;${basedir}/src/main/java&lt;/outputDirectory&gt;
                  &lt;schemaFiles&gt;1.0.xsd&lt;/schemaFiles&gt;
                  &lt;clearOutputDir&gt;true&lt;/clearOutputDir&gt;
              &lt;/configuration&gt;
              &lt;dependencies&gt;
                  &lt;dependency&gt;
                      &lt;groupId&gt;org.jvnet.jaxb2_commons&lt;/groupId&gt;
                      &lt;artifactId&gt;jaxb2-basics-annotate&lt;/artifactId&gt;
                      &lt;version&gt;0.6.4&lt;/version&gt;
                  &lt;/dependency&gt;
                  &lt;dependency&gt;
                      &lt;groupId&gt;com.sun.codemodel&lt;/groupId&gt;
                      &lt;artifactId&gt;codemodel&lt;/artifactId&gt;
                      &lt;version&gt;2.6&lt;/version&gt;
                  &lt;/dependency&gt;
                  &lt;dependency&gt;
                      &lt;groupId&gt;javax.persistence&lt;/groupId&gt;
                      &lt;artifactId&gt;persistence-api&lt;/artifactId&gt;
                      &lt;version&gt;1.0.2&lt;/version&gt;
                  &lt;/dependency&gt;
              &lt;/dependencies&gt;
          &lt;/plugin&gt;
  </code></pre>
  
  <p>And the xsd 1.0:</p>
  
  <pre><code>&lt;xs:schema
   targetNamespace="http://example.com/1.0"
   xmlns:gs="http://example.com/1.0"
   xmlns:cmn="http://example.com/another"
   xmlns:xs="http://www.w3.org/2001/XMLSchema"&gt;
     &lt;xs:import schemaLocation="another.xsd"
     namespace="http://example.com/another" /&gt;
     ....
   &lt;/xs:schema&gt;
  </code></pre>
  
  <p>As you can seen with the import tag I intend to import another schema. </p>
  
  <p>another.xsd:</p>
  
  <pre><code>&lt;xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
   elementFormDefault="qualified"
   targetNamespace="http://example.com/another"
   xmlns:vt="http://example.com/another"&gt;
    ...
  &lt;/xs:schema&gt;
  </code></pre>
  
  <p>So, if maven executes XJC to generate the java classes by XSD, the package-info is also generated:</p>
  
  <pre><code>@javax.xml.bind.annotation.XmlSchema(namespace = "http://example.com/another")
  package de.fraunhofer.fokus.testing.fokusmbt.specexplorer.model;
  </code></pre>
  
  <p>As you can seen above the namespace is <a href="http://example.com/another" rel="nofollow">http://example.com/another</a>. But this is wrong. The namespace should be <a href="http://example.com/1.0" rel="nofollow">http://example.com/1.0</a>.</p>
  
  <p>The another stuff works fine (generating java classes and so on).</p>
  
  <p>What do I wrong?</p>