1.1 --- a/src/os/posix/launcher/java_md.c Tue Dec 14 15:10:52 2010 -0500 1.2 +++ b/src/os/posix/launcher/java_md.c Wed Dec 15 07:11:31 2010 -0800 1.3 @@ -28,6 +28,7 @@ 1.4 #include <dlfcn.h> 1.5 #include <fcntl.h> 1.6 #include <inttypes.h> 1.7 +#include <stdint.h> 1.8 #include <stdio.h> 1.9 #include <string.h> 1.10 #include <stdlib.h> 1.11 @@ -812,13 +813,10 @@ 1.12 1.13 #ifdef GAMMA 1.14 { 1.15 - /* gamma launcher uses JAVA_HOME or ALT_JAVA_HOME environment variable to find JDK/JRE */ 1.16 - char* java_home_var = getenv("ALT_JAVA_HOME"); 1.17 + /* gamma launcher uses JAVA_HOME environment variable to find JDK/JRE */ 1.18 + char* java_home_var = getenv("JAVA_HOME"); 1.19 if (java_home_var == NULL) { 1.20 - java_home_var = getenv("JAVA_HOME"); 1.21 - } 1.22 - if (java_home_var == NULL) { 1.23 - printf("JAVA_HOME or ALT_JAVA_HOME must point to a valid JDK/JRE to run gamma\n"); 1.24 + printf("JAVA_HOME must point to a valid JDK/JRE to run gamma\n"); 1.25 return JNI_FALSE; 1.26 } 1.27 snprintf(buf, bufsize, "%s", java_home_var); 1.28 @@ -1837,7 +1835,7 @@ 1.29 if (pthread_create(&tid, &attr, (void *(*)(void*))continuation, (void*)args) == 0) { 1.30 void * tmp; 1.31 pthread_join(tid, &tmp); 1.32 - rslt = (int)tmp; 1.33 + rslt = (int)(intptr_t)tmp; 1.34 } else { 1.35 /* 1.36 * Continue execution in current thread if for some reason (e.g. out of 1.37 @@ -1855,7 +1853,7 @@ 1.38 if (thr_create(NULL, stack_size, (void *(*)(void *))continuation, args, flags, &tid) == 0) { 1.39 void * tmp; 1.40 thr_join(tid, NULL, &tmp); 1.41 - rslt = (int)tmp; 1.42 + rslt = (int)(intptr_t)tmp; 1.43 } else { 1.44 /* See above. Continue in current thread if thr_create() failed */ 1.45 rslt = continuation(args);