[
https://jira.codehaus.org/browse/MJAR-142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=333642#comment-333642
]
Dennis Lundberg commented on MJAR-142:
--------------------------------------
Hi Ron,
I was merely pointing out that the stacktrace was not the same and the plugin
where the failure occured was not the JAR plugin.
The real problem though doesn't seem to be in the JAR plugin, but rather in
plexus-archiver, since we now have three different plugins that show the same
problem; JAR, Assembly and Jangaroo.
> 'Negative time' when trying to create an empty jar
> --------------------------------------------------
>
> Key: MJAR-142
> URL: https://jira.codehaus.org/browse/MJAR-142
> Project: Maven JAR Plugin
> Issue Type: Bug
> Affects Versions: 2.3
> Environment: Windows 7
> maven 3.0.2
> Reporter: bblasi bblasi
>
> When I try to run 'package' on a multi-module project one of the modules
> fails. The only difference on this module being it will run an ant script so
> no jar, or an empty one up until now, would be generated.
> Plugin 2.2 will do the job. Plugin 2.3 fails on '-X package' with:
> {code}
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-jar-plugin:2.3.1:jar (default-jar) on project
> ETRAMPackager: Error assembling JAR: Negative time -> [Help 1]
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute
> goal org.apache.maven.plugins:maven-jar-plugin:2.3.1:jar (default-jar) on
> project ETRAMPackager: Error assembling JAR
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
> at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
> at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
> at
> org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
> at
> org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:319)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
> at org.apache.maven.cli.MavenCli.execute(MavenCli.java:534)
> at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:597)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
> at
> org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Error assembling
> JAR
> at
> org.apache.maven.plugin.jar.AbstractJarMojo.createArchive(AbstractJarMojo.java:223)
> at
> org.apache.maven.plugin.jar.AbstractJarMojo.execute(AbstractJarMojo.java:235)
> at
> org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:107)
> at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
> ... 19 more
> Caused by: java.lang.IllegalArgumentException: Negative time
> at java.io.File.setLastModified(File.java:1258)
> at
> org.codehaus.plexus.components.io.resources.PlexusIoFileResource.setLastModified(PlexusIoFileResource.java:148)
> at
> org.codehaus.plexus.components.io.resources.PlexusIoFileResource.setFile(PlexusIoFileResource.java:82)
> at
> org.codehaus.plexus.components.io.resources.PlexusIoFileResource.<init>(PlexusIoFileResource.java:73)
> at
> org.codehaus.plexus.components.io.resources.PlexusIoFileResourceCollection.addResources(PlexusIoFileResourceCollection.java:144)
> at
> org.codehaus.plexus.components.io.resources.PlexusIoFileResourceCollection.getResources(PlexusIoFileResourceCollection.java:181)
> at
> org.codehaus.plexus.components.io.resources.AbstractPlexusIoResourceCollection.getLastModified(AbstractPlexusIoResourceCollection.java:247)
> at
> org.codehaus.plexus.archiver.AbstractArchiver.isUptodate(AbstractArchiver.java:768)
> at
> org.codehaus.plexus.archiver.AbstractArchiver.checkForced(AbstractArchiver.java:799)
> at
> org.codehaus.plexus.archiver.zip.AbstractZipArchiver.execute(AbstractZipArchiver.java:236)
> at
> org.codehaus.plexus.archiver.AbstractArchiver.createArchive(AbstractArchiver.java:852)
> at
> org.apache.maven.archiver.MavenArchiver.createArchive(MavenArchiver.java:543)
> at
> org.apache.maven.plugin.jar.AbstractJarMojo.createArchive(AbstractJarMojo.java:216)
> ... 22 more
> [ERROR]
> [ERROR]
> [ERROR] For more information about the errors and possible solutions, please
> read the following articles:
> [ERROR] [Help 1]
> http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
> [ERROR]
> [ERROR] After correcting the problems, you can resume the build with the
> command
> [ERROR] mvn <goals> -rf :ETRAMPackager
> {code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira