4 Replies Latest reply on Apr 27, 2010 6:08 PM by Arbi Sookazian

    class file has wrong version 50.0, should be 49.0

    Arbi Sookazian Master

      JDK 5.0 or JDK 6.0 is required for all Weld releases

      source: http://seamframework.org/Download


      I am building weld-translator using JDK 5 in this case.  There is a compiler error at the bottom of the log which is basically complaining that I should be using JDK 6 rather than JDK 5.  So is this a problem or what given the statement at the top of this post?  Or am I missing something?



      class file has wrong version 50.0, should be 49.0

      C:\java\weld-1.0.1-Final\examples\jsf\translator>mvn clean install
      [INFO] Scanning for projects...
      [INFO] Reactor build order:
      [INFO]   Weld Examples: Translator (parent)
      [INFO]   Weld Examples: Translator (war)
      [INFO]   Weld Examples: Translator (ejb)
      [INFO]   Weld Examples: Translator (ear)
      [INFO] ------------------------------------------------------------------------
      [INFO] Building Weld Examples: Translator (parent)
      [INFO]    task-segment: [clean, install]
      [INFO] ------------------------------------------------------------------------
      [INFO] [clean:clean {execution: default-clean}]
      [INFO] [enforcer:enforce {execution: enforce}]
      [INFO] [build-helper:maven-version {execution: default}]
      [INFO] [build-helper:parse-version {execution: default}]
      [INFO] [buildnumber:create {execution: set-build-properties}]
      [INFO] Checking for local modifications: skipped.
      [INFO] Updating project files from SCM: skipped.
      [INFO] Executing: cmd.exe /X /C "svn --non-interactive info"
      [INFO] Working directory: C:\java\weld-1.0.1-Final\examples\jsf\translator
      Provider message:
      The svn command failed.
      Command output:
      svn: '.' is not a working copy
      
      [WARNING] Cannot get the revision information from the scm repository, proceedin
      g with revision of unavailable :
      Error!
      [INFO] Storing buildNumber: unavailable at timestamp: April 26, 2010 12:49:30 PM
       PDT
      [INFO] [site:attach-descriptor {execution: default-attach-descriptor}]
      [INFO] Preparing source:jar
      [WARNING] Removing: jar from forked lifecycle, to prevent recursive invocation.
      [INFO] [enforcer:enforce {execution: enforce}]
      [INFO] [build-helper:maven-version {execution: default}]
      [INFO] [build-helper:parse-version {execution: default}]
      [INFO] [buildnumber:create {execution: set-build-properties}]
      [INFO] [source:jar {execution: attach-sources}]
      [INFO] [install:install {execution: default-install}]
      [INFO] Installing C:\java\weld-1.0.1-Final\examples\jsf\translator\pom.xml to C:
      \Documents and Settings\asookazian\.m2\repository\org\jboss\weld\examples\jsf\tr
      anslator\weld-jsf-translator-parent\1.0.1-Final\weld-jsf-translator-parent-1.0.1
      -Final.pom
      [INFO] ------------------------------------------------------------------------
      [INFO] Building Weld Examples: Translator (war)
      [INFO]    task-segment: [clean, install]
      [INFO] ------------------------------------------------------------------------
      [INFO] [clean:clean {execution: default-clean}]
      [INFO] [enforcer:enforce {execution: enforce}]
      [INFO] [build-helper:maven-version {execution: default}]
      [INFO] [build-helper:parse-version {execution: default}]
      [INFO] [buildnumber:create {execution: set-build-properties}]
      [INFO] [resources:resources {execution: default-resources}]
      [INFO] Using 'UTF-8' encoding to copy filtered resources.
      [INFO] skip non existing resourceDirectory C:\java\weld-1.0.1-Final\examples\jsf
      \translator\war\src\main\resources
      [INFO] [compiler:compile {execution: default-compile}]
      [INFO] No sources to compile
      [INFO] [resources:testResources {execution: default-testResources}]
      [INFO] Using 'UTF-8' encoding to copy filtered resources.
      [INFO] skip non existing resourceDirectory C:\java\weld-1.0.1-Final\examples\jsf
      \translator\war\src\test\resources
      [INFO] [compiler:testCompile {execution: default-testCompile}]
      [INFO] No sources to compile
      [INFO] [surefire:test {execution: default-test}]
      [INFO] No tests to run.
      [INFO] [war:war {execution: default-war}]
      [INFO] Packaging webapp
      [INFO] Assembling webapp[weld-jsf-translator-war] in [C:\java\weld-1.0.1-Final\e
      xamples\jsf\translator\war\target\weld-translator]
      [INFO] Processing war project
      [INFO] Copying webapp resources[C:\java\weld-1.0.1-Final\examples\jsf\translator
      \war\src\main\webapp]
      [INFO] Webapp assembled in [172 msecs]
      [INFO] Building war: C:\java\weld-1.0.1-Final\examples\jsf\translator\war\target
      \weld-translator.war
      [INFO] Preparing source:jar
      [WARNING] Removing: jar from forked lifecycle, to prevent recursive invocation.
      [INFO] [enforcer:enforce {execution: enforce}]
      [INFO] [build-helper:maven-version {execution: default}]
      [INFO] [build-helper:parse-version {execution: default}]
      [INFO] [buildnumber:create {execution: set-build-properties}]
      [INFO] [source:jar {execution: attach-sources}]
      [INFO] Building jar: C:\java\weld-1.0.1-Final\examples\jsf\translator\war\target
      \weld-translator-sources.jar
      [INFO] [install:install {execution: default-install}]
      [INFO] Installing C:\java\weld-1.0.1-Final\examples\jsf\translator\war\target\we
      ld-translator.war to C:\Documents and Settings\asookazian\.m2\repository\org\jbo
      ss\weld\examples\jsf\translator\weld-jsf-translator-war\1.0.1-Final\weld-jsf-tra
      nslator-war-1.0.1-Final.war
      [INFO] Installing C:\java\weld-1.0.1-Final\examples\jsf\translator\war\target\we
      ld-translator-sources.jar to C:\Documents and Settings\asookazian\.m2\repository
      \org\jboss\weld\examples\jsf\translator\weld-jsf-translator-war\1.0.1-Final\weld
      -jsf-translator-war-1.0.1-Final-sources.jar
      [INFO] ------------------------------------------------------------------------
      [INFO] Building Weld Examples: Translator (ejb)
      [INFO]    task-segment: [clean, install]
      [INFO] ------------------------------------------------------------------------
      [INFO] [clean:clean {execution: default-clean}]
      [INFO] [enforcer:enforce {execution: enforce}]
      [INFO] [build-helper:maven-version {execution: default}]
      [INFO] [build-helper:parse-version {execution: default}]
      [INFO] [buildnumber:create {execution: set-build-properties}]
      [INFO] [resources:resources {execution: default-resources}]
      [INFO] Using 'UTF-8' encoding to copy filtered resources.
      [INFO] Copying 1 resource
      [INFO] [compiler:compile {execution: default-compile}]
      [INFO] Compiling 6 source files to C:\java\weld-1.0.1-Final\examples\jsf\transla
      tor\ejb\target\classes
      [INFO] ------------------------------------------------------------------------
      [ERROR] BUILD FAILURE
      [INFO] ------------------------------------------------------------------------
      [INFO] Compilation failure
      C:\java\weld-1.0.1-Final\examples\jsf\translator\ejb\src\main\java\org\jboss\wel
      d\examples\translator\SentenceTranslator.java:[3,-1] cannot access javax.ejb.Sta
      teless
      bad class file: C:\Documents and Settings\asookazian\.m2\repository\org\jboss\ej
      b3\jboss-ejb3-api\3.1.0\jboss-ejb3-api-3.1.0.jar(javax/ejb/Stateless.class)
      class file has wrong version 50.0, should be 49.0
      
      
      [INFO] ------------------------------------------------------------------------
      [INFO] For more information, run Maven with the -e switch
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 9 seconds
      [INFO] Finished at: Mon Apr 26 12:49:35 PDT 2010
      [INFO] Final Memory: 25M/45M
      [INFO] ------------------------------------------------------------------------
      C:\java\weld-1.0.1-Final\examples\jsf\translator>java -version
      java version "1.5.0_22"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_22-b03)
      Java HotSpot(TM) Client VM (build 1.5.0_22-b03, mixed mode)