The fix for this normally is to exclude both asm and cglib from the
hibernate dependency and then add cglib-nodeps as a dependency to your
project.   Thus, hibernate will use the cglib-nodeps stuff which includes
the masked version it requires.

The cobertura and spring deps are fine.   CXF will work with any 2.x or 3.x
version of asm so pulling that in is fine.  

Dan Kulp




Mick Knutson-4 wrote:
> 
> I keep getting the following errors:
> *Caused by: java.lang.NoSuchMethodError:
> org.objectweb.asm.ClassVisitor.visit(ILjava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)V
> *
> *    at net.sf.cglib.core.ClassEmitter.begin_class(ClassEmitter.java:63)*
> 
> The standard fix talks about cgi-full already having the asm classes in
> it.
> This means I need to exclude asm in my build I assume.
> So I have:
>         <dependency>
>             <groupId>cglib</groupId>
>             <artifactId>cglib-full</artifactId>
>             <version>2.0.2</version>
>             *<exclusions>
>                 <exclusion>
>                     <groupId>asm</groupId>
>                     <artifactId>asm</artifactId>
>                 </exclusion>
>             </exclusions>*
>         </dependency>
> 
> But I still get asm 1.5.3, 2.2.1 and 2.2.3 downloaded.
> 
> Now when I look at my REPO and try to see what depends upon asm, I find
> that
> hibernate needs 1.5.3, and cobertura needs 2.2.1, and spring-2.5.2 needs
> 2.2.3
> 
> So should I just add excludes for asm on hibernate and cobertura?
> 
> 
> -- 
> Thanks,
> Mick Knutson
> 
> http://www.baselogic.com
> http://www.blincmagazine.com
> http://www.linkedin.com/in/mickknutson
> http://www.djmick.com
> http://www.myspace.com/mickknutson
> http://www.myspace.com/BLiNCMagazine
> http://tahoe.baselogic.com
> ---
> 
> 

-- 
View this message in context: 
http://www.nabble.com/-m2--Issue-with-asm-Dependancy-and-cxf-tp17117334p17117618.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to