Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Modify the Makefile, replacing the PACKAGE, MODULE and INTERFACENAME values with values appropriate for your new data provider.

Code Block
 rdh@tersk09rdh@tersk09 $ emacs Makefile.sun4
<edit PACKAGE, MODULE and INTERFACENAME>

Run the Makefile.sun4; this will create all client and server sides, except the _impl.java file. You will create an _impl.java file by hand later.

Code Block

rdh@tersk09 $ gmake -f Makefile.sun4
jidl: couldn't open /u/cd/rdh/work2/package/aida/idl/dpSlcMagnet.idl
echo 'me first'
me first
sed -e 's/THIS/dpSlcMagnet/g' ....
...

Create the JNI prototypes for the native methods:

Code Block
MCCDEV> javah -o dpslcbpm_jni.h -classpath [------] "edu.stanford.slac.aida.dp.d
pSlcBpm.DpSlcBpmI_impl"

...

Create your JNI interface module (the C code that the java calls). By convention we call this module dp<servername>_jni.c. It must have the *ATTRIBUTES*=JNI at the top so cmp knows how to compile it, and it should include the output file from the step above. Eg:

...