19465
Port pluglets to linux and Solaris (This is not part of the build) git-svn-id: svn://10.0.0.236/trunk@54082 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -175,11 +175,17 @@ void PlugletEngine::StartJVM(void) {
|
||||
sprintf(classpath, "%s%c%s",
|
||||
vm_args.classpath, PATH_SEPARATOR, PR_GetEnv("CLASSPATH"));
|
||||
printf("-- classpath %s\n",classpath);
|
||||
char **props = new char*[2];
|
||||
props[0]="java.compiler=NONE";
|
||||
props[1]=0;
|
||||
vm_args.properties = props;
|
||||
vm_args.classpath = classpath;
|
||||
/* Create the Java VM */
|
||||
res = JNI_CreateJavaVM(&jvm, &env, &vm_args);
|
||||
if(res < 0 ) {
|
||||
printf("--JNI_CreateJavaVM failed \n");
|
||||
} else {
|
||||
printf("--PlugletEngine::StartJVM() jvm was started \n");
|
||||
}
|
||||
}
|
||||
#endif /* OJI_DISABLE */
|
||||
@@ -208,6 +214,7 @@ JNIEnv * PlugletEngine::GetJNIEnv(void) {
|
||||
StartJVM();
|
||||
}
|
||||
jvm->AttachCurrentThread(&res,NULL);
|
||||
printf("--PluglgetEngine::GetJNIEnv after jvm->Attach \n");
|
||||
#endif /* OJI_DISABLE */
|
||||
return res;
|
||||
}
|
||||
@@ -230,7 +237,7 @@ jobject PlugletEngine::GetPlugletManager(void) {
|
||||
}
|
||||
|
||||
PlugletEngine * PlugletEngine::GetEngine(void) {
|
||||
return engine;
|
||||
return engine;
|
||||
}
|
||||
void PlugletEngine::IncObjectCount(void) {
|
||||
objectCount++;
|
||||
|
||||
Reference in New Issue
Block a user