Environment variables

Four environment variables are associated with running Java bindings. The first three, described below, identify path-related directories that must be set properly for various tools. It is assumed Babel was already installed in directories rooted at $PREFIX. The last variable is used to pass options to the implementation-side.

CLASSPATH.
Java uses the CLASSPATH environment variable to find .class files. While not specific to Babel, this colon-separated list of directories must include at least three directories. The first is the one containing the implementation-side .class files. The second is the directory containing sidl_$VERSION.jar, where $VERSION is the version of your installed Babel, which is likely to be the SIDL jar file. The latter directory should be $PREFIX/lib. Finally, CLASSPATH must include $PREFIX/runtime/java.

LD_LIBRARY_PATH (or LIBPATH on AIX).
Many systems require LD_LIBRARY_PATH environment variable contain $PREFIX/lib. However, the system-specific environment variable should be used. AIX, for example, uses LIBPATH. The goal is to include $PREFIX/lib in the search path used to locate shared/dynamic link libraries.

SIDL_DLL_PATH.
The SIDL_DLL_PATH environment variable is typically required to contain the path to the directory holding the shared/dynamic link library containing the implementation of SIDL objects. This is a semicolon-separated path variable.

BABEL_JVM_FLAGS.
Consisting of a semicolon-separated list of command line options, BABEL_JVM_FLAGS passes them on to the implementation. For instance, -Xcheck:jni can be useful since it results in the JVM validating parameters and environment data prior to JNI requests. The following command illustrates additional useful options$:$


BABEL_JVM_FLAGS="-verbose:gc;-Xmx500m"

WARNING$:$ Not including all the necessary files in the SIDL_DLL_PATH and LD_LIBRARY_PATH can crash the JVM in unexpected ways. Babel tries to generate helpful error messages, but sometimes the JVM crashes due to missing files with the resulting output not being very helpful. If the JVM crashes, SIDL_DLL_PATH and LD_LIBRARY_PATH should be checked to ensure they point to the necessary files.



babel-1.4.0
users_guide Last Modified 2008-10-16

http://www.llnl.gov/CASC/components
components@llnl.gov