Question

Running $mvn test on a 64-bit Windows gives me the following error, even if I do $mvn test -Dgwt.genParam=false:

The command line is too long
Était-ce utile?

La solution

Make sure you are using version 2.16 and that you have the useManifestOnlyJar option (as documented here).

For example:

<project>
    [...]
    <build>
      <pluginManagement>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <version>2.16</version>

            <configuration>
                <useManifestOnlyJar>true</useManifestOnlyJar>
            </configuration>

          </plugin>
        </plugins>
      </pluginManagement>
    </build>
    [...]
</project>

This will create jar with a manifest that re-creates your classpath (as opposed to setting it via the CLASSPATH variable which is an approach that is affected by Windows' command-line limit problem).

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top