Programming CORBA with Orbacus on Linux
Using Java with Orbacus on Windows
To succesfully use Orbacus with Java, you have to set the environment variable CLASSPATH to the
following value (shown for Windows):
$ set JOB=c:\ingo\JOB-4.1.0
$ set JOBBIN=c:\ingo\bin
$ set PATH=%PATH%;%JAVA_HOME%\bin:%JOBBIN%\bin
$ set CLASSPATH=%JOB%\lib\OB.jar;%JOB%\lib\OBNaming.jar;%JOB%\lib\OBEvent.jar
JOBBIN is the directory where I placed the executables for Windows I downloaded from the
IONA Orbacus homepage. In JOB, I extracted the Java archives for Orbacus. JAVA_HOME points to the
root directory of my JDK.
If you use more services besides CosNaming and CosEvent, you have to include the appropriate
Java archives in the CLASSPATH variable.
Compilation and execution of a Java CORBA program can now simply be performed via regular javac
and java commands. An example for a Java server and client can be found
here.
|