Page MenuHomeHEPForge

rave_autoconf.i.in
No OneTemporary

rave_autoconf.i.in

// Python & Java convenience
%{
#include <sstream>
%}
%define STRINGHELPER(classname)
%extend classname {
const char * toString() {
std::ostringstream os;
os << (*self);
return os.str().c_str();
}
std::string __str__() {
std::ostringstream os;
os << (*self);
return os.str();
}
};
%enddef // STRINGHELPER
%include "rave.i"
%pragma(java) jniclasscode = %{
static {
String libname = System.mapLibraryName( "@JAVALIBRARY@" );
try {
try {
System.load ( "@prefix@/lib/jni/" + libname );
System.out.println( libname + " successfully loaded!" );
} catch(UnsatisfiedLinkError e) {
libname = "lib@JAVALIBRARY@.so";
System.load ( "@prefix@/lib/jni/" + libname );
System.out.println( libname + " successfully loaded!" );
}
} catch(SecurityException e) {
System.out.println( libname + " not loaded!" );
e.printStackTrace();
} catch(UnsatisfiedLinkError e) {
System.out.println( libname + " not loaded!" );
e.printStackTrace();
}
}
%}

File Metadata

Mime Type
text/x-c
Expires
Sat, Dec 21, 5:46 PM (10 h, 54 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3818273
Default Alt Text
rave_autoconf.i.in (1 KB)

Event Timeline