Forum OpenACS Q&A: nsjava with Aolserver 4.08

Request notifications

Posted by Jeff Wang on
Hi all,

Our research group has gotten nsjava working well with Aolserver 3.4 and OpenACS 4.6. However, we wanted to upgrade to Aolserver 4.08 and couldn't seem to get nsjava running there. The error log reports :

/home/aolserver408/bin/ undefined symbol: NsTclDbCmd
[14/Jun/2005:12:27:45][16562.1024][-main-] Fatal: modload: failed to load module '/home/aolserver408/bin/'

Does anyone know what this error is and how to fix it? Is nsjava even compatible with Aolserver 4.x??

Thanks for the help!

Posted by Andrew Piskorski on
Jeff, in addition to here, you definitely should ask about this on the AOLserver list.

Also, what are you using nsjava for? I'm curious...

Posted by Jeff Wang on
Hi Andrew,

We're consuming webservices as a client and are using Java. We use nsjava to instantiate classes and invoke methods for utilizing the webservices in TCL/Openacs.


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 ... libraries. Looking at the configure script I found out, that it is grepping for using "find $JDK_DIR -name" 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  /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 dir:        /usr/java/j2re1.4.2_04/lib/i386 dir:         /usr/java/j2re1.4.2_04/lib/i386/native_threads
hpi lib:      dir:         /usr/java/j2re1.4.2_04/lib/i386/client
jvm lib:     
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


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/
Error: could not find
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?
Posted by Mark Aufflick on
Has anyone solved this? I have just posted a similar question to the aolserver list.
Posted by Jeff Wang on
Hi Mark,

We never ended up solving this issue. Instead, we had a workaround in which we run an instance of aolserver 3.x that handles all the nsjava stuff. All the aolserver 4.x instances will forward requests to the 3.x nsjava gateway.