From 66bd7e0814cb761c25425f46d61d574f058c391a Mon Sep 17 00:00:00 2001 From: Joel Dice Date: Sat, 18 Jan 2014 19:41:43 -0700 Subject: [PATCH 1/2] use "lzma." prefix for LZMA-compressed embedded jars Previously, we used "lzma:", which worked fine on Windows (where the path separator is ";") but not on Unix-style OSes (where the path separator is ":"). In the latter case, the VM would parse "[lzma:bootJar]" as a path containing two elements, "[lzma" and "bootJar]", which is not what was intended. So now we use "lzma." as the prefix, which works on all OSes. --- README.md | 2 +- src/finder.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8f722634be..dfa7b580b2 100644 --- a/README.md +++ b/README.md @@ -503,7 +503,7 @@ compress the jar before generating the object: boot.jar.lzma boot-jar.o _binary_boot_jar_start _binary_boot_jar_end \ ${platform} ${arch} -Note that you'll need to specify "-Xbootclasspath:[lzma:bootJar]" +Note that you'll need to specify "-Xbootclasspath:[lzma.bootJar]" instead of "-Xbootclasspath:[bootJar]" in the next step if you've used LZMA to compress the jar. diff --git a/src/finder.cpp b/src/finder.cpp index 32ce777b7b..eb64d92c08 100644 --- a/src/finder.cpp +++ b/src/finder.cpp @@ -566,7 +566,7 @@ class BuiltinElement: public JarElement { virtual void init() { if (index == 0) { if (s->success(s->load(&library, libraryName))) { - bool lzma = strncmp("lzma:", name, 5) == 0; + bool lzma = strncmp("lzma.", name, 5) == 0; const char* symbolName = lzma ? name + 5 : name; void* p = library->resolve(symbolName); From 7ec7fe7e4d9f30d52781262282e64d774b3c5ff9 Mon Sep 17 00:00:00 2001 From: Joel Dice Date: Sat, 18 Jan 2014 19:45:10 -0700 Subject: [PATCH 2/2] preserve ThreadGroup.threadTerminated in openjdk.pro We call this cleanup method from within the VM for every thread, so we need to preserve it. --- openjdk.pro | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/openjdk.pro b/openjdk.pro index 4ad548281d..d3560dc7bb 100644 --- a/openjdk.pro +++ b/openjdk.pro @@ -9,6 +9,10 @@ public void run(); } +-keepclassmembers class java.lang.ThreadGroup { + void threadTerminated(java.lang.Thread); + } + -keep class java.lang.System { private static void initializeSystemClass(); public static void setProperties(java.util.Properties);