Skip to content
Prev 58244 / 63424 Next

[BULK] Re: status of Java & rJava?

Hi, Simon et al.:


 ????? My attempts to install rJava 0.9-12 from source failed under both 
macOS 10.15.4 and Windows 10.


 ????? Below please find what I got just now trying "update.packages()" 
and selecting "install from sources" on both computers followed by 
"sessionInfo()" in each case.


 ????? Thanks for your help.
 ????? Spencer Graves


 ?update.packages()
rJava :
 ?Version 0.9-11 installed in 
/Library/Frameworks/R.framework/Versions/3.6/Resources/library
 ?Version 0.9-12 available at https://cran.rstudio.com
Update? (Yes/no/cancel) y
sf :
 ?Version 0.8-1 installed in 
/Library/Frameworks/R.framework/Versions/3.6/Resources/library
 ?Version 0.9-0 available at https://cran.rstudio.com
Update? (Yes/no/cancel) n
XLConnect :
 ?Version 0.2-15 installed in 
/Library/Frameworks/R.framework/Versions/3.6/Resources/library
 ?Version 1.0.1 available at https://cran.rstudio.com
Update? (Yes/no/cancel) n

 ? There is a binary version available but the
 ? source version is later:
 ????? binary source needs_compilation
rJava 0.9-11 0.9-12????????????? TRUE

Do you want to install from sources the package which needs compilation? 
(Yes/no/cancel) y
installing the source package ?rJava?

trying URL 'https://cran.rstudio.com/src/contrib/rJava_0.9-12.tar.gz'
Content type 'application/x-gzip' length 1103629 bytes (1.1 MB)
==================================================
downloaded 1.1 MB

* installing *source* package ?rJava? ...
** package ?rJava? successfully unpacked and MD5 sums checked
** using staged installation
checking for gcc... clang
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... configure: error: in 
`/private/var/folders/mh/mrm_14nx19g13lsnj9zmvwjr0000gn/T/Rtmpm3rVc5/R.INSTALL5d09696e941d/rJava':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details
ERROR: configuration failed for package ?rJava?
* removing 
?/Library/Frameworks/R.framework/Versions/3.6/Resources/library/rJava?
* restoring previous 
?/Library/Frameworks/R.framework/Versions/3.6/Resources/library/rJava?

The downloaded source packages are in
?/private/var/folders/mh/mrm_14nx19g13lsnj9zmvwjr0000gn/T/RtmpbxyWRI/downloaded_packages?
Warning message:
In install.packages(update[instlib == l, "Package"], l, repos = repos,? :
 ? installation of package ?rJava? had non-zero exit status
 > sessionInfo()
R version 3.6.3 (2020-02-29)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Catalina 10.15.4

Matrix products: default
BLAS: 
/System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: 
/Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats???? graphics? grDevices utils???? datasets
[6] methods?? base

loaded via a namespace (and not attached):
[1] compiler_3.6.3 tools_3.6.3



 > update.packages()
rJava :
 ?Version 0.9-11 installed in C:/Program Files/R/R-3.6.3/library
 ?Version 0.9-12 available at https://cran.rstudio.com

 ? There is a binary version available but
 ? the source version is later:
 ????? binary source needs_compilation
rJava 0.9-11 0.9-12????????????? TRUE

installing the source package 'rJava'

trying URL 'https://cran.rstudio.com/src/contrib/rJava_0.9-12.tar.gz'
Content type 'application/x-gzip' length 1103629 bytes (1.1 MB)
downloaded 1.1 MB

* installing *source* package 'rJava' ...
** package 'rJava' successfully unpacked and MD5 sums checked
** using staged installation
Generate Windows-specific files (src/jvm-w32) ...
make: Entering directory 
'/Users/spenc/AppData/Local/Temp/RtmpQbnYkA/R.INSTALL8ec5478248a/rJava/src/jvm-w32'
c:/Rtools/mingw_64/bin/dlltool --as c:/Rtools/mingw_64/bin/as 
--input-def jvm64.def --kill-at --dllname jvm.dll --output-lib libjvm.dll.a
c:/Rtools/mingw_64/bin/gcc? -O2 -c -o findjava.o findjava.c
c:/Rtools/mingw_64/bin/gcc? -s -o findjava.exe findjava.o
make: Leaving directory 
'/Users/spenc/AppData/Local/Temp/RtmpQbnYkA/R.INSTALL8ec5478248a/rJava/src/jvm-w32'
Find Java...
 ? JAVA_HOME=C:/PROGRA~1/Java/JRE18~1.0_2
=== Building JRI ===
 ? JAVA_HOME=C:/PROGRA~1/Java/JRE18~1.0_2
 ? R_HOME=C:/PROGRA~1/R/R-36~1.3
JDK has no javah.exe - using javac -h . instead
Creating Makefiles ...
Configuration done.
make -C src JRI.jar
make[1]: Entering directory 
'/Users/spenc/AppData/Local/Temp/RtmpQbnYkA/R.INSTALL8ec5478248a/rJava/jri/src'
C:/PROGRA~1/Java/JRE18~1.0_2/bin/javac -h . -d . ../RList.java 
../RBool.java ../RVector.java ../RMainLoopCallbacks.java 
../RConsoleOutputStream.java ../Mutex.java ../Rengine.java ../REXP.java 
../RFactor.java ../package-info.java
sh: C:/PROGRA~1/Java/JRE18~1.0_2/bin/javac: No such file or directory
make[1]: *** [Makefile.all:41: org/rosuda/JRI/Rengine.class] Error 127
make[1]: Leaving directory 
'/Users/spenc/AppData/Local/Temp/RtmpQbnYkA/R.INSTALL8ec5478248a/rJava/jri/src'
make: *** [Makefile.all:19: src/JRI.jar] Error 2
**** WARNING: JRI could NOT be built
Set IGNORE=1 if you want to build rJava anyway.
ERROR: configuration failed for package 'rJava'
* removing 'C:/Program Files/R/R-3.6.3/library/rJava'
* restoring previous 'C:/Program Files/R/R-3.6.3/library/rJava'

The downloaded source packages are in
'C:\Users\spenc\AppData\Local\Temp\RtmpsDQIkn\downloaded_packages'
Warning message:
In install.packages(update[instlib == l, "Package"], l, repos = repos,? :
 ? installation of package 'rJava' had non-zero exit status

 > sessionInfo()
R version 3.6.3 (2020-02-29)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 18362)

Matrix products: default

locale:
[1] LC_COLLATE=English_United States.1252
[2] LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.1252

attached base packages:
[1] stats???? graphics? grDevices utils
[5] datasets? methods?? base

loaded via a namespace (and not attached):
[1] compiler_3.6.3 tools_3.6.3
On 2020-03-28 22:07, Simon Urbanek wrote: