仮想マシンの新しいUbuntuにrstudioとJavaをインストールしましたが、rJavaをインストールすることはできません。UbuntuにrJavaをインストールする
出力は次のようになります。
make[1]: Entering directory '/tmp/RtmpZkzbyR/R.INSTALL23562679b2a2/rJava/jri' make -C src JRI.jar make[2]: Entering directory '/tmp/RtmpZkzbyR/R.INSTALL23562679b2a2/rJava/jri/src' /usr/lib/jvm/default-java/bin/javac -target 1.4 -source 1.4 -d . ../package-info.java ../RFactor.java ../REXP.java ../Rengine.java ../Mutex.java ../RConsoleOutputStream.java ../RMainLoopCallbacks.java ../RVector.java ../RBool.java ../RList.java warning: [options] bootstrap class path not set in conjunction with -source 1.4 warning: [options] source value 1.4 is obsolete and will be removed in a future release warning: [options] target value 1.4 is obsolete and will be removed in a future release warning: [options] To suppress warnings about obsolete options, use -Xlint:-options. 4 warnings /usr/lib/jvm/default-java/bin/javah -d . -classpath . org.rosuda.JRI.Rengine gcc -std=gnu99 -c -o Rengine.o Rengine.c -g -Iinclude -DRIF_HAS_CSTACK -DRIF_HAS_RSIGHAND -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux -fpic -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux -I/usr/share/R/include -I/usr/share/R/include gcc -std=gnu99 -c -o jri.o jri.c -g -Iinclude -DRIF_HAS_CSTACK -DRIF_HAS_RSIGHAND -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux -fpic -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux -I/usr/share/R/include -I/usr/share/R/include gcc -std=gnu99 -c -o Rcallbacks.o Rcallbacks.c -g -Iinclude -DRIF_HAS_CSTACK -DRIF_HAS_RSIGHAND -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux -fpic -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux -I/usr/share/R/include -I/usr/share/R/include gcc -std=gnu99 -c -o Rinit.o Rinit.c -g -Iinclude -DRIF_HAS_CSTACK -DRIF_HAS_RSIGHAND -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux -fpic -I/usr/share/R/include -I/usr/share/R/include gcc -std=gnu99 -c -o globals.o globals.c -g -Iinclude -DRIF_HAS_CSTACK -DRIF_HAS_RSIGHAND -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux -fpic -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux gcc -std=gnu99 -c -o rjava.o rjava.c -g -Iinclude -DRIF_HAS_CSTACK -DRIF_HAS_RSIGHAND -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux -fpic -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux rjava.c: In function ‘RJava_request_lock’: rjava.c:22:3: warning: ignoring return value of ‘write’, declared with attribute warn_unused_result [-Wunused-result] write(ipcout, buf, sizeof(ptrlong)); ^ rjava.c: In function ‘RJava_clear_lock’: rjava.c:30:3: warning: ignoring return value of ‘write’, declared with attribute warn_unused_result [-Wunused-result] write(ipcout, buf, sizeof(ptrlong)); ^ rjava.c: In function ‘RJava_request_callback’: rjava.c:39:3: warning: ignoring return value of ‘write’, declared with attribute warn_unused_result [-Wunused-result] write(ipcout, buf, sizeof(ptrlong) * 3); ^ rjava.c: In function ‘RJava_init_ctrl’: rjava.c:51:3: warning: ignoring return value of ‘write’, declared with attribute warn_unused_result [-Wunused-result] write(ipcout, buf, sizeof(ptrlong)); ^ rjava.c:52:3: warning: ignoring return value of ‘read’, declared with attribute warn_unused_result [-Wunused-result] read(resin, buf, sizeof(ptrlong) * 2); ^ gcc -std=gnu99 -o libjri.so Rengine.o jri.o Rcallbacks.o Rinit.o globals.o rjava.o -shared -L/usr/lib/jvm/default-java/jre/lib/amd64/server -ljvm -Wl,--export-dynamic -fopenmp -L/usr/lib/R/lib -lR -lpcre -llzma -lbz2 -lz -lrt -ldl -lm /usr/bin/ld: cannot find -lpcre /usr/bin/ld: cannot find -llzma /usr/bin/ld: cannot find -lbz2 /usr/bin/ld: cannot find -lz collect2: error: ld returned 1 exit status Makefile.all:38: recipe for target 'libjri.so' failed make[2]: Leaving directory '/tmp/RtmpZkzbyR/R.INSTALL23562679b2a2/rJava/jri/src' Makefile.all:21: recipe for target 'src/JRI.jar' failed make[1]: Leaving directory '/tmp/RtmpZkzbyR/R.INSTALL23562679b2a2/rJava/jri' make[2]: * [libjri.so] Error 1 make[1]: * [src/JRI.jar] Error 2 Makevars:14: recipe for target 'jri' failed make: *** [jri] Error 2 ERROR: compilation failed for package ‘rJava’ * removing ‘/home/virtualbox/R/x86_64-pc-linux-gnu-library/3.2/rJava’ Warning in install.packages : installation of package ‘rJava’ had non-zero exit status
The downloaded source packages are in ‘/tmp/RtmpldZhGw/downloaded_packages’
だから私はいくつかのjarファイルが欠落しているまた、リンカオプションを理解していないと思います。どんな助けもありがたい。