[hibernate-dev] If Unable to compile core, try this

Emmanuel Bernard emmanuel at hibernate.org
Mon Aug 10 11:09:48 EDT 2009


If you see the following when compiling core/core
mvn clean install or mvn -e clean install

=> do

rm -fR ~/.m2/repository/org/hibernate/
rm -fR ~/.m2/repository/org/jboss/maven/

That does the trick for me.


-------

[INFO] [compiler:compile]
[INFO] Nothing to compile - all classes are up to date
[INFO] [injection:bytecode {execution: default}]
[INFO] Adding project compile classpath element : /Users/manu/projects/ 
trunk/core/core/target/classes
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/antlr/antlr/2.7.6/antlr-2.7.6.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/commons-collections/commons-collections/3.1/commons- 
collections-3.1.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/dom4j/dom4j/1.6.1/dom4j-1.6.1.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/xml-apis/xml-apis/1.0.b2/xml-apis-1.0.b2.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/javassist/javassist/3.9.0.GA/javassist-3.9.0.GA.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/cglib/cglib/2.2/cglib-2.2.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/asm/asm/3.1/asm-3.1.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/javax/transaction/jta/1.1/jta-1.1.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/javax/security/jaas/1.0.01/jaas-1.0.01.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/javax/security/jacc/1.0/jacc-1.0.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/ant/ant/1.6.5/ant-1.6.5.jar
[INFO] Adding project compile classpath element : /Users/manu/.m2/ 
repository/org/slf4j/slf4j-api/1.5.8/slf4j-api-1.5.8.jar
[INFO]  
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]  
------------------------------------------------------------------------
[INFO] Unable to resolve class file path

[INFO]  
------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Unable to  
resolve class file path
	at  
org 
.apache 
.maven 
.lifecycle 
.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java: 
584)
	at  
org 
.apache 
.maven 
.lifecycle 
.DefaultLifecycleExecutor 
.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:500)
	at  
org 
.apache 
.maven 
.lifecycle 
.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:479)
	at  
org 
.apache 
.maven 
.lifecycle 
.DefaultLifecycleExecutor 
.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
	at  
org 
.apache 
.maven 
.lifecycle 
.DefaultLifecycleExecutor 
.executeTaskSegments(DefaultLifecycleExecutor.java:292)
	at  
org 
.apache 
.maven 
.lifecycle 
.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
	at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
	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:585)
	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: Unable to  
resolve class file path
	at org.jboss.maven.plugins.injection.BytecodeInjectionMojo 
$BaseInjectionTarget.<init>(BytecodeInjectionMojo.java:127)
	at org.jboss.maven.plugins.injection.BytecodeInjectionMojo 
$MethodBodyReturnReplacementTarget.<init>(BytecodeInjectionMojo.java: 
185)
	at org.jboss.maven.plugins.injection.BytecodeInjectionMojo 
$MethodBodyReturnReplacementTarget.<init>(BytecodeInjectionMojo.java: 
181)
	at  
org 
.jboss 
.maven 
.plugins 
.injection 
.BytecodeInjectionMojo 
.generateBytecodeInjectionTarget(BytecodeInjectionMojo.java:96)
	at  
org 
.jboss 
.maven 
.plugins 
.injection 
.BytecodeInjectionMojo.generateDescriptor(BytecodeInjectionMojo.java:86)
	at  
org 
.jboss 
.maven 
.plugins 
.injection 
.BytecodeInjectionMojo 
.getInjectionDescriptors(BytecodeInjectionMojo.java:78)
	at  
org 
.jboss 
.maven 
.plugins 
.injection.AbstractInjectionMojo.execute(AbstractInjectionMojo.java:45)
	at  
org 
.apache 
.maven 
.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
	at  
org 
.apache 
.maven 
.lifecycle 
.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java: 
559)
	... 16 more
Caused by: java.lang.NullPointerException
	at org.jboss.maven.plugins.injection.BytecodeInjectionMojo 
$BaseInjectionTarget.<init>(BytecodeInjectionMojo.java:123)
	... 24 more




More information about the hibernate-dev mailing list