Forum OpenACS Q&A: Re: nsjava with Aolserver 4.08

Collapse
Posted by Nima Mazloumi on
Hi, I tried to run configure and make, make install but have problems. I installed the java SDK for the javac compiler.
./configure --prefix=/usr/local/aolserver40r10-chroot --with-aolserver-src=/opt/source/installer/package_dir/aolserver-4.0.10 --with-jdk=/usr/lib/SunJava2-1.4.2
Was not able to find libjava.so ... libraries. Looking at the configure script I found out, that it is grepping for libjava.so using "find $JDK_DIR -name libjava.so" which returns nothing. I changed that to use the directory /usr/java/j2re1.4.2_04/lib/i386 where all the libraries are and configure worked. Same I did for all the other java libraries in configure:
Using c-compiler:      gcc
JDK Version:           1.2
Install libnsjava.so:  /usr/local/aolserver40r10-chroot/bin
Aolserver Version:     3_0_PLUS
Aolserver include:     /opt/source/installer/package_dir/aolserver-4.0.10/include
Aolserver nsd include: /opt/source/installer/package_dir/aolserver-4.0.10/nsd
jdk include:           /usr/lib/SunJava2-1.4.2/include
jdk platform include:  /usr/lib/SunJava2-1.4.2/include/linux
libjava.so dir:        /usr/java/j2re1.4.2_04/lib/i386
libhpi.so dir:         /usr/java/j2re1.4.2_04/lib/i386/native_threads
hpi lib:               libhpi.so
libjvm.so dir:         /usr/java/j2re1.4.2_04/lib/i386/client
jvm lib:               libjvm.so
java classpath:        /usr/lib/SunJava2-1.4.2/lib/tools.jar
RPATH:                 /usr/java/j2re1.4.2_04/lib/i386:/usr/java/j2re1.4.2_04/lib/i386/native_threads:/usr/java/j2re1.4.2_04/lib/i386/client

CFLAGS:  '-DUSING_JDK1_2'

LDFLAGS: '-L/usr/java/j2re1.4.2_04/lib/i386 -ljava -L/usr/java/j2re1.4.2_04/lib/i386/native_threads -lhpi -L/usr/java/j2re1.4.2_04/lib/i386/client -ljvm '
But calling make fails:
building "java"
make[1]: Entering directory `/opt/source/installer/package_dir/aolserver-4.0.10/nsjava-1.0.5/java'
/usr/lib/SunJava2-1.4.2/bin/javac -g -classpath /usr/lib/SunJava2-1.4.2/lib/tools.jar:/opt/source/installer/package_dir/aolserver-4.0.10/nsjava-1.0.5/java ../java/nsjava/internal/Interp.java
Error: could not find libjava.so
Error: could not find Java 2 Runtime Environment.
make[1]: *** [Interp.class] Error 2
make[1]: Leaving directory `/opt/source/installer/package_dir/aolserver-4.0.10/nsjava-1.0.5/java'
make: *** [all] Error 1
Any idea?