I found the problem: for other purposes, I had modified the %PATH% variable to point to a 1.4.x JRE bin folder. So even if my JAVA_HOME was pointing to a 1.5 SDK, there was a problem with the JPOX plugin because it seems that it launches a "java ..." command in a new process... so JPOX was running on a 1.4 JVM.
Now, everything works fine. Whew!! :-) Fabrice. On 6/21/07, Emmanuel Venisse <[EMAIL PROTECTED]> wrote:
It works fine for me. The difference I see is the OS (WinXP and OSX) Emmanuel Fabrice Bellingard a écrit : > Still the same problem running a "clean install" with the following > configuration: > - Win2k > - JDK 1.5.0_012 > - Maven 2.0.7 > > No one else has the same issue? > > Fabrice. > > On 6/21/07, Brett Porter <[EMAIL PROTECTED]> wrote: >> >> No problems here, or on the solaris zone. You ran with clean as well? >> >> I'd suggest upgrading your JDK if it really is _01 - that's pretty >> old :) >> >> - Brett >> >> On 20/06/2007, at 8:42 PM, Fabrice Bellingard wrote: >> >> > Hi Brett, >> > >> > I updated my workspace today and tried to build Archiva, and I get >> > an error >> > during JPOX enhancement, in the archiva-model module >> > (UnsupportedClassVersionError, see at the end of the mail for the >> > log). If I >> > use the last revision of the Archiva's root POM (that is, with >> > compiler set >> > to 1.4), then Archiva builds fine. >> > I'm using JDK 1.5.0_01 to run Maven. >> > >> > Any idea? >> > >> > Thanks, >> > Fabrice. >> > >> > ============================================================ >> > >> > INFO [JPOX.Enhancer] - JPOX Enhancer : Input Files >> > JPOX Enhancer : Input Files >> > INFO [JPOX.Enhancer] - >> >> > C:\Archiva\workspace\archiva\archiva-base\archiva-model\target >> > \classes\org\apache\maven\archiva\model\package.jdo >> >>> >> > C:\Archiva\workspace\archiva\archiva-base\archiva-model\target >> > \classes\org\apache\maven\archiva\model\package.jdo >> > >> > INFO [JPOX.Enhancer] - JPOX Enhancer : Using ClassEnhancer "BCEL" >> > JPOX Enhancer : Using ClassEnhancer "BCEL" >> > >> > >> > [ERROR] -------------------- >> > [ERROR] Standard error from the JPox enhancer tool: >> > [ERROR] -------------------- >> > [ERROR] java.lang.UnsupportedClassVersionError: >> > org/apache/maven/archiva/model/ArchivaRepositoryModel (Unsupported >> > major.minor version 49.0) >> > at java.lang.ClassLoader.defineClass0(Native Method) >> > at java.lang.ClassLoader.defineClass(Unknown Source) >> > at java.security.SecureClassLoader.defineClass(Unknown Source) >> > at java.net.URLClassLoader.defineClass(Unknown Source) >> > at java.net.URLClassLoader.access$100(Unknown Source) >> > at java.net.URLClassLoader$1.run(Unknown Source) >> > at java.security.AccessController.doPrivileged(Native Method) >> > at java.net.URLClassLoader.findClass(Unknown Source) >> > at java.lang.ClassLoader.loadClass(Unknown Source) >> > at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) >> > at java.lang.ClassLoader.loadClass(Unknown Source) >> > at org.jpox.JDOClassLoaderResolver.classOrNull( >> > JDOClassLoaderResolver.java:510) >> > at org.jpox.JDOClassLoaderResolver.classForName( >> > JDOClassLoaderResolver.java:196) >> > at org.jpox.JDOClassLoaderResolver.classForName( >> > JDOClassLoaderResolver.java:362) >> > at org.jpox.metadata.AbstractClassMetaData.loadClass( >> > AbstractClassMetaData.java:524) >> > at org.jpox.metadata.ClassMetaData.populate(ClassMetaData.java :215) >> > at org.jpox.metadata.MetaDataManager.populateFileMetaData( >> > MetaDataManager.java:1060) >> > at >> > org.jpox.enhancer.bcel.metadata.BCELMetaDataManager.populateRegistered >> > File( >> > BCELMetaDataManager.java:241) >> > at org.jpox.enhancer.bcel.BCELUtils.getMetaDataForInput >> > (BCELUtils.java >> > :175) >> > at org.jpox.enhancer.JPOXEnhancer.main(JPOXEnhancer.java:512) >> > Exception in thread "main" >> > >> > [ERROR] -------------------- >> > [INFO] >> > ---------------------------------------------------------------------- >> > -- >> > [ERROR] BUILD ERROR >> > [INFO] >> > ---------------------------------------------------------------------- >> > -- >> > [INFO] The JPox enhancer tool exited with a non-null exit code. >> > [INFO] >> > ---------------------------------------------------------------------- >> > -- >> > >> > ============================================================ >> > >> > >> > On 6/19/07, Brett Porter <[EMAIL PROTECTED]> wrote: >> >> >> >> As in Continuum, I've made this change. I'm going with lazy consensus >> >> - so if there are any objections please holler before dependent code >> >> arrives :) >> >> >> >> On 19/06/2007, at 11:26 AM, [EMAIL PROTECTED] wrote: >> >> >> >> > Author: brett >> >> > Date: Mon Jun 18 18:26:34 2007 >> >> > New Revision: 548544 >> >> > >> >> > URL: http://svn.apache.org/viewvc?view=rev&rev=548544 >> >> > Log: >> >> > allow use of JDK 5 in Archiva >> >> > >> >> > Modified: >> >> > maven/archiva/trunk/pom.xml >> >> > >> >> > Modified: maven/archiva/trunk/pom.xml >> >> > URL: http://svn.apache.org/viewvc/maven/archiva/trunk/pom.xml? >> >> > view=diff&rev=548544&r1=548543&r2=548544 >> >> > >> >> ===================================================================== >> >> = >> >> > ======== >> >> > --- maven/archiva/trunk/pom.xml (original) >> >> > +++ maven/archiva/trunk/pom.xml Mon Jun 18 18:26:34 2007 >> >> > @@ -95,11 +95,31 @@ >> >> > </execution> >> >> > </executions> >> >> > </plugin> >> >> > +<!-- Doesn't work on Mac with Java 6 yet >> >> > + <plugin> >> >> > + <artifactId>maven-enforcer-plugin</artifactId> >> >> > + <executions> >> >> > + <execution> >> >> > + <id>enforce-java</id> >> >> > + <goals> >> >> > + <goal>enforce-once</goal> >> >> > + </goals> >> >> > + <configuration> >> >> > + <rules> >> >> > + <requireJavaVersion> >> >> > + <version>1.5.0</version> >> >> > + </requireJavaVersion> >> >> > + </rules> >> >> > + </configuration> >> >> > + </execution> >> >> > + </executions> >> >> > + </plugin> >> >> > +--> >> >> > <plugin> >> >> > <artifactId>maven-compiler-plugin</artifactId> >> >> > <configuration> >> >> > - <source>1.4</source> >> >> > - <target>1.4</target> >> >> > + <source>1.5</source> >> >> > + <target>1.5</target> >> >> > </configuration> >> >> > </plugin> >> >> > <plugin> >> >> > >> >> >> >
