Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

9.2.0.0 requires java 8 but states java 7 as requirement #5247

Closed
p-mongo opened this Issue Jul 12, 2018 · 4 comments

Comments

Projects
None yet
4 participants
@p-mongo
Copy link

p-mongo commented Jul 12, 2018

I attempted to install 9.2.0.0 on a bunch of systems, including Debian 8 and 9.

On Debian 9 which provides openjdk 8, installation succeeded.

On Debian 8 which provides openjdk 7, installation failed with the following message:

 [2018/07/12 00:55:04.613] Installing jruby-9.2.0.0...
 [2018/07/12 00:55:04.613] BUILD FAILED (Debian 8.1 using ruby-build 20180618-5-gad8f3a4)
 [2018/07/12 00:55:04.615] Inspect or clean up the working tree at /tmp/ruby-build.20180712045503.32377
 [2018/07/12 00:55:04.615] Results logged to /tmp/ruby-build.20180712045503.32377.log
 [2018/07/12 00:55:04.616] Last 10 log lines:
 [2018/07/12 00:55:04.616] jruby-9.2.0.0.tar.gz
 [2018/07/12 00:55:04.616] /tmp/ruby-build.20180712045503.32377/jruby-9.2.0.0 /tmp/ruby-build.20180712045503.32377 /data/mci/bf500ceccf733ed3042569a054af6151/mongo-ruby-toolchain
 [2018/07/12 00:55:04.616] Exception in thread "main" java.lang.UnsupportedClassVersionError: org/jruby/Main : Unsupported major.minor version 52.0
 [2018/07/12 00:55:04.616] 	at java.lang.ClassLoader.findBootstrapClass(Native Method)
 [2018/07/12 00:55:04.616] 	at java.lang.ClassLoader.findBootstrapClassOrNull(ClassLoader.java:1078)
 [2018/07/12 00:55:04.616] 	at java.lang.ClassLoader.loadClass(ClassLoader.java:419)
 [2018/07/12 00:55:04.616] 	at java.lang.ClassLoader.loadClass(ClassLoader.java:417)
 [2018/07/12 00:55:04.616] 	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:323)
 [2018/07/12 00:55:04.616] 	at java.lang.ClassLoader.loadClass(ClassLoader.java:363)
 [2018/07/12 00:55:04.616] 	at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:482)
 [2018/07/12 00:55:04.641] Command failed: command [pid=28119] encountered problem: exit status 1

Installing java 8 on Debian 8 allowed 9.2.0.0 installation to succeed.

I then attempted to figure out what java is required by jruby:

So, I checked out master and attempted to build it on Debian 8, and received the following error:

