8009389: Unpack200 native library should be removed from profiles
Reviewed-by: alanb, bobv, jrose
--- a/jdk/makefiles/profile-includes.txt Tue Apr 30 12:32:49 2013 -0700
+++ b/jdk/makefiles/profile-includes.txt Tue Apr 30 13:12:54 2013 -0700
@@ -36,7 +36,6 @@
$(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)npt$(SHARED_LIBRARY_SUFFIX) \
$(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)npt.diz \
$(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)sunec$(SHARED_LIBRARY_SUFFIX) \
- $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)unpack$(SHARED_LIBRARY_SUFFIX) \
$(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)verify$(SHARED_LIBRARY_SUFFIX) \
$(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)verify.diz \
$(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)zip$(SHARED_LIBRARY_SUFFIX) \
@@ -172,6 +171,7 @@
$(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)mlib_image$(SHARED_LIBRARY_SUFFIX) \
$(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)splashscreen$(SHARED_LIBRARY_SUFFIX) \
$(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)t2k$(SHARED_LIBRARY_SUFFIX) \
+ $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)unpack$(SHARED_LIBRARY_SUFFIX) \
alt-rt.jar \
charsets.jar \
cmm/CIEXYZ.pf \
--- a/jdk/src/share/classes/com/sun/java/util/jar/pack/UnpackerImpl.java Tue Apr 30 12:32:49 2013 -0700
+++ b/jdk/src/share/classes/com/sun/java/util/jar/pack/UnpackerImpl.java Tue Apr 30 13:12:54 2013 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -132,7 +132,12 @@
in0.close();
Utils.markJarFile(out);
} else {
- (new NativeUnpack(this)).run(in0, out);
+ try {
+ (new NativeUnpack(this)).run(in0, out);
+ } catch (UnsatisfiedLinkError ule) {
+ // failover to java implementation
+ (new DoUnpack()).run(in0, out);
+ }
in0.close();
Utils.markJarFile(out);
}