diff --git a/classpath/avian/avian_vm_resource/Handler.java b/classpath/avian/avianvmresource/Handler.java similarity index 98% rename from classpath/avian/avian_vm_resource/Handler.java rename to classpath/avian/avianvmresource/Handler.java index dfad1f7964..ea776c7e92 100644 --- a/classpath/avian/avian_vm_resource/Handler.java +++ b/classpath/avian/avianvmresource/Handler.java @@ -8,7 +8,7 @@ There is NO WARRANTY for this software. See license.txt for details. */ -package avian.avian_vm_resource; +package avian.avianvmresource; import java.net.URL; import java.net.URLStreamHandler; diff --git a/classpath/java/net/URL.java b/classpath/java/net/URL.java index 3c2852f394..c311ad8c15 100644 --- a/classpath/java/net/URL.java +++ b/classpath/java/net/URL.java @@ -83,8 +83,8 @@ public final class URL { { if ("http".equals(protocol) || "https".equals(protocol)) { return new avian.http.Handler(); - } else if ("avian_vm_resource".equals(protocol)) { - return new avian.avian_vm_resource.Handler(); + } else if ("avianvmresource".equals(protocol)) { + return new avian.avianvmresource.Handler(); } else if ("file".equals(protocol)) { return new avian.file.Handler(); } else if ("jar".equals(protocol)) { diff --git a/makefile b/makefile index 6b611ebd2c..8330ff31e0 100755 --- a/makefile +++ b/makefile @@ -806,7 +806,7 @@ ifneq ($(classpath),avian) $(classpath-src)/avian/VMClass.java \ $(classpath-src)/avian/VMField.java \ $(classpath-src)/avian/VMMethod.java \ - $(classpath-src)/avian/avian_vm_resource/Handler.java + $(classpath-src)/avian/avianvmresource/Handler.java ifneq ($(openjdk),) classpath-sources := $(classpath-sources) \ diff --git a/openjdk.pro b/openjdk.pro index 8207016de5..165a6067af 100644 --- a/openjdk.pro +++ b/openjdk.pro @@ -208,7 +208,7 @@ -keep class sun.nio.cs.UTF_8 # loaded reflectively to handle embedded resources: --keep class avian.resource.Handler +-keep class avian.avianvmresource.Handler # refered to symbolically in MethodAccessorGenerator: -keep class sun.reflect.MethodAccessorImpl { @@ -244,3 +244,5 @@ -keep class sun.nio.fs.UnixException { UnixException(int); } + +-keep class sun.net.www.protocol.jar.Handler diff --git a/src/builtin.cpp b/src/builtin.cpp index c438aebea0..845c0cebe1 100644 --- a/src/builtin.cpp +++ b/src/builtin.cpp @@ -155,7 +155,7 @@ Avian_java_lang_Runtime_exit } extern "C" JNIEXPORT int64_t JNICALL -Avian_avian_resource_Handler_00024ResourceInputStream_getContentLength +Avian_avian_avianvmresource_Handler_00024ResourceInputStream_getContentLength (Thread* t, object, uintptr_t* arguments) { object path = reinterpret_cast(*arguments); @@ -179,7 +179,7 @@ Avian_avian_resource_Handler_00024ResourceInputStream_getContentLength } extern "C" JNIEXPORT int64_t JNICALL -Avian_avian_resource_Handler_00024ResourceInputStream_open +Avian_avian_avianvmresource_Handler_00024ResourceInputStream_open (Thread* t, object, uintptr_t* arguments) { object path = reinterpret_cast(*arguments); @@ -200,7 +200,7 @@ Avian_avian_resource_Handler_00024ResourceInputStream_open } extern "C" JNIEXPORT int64_t JNICALL -Avian_avian_resource_Handler_00024ResourceInputStream_available +Avian_avian_avianvmresource_Handler_00024ResourceInputStream_available (Thread*, object, uintptr_t* arguments) { int64_t peer; memcpy(&peer, arguments, 8); @@ -211,7 +211,7 @@ Avian_avian_resource_Handler_00024ResourceInputStream_available } extern "C" JNIEXPORT int64_t JNICALL -Avian_avian_resource_Handler_00024ResourceInputStream_read__JI +Avian_avian_avianvmresource_Handler_00024ResourceInputStream_read__JI (Thread*, object, uintptr_t* arguments) { int64_t peer; memcpy(&peer, arguments, 8); @@ -226,7 +226,7 @@ Avian_avian_resource_Handler_00024ResourceInputStream_read__JI } extern "C" JNIEXPORT int64_t JNICALL -Avian_avian_resource_Handler_00024ResourceInputStream_read__JI_3BII +Avian_avian_avianvmresource_Handler_00024ResourceInputStream_read__JI_3BII (Thread* t, object, uintptr_t* arguments) { int64_t peer; memcpy(&peer, arguments, 8); @@ -251,7 +251,7 @@ Avian_avian_resource_Handler_00024ResourceInputStream_read__JI_3BII } extern "C" JNIEXPORT void JNICALL -Avian_avian_resource_Handler_00024ResourceInputStream_close +Avian_avian_avianvmresource_Handler_00024ResourceInputStream_close (Thread*, object, uintptr_t* arguments) { int64_t peer; memcpy(&peer, arguments, 8); diff --git a/src/finder.cpp b/src/finder.cpp index 12c8edc8eb..bfe6214a9e 100644 --- a/src/finder.cpp +++ b/src/finder.cpp @@ -602,7 +602,7 @@ class BuiltinElement: public JarElement { } virtual const char* urlPrefix() { - return "avian_vm_resource:"; + return "avianvmresource:"; } virtual const char* sourceUrl() {