[R] R-2.7.0 rJava installation failure on x86_64

Nathan Coulter org.r-project at pooryorick.com
Tue Jun 3 19:46:42 CEST 2008

attempting to install rJava on R-2.7.0, x86_64 platform, config.log shows the
following error:

	configure:3880: checking whether JNI programs can be compiled
	configure:3898: gcc -m64 -std=gnu99 -o conftest -g -O2
	-I/path/to/x86-64-linux/jdk-1.6.0_06/jre/../include   conftest.c
	-L/path/to/x86-64-linux/jdk-1.6.0_06/jre/../lib/amd64 -L
	-L/usr/java/packages/lib/amd64 -L/lib -L/usr/lib -ljvm >&5
	/path/to/x86-64-linux/bin/ld: skipping incompatible /usr/lib/libc.so when
	searching for -lc /usr/lib/libc.a: could not read symbols: File format is
	ambiguous collect2: ld returned 1 exit status

It looks like the command above could use /lib64/libc.so.6, but running "R CMD
javareconf" shows that JNI linker flags don't contain any entry similar to

	-bash-3.00$ /path/to/noarch/bin/statcomp R-2.7.0 CMD javareconf
	Java interpreter : /path/to/x86-64-linux/bin/java
	Java version     : 1.6.0_06
	Java home path   : /path/to/x86-64-linux/jdk-1.6.0_06/jre Java
	compiler : /path/to/x86-64-linux/bin/javac
	Java headers gen.: /path/to/x86-64-linux/bin/javah
	Java archive tool: /path/to/x86-64-linux/bin/jar
	Java library path:
	JNI linker flags : -L$(JAVA_HOME)/lib/amd64/server -L$(JAVA_HOME)/lib/amd64
	-L$(JAVA_HOME)/../lib/amd64 -L -L/usr/java/packages/lib/amd64 -L/lib
	-L/usr/lib -ljvm JNI cpp flags    : -I$(JAVA_HOME)/../include

Suggests on the root of the problem or best workarounds?


More information about the R-help mailing list