0

I'm trying to run rJava package, which is needed in tabulizer package but rJava reports the same error no matter what I do.

Unable to find any JVMs matching version "(null)".
No Java runtime present, try --request to install.
Error: package or namespace load failed for ‘rJava’:
 .onLoad failed in loadNamespace() for 'rJava', details:
  call: fun(libname, pkgname)
  error: JVM could not be found
In addition: Warning messages:
1: In system("/usr/libexec/java_home", intern = TRUE) :
  running command '/usr/libexec/java_home' had status 1
2: In fun(libname, pkgname) :
  Cannot find JVM library 'NA/lib/server/libjvm.dylib'
Install Java and/or check JAVA_HOME (if in doubt, do NOT set it, it will be detected)

I have installed Java:

$ java -version
java version "14.0.1" 2020-04-14
Java(TM) SE Runtime Environment (build 14.0.1+7)
Java HotSpot(TM) 64-Bit Server VM (build 14.0.1+7, mixed mode, sharing)

Also I've set the JAVA_HOME directory. Have tried also running this command:

sudo R CMD javareconf

but this no good either.

I'm currently using macOS Catalina version 10.15.3.

Honestly I think I've read all topics about this problem on this and other forums, but nothing works.

zx8754
  • 52,746
  • 12
  • 114
  • 209
  • Take a look here: https://www.owsiak.org/r4-0-with-java-14-inside-macos-10-15-4/ – Oo.oO Jul 06 '20 at 12:57
  • According to the error message, your `JAVA_HOME` is set to something weird, so that it puts `NA` in the path. Since you haven’t shown the output of `R CMD javareconf` nor your `JAVA_HOME`, that’s all we know. – Konrad Rudolph Jul 06 '20 at 14:34
  • 1
    @Oo.oO thx! That was really helpful and solve all problems - everything runs just fine now! – wojtek_p Jul 06 '20 at 19:30
  • .oOo.oOo. Cool! Have fun with R :) – Oo.oO Jul 06 '20 at 21:28

0 Answers0