RFC: cannot run hotspot with bootstrap jdk1.7.0_45: see 8014399: Remove JVM_SetProtectionDomain from hotspot:

Daniel D. Daugherty daniel.daugherty at oracle.com
Sun Nov 3 07:10:04 PST 2013


Just to add a bit of clarity to this thread:

- Bug ID 8014399 was used in error to push the HotSpot changeset that
   removed JVM_SetProtectionDomain(); it was a typo, but there's no easy
   way to fix such things with Mercurial.

- The correct bug ID for this work is:

   JDK-8014933 setProtectionDomain0 in java/lang/Class should be removed
               in JDK and JVM
   https://bugs.openjdk.java.net/browse/JDK-8014933

- The removal of JVM_SetProtectionDomain() is probably not the only
   thing that keeps OpenJDK7update from using an HSX-25 JVM.

- Making this kind of change requires coordination of the 'jdk' repo push
   and the corresponding 'hotspot' push; in this case, the 'jdk' repo push
   must happen first and the 'hotspot' push must wait until the 'jdk'
   changes are 'promoted' to avoid breaking our testing infrastructure.

Dan


On 11/3/13 8:30 AM, Francis ANDRE wrote:
> Hi again
>
> I found another problem. It seems that the jdk itself should be 
> patched by removing the reference to _JVM_SetProtectionDomain as follow:
>
> diff --git a/src/share/javavm/export/jvm.h 
> b/src/share/javavm/export/jvm.h
> --- a/src/share/javavm/export/jvm.h
> +++ b/src/share/javavm/export/jvm.h
> @@ -439,9 +439,6 @@
>  JNIEXPORT jobject JNICALL
>  JVM_GetProtectionDomain(JNIEnv *env, jclass cls);
>
> -JNIEXPORT void JNICALL
> -JVM_SetProtectionDomain(JNIEnv *env, jclass cls, jobject 
> protection_domain);
> -
>  JNIEXPORT jboolean JNICALL
>  JVM_IsArrayClass(JNIEnv *env, jclass cls);
>
> diff --git a/src/share/native/java/lang/Class.c 
> b/src/share/native/java/lang/Class.c
> --- a/src/share/native/java/lang/Class.c
> +++ b/src/share/native/java/lang/Class.c
> @@ -68,7 +68,6 @@
>      {"getDeclaredMethods0","(Z)[" MHD,      (void 
> *)&JVM_GetClassDeclaredMethods},
>      {"getDeclaredConstructors0","(Z)[" CTR, (void 
> *)&JVM_GetClassDeclaredConstructors},
>      {"getProtectionDomain0", "()" PD,       (void 
> *)&JVM_GetProtectionDomain},
> -    {"setProtectionDomain0", "(" PD ")V",   (void 
> *)&JVM_SetProtectionDomain},
>      {"getDeclaredClasses0",  "()[" CLS,      (void 
> *)&JVM_GetDeclaredClasses},
>      {"getDeclaringClass0",   "()" CLS,      (void 
> *)&JVM_GetDeclaringClass},
>      {"getGenericSignature", "()" STR,       (void 
> *)&JVM_GetClassSignature},
>
>
>
> Francis
>
> Le 02/11/2013 13:58, Francis ANDRE a écrit :
>> Hi
>>
>> Building hotspot-rt using this repository 
>> http://hg.openjdk.java.net/hsx/hotspot-rt on a WXP/Cygwin/VS2010 
>> platform and running
>>
>> C:/Progra~1/Java/jdk1.7.0_45\bin\java.exe 
>> -XXaltjvm=Z:/JDK/hotspot-rt/hotspot/build\vs-i486/compiler1/debug 
>> -Dsun.java.launcher=gamma
>>
>> produces the following exception
>>
>> _JVM_SetProtectionDomain at 12 is not found in the dynamic linked 
>> library jvm.dll
>>
>>
>> The definition of SetProtectionDomain has been removed from the jdk8 
>> jvm but not its reference in the jdk7 java.exe, thus it is not 
>> possible anymore to build/run a jdk8 release with a bootstrap release 
>> as of jdk7 that contains such reference. Thus I am proposing to build 
>> a jdk7 release without any reference to the _JVM_SetProtectionDomain 
>> entry point by back-porting the 8014399 to the jdk7u distribution.
>>
>>
>>
>> Francis
>>
>>
>>
>
>
>



More information about the hotspot-runtime-dev mailing list