Details
Description
I have a created a simple project that includes a module with a packaging type of ejb. This module does not yet contain any Java classes. When I run mvn clean package I get the following error:
There was a problem creating the EJB archive: /home/jlittlej/workspace/todo/trunk/ToDo-Core/target/classes isn't a directory.
If the packaging type is jar, this error does not occur - a normal jar that doesn't contain any classes is built. If the packaging type is ejb, the build fails.
Full trace:
[INFO] Trace org.apache.maven.lifecycle.LifecycleExecutionException: There was a problem creating the EJB archive: /home/jlittlej/workspace/todo/trunk/ToDo-Core/target/classes isn't a directory. at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138) at org.apache.maven.cli.MavenCli.main(MavenCli.java:362) at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60) 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.classworlds.Launcher.launchEnhanced(Launcher.java:315) at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) at org.codehaus.classworlds.Launcher.main(Launcher.java:375) Caused by: org.apache.maven.plugin.MojoExecutionException: There was a problem creating the EJB archive: /home/jlittlej/workspace/todo/trunk/ToDo-Core/target/classes isn't a directory. at org.apache.maven.plugin.ejb.EjbMojo.execute(EjbMojo.java:256) at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694) ... 17 more Caused by: org.codehaus.plexus.archiver.ArchiverException: /home/jlittlej/workspace/todo/trunk/ToDo-Core/target/classes isn't a directory. at org.codehaus.plexus.archiver.AbstractArchiver.addFileSet(AbstractArchiver.java:208) at org.codehaus.plexus.archiver.AbstractArchiver.addDirectory(AbstractArchiver.java:194) at org.codehaus.plexus.archiver.AbstractArchiver.addDirectory(AbstractArchiver.java:182) at org.apache.maven.plugin.ejb.EjbMojo.execute(EjbMojo.java:244) ... 19 more