Menu

#52 tclBlend configure script - jvm lib location on Solaris/HPUX

open
nobody
None
5
2010-02-05
2010-02-05
Tony B
No

tclBlend configure script doesn't find the jvm libraies for Solaris 9/10 or HPUX 11 (parisc or ia64). For HP parisc there is the additional problem that libjvm can not be dynamically loaded using shl_load() because it contains thread local storage. Unless the executable is linked with libjvm the only way to load it is using LD_PRELOAD. I'm not sure about autoconf, so I hacked the configure script directly. The following extract is the changes I've made and appear to work on Solaris 9/10 (sparc) and HPUX 11 (parisc & ia64)

# Find out where the JNI native thread libraries live

machine=`uname -m`
shlibext=".so"
jretype="client"
case "$machine" in
i?86)
machine=i386
;;
sun4u)
machine="sparc"
;;
sun4v)
machine="sparc"
;;
9000/800)
machine="PA_RISC2.0"
shlibext=".sl"
jretype="server"
ac_java_jvm_ld_preload="libjvm${shlibext}"
;;
ia64)
machine="IA64N"
jretype="server"
;;
esac

# Check for known JDK installation layouts

if test "$ac_java_jvm_name" = "jdk"; then

# Sun/Blackdown 1.4 for Linux (client JVM)

F=jre/lib/$machine/libjava${shlibext}
if test "x$ac_java_jvm_jni_lib_flags" = "x" ; then

echo Looking for $ac_java_jvm_dir/$F >&5

if test -f $ac_java_jvm_dir/$F ; then

echo Found $ac_java_jvm_dir/$F >&5

D=`dirname $ac_java_jvm_dir/$F`
ac_java_jvm_jni_lib_runtime_path=$D
ac_java_jvm_jni_lib_flags="-L$D -ljava -lverify"
D=$ac_java_jvm_dir/jre/lib/$machine/${jretype}
ac_java_jvm_jni_lib_runtime_path="${ac_java_jvm_jni_lib_runtime_path}:$D"
ac_java_jvm_jni_lib_flags="$ac_java_jvm_jni_lib_flags -L$D -ljvm"
D=$ac_java_jvm_dir/jre/lib/$machine/native_threads
ac_java_jvm_jni_lib_runtime_path="${ac_java_jvm_jni_lib_runtime_path}:$D"
ac_java_jvm_jni_lib_flags="$ac_java_jvm_jni_lib_flags -L$D -lhpi"

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.