debian-8% ./mvnw 
[INFO] Scanning for projects...
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for org.jruby:jruby-core:jar:9.2.1.0-SNAPSHOT
[WARNING] 'build.pluginManagement.plugins.plugin.(groupId:artifactId)' must be unique but found duplicate declaration of plugin org.apache.felix:maven-bundle-plugin @ org.jruby:jruby-parent:9.2.1.0-SNAPSHOT, /home/vagrant/jruby/pom.xml, line 338, column 17
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for org.jruby:jruby-stdlib:jar:9.2.1.0-SNAPSHOT
[WARNING] 'build.pluginManagement.plugins.plugin.(groupId:artifactId)' must be unique but found duplicate declaration of plugin org.apache.felix:maven-bundle-plugin @ org.jruby:jruby-parent:9.2.1.0-SNAPSHOT, /home/vagrant/jruby/pom.xml, line 338, column 17
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for org.jruby:jruby-parent:pom:9.2.1.0-SNAPSHOT
[WARNING] 'build.pluginManagement.plugins.plugin.(groupId:artifactId)' must be unique but found duplicate declaration of plugin org.apache.felix:maven-bundle-plugin
[WARNING] 
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING] 
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING] 
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO] 
[INFO] JRuby
[INFO] JRuby Core
[INFO] JRuby Lib Setup
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building JRuby 9.2.1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-enforcer-plugin:1.0:enforce (default) @ jruby-parent ---
[INFO] 
[INFO] --- maven-enforcer-plugin:1.0:enforce (enforce-maven) @ jruby-parent ---
[INFO] 
[INFO] --- maven-install-plugin:2.4:install (default-install) @ jruby-parent ---
[INFO] Installing /home/vagrant/jruby/.polyglot.pom.rb to /home/vagrant/.m2/repository/org/jruby/jruby-parent/9.2.1.0-SNAPSHOT/jruby-parent-9.2.1.0-SNAPSHOT.pom
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building JRuby Core 9.2.1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-enforcer-plugin:1.0:enforce (default) @ jruby-core ---
[INFO] 
[INFO] --- maven-enforcer-plugin:1.0:enforce (enforce-maven) @ jruby-core ---
[INFO] 
[INFO] --- exec-maven-plugin:1.2.1:exec (default) @ jruby-core ---
[INFO] 
[INFO] --- buildnumber-maven-plugin:1.2:create (jruby-revision) @ jruby-core ---
[INFO] Checking for local modifications: skipped.
[INFO] Updating project files from SCM: skipped.
[INFO] ShortRevision tag detected. The value is '7'.
[INFO] Executing: /bin/sh -c cd /home/vagrant/jruby/core && git rev-parse --verify --short=7 HEAD
[INFO] Working directory: /home/vagrant/jruby/core
[INFO] Storing buildNumber: 7026bae at timestamp: 1531430917098
[INFO] ShortRevision tag detected. The value is '7'.
[INFO] Executing: /bin/sh -c cd /home/vagrant/jruby/core && git rev-parse --verify --short=7 HEAD
[INFO] Working directory: /home/vagrant/jruby/core
[INFO] Storing buildScmBranch: UNKNOWN
[INFO] 
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ jruby-core ---
[INFO] Using 'utf-8' encoding to copy filtered resources.
[INFO] Copying 41 resources
[INFO] Copying 2 resources
[INFO] Copying 1 resource to /home/vagrant/jruby/core/src/main/java
[INFO] Copying 4 resources to /home/vagrant/jruby/core/target/classes/META-INF/
[INFO] 
[INFO] --- maven-compiler-plugin:3.3:compile (anno) @ jruby-core ---
[INFO] Compiling 7 source files to /home/vagrant/jruby/core/target/classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR : 
[INFO] -------------------------------------------------------------
[ERROR] javac: invalid target release: 1.8
Usage: javac  
use -help for a list of possible options

[INFO] 1 error
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] JRuby .............................................. SUCCESS [  0.303 s]
[INFO] JRuby Core ......................................... FAILURE [  1.638 s]
[INFO] JRuby Lib Setup .................................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 7.066 s
[INFO] Finished at: 2018-07-12T21:28:37+00:00
[INFO] Final Memory: 30M/72M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.3:compile (anno) on project jruby-core: Compilation failure
[ERROR] javac: invalid target release: 1.8
[ERROR] Usage: javac  
[ERROR] use -help for a list of possible options
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn  -rf :jruby-core

... leading me to believe that java 8 is the minimum required version for 9.2.0.0.

@headius

This comment has been minimized.

Copy link
Member

headius commented Jul 12, 2018

Ahh I guess we didn't announce the move to 8 in all appropriate places. We'll get that fixed up everywhere.

@headius headius added this to the JRuby 9.2.1.0 milestone Jul 12, 2018

olleolleolle added a commit to olleolleolle/jruby that referenced this issue Aug 14, 2018

@enebo enebo closed this Aug 14, 2018

@seadoggie01

This comment has been minimized.

Copy link

seadoggie01 commented Sep 14, 2018

jRuby requests java version 1.5 or higher (if it cannot find the Java version) when run with no arguments

@enebo

This comment has been minimized.

Copy link
Member

enebo commented Sep 14, 2018

@seadoggie01 that appears to be changed on master to 1.8.

@seadoggie01

This comment has been minimized.

Copy link

seadoggie01 commented Sep 15, 2018

@enebo That could be, I was using version 9.2.0.0 that I downloaded from the website. I should've thought of that!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.