Initial version
This commit is contained in:
parent
271009eb6a
commit
ff9254ee03
4
.gitignore
vendored
4
.gitignore
vendored
@ -0,0 +1,4 @@
|
||||
/class-rewriter.tar.gz
|
||||
/desktop-files.tar.gz
|
||||
/jdk8-b79.tar.gz
|
||||
/systemtap-tapset.tar.gz
|
2
README.src
Normal file
2
README.src
Normal file
@ -0,0 +1,2 @@
|
||||
The java-1.8.0-openjdk-src subpackage contains the complete OpenJDK 8
|
||||
class library source code for use by IDE indexers and debuggers.
|
72
TestCryptoLevel.java
Normal file
72
TestCryptoLevel.java
Normal file
@ -0,0 +1,72 @@
|
||||
/* TestCryptoLevel -- Ensure unlimited crypto policy is in use.
|
||||
Copyright (C) 2012 Red Hat, Inc.
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as
|
||||
published by the Free Software Foundation, either version 3 of the
|
||||
License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.lang.reflect.Method;
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
|
||||
import java.security.Permission;
|
||||
import java.security.PermissionCollection;
|
||||
|
||||
public class TestCryptoLevel
|
||||
{
|
||||
public static void main(String[] args)
|
||||
throws NoSuchFieldException, ClassNotFoundException,
|
||||
IllegalAccessException, InvocationTargetException
|
||||
{
|
||||
Class<?> cls = null;
|
||||
Method def = null, exempt = null;
|
||||
|
||||
try
|
||||
{
|
||||
cls = Class.forName("javax.crypto.JceSecurity");
|
||||
}
|
||||
catch (ClassNotFoundException ex)
|
||||
{
|
||||
System.err.println("Running a non-Sun JDK.");
|
||||
System.exit(0);
|
||||
}
|
||||
try
|
||||
{
|
||||
def = cls.getDeclaredMethod("getDefaultPolicy");
|
||||
exempt = cls.getDeclaredMethod("getExemptPolicy");
|
||||
}
|
||||
catch (NoSuchMethodException ex)
|
||||
{
|
||||
System.err.println("Running IcedTea with the original crypto patch.");
|
||||
System.exit(0);
|
||||
}
|
||||
def.setAccessible(true);
|
||||
exempt.setAccessible(true);
|
||||
PermissionCollection defPerms = (PermissionCollection) def.invoke(null);
|
||||
PermissionCollection exemptPerms = (PermissionCollection) exempt.invoke(null);
|
||||
Class<?> apCls = Class.forName("javax.crypto.CryptoAllPermission");
|
||||
Field apField = apCls.getDeclaredField("INSTANCE");
|
||||
apField.setAccessible(true);
|
||||
Permission allPerms = (Permission) apField.get(null);
|
||||
if (defPerms.implies(allPerms) && (exemptPerms == null || exemptPerms.implies(allPerms)))
|
||||
{
|
||||
System.err.println("Running with the unlimited policy.");
|
||||
System.exit(0);
|
||||
}
|
||||
else
|
||||
{
|
||||
System.err.println("WARNING: Running with a restricted crypto policy.");
|
||||
System.exit(-1);
|
||||
}
|
||||
}
|
||||
}
|
15
disable-werror.patch
Normal file
15
disable-werror.patch
Normal file
@ -0,0 +1,15 @@
|
||||
diff --git a/makefiles/CompileNativeLibraries.gmk b/makefiles/CompileNativeLibraries.gmk
|
||||
--- jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
+++ jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
@@ -1980,10 +1980,7 @@
|
||||
|
||||
ifneq ($(OPENJDK_TARGET_OS),macosx)
|
||||
|
||||
- SCTP_WERROR := -Werror
|
||||
- ifeq ($(OPENJDK_TARGET_CPU_ARCH), ppc)
|
||||
- SCTP_WERROR :=
|
||||
- endif
|
||||
+ SCTP_WERROR :=
|
||||
|
||||
$(eval $(call SetupNativeCompilation,BUILD_LIBSCTP,\
|
||||
LIBRARY:=sctp,\
|
27
dont-use-gstabs.patch
Normal file
27
dont-use-gstabs.patch
Normal file
@ -0,0 +1,27 @@
|
||||
diff --git jdk8/hotspot/make/linux/makefiles/gcc.make jdk8/hotspot/make/linux/makefiles/gcc.make
|
||||
--- jdk8/hotspot/make/linux/makefiles/gcc.make
|
||||
+++ jdk8/hotspot/make/linux/makefiles/gcc.make
|
||||
@@ -234,6 +234,7 @@
|
||||
# (warning: that could easily inflate libjvm.so to 150M!)
|
||||
# Note: The Itanium gcc compiler crashes when using -gstabs.
|
||||
DEBUG_CFLAGS/ia64 = -g
|
||||
+ DEBUG_CFLAGS/i486 = -g
|
||||
DEBUG_CFLAGS/amd64 = -g
|
||||
DEBUG_CFLAGS/arm = -g
|
||||
DEBUG_CFLAGS/ppc = -g
|
||||
@@ -244,6 +245,7 @@
|
||||
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
FASTDEBUG_CFLAGS/ia64 = -g
|
||||
+ FASTDEBUG_CFLAGS/i486 = -g
|
||||
FASTDEBUG_CFLAGS/amd64 = -g
|
||||
FASTDEBUG_CFLAGS/arm = -g
|
||||
FASTDEBUG_CFLAGS/ppc = -g
|
||||
@@ -253,6 +255,7 @@
|
||||
endif
|
||||
|
||||
OPT_CFLAGS/ia64 = -g
|
||||
+ OPT_CFLAGS/i486 = -g
|
||||
OPT_CFLAGS/amd64 = -g
|
||||
OPT_CFLAGS/arm = -g
|
||||
OPT_CFLAGS/ppc = -g
|
31
generate_source_tarball.sh
Executable file
31
generate_source_tarball.sh
Executable file
@ -0,0 +1,31 @@
|
||||
#!/bin/bash
|
||||
|
||||
VERSION=$1
|
||||
REV=$2
|
||||
JDK8_URL=http://hg.openjdk.java.net/jdk8/jdk8
|
||||
|
||||
if test "x${VERSION}" = "x"; then
|
||||
echo "No version specified. A version is of the form 'jdk8-bXX' (such as 'jdk8-b79')"
|
||||
exit -1;
|
||||
fi
|
||||
|
||||
wget -O root.tar.gz ${JDK8_URL}/archive/${VERSION}.tar.gz
|
||||
tar xzf root.tar.gz
|
||||
rm -f root.tar.gz
|
||||
mv jdk8-${VERSION} jdk8
|
||||
rm -f jdk8/.hg*
|
||||
pushd jdk8
|
||||
|
||||
for repos in corba jaxp jaxws langtools hotspot jdk
|
||||
do
|
||||
wget -O $repos.tar.gz ${JDK8_URL}/${repos}/archive/${VERSION}.tar.gz
|
||||
tar xzf $repos.tar.gz
|
||||
rm -f $repos.tar.gz
|
||||
mv $repos-${VERSION} $repos
|
||||
rm -f $repos/.hg*
|
||||
done
|
||||
|
||||
rm -rvf jdk/src/share//native/sun/security/ec/impl
|
||||
|
||||
popd
|
||||
tar czf ${VERSION}.tar.gz jdk8
|
28
generate_tarballs.sh
Executable file
28
generate_tarballs.sh
Executable file
@ -0,0 +1,28 @@
|
||||
#!/bin/bash
|
||||
|
||||
VERSION=3506c375241e
|
||||
ICEDTEA_URL=http://icedtea.classpath.org/hg/icedtea7/
|
||||
|
||||
wget -O icedtea7.tar.gz ${ICEDTEA_URL}/archive/${VERSION}.tar.gz
|
||||
tar xzf icedtea7.tar.gz
|
||||
rm -f icedtea7.tar.gz
|
||||
pushd icedtea7-${VERSION}
|
||||
|
||||
# rewriter
|
||||
tar cvzf class-rewriter.tar.gz rewriter
|
||||
mv class-rewriter.tar.gz ../
|
||||
|
||||
# desktop files
|
||||
tar cvzf desktop-files.tar.gz jconsole.desktop policytool.desktop
|
||||
mv desktop-files.tar.gz ../
|
||||
|
||||
# tapsets
|
||||
mv tapset/hotspot{,-1.8.0}.stp.in || exit 1
|
||||
mv tapset/hotspot_gc{,-1.8.0}.stp.in || exit 1
|
||||
mv tapset/hotspot_jni{,-1.8.0}.stp.in || exit 1
|
||||
mv tapset/jstack{,-1.8.0}.stp.in || exit 1
|
||||
tar cvzf systemtap-tapset.tar.gz tapset
|
||||
mv systemtap-tapset.tar.gz ../
|
||||
|
||||
popd
|
||||
rm -rf icedtea7-${VERSION}
|
16
java-1.8.0-openjdk-accessible-toolkit.patch
Normal file
16
java-1.8.0-openjdk-accessible-toolkit.patch
Normal file
@ -0,0 +1,16 @@
|
||||
diff -uNr openjdk-orig/jdk/src/share/classes/java/awt/Toolkit.java jdk8/jdk/src/share/classes/java/awt/Toolkit.java
|
||||
--- openjdk-orig/jdk/src/share/classes/java/awt/Toolkit.java 2009-01-23 11:59:47.000000000 -0500
|
||||
+++ jdk8/jdk/src/share/classes/java/awt/Toolkit.java 2009-01-23 12:05:20.000000000 -0500
|
||||
@@ -871,7 +871,11 @@
|
||||
return null;
|
||||
}
|
||||
});
|
||||
- loadAssistiveTechnologies();
|
||||
+ try {
|
||||
+ loadAssistiveTechnologies();
|
||||
+ } catch ( AWTError error) {
|
||||
+ // ignore silently
|
||||
+ }
|
||||
} finally {
|
||||
// Make sure to always re-enable the JIT.
|
||||
java.lang.Compiler.enable();
|
22
java-1.8.0-openjdk-arm-fixes.patch
Normal file
22
java-1.8.0-openjdk-arm-fixes.patch
Normal file
@ -0,0 +1,22 @@
|
||||
diff -up jdk8/jdk/make/jdk_generic_profile.sh.sav openjdk/jdk/make/jdk_generic_profile.sh
|
||||
--- jdk8/jdk/make/jdk_generic_profile.sh.sav 2012-02-14 16:12:48.000000000 -0500
|
||||
+++ jdk8/jdk/make/jdk_generic_profile.sh 2012-03-07 17:31:26.154840740 -0500
|
||||
@@ -280,7 +280,7 @@ if [ "${ZERO_BUILD}" = true ] ; then
|
||||
|
||||
# ZERO_ENDIANNESS is the endianness of the processor
|
||||
case "${ZERO_LIBARCH}" in
|
||||
- i386|amd64|ia64)
|
||||
+ i386|amd64|ia64|arm)
|
||||
ZERO_ENDIANNESS=little
|
||||
;;
|
||||
ppc*|s390*|sparc*|alpha)
|
||||
@@ -307,6 +307,9 @@ if [ "${ZERO_BUILD}" = true ] ; then
|
||||
s390)
|
||||
ZERO_ARCHFLAG="-m31"
|
||||
;;
|
||||
+ arm)
|
||||
+ ZERO_ARCHFLAG="-D_LITTLE_ENDIAN"
|
||||
+ ;;
|
||||
*)
|
||||
ZERO_ARCHFLAG="-m${ARCH_DATA_MODEL}"
|
||||
esac
|
47
java-1.8.0-openjdk-bitmap.patch
Normal file
47
java-1.8.0-openjdk-bitmap.patch
Normal file
@ -0,0 +1,47 @@
|
||||
diff -up jdk8/hotspot/src/share/vm/utilities/bitMap.inline.hpp.s390 openjdk/hotspot/src/share/vm/utilities/bitMap.inline.hpp
|
||||
--- jdk8/hotspot/src/share/vm/utilities/bitMap.inline.hpp.s390 2012-02-10 08:30:46.378435291 -0500
|
||||
+++ jdk8/hotspot/src/share/vm/utilities/bitMap.inline.hpp 2012-02-10 08:47:27.478427892 -0500
|
||||
@@ -52,16 +52,16 @@ inline void BitMap::clear_bit(idx_t bit)
|
||||
|
||||
inline bool BitMap::par_set_bit(idx_t bit) {
|
||||
verify_index(bit);
|
||||
- volatile idx_t* const addr = word_addr(bit);
|
||||
- const idx_t mask = bit_mask(bit);
|
||||
- idx_t old_val = *addr;
|
||||
+ volatile bm_word_t* const addr = word_addr(bit);
|
||||
+ const bm_word_t mask = bit_mask(bit);
|
||||
+ bm_word_t old_val = *addr;
|
||||
|
||||
do {
|
||||
- const idx_t new_val = old_val | mask;
|
||||
+ const bm_word_t new_val = old_val | mask;
|
||||
if (new_val == old_val) {
|
||||
return false; // Someone else beat us to it.
|
||||
}
|
||||
- const idx_t cur_val = (idx_t) Atomic::cmpxchg_ptr((void*) new_val,
|
||||
+ const bm_word_t cur_val = (bm_word_t) Atomic::cmpxchg_ptr((void*) new_val,
|
||||
(volatile void*) addr,
|
||||
(void*) old_val);
|
||||
if (cur_val == old_val) {
|
||||
@@ -73,16 +73,16 @@ inline bool BitMap::par_set_bit(idx_t bi
|
||||
|
||||
inline bool BitMap::par_clear_bit(idx_t bit) {
|
||||
verify_index(bit);
|
||||
- volatile idx_t* const addr = word_addr(bit);
|
||||
- const idx_t mask = ~bit_mask(bit);
|
||||
- idx_t old_val = *addr;
|
||||
+ volatile bm_word_t* const addr = word_addr(bit);
|
||||
+ const bm_word_t mask = ~bit_mask(bit);
|
||||
+ bm_word_t old_val = *addr;
|
||||
|
||||
do {
|
||||
- const idx_t new_val = old_val & mask;
|
||||
+ const bm_word_t new_val = old_val & mask;
|
||||
if (new_val == old_val) {
|
||||
return false; // Someone else beat us to it.
|
||||
}
|
||||
- const idx_t cur_val = (idx_t) Atomic::cmpxchg_ptr((void*) new_val,
|
||||
+ const bm_word_t cur_val = (bm_word_t) Atomic::cmpxchg_ptr((void*) new_val,
|
||||
(volatile void*) addr,
|
||||
(void*) old_val);
|
||||
if (cur_val == old_val) {
|
22
java-1.8.0-openjdk-freetype-check-fix.patch
Normal file
22
java-1.8.0-openjdk-freetype-check-fix.patch
Normal file
@ -0,0 +1,22 @@
|
||||
diff -up jdk8/jdk/make/common/shared/Sanity.gmk.sav openjdk/jdk/make/common/shared/Sanity.gmk
|
||||
--- jdk8/jdk/make/common/shared/Sanity.gmk.sav 2012-02-14 16:12:48.000000000 -0500
|
||||
+++ jdk8/jdk/make/common/shared/Sanity.gmk 2012-03-07 17:31:26.153840755 -0500
|
||||
@@ -814,12 +814,12 @@ ifdef OPENJDK
|
||||
@(($(CD) $(BUILDDIR)/tools/freetypecheck && $(MAKE)) || \
|
||||
$(ECHO) "Failed to build freetypecheck." ) > $@
|
||||
|
||||
- sane-freetype: $(TEMPDIR)/freetypeinfo
|
||||
- @if [ "`$(CAT) $< | $(GREP) Fail`" != "" ]; then \
|
||||
- $(ECHO) "ERROR: FreeType version " $(REQUIRED_FREETYPE_VERSION) \
|
||||
- " or higher is required. \n" \
|
||||
- "`$(CAT) $<` \n" >> $(ERROR_FILE) ; \
|
||||
- fi
|
||||
+# sane-freetype: $(TEMPDIR)/freetypeinfo
|
||||
+# @if [ "`$(CAT) $< | $(GREP) Fail`" != "" ]; then \
|
||||
+# $(ECHO) "ERROR: FreeType version " $(REQUIRED_FREETYPE_VERSION) \
|
||||
+# " or higher is required. \n" \
|
||||
+# "`$(CAT) $<` \n" >> $(ERROR_FILE) ; \
|
||||
+# fi
|
||||
else
|
||||
#do nothing (cross-compiling)
|
||||
sane-freetype:
|
15
java-1.8.0-openjdk-ppc-zero-corba.patch
Normal file
15
java-1.8.0-openjdk-ppc-zero-corba.patch
Normal file
@ -0,0 +1,15 @@
|
||||
diff -up jdk8/corba/make/common/shared/Defs-java.gmk.ppc openjdk/corba/make/common/shared/Defs-java.gmk
|
||||
--- jdk8/corba/make/common/shared/Defs-java.gmk.ppc 2012-03-24 11:44:34.450072733 +0100
|
||||
+++ jdk8/corba/make/common/shared/Defs-java.gmk 2012-03-24 11:44:53.300073137 +0100
|
||||
@@ -79,9 +79,9 @@ JAVAC_JVM_FLAGS =
|
||||
|
||||
# 64-bit builds require a larger thread stack size.
|
||||
ifeq ($(ARCH_DATA_MODEL), 32)
|
||||
- JAVAC_JVM_FLAGS += -J-XX:ThreadStackSize=768
|
||||
+ JAVAC_JVM_FLAGS += -J-XX:ThreadStackSize=1152
|
||||
else
|
||||
- JAVAC_JVM_FLAGS += -J-XX:ThreadStackSize=1536
|
||||
+ JAVAC_JVM_FLAGS += -J-XX:ThreadStackSize=1664
|
||||
endif
|
||||
JAVAC_JVM_FLAGS += $(JAVA_TOOLS_FLAGS:%=-J%)
|
||||
|
17
java-1.8.0-openjdk-ppc-zero-hotspot.patch
Normal file
17
java-1.8.0-openjdk-ppc-zero-hotspot.patch
Normal file
@ -0,0 +1,17 @@
|
||||
--- jdk8/hotspot/src/os_cpu/linux_zero/vm/globals_linux_zero.hpp 2012-03-23 10:57:01.000000000 -0400
|
||||
+++ jdk8/hotspot/src/os_cpu/linux_zero/vm/globals_linux_zero.hpp 2012-03-23 10:57:00.000000000 -0400
|
||||
@@ -32,11 +32,11 @@
|
||||
//
|
||||
|
||||
define_pd_global(bool, DontYieldALot, false);
|
||||
-define_pd_global(intx, ThreadStackSize, 1536);
|
||||
+define_pd_global(intx, ThreadStackSize, 1664);
|
||||
#ifdef _LP64
|
||||
-define_pd_global(intx, VMThreadStackSize, 1024);
|
||||
+define_pd_global(intx, VMThreadStackSize, 1664);
|
||||
#else
|
||||
-define_pd_global(intx, VMThreadStackSize, 512);
|
||||
+define_pd_global(intx, VMThreadStackSize, 1152);
|
||||
#endif // _LP64
|
||||
define_pd_global(intx, SurvivorRatio, 8);
|
||||
define_pd_global(intx, CompilerThreadStackSize, 0);
|
14
java-1.8.0-openjdk-ppc-zero-jdk.patch
Normal file
14
java-1.8.0-openjdk-ppc-zero-jdk.patch
Normal file
@ -0,0 +1,14 @@
|
||||
--- jdk8/jdk/make/common/shared/Defs-java.gmk 2012-03-23 10:56:45.000000000 -0400
|
||||
+++ jdk8/jdk/make/common/shared/Defs-java.gmk 2012-03-23 10:56:45.000000000 -0400
|
||||
@@ -83,9 +83,9 @@
|
||||
|
||||
# 64-bit builds require a larger thread stack size.
|
||||
ifeq ($(ARCH_DATA_MODEL), 32)
|
||||
- JAVAC_JVM_FLAGS += -J-XX:ThreadStackSize=768
|
||||
+ JAVAC_JVM_FLAGS += -J-XX:ThreadStackSize=1152
|
||||
else
|
||||
- JAVAC_JVM_FLAGS += -J-XX:ThreadStackSize=1536
|
||||
+ JAVAC_JVM_FLAGS += -J-XX:ThreadStackSize=1664
|
||||
endif
|
||||
JAVAC_JVM_FLAGS += $(JAVA_TOOLS_FLAGS:%=-J%)
|
||||
|
179
java-1.8.0-openjdk-size_t.patch
Normal file
179
java-1.8.0-openjdk-size_t.patch
Normal file
@ -0,0 +1,179 @@
|
||||
diff --git a/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp b/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp
|
||||
--- jdk8/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp
|
||||
+++ jdk8/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp
|
||||
@@ -2677,7 +2677,7 @@
|
||||
if (ResizeOldPLAB && CMSOldPLABResizeQuicker) {
|
||||
size_t multiple = _num_blocks[word_sz]/(CMSOldPLABToleranceFactor*CMSOldPLABNumRefills*n_blks);
|
||||
n_blks += CMSOldPLABReactivityFactor*multiple*n_blks;
|
||||
- n_blks = MIN2(n_blks, CMSOldPLABMax);
|
||||
+ n_blks = MIN2(n_blks, (size_t)CMSOldPLABMax);
|
||||
}
|
||||
assert(n_blks > 0, "Error");
|
||||
_cfls->par_get_chunk_of_blocks(word_sz, n_blks, fl);
|
||||
diff --git a/src/share/vm/gc_implementation/g1/concurrentMark.cpp b/src/share/vm/gc_implementation/g1/concurrentMark.cpp
|
||||
--- jdk8/hotspot/src/share/vm/gc_implementation/g1/concurrentMark.cpp
|
||||
+++ jdk8/hotspot/src/share/vm/gc_implementation/g1/concurrentMark.cpp
|
||||
@@ -3538,7 +3538,7 @@
|
||||
// of things to do) or totally (at the very end).
|
||||
size_t target_size;
|
||||
if (partially) {
|
||||
- target_size = MIN2((size_t)_task_queue->max_elems()/3, GCDrainStackTargetSize);
|
||||
+ target_size = MIN2((size_t)(_task_queue->max_elems()/3), (size_t) GCDrainStackTargetSize);
|
||||
} else {
|
||||
target_size = 0;
|
||||
}
|
||||
@@ -4318,7 +4318,7 @@
|
||||
// The > 0 check is to deal with the prev and next live bytes which
|
||||
// could be 0.
|
||||
if (*hum_bytes > 0) {
|
||||
- bytes = MIN2(HeapRegion::GrainBytes, *hum_bytes);
|
||||
+ bytes = MIN2(HeapRegion::GrainBytes, (size_t)*hum_bytes);
|
||||
*hum_bytes -= bytes;
|
||||
}
|
||||
return bytes;
|
||||
diff --git a/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp b/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp
|
||||
--- jdk8/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp
|
||||
+++ jdk8/hotspot/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp
|
||||
@@ -1700,7 +1700,7 @@
|
||||
|
||||
verify_region_sets_optional();
|
||||
|
||||
- size_t expand_bytes = MAX2(word_size * HeapWordSize, MinHeapDeltaBytes);
|
||||
+ size_t expand_bytes = MAX2(word_size * HeapWordSize, (size_t)MinHeapDeltaBytes);
|
||||
ergo_verbose1(ErgoHeapSizing,
|
||||
"attempt heap expansion",
|
||||
ergo_format_reason("allocation request failed")
|
||||
diff --git a/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp b/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp
|
||||
--- jdk8/hotspot/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp
|
||||
+++ jdk8/hotspot/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp
|
||||
@@ -840,7 +840,7 @@
|
||||
// This can be done by either mutator threads together with the
|
||||
// concurrent refinement threads or GC threads.
|
||||
int HeapRegionRemSet::num_par_rem_sets() {
|
||||
- return (int)MAX2(DirtyCardQueueSet::num_par_ids() + ConcurrentG1Refine::thread_num(), ParallelGCThreads);
|
||||
+ return (int)MAX2(DirtyCardQueueSet::num_par_ids() + ConcurrentG1Refine::thread_num(), (size_t)ParallelGCThreads);
|
||||
}
|
||||
|
||||
HeapRegionRemSet::HeapRegionRemSet(G1BlockOffsetSharedArray* bosa,
|
||||
diff --git a/src/share/vm/gc_implementation/parNew/parNewGeneration.cpp b/src/share/vm/gc_implementation/parNew/parNewGeneration.cpp
|
||||
--- jdk8/hotspot/src/share/vm/gc_implementation/parNew/parNewGeneration.cpp
|
||||
+++ jdk8/hotspot/src/share/vm/gc_implementation/parNew/parNewGeneration.cpp
|
||||
@@ -188,7 +188,7 @@
|
||||
const size_t num_overflow_elems = of_stack->size();
|
||||
const size_t space_available = queue->max_elems() - queue->size();
|
||||
const size_t num_take_elems = MIN3(space_available / 4,
|
||||
- ParGCDesiredObjsFromOverflowList,
|
||||
+ (size_t)ParGCDesiredObjsFromOverflowList,
|
||||
num_overflow_elems);
|
||||
// Transfer the most recent num_take_elems from the overflow
|
||||
// stack to our work queue.
|
||||
diff --git a/src/share/vm/gc_implementation/parallelScavenge/parMarkBitMap.cpp b/src/share/vm/gc_implementation/parallelScavenge/parMarkBitMap.cpp
|
||||
--- jdk8/hotspot/src/share/vm/gc_implementation/parallelScavenge/parMarkBitMap.cpp
|
||||
+++ jdk8/hotspot/src/share/vm/gc_implementation/parallelScavenge/parMarkBitMap.cpp
|
||||
@@ -69,7 +69,7 @@
|
||||
if (_virtual_space != NULL && _virtual_space->expand_by(bytes)) {
|
||||
_region_start = covered_region.start();
|
||||
_region_size = covered_region.word_size();
|
||||
- idx_t* map = (idx_t*)_virtual_space->reserved_low_addr();
|
||||
+ BitMap::bm_word_t* map = (BitMap::bm_word_t*)_virtual_space->reserved_low_addr();
|
||||
_beg_bits.set_map(map);
|
||||
_beg_bits.set_size(bits / 2);
|
||||
_end_bits.set_map(map + words / 2);
|
||||
diff --git a/src/share/vm/memory/collectorPolicy.cpp b/src/share/vm/memory/collectorPolicy.cpp
|
||||
--- jdk8/hotspot/src/share/vm/memory/collectorPolicy.cpp
|
||||
+++ jdk8/hotspot/src/share/vm/memory/collectorPolicy.cpp
|
||||
@@ -357,7 +357,7 @@
|
||||
// generally small compared to the NewRatio calculation.
|
||||
_min_gen0_size = NewSize;
|
||||
desired_new_size = NewSize;
|
||||
- max_new_size = MAX2(max_new_size, NewSize);
|
||||
+ max_new_size = MAX2(max_new_size, (size_t)NewSize);
|
||||
} else {
|
||||
// For the case where NewSize is the default, use NewRatio
|
||||
// to size the minimum and initial generation sizes.
|
||||
@@ -365,10 +365,10 @@
|
||||
// NewRatio is overly large, the resulting sizes can be too
|
||||
// small.
|
||||
_min_gen0_size = MAX2(scale_by_NewRatio_aligned(min_heap_byte_size()),
|
||||
- NewSize);
|
||||
+ (size_t)NewSize);
|
||||
desired_new_size =
|
||||
MAX2(scale_by_NewRatio_aligned(initial_heap_byte_size()),
|
||||
- NewSize);
|
||||
+ (size_t)NewSize);
|
||||
}
|
||||
|
||||
assert(_min_gen0_size > 0, "Sanity check");
|
||||
@@ -423,14 +423,14 @@
|
||||
// Adjust gen0 down to accomodate OldSize
|
||||
*gen0_size_ptr = heap_size - min_gen0_size;
|
||||
*gen0_size_ptr =
|
||||
- MAX2((uintx)align_size_down(*gen0_size_ptr, min_alignment()),
|
||||
+ MAX2((size_t)align_size_down(*gen0_size_ptr, min_alignment()),
|
||||
min_alignment());
|
||||
assert(*gen0_size_ptr > 0, "Min gen0 is too large");
|
||||
result = true;
|
||||
} else {
|
||||
*gen1_size_ptr = heap_size - *gen0_size_ptr;
|
||||
*gen1_size_ptr =
|
||||
- MAX2((uintx)align_size_down(*gen1_size_ptr, min_alignment()),
|
||||
+ MAX2((size_t)align_size_down(*gen1_size_ptr, min_alignment()),
|
||||
min_alignment());
|
||||
}
|
||||
}
|
||||
@@ -454,7 +454,7 @@
|
||||
// for setting the gen1 maximum.
|
||||
_max_gen1_size = max_heap_byte_size() - _max_gen0_size;
|
||||
_max_gen1_size =
|
||||
- MAX2((uintx)align_size_down(_max_gen1_size, min_alignment()),
|
||||
+ MAX2((size_t)align_size_down(_max_gen1_size, min_alignment()),
|
||||
min_alignment());
|
||||
// If no explicit command line flag has been set for the
|
||||
// gen1 size, use what is left for gen1.
|
||||
@@ -468,11 +468,11 @@
|
||||
"gen0 has an unexpected minimum size");
|
||||
set_min_gen1_size(min_heap_byte_size() - min_gen0_size());
|
||||
set_min_gen1_size(
|
||||
- MAX2((uintx)align_size_down(_min_gen1_size, min_alignment()),
|
||||
+ MAX2((size_t)align_size_down(_min_gen1_size, min_alignment()),
|
||||
min_alignment()));
|
||||
set_initial_gen1_size(initial_heap_byte_size() - initial_gen0_size());
|
||||
set_initial_gen1_size(
|
||||
- MAX2((uintx)align_size_down(_initial_gen1_size, min_alignment()),
|
||||
+ MAX2((size_t)align_size_down(_initial_gen1_size, min_alignment()),
|
||||
min_alignment()));
|
||||
|
||||
} else {
|
||||
diff --git a/src/share/vm/oops/objArrayKlass.inline.hpp b/src/share/vm/oops/objArrayKlass.inline.hpp
|
||||
--- jdk8/hotspot/src/share/vm/oops/objArrayKlass.inline.hpp
|
||||
+++ jdk8/hotspot/src/share/vm/oops/objArrayKlass.inline.hpp
|
||||
@@ -46,7 +46,7 @@
|
||||
const size_t beg_index = size_t(index);
|
||||
assert(beg_index < len || len == 0, "index too large");
|
||||
|
||||
- const size_t stride = MIN2(len - beg_index, ObjArrayMarkingStride);
|
||||
+ const size_t stride = MIN2(len - beg_index, (size_t)ObjArrayMarkingStride);
|
||||
const size_t end_index = beg_index + stride;
|
||||
T* const base = (T*)a->base();
|
||||
T* const beg = base + beg_index;
|
||||
@@ -80,7 +80,7 @@
|
||||
const size_t beg_index = size_t(index);
|
||||
assert(beg_index < len || len == 0, "index too large");
|
||||
|
||||
- const size_t stride = MIN2(len - beg_index, ObjArrayMarkingStride);
|
||||
+ const size_t stride = MIN2(len - beg_index, (size_t)ObjArrayMarkingStride);
|
||||
const size_t end_index = beg_index + stride;
|
||||
T* const base = (T*)a->base();
|
||||
T* const beg = base + beg_index;
|
||||
diff --git a/src/share/vm/runtime/arguments.cpp b/src/share/vm/runtime/arguments.cpp
|
||||
--- jdk8/hotspot/src/share/vm/runtime/arguments.cpp
|
||||
+++ jdk8/hotspot/src/share/vm/runtime/arguments.cpp
|
||||
@@ -1209,7 +1209,7 @@
|
||||
// so it's NewRatio x of NewSize.
|
||||
if (FLAG_IS_DEFAULT(OldSize)) {
|
||||
if (max_heap > NewSize) {
|
||||
- FLAG_SET_ERGO(uintx, OldSize, MIN2(NewRatio*NewSize, max_heap - NewSize));
|
||||
+ FLAG_SET_ERGO(uintx, OldSize, MIN2((size_t)(NewRatio*NewSize), max_heap - NewSize));
|
||||
if (PrintGCDetails && Verbose) {
|
||||
// Too early to use gclog_or_tty
|
||||
tty->print_cr("CMS ergo set OldSize: " SIZE_FORMAT, OldSize);
|
969
java-1.8.0-openjdk.spec
Normal file
969
java-1.8.0-openjdk.spec
Normal file
@ -0,0 +1,969 @@
|
||||
# If debug is 1, OpenJDK is built with all debug info present.
|
||||
%global debug 0
|
||||
|
||||
%global jdk8_version b79
|
||||
%global hg_tag jdk8-%{jdk8_version}
|
||||
|
||||
%global multilib_arches ppc64 sparc64 x86_64
|
||||
|
||||
%global jit_arches %{ix86} x86_64 sparcv9 sparc64
|
||||
|
||||
%ifarch x86_64
|
||||
%global archbuild amd64
|
||||
%global archinstall amd64
|
||||
%endif
|
||||
%ifarch ppc
|
||||
%global archbuild ppc
|
||||
%global archinstall ppc
|
||||
%global archdef PPC
|
||||
%endif
|
||||
%ifarch ppc64
|
||||
%global archbuild ppc64
|
||||
%global archinstall ppc64
|
||||
%global archdef PPC
|
||||
%endif
|
||||
%ifarch %{ix86}
|
||||
%global archbuild i586
|
||||
%global archinstall i386
|
||||
%endif
|
||||
%ifarch ia64
|
||||
%global archbuild ia64
|
||||
%global archinstall ia64
|
||||
%endif
|
||||
%ifarch s390
|
||||
%global archbuild s390
|
||||
%global archinstall s390
|
||||
%global archdef S390
|
||||
%endif
|
||||
%ifarch s390x
|
||||
%global archbuild s390x
|
||||
%global archinstall s390x
|
||||
%global archdef S390
|
||||
%endif
|
||||
%ifarch %{arm}
|
||||
%global archbuild arm
|
||||
%global archinstall arm
|
||||
%global archdef ARM
|
||||
%endif
|
||||
# 32 bit sparc, optimized for v9
|
||||
%ifarch sparcv9
|
||||
%global archbuild sparc
|
||||
%global archinstall sparc
|
||||
%endif
|
||||
# 64 bit sparc
|
||||
%ifarch sparc64
|
||||
%global archbuild sparcv9
|
||||
%global archinstall sparcv9
|
||||
%endif
|
||||
%ifnarch %{jit_arches}
|
||||
%global archbuild %{_arch}
|
||||
%global archinstall %{_arch}
|
||||
%endif
|
||||
|
||||
%if %{debug}
|
||||
%global debugbuild slowdebug
|
||||
%else
|
||||
%global debugbuild release
|
||||
%endif
|
||||
|
||||
%global buildoutputdir jdk8/build/jdk8.build
|
||||
|
||||
%ifarch %{jit_arches}
|
||||
%global with_systemtap 1
|
||||
%else
|
||||
%global with_systemtap 0
|
||||
%endif
|
||||
|
||||
# Convert an absolute path to a relative path. Each symbolic link is
|
||||
# specified relative to the directory in which it is installed so that
|
||||
# it will resolve properly within chrooted installations.
|
||||
%global script 'use File::Spec; print File::Spec->abs2rel($ARGV[0], $ARGV[1])'
|
||||
%global abs2rel %{__perl} -e %{script}
|
||||
|
||||
# Hard-code libdir on 64-bit architectures to make the 64-bit JDK
|
||||
# simply be another alternative.
|
||||
%ifarch %{multilib_arches}
|
||||
%global syslibdir %{_prefix}/lib64
|
||||
%global _libdir %{_prefix}/lib
|
||||
%global archname %{name}.%{_arch}
|
||||
%else
|
||||
%global syslibdir %{_libdir}
|
||||
%global archname %{name}
|
||||
%endif
|
||||
|
||||
# Standard JPackage naming and versioning defines.
|
||||
%global origin openjdk
|
||||
%global buildver 0
|
||||
# Keep priority on 5digits in case buildver>9
|
||||
%global priority 1800%{buildver}
|
||||
%global javaver 1.8.0
|
||||
|
||||
# Standard JPackage directories and symbolic links.
|
||||
# Make 64-bit JDKs just another alternative on 64-bit architectures.
|
||||
%ifarch %{multilib_arches}
|
||||
%global sdklnk java-%{javaver}-%{origin}.%{_arch}
|
||||
%global jrelnk jre-%{javaver}-%{origin}.%{_arch}
|
||||
%global sdkdir %{name}-%{version}.%{_arch}
|
||||
%else
|
||||
%global sdklnk java-%{javaver}-%{origin}
|
||||
%global jrelnk jre-%{javaver}-%{origin}
|
||||
%global sdkdir %{name}-%{version}
|
||||
%endif
|
||||
%global jredir %{sdkdir}/jre
|
||||
%global sdkbindir %{_jvmdir}/%{sdklnk}/bin
|
||||
%global jrebindir %{_jvmdir}/%{jrelnk}/bin
|
||||
%ifarch %{multilib_arches}
|
||||
%global jvmjardir %{_jvmjardir}/%{name}-%{version}.%{_arch}
|
||||
%else
|
||||
%global jvmjardir %{_jvmjardir}/%{name}-%{version}
|
||||
%endif
|
||||
|
||||
%ifarch %{jit_arches}
|
||||
# Where to install systemtap tapset (links)
|
||||
# We would like these to be in a package specific subdir,
|
||||
# but currently systemtap doesn't support that, so we have to
|
||||
# use the root tapset dir for now. To distinquish between 64
|
||||
# and 32 bit architectures we place the tapsets under the arch
|
||||
# specific dir (note that systemtap will only pickup the tapset
|
||||
# for the primary arch for now). Systemtap uses the machine name
|
||||
# aka build_cpu as architecture specific directory name.
|
||||
%global tapsetroot /usr/share/systemtap
|
||||
%global tapsetdir %{tapsetroot}/tapset/%{_build_cpu}
|
||||
%endif
|
||||
|
||||
# Prevent brp-java-repack-jars from being run.
|
||||
%global __jar_repack 0
|
||||
|
||||
Name: java-%{javaver}-%{origin}
|
||||
Version: %{javaver}.%{buildver}
|
||||
Release: 0.1.%{jdk8_version}%{?dist}
|
||||
# java-1.5.0-ibm from jpackage.org set Epoch to 1 for unknown reasons,
|
||||
# and this change was brought into RHEL-4. java-1.5.0-ibm packages
|
||||
# also included the epoch in their virtual provides. This created a
|
||||
# situation where in-the-wild java-1.5.0-ibm packages provided "java =
|
||||
# 1:1.5.0". In RPM terms, "1.6.0 < 1:1.5.0" since 1.6.0 is
|
||||
# interpreted as 0:1.6.0. So the "java >= 1.6.0" requirement would be
|
||||
# satisfied by the 1:1.5.0 packages. Thus we need to set the epoch in
|
||||
# JDK package >= 1.6.0 to 1, and packages referring to JDK virtual
|
||||
# provides >= 1.6.0 must specify the epoch, "java >= 1:1.6.0".
|
||||
Epoch: 1
|
||||
Summary: OpenJDK Runtime Environment
|
||||
Group: Development/Languages
|
||||
|
||||
License: ASL 1.1 and ASL 2.0 and GPL+ and GPLv2 and GPLv2 with exceptions and LGPL+ and LGPLv2 and MPLv1.0 and MPLv1.1 and Public Domain and W3C
|
||||
URL: http://openjdk.java.net/
|
||||
|
||||
# Source from upstrem OpenJDK8 project. Use
|
||||
# './generate_source_tarball.sh %{hg_tag}' to generate. The script merges
|
||||
# multiple tarballs into one and removes code not allowed in Fedora.
|
||||
Source0: jdk8-%{jdk8_version}.tar.gz
|
||||
|
||||
# Custom README for -src subpackage
|
||||
Source2: README.src
|
||||
|
||||
# Use 'generate_tarballs.sh' to generate the following tarballs
|
||||
# They are based on code contained in the IcedTea7 project.
|
||||
|
||||
# Class rewrite to rewrite rhino hierarchy
|
||||
Source7: class-rewriter.tar.gz
|
||||
# Systemtap tapsets. Zipped up to keep it small.
|
||||
Source8: systemtap-tapset.tar.gz
|
||||
# .desktop files. Zipped up to keep it small.
|
||||
Source9: desktop-files.tar.gz
|
||||
|
||||
# nss configuration file
|
||||
Source10: nss.cfg
|
||||
|
||||
# Removed libraries that we link instead
|
||||
Source12: remove-intree-libraries.sh
|
||||
|
||||
# Ensure we aren't using the limited crypto policy
|
||||
Source13: TestCryptoLevel.java
|
||||
|
||||
# RPM/distribution specific patches
|
||||
|
||||
# Ignore AWTError when assistive technologies are loaded
|
||||
Patch4: %{name}-accessible-toolkit.patch
|
||||
|
||||
#
|
||||
# OpenJDK specific patches
|
||||
#
|
||||
|
||||
# Add rhino support
|
||||
Patch100: rhino.patch
|
||||
|
||||
# Type fixing for s390
|
||||
Patch101: %{name}-bitmap.patch
|
||||
Patch102: %{name}-size_t.patch
|
||||
|
||||
# Patches for Arm
|
||||
Patch103: %{name}-arm-fixes.patch
|
||||
|
||||
# Patch for PPC/PPC64
|
||||
Patch104: %{name}-ppc-zero-jdk.patch
|
||||
Patch105: %{name}-ppc-zero-hotspot.patch
|
||||
Patch106: %{name}-ppc-zero-corba.patch
|
||||
|
||||
Patch107: %{name}-freetype-check-fix.patch
|
||||
Patch108: dont-use-gstabs.patch
|
||||
Patch109: disable-werror.patch
|
||||
|
||||
Patch200: system-giflib.patch
|
||||
Patch201: system-libjpeg.patch
|
||||
Patch202: system-libpng.patch
|
||||
Patch203: system-lcms.patch
|
||||
|
||||
BuildRequires: autoconf
|
||||
BuildRequires: automake
|
||||
BuildRequires: alsa-lib-devel
|
||||
BuildRequires: cups-devel
|
||||
BuildRequires: desktop-file-utils
|
||||
BuildRequires: fontconfig
|
||||
BuildRequires: freetype-devel
|
||||
BuildRequires: giflib-devel
|
||||
BuildRequires: gtk2-devel
|
||||
BuildRequires: lcms2-devel
|
||||
BuildRequires: libjpeg-devel
|
||||
BuildRequires: libpng-devel
|
||||
BuildRequires: libxslt
|
||||
BuildRequires: libX11-devel
|
||||
BuildRequires: libXi-devel
|
||||
BuildRequires: libXinerama-devel
|
||||
BuildRequires: libXt-devel
|
||||
BuildRequires: libXtst-devel
|
||||
BuildRequires: pkgconfig
|
||||
BuildRequires: wget
|
||||
BuildRequires: xorg-x11-proto-devel
|
||||
BuildRequires: rhino
|
||||
#BuildRequires: redhat-lsb
|
||||
BuildRequires: zip
|
||||
# OpenJDK X officially requires OpenJDK (X-1) to build
|
||||
BuildRequires: java-1.7.0-openjdk-devel
|
||||
# Zero-assembler build requirement.
|
||||
%ifnarch %{jit_arches}
|
||||
BuildRequires: libffi-devel
|
||||
%endif
|
||||
|
||||
# cacerts build requirement.
|
||||
BuildRequires: openssl
|
||||
# execstack build requirement.
|
||||
# no prelink on ARM yet
|
||||
%ifnarch %{arm}
|
||||
BuildRequires: prelink
|
||||
%endif
|
||||
%ifarch %{jit_arches}
|
||||
#systemtap build requirement.
|
||||
BuildRequires: systemtap-sdt-devel
|
||||
%endif
|
||||
|
||||
Requires: rhino
|
||||
# Require /etc/pki/java/cacerts.
|
||||
Requires: ca-certificates
|
||||
# Require jpackage-utils for ownership of /usr/lib/jvm/
|
||||
Requires: jpackage-utils
|
||||
# Require zoneinfo data provided by tzdata-java subpackage.
|
||||
Requires: tzdata-java
|
||||
# Post requires alternatives to install tool alternatives.
|
||||
Requires(post): %{_sbindir}/alternatives
|
||||
# Postun requires alternatives to uninstall tool alternatives.
|
||||
Requires(postun): %{_sbindir}/alternatives
|
||||
|
||||
# Standard JPackage base provides.
|
||||
Provides: jre8-%{javaver}-%{origin} = %{epoch}:%{version}-%{release}
|
||||
Provides: jre8-%{origin} = %{epoch}:%{version}-%{release}
|
||||
Provides: jre8-%{javaver} = %{epoch}:%{version}-%{release}
|
||||
Provides: java8-%{javaver} = %{epoch}:%{version}-%{release}
|
||||
Provides: jre8 = %{javaver}
|
||||
Provides: java8-%{origin} = %{epoch}:%{version}-%{release}
|
||||
Provides: java8 = %{epoch}:%{javaver}
|
||||
# Standard JPackage extensions provides.
|
||||
Provides: jndi8 = %{epoch}:%{version}
|
||||
Provides: jndi8-ldap = %{epoch}:%{version}
|
||||
Provides: jndi8-cos = %{epoch}:%{version}
|
||||
Provides: jndi8-rmi = %{epoch}:%{version}
|
||||
Provides: jndi8-dns = %{epoch}:%{version}
|
||||
Provides: jaas8 = %{epoch}:%{version}
|
||||
Provides: jsse8 = %{epoch}:%{version}
|
||||
Provides: jce8 = %{epoch}:%{version}
|
||||
Provides: jdbc8-stdext = 4.1
|
||||
Provides: java8-sasl = %{epoch}:%{version}
|
||||
Provides: java8-fonts = %{epoch}:%{version}
|
||||
|
||||
%description
|
||||
The OpenJDK runtime environment.
|
||||
|
||||
%package devel
|
||||
Summary: OpenJDK Development Environment
|
||||
Group: Development/Tools
|
||||
|
||||
# Require base package.
|
||||
Requires: %{name} = %{epoch}:%{version}-%{release}
|
||||
# Post requires alternatives to install tool alternatives.
|
||||
Requires(post): %{_sbindir}/alternatives
|
||||
# Postun requires alternatives to uninstall tool alternatives.
|
||||
Requires(postun): %{_sbindir}/alternatives
|
||||
|
||||
# Standard JPackage devel provides.
|
||||
Provides: java8-sdk-%{javaver}-%{origin} = %{epoch}:%{version}
|
||||
Provides: java8-sdk-%{javaver} = %{epoch}:%{version}
|
||||
Provides: java8-sdk-%{origin} = %{epoch}:%{version}
|
||||
Provides: java8-sdk = %{epoch}:%{javaver}
|
||||
Provides: java8-%{javaver}-devel = %{epoch}:%{version}
|
||||
Provides: java8-devel-%{origin} = %{epoch}:%{version}
|
||||
Provides: java8-devel = %{epoch}:%{javaver}
|
||||
|
||||
|
||||
%description devel
|
||||
The OpenJDK development tools.
|
||||
|
||||
%package demo
|
||||
Summary: OpenJDK Demos
|
||||
Group: Development/Languages
|
||||
|
||||
Requires: %{name} = %{epoch}:%{version}-%{release}
|
||||
|
||||
%description demo
|
||||
The OpenJDK demos.
|
||||
|
||||
%package src
|
||||
Summary: OpenJDK Source Bundle
|
||||
Group: Development/Languages
|
||||
|
||||
Requires: %{name} = %{epoch}:%{version}-%{release}
|
||||
|
||||
%description src
|
||||
The OpenJDK source bundle.
|
||||
|
||||
%package javadoc
|
||||
Summary: OpenJDK API Documentation
|
||||
Group: Documentation
|
||||
Requires: jpackage-utils
|
||||
BuildArch: noarch
|
||||
|
||||
# Post requires alternatives to install javadoc alternative.
|
||||
Requires(post): %{_sbindir}/alternatives
|
||||
# Postun requires alternatives to uninstall javadoc alternative.
|
||||
Requires(postun): %{_sbindir}/alternatives
|
||||
|
||||
# Standard JPackage javadoc provides.
|
||||
Provides: java8-javadoc = %{epoch}:%{version}-%{release}
|
||||
Provides: java8-%{javaver}-javadoc = %{epoch}:%{version}-%{release}
|
||||
|
||||
%description javadoc
|
||||
The OpenJDK API documentation.
|
||||
|
||||
%prep
|
||||
|
||||
%setup -q -c -n %{name} -T -a 0
|
||||
cp %{SOURCE2} .
|
||||
|
||||
# OpenJDK patches
|
||||
%patch108
|
||||
%patch109
|
||||
|
||||
# Rhino patch
|
||||
%patch100
|
||||
|
||||
# Remove libraries that are linked
|
||||
# disabled until 8 has all system library fixes upstream
|
||||
sh %{SOURCE12}
|
||||
|
||||
%patch200
|
||||
%patch201
|
||||
%patch202
|
||||
%patch203
|
||||
|
||||
%patch4
|
||||
|
||||
# Type fixes for s390
|
||||
%ifarch s390 s390x
|
||||
%patch101
|
||||
%patch102
|
||||
%endif
|
||||
|
||||
# Arm fixes
|
||||
%ifarch %{arm}
|
||||
%patch103
|
||||
%endif
|
||||
|
||||
%patch107
|
||||
|
||||
%ifarch ppc ppc64
|
||||
# PPC fixes
|
||||
%patch104
|
||||
%patch105
|
||||
%patch106
|
||||
%endif
|
||||
|
||||
|
||||
# Copy jaxp, jaf and jaxws drops
|
||||
mkdir drops/
|
||||
|
||||
# Extract the rewriter (to rewrite rhino classes)
|
||||
tar xzf %{SOURCE7}
|
||||
|
||||
# Extract systemtap tapsets
|
||||
%if %{with_systemtap}
|
||||
|
||||
tar xzf %{SOURCE8}
|
||||
|
||||
for file in tapset/*.in; do
|
||||
|
||||
OUTPUT_FILE=`echo $file | sed -e s:\.in$::g`
|
||||
sed -e s:@ABS_SERVER_LIBJVM_SO@:%{_jvmdir}/%{sdkdir}/jre/lib/amd64/server/libjvm.so:g $file > $OUTPUT_FILE
|
||||
sed -i -e '/@ABS_CLIENT_LIBJVM_SO@/d' $OUTPUT_FILE
|
||||
sed -i -e s:@ABS_JAVA_HOME_DIR@:%{_jvmdir}/%{sdkdir}:g $OUTPUT_FILE
|
||||
sed -i -e s:@INSTALL_ARCH_DIR@:%{archinstall}:g $OUTPUT_FILE
|
||||
|
||||
done
|
||||
|
||||
%endif
|
||||
|
||||
# Extract desktop files
|
||||
tar xzf %{SOURCE9}
|
||||
|
||||
%build
|
||||
# How many cpu's do we have?
|
||||
export NUM_PROC=`/usr/bin/getconf _NPROCESSORS_ONLN 2> /dev/null || :`
|
||||
export NUM_PROC=${NUM_PROC:-1}
|
||||
|
||||
# Build IcedTea and OpenJDK.
|
||||
%ifarch s390x sparc64 alpha ppc64
|
||||
export ARCH_DATA_MODEL=64
|
||||
%endif
|
||||
%ifarch alpha
|
||||
export CFLAGS="$CFLAGS -mieee"
|
||||
%endif
|
||||
# Build the re-written rhino jar
|
||||
mkdir -p rhino/{old,new}
|
||||
|
||||
# Compile the rewriter
|
||||
(cd rewriter
|
||||
javac com/redhat/rewriter/ClassRewriter.java
|
||||
)
|
||||
|
||||
# Extract rhino.jar contents and rewrite
|
||||
(cd rhino/old
|
||||
jar xf /usr/share/java/rhino.jar
|
||||
)
|
||||
|
||||
java -cp rewriter com.redhat.rewriter.ClassRewriter \
|
||||
$PWD/rhino/old \
|
||||
$PWD/rhino/new \
|
||||
org.mozilla \
|
||||
sun.org.mozilla
|
||||
|
||||
(cd rhino/old
|
||||
for file in `find -type f -not -name '*.class'` ; do
|
||||
new_file=../new/`echo $file | sed -e 's#org#sun/org#'`
|
||||
mkdir -pv `dirname $new_file`
|
||||
cp -v $file $new_file
|
||||
sed -ie 's#org\.mozilla#sun.org.mozilla#g' $new_file
|
||||
done
|
||||
)
|
||||
|
||||
(cd rhino/new
|
||||
jar cfm ../rhino.jar META-INF/MANIFEST.MF sun
|
||||
)
|
||||
|
||||
(cd jdk8/common/autoconf
|
||||
bash ./autogen.sh
|
||||
)
|
||||
|
||||
mkdir -p %{buildoutputdir}
|
||||
|
||||
pushd %{buildoutputdir}
|
||||
|
||||
bash ../../configure \
|
||||
--with-build-number=%{buildver} \
|
||||
--with-boot-jdk=/usr/lib/jvm/java-openjdk \
|
||||
--with-debug-level=%{debugbuild} \
|
||||
--enable-unlimited-crypto \
|
||||
--with-zlib=system \
|
||||
--with-giflib=system \
|
||||
--with-libpng=system \
|
||||
--with-lcms=system \
|
||||
--with-stdc++lib=dynamic \
|
||||
--with-num-cores="$NUM_PROC"
|
||||
|
||||
make DISABLE_INTREE_EC=true LOG=trace all
|
||||
|
||||
popd >& /dev/null
|
||||
|
||||
export JAVA_HOME=$(pwd)/%{buildoutputdir}/images/j2sdk-image
|
||||
|
||||
# Copy tz.properties
|
||||
echo "sun.zoneinfo.dir=/usr/share/javazi" >> $JAVA_HOME/jre/lib/tz.properties
|
||||
|
||||
# Check unlimited policy has been used
|
||||
$JAVA_HOME/bin/javac -d . %{SOURCE13}
|
||||
$JAVA_HOME/bin/java TestCryptoLevel
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
STRIP_KEEP_SYMTAB=libjvm*
|
||||
|
||||
# Install symlink to default soundfont
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{_jvmdir}/%{jredir}/lib/audio
|
||||
pushd $RPM_BUILD_ROOT%{_jvmdir}/%{jredir}/lib/audio
|
||||
ln -s %{_datadir}/soundfonts/default.sf2
|
||||
popd
|
||||
|
||||
pushd %{buildoutputdir}/images/j2sdk-image
|
||||
|
||||
# Install main files.
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}
|
||||
cp -a bin include lib src.zip $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{_jvmdir}/%{jredir}
|
||||
cp -a jre/bin jre/lib $RPM_BUILD_ROOT%{_jvmdir}/%{jredir}
|
||||
|
||||
%ifarch %{jit_arches}
|
||||
# Install systemtap support files.
|
||||
install -dm 755 $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}/tapset
|
||||
cp -a $RPM_BUILD_DIR/%{name}/tapset/*.stp $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}/tapset/
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{tapsetdir}
|
||||
pushd $RPM_BUILD_ROOT%{tapsetdir}
|
||||
RELATIVE=$(%{abs2rel} %{_jvmdir}/%{sdkdir}/tapset %{tapsetdir})
|
||||
ln -sf $RELATIVE/*.stp .
|
||||
popd
|
||||
%endif
|
||||
|
||||
# Install cacerts symlink.
|
||||
rm -f $RPM_BUILD_ROOT%{_jvmdir}/%{jredir}/lib/security/cacerts
|
||||
pushd $RPM_BUILD_ROOT%{_jvmdir}/%{jredir}/lib/security
|
||||
RELATIVE=$(%{abs2rel} %{_sysconfdir}/pki/java \
|
||||
%{_jvmdir}/%{jredir}/lib/security)
|
||||
ln -sf $RELATIVE/cacerts .
|
||||
popd
|
||||
|
||||
# Install extension symlinks.
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{jvmjardir}
|
||||
pushd $RPM_BUILD_ROOT%{jvmjardir}
|
||||
RELATIVE=$(%{abs2rel} %{_jvmdir}/%{jredir}/lib %{jvmjardir})
|
||||
ln -sf $RELATIVE/jsse.jar jsse-%{version}.jar
|
||||
ln -sf $RELATIVE/jce.jar jce-%{version}.jar
|
||||
ln -sf $RELATIVE/rt.jar jndi-%{version}.jar
|
||||
ln -sf $RELATIVE/rt.jar jndi-ldap-%{version}.jar
|
||||
ln -sf $RELATIVE/rt.jar jndi-cos-%{version}.jar
|
||||
ln -sf $RELATIVE/rt.jar jndi-rmi-%{version}.jar
|
||||
ln -sf $RELATIVE/rt.jar jaas-%{version}.jar
|
||||
ln -sf $RELATIVE/rt.jar jdbc-stdext-%{version}.jar
|
||||
ln -sf jdbc-stdext-%{version}.jar jdbc-stdext-3.0.jar
|
||||
ln -sf $RELATIVE/rt.jar sasl-%{version}.jar
|
||||
for jar in *-%{version}.jar
|
||||
do
|
||||
if [ x%{version} != x%{javaver} ]
|
||||
then
|
||||
ln -sf $jar $(echo $jar | sed "s|-%{version}.jar|-%{javaver}.jar|g")
|
||||
fi
|
||||
ln -sf $jar $(echo $jar | sed "s|-%{version}.jar|.jar|g")
|
||||
done
|
||||
popd
|
||||
|
||||
# Install JCE policy symlinks.
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{_jvmprivdir}/%{archname}/jce/vanilla
|
||||
|
||||
# Install versionless symlinks.
|
||||
pushd $RPM_BUILD_ROOT%{_jvmdir}
|
||||
ln -sf %{jredir} %{jrelnk}
|
||||
ln -sf %{sdkdir} %{sdklnk}
|
||||
popd
|
||||
|
||||
pushd $RPM_BUILD_ROOT%{_jvmjardir}
|
||||
ln -sf %{sdkdir} %{jrelnk}
|
||||
ln -sf %{sdkdir} %{sdklnk}
|
||||
popd
|
||||
|
||||
# Remove javaws man page
|
||||
rm -f man/man1/javaws*
|
||||
|
||||
# Install man pages.
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{_mandir}/man1
|
||||
for manpage in man/man1/*
|
||||
do
|
||||
# Convert man pages to UTF8 encoding.
|
||||
iconv -f ISO_8859-1 -t UTF8 $manpage -o $manpage.tmp
|
||||
mv -f $manpage.tmp $manpage
|
||||
install -m 644 -p $manpage $RPM_BUILD_ROOT%{_mandir}/man1/$(basename \
|
||||
$manpage .1)-%{name}.1
|
||||
done
|
||||
|
||||
# Install demos and samples.
|
||||
cp -a demo $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}
|
||||
mkdir -p sample/rmi
|
||||
mv bin/java-rmi.cgi sample/rmi
|
||||
cp -a sample $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}
|
||||
|
||||
popd
|
||||
|
||||
|
||||
# Install nss.cfg
|
||||
install -m 644 %{SOURCE10} $RPM_BUILD_ROOT%{_jvmdir}/%{jredir}/lib/security/
|
||||
|
||||
|
||||
# Install Javadoc documentation.
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}
|
||||
cp -a %{buildoutputdir}/docs $RPM_BUILD_ROOT%{_javadocdir}/%{name}
|
||||
|
||||
# Install icons and menu entries.
|
||||
for s in 16 24 32 48 ; do
|
||||
install -D -p -m 644 \
|
||||
jdk8/jdk/src/solaris/classes/sun/awt/X11/java-icon${s}.png \
|
||||
$RPM_BUILD_ROOT%{_datadir}/icons/hicolor/${s}x${s}/apps/java-%{javaver}.png
|
||||
done
|
||||
|
||||
# Install desktop files.
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{_datadir}/{applications,pixmaps}
|
||||
for e in jconsole policytool ; do
|
||||
desktop-file-install --vendor=%{name} --mode=644 \
|
||||
--dir=$RPM_BUILD_ROOT%{_datadir}/applications $e.desktop
|
||||
done
|
||||
|
||||
# Find JRE directories.
|
||||
find $RPM_BUILD_ROOT%{_jvmdir}/%{jredir} -type d \
|
||||
| grep -v jre/lib/security \
|
||||
| sed 's|'$RPM_BUILD_ROOT'|%dir |' \
|
||||
> %{name}.files
|
||||
# Find JRE files.
|
||||
find $RPM_BUILD_ROOT%{_jvmdir}/%{jredir} -type f -o -type l \
|
||||
| grep -v jre/lib/security \
|
||||
| sed 's|'$RPM_BUILD_ROOT'||' \
|
||||
>> %{name}.files
|
||||
# Find demo directories.
|
||||
find $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}/demo \
|
||||
$RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}/sample -type d \
|
||||
| sed 's|'$RPM_BUILD_ROOT'|%dir |' \
|
||||
> %{name}-demo.files
|
||||
|
||||
# FIXME: remove SONAME entries from demo DSOs. See
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=436497
|
||||
|
||||
# Find non-documentation demo files.
|
||||
find $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}/demo \
|
||||
$RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}/sample \
|
||||
-type f -o -type l | sort \
|
||||
| grep -v README \
|
||||
| sed 's|'$RPM_BUILD_ROOT'||' \
|
||||
>> %{name}-demo.files
|
||||
# Find documentation demo files.
|
||||
find $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}/demo \
|
||||
$RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}/sample \
|
||||
-type f -o -type l | sort \
|
||||
| grep README \
|
||||
| sed 's|'$RPM_BUILD_ROOT'||' \
|
||||
| sed 's|^|%doc |' \
|
||||
>> %{name}-demo.files
|
||||
|
||||
# FIXME: identical binaries are copied, not linked. This needs to be
|
||||
# fixed upstream.
|
||||
%post
|
||||
ext=.gz
|
||||
alternatives \
|
||||
--install %{_bindir}/java java %{jrebindir}/java %{priority} \
|
||||
--slave %{_jvmdir}/jre jre %{_jvmdir}/%{jrelnk} \
|
||||
--slave %{_jvmjardir}/jre jre_exports %{_jvmjardir}/%{jrelnk} \
|
||||
--slave %{_bindir}/keytool keytool %{jrebindir}/keytool \
|
||||
--slave %{_bindir}/orbd orbd %{jrebindir}/orbd \
|
||||
--slave %{_bindir}/pack200 pack200 %{jrebindir}/pack200 \
|
||||
--slave %{_bindir}/rmid rmid %{jrebindir}/rmid \
|
||||
--slave %{_bindir}/rmiregistry rmiregistry %{jrebindir}/rmiregistry \
|
||||
--slave %{_bindir}/servertool servertool %{jrebindir}/servertool \
|
||||
--slave %{_bindir}/tnameserv tnameserv %{jrebindir}/tnameserv \
|
||||
--slave %{_bindir}/unpack200 unpack200 %{jrebindir}/unpack200 \
|
||||
--slave %{_mandir}/man1/java.1$ext java.1$ext \
|
||||
%{_mandir}/man1/java-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/keytool.1$ext keytool.1$ext \
|
||||
%{_mandir}/man1/keytool-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/orbd.1$ext orbd.1$ext \
|
||||
%{_mandir}/man1/orbd-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/pack200.1$ext pack200.1$ext \
|
||||
%{_mandir}/man1/pack200-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/rmid.1$ext rmid.1$ext \
|
||||
%{_mandir}/man1/rmid-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/rmiregistry.1$ext rmiregistry.1$ext \
|
||||
%{_mandir}/man1/rmiregistry-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/servertool.1$ext servertool.1$ext \
|
||||
%{_mandir}/man1/servertool-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/tnameserv.1$ext tnameserv.1$ext \
|
||||
%{_mandir}/man1/tnameserv-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/unpack200.1$ext unpack200.1$ext \
|
||||
%{_mandir}/man1/unpack200-%{name}.1$ext
|
||||
|
||||
alternatives \
|
||||
--install %{_jvmdir}/jre-%{origin} \
|
||||
jre_%{origin} %{_jvmdir}/%{jrelnk} %{priority} \
|
||||
--slave %{_jvmjardir}/jre-%{origin} \
|
||||
jre_%{origin}_exports %{_jvmjardir}/%{jrelnk}
|
||||
|
||||
alternatives \
|
||||
--install %{_jvmdir}/jre-%{javaver} \
|
||||
jre_%{javaver} %{_jvmdir}/%{jrelnk} %{priority} \
|
||||
--slave %{_jvmjardir}/jre-%{javaver} \
|
||||
jre_%{javaver}_exports %{_jvmjardir}/%{jrelnk}
|
||||
|
||||
update-desktop-database %{_datadir}/applications &> /dev/null || :
|
||||
|
||||
touch --no-create %{_datadir}/icons/hicolor
|
||||
if [ -x %{_bindir}/gtk-update-icon-cache ] ; then
|
||||
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
||||
%postun
|
||||
if [ $1 -eq 0 ]
|
||||
then
|
||||
alternatives --remove java %{jrebindir}/java
|
||||
alternatives --remove jre_%{origin} %{_jvmdir}/%{jrelnk}
|
||||
alternatives --remove jre_%{javaver} %{_jvmdir}/%{jrelnk}
|
||||
fi
|
||||
|
||||
update-desktop-database %{_datadir}/applications &> /dev/null || :
|
||||
|
||||
touch --no-create %{_datadir}/icons/hicolor
|
||||
if [ -x %{_bindir}/gtk-update-icon-cache ] ; then
|
||||
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
||||
%post devel
|
||||
ext=.gz
|
||||
alternatives \
|
||||
--install %{_bindir}/javac javac %{sdkbindir}/javac %{priority} \
|
||||
--slave %{_jvmdir}/java java_sdk %{_jvmdir}/%{sdklnk} \
|
||||
--slave %{_jvmjardir}/java java_sdk_exports %{_jvmjardir}/%{sdklnk} \
|
||||
--slave %{_bindir}/appletviewer appletviewer %{sdkbindir}/appletviewer \
|
||||
--slave %{_bindir}/extcheck extcheck %{sdkbindir}/extcheck \
|
||||
--slave %{_bindir}/idlj idlj %{sdkbindir}/idlj \
|
||||
--slave %{_bindir}/jar jar %{sdkbindir}/jar \
|
||||
--slave %{_bindir}/jarsigner jarsigner %{sdkbindir}/jarsigner \
|
||||
--slave %{_bindir}/javadoc javadoc %{sdkbindir}/javadoc \
|
||||
--slave %{_bindir}/javah javah %{sdkbindir}/javah \
|
||||
--slave %{_bindir}/javap javap %{sdkbindir}/javap \
|
||||
--slave %{_bindir}/jcmd jcmd %{sdkbindir}/jcmd \
|
||||
--slave %{_bindir}/jconsole jconsole %{sdkbindir}/jconsole \
|
||||
--slave %{_bindir}/jdb jdb %{sdkbindir}/jdb \
|
||||
--slave %{_bindir}/jhat jhat %{sdkbindir}/jhat \
|
||||
--slave %{_bindir}/jinfo jinfo %{sdkbindir}/jinfo \
|
||||
--slave %{_bindir}/jmap jmap %{sdkbindir}/jmap \
|
||||
--slave %{_bindir}/jps jps %{sdkbindir}/jps \
|
||||
--slave %{_bindir}/jrunscript jrunscript %{sdkbindir}/jrunscript \
|
||||
--slave %{_bindir}/jsadebugd jsadebugd %{sdkbindir}/jsadebugd \
|
||||
--slave %{_bindir}/jstack jstack %{sdkbindir}/jstack \
|
||||
--slave %{_bindir}/jstat jstat %{sdkbindir}/jstat \
|
||||
--slave %{_bindir}/jstatd jstatd %{sdkbindir}/jstatd \
|
||||
--slave %{_bindir}/native2ascii native2ascii %{sdkbindir}/native2ascii \
|
||||
--slave %{_bindir}/policytool policytool %{sdkbindir}/policytool \
|
||||
--slave %{_bindir}/rmic rmic %{sdkbindir}/rmic \
|
||||
--slave %{_bindir}/schemagen schemagen %{sdkbindir}/schemagen \
|
||||
--slave %{_bindir}/serialver serialver %{sdkbindir}/serialver \
|
||||
--slave %{_bindir}/wsgen wsgen %{sdkbindir}/wsgen \
|
||||
--slave %{_bindir}/wsimport wsimport %{sdkbindir}/wsimport \
|
||||
--slave %{_bindir}/xjc xjc %{sdkbindir}/xjc \
|
||||
--slave %{_mandir}/man1/appletviewer.1$ext appletviewer.1$ext \
|
||||
%{_mandir}/man1/appletviewer-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/extcheck.1$ext extcheck.1$ext \
|
||||
%{_mandir}/man1/extcheck-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/idlj.1$ext idlj.1$ext \
|
||||
%{_mandir}/man1/idlj-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jar.1$ext jar.1$ext \
|
||||
%{_mandir}/man1/jar-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jarsigner.1$ext jarsigner.1$ext \
|
||||
%{_mandir}/man1/jarsigner-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/javac.1$ext javac.1$ext \
|
||||
%{_mandir}/man1/javac-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/javadoc.1$ext javadoc.1$ext \
|
||||
%{_mandir}/man1/javadoc-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/javah.1$ext javah.1$ext \
|
||||
%{_mandir}/man1/javah-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/javap.1$ext javap.1$ext \
|
||||
%{_mandir}/man1/javap-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jcmd.1$ext jcmd.1$ext \
|
||||
%{_mandir}/man1/jcmd-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jconsole.1$ext jconsole.1$ext \
|
||||
%{_mandir}/man1/jconsole-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jdb.1$ext jdb.1$ext \
|
||||
%{_mandir}/man1/jdb-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jhat.1$ext jhat.1$ext \
|
||||
%{_mandir}/man1/jhat-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jinfo.1$ext jinfo.1$ext \
|
||||
%{_mandir}/man1/jinfo-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jmap.1$ext jmap.1$ext \
|
||||
%{_mandir}/man1/jmap-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jps.1$ext jps.1$ext \
|
||||
%{_mandir}/man1/jps-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jrunscript.1$ext jrunscript.1$ext \
|
||||
%{_mandir}/man1/jrunscript-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jsadebugd.1$ext jsadebugd.1$ext \
|
||||
%{_mandir}/man1/jsadebugd-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jstack.1$ext jstack.1$ext \
|
||||
%{_mandir}/man1/jstack-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jstat.1$ext jstat.1$ext \
|
||||
%{_mandir}/man1/jstat-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/jstatd.1$ext jstatd.1$ext \
|
||||
%{_mandir}/man1/jstatd-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/native2ascii.1$ext native2ascii.1$ext \
|
||||
%{_mandir}/man1/native2ascii-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/policytool.1$ext policytool.1$ext \
|
||||
%{_mandir}/man1/policytool-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/rmic.1$ext rmic.1$ext \
|
||||
%{_mandir}/man1/rmic-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/schemagen.1$ext schemagen.1$ext \
|
||||
%{_mandir}/man1/schemagen-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/serialver.1$ext serialver.1$ext \
|
||||
%{_mandir}/man1/serialver-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/wsgen.1$ext wsgen.1$ext \
|
||||
%{_mandir}/man1/wsgen-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/wsimport.1$ext wsimport.1$ext \
|
||||
%{_mandir}/man1/wsimport-%{name}.1$ext \
|
||||
--slave %{_mandir}/man1/xjc.1$ext xjc.1$ext \
|
||||
%{_mandir}/man1/xjc-%{name}.1$ext
|
||||
|
||||
alternatives \
|
||||
--install %{_jvmdir}/java-%{origin} \
|
||||
java_sdk_%{origin} %{_jvmdir}/%{sdklnk} %{priority} \
|
||||
--slave %{_jvmjardir}/java-%{origin} \
|
||||
java_sdk_%{origin}_exports %{_jvmjardir}/%{sdklnk}
|
||||
|
||||
alternatives \
|
||||
--install %{_jvmdir}/java-%{javaver} \
|
||||
java_sdk_%{javaver} %{_jvmdir}/%{sdklnk} %{priority} \
|
||||
--slave %{_jvmjardir}/java-%{javaver} \
|
||||
java_sdk_%{javaver}_exports %{_jvmjardir}/%{sdklnk}
|
||||
|
||||
exit 0
|
||||
|
||||
%postun devel
|
||||
if [ $1 -eq 0 ]
|
||||
then
|
||||
alternatives --remove javac %{sdkbindir}/javac
|
||||
alternatives --remove java_sdk_%{origin} %{_jvmdir}/%{sdklnk}
|
||||
alternatives --remove java_sdk_%{javaver} %{_jvmdir}/%{sdklnk}
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
||||
%post javadoc
|
||||
alternatives \
|
||||
--install %{_javadocdir}/java javadocdir %{_javadocdir}/%{name}/api \
|
||||
%{priority}
|
||||
|
||||
exit 0
|
||||
|
||||
%postun javadoc
|
||||
if [ $1 -eq 0 ]
|
||||
then
|
||||
alternatives --remove javadocdir %{_javadocdir}/%{name}/api
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
||||
|
||||
%files -f %{name}.files
|
||||
%defattr(-,root,root,-)
|
||||
%doc %{buildoutputdir}/images/j2sdk-image/jre/ASSEMBLY_EXCEPTION
|
||||
%doc %{buildoutputdir}/images/j2sdk-image/jre/LICENSE
|
||||
%doc %{buildoutputdir}/images/j2sdk-image/jre/THIRD_PARTY_README
|
||||
|
||||
%dir %{_jvmdir}/%{sdkdir}
|
||||
%{_jvmdir}/%{jrelnk}
|
||||
%{_jvmjardir}/%{jrelnk}
|
||||
%{_jvmprivdir}/*
|
||||
%{jvmjardir}
|
||||
%dir %{_jvmdir}/%{jredir}/lib/security
|
||||
%{_jvmdir}/%{jredir}/lib/security/cacerts
|
||||
%config(noreplace) %{_jvmdir}/%{jredir}/lib/security/java.policy
|
||||
%config(noreplace) %{_jvmdir}/%{jredir}/lib/security/java.security
|
||||
%{_datadir}/icons/hicolor/*x*/apps/java-%{javaver}.png
|
||||
%{_mandir}/man1/java-%{name}.1*
|
||||
%{_mandir}/man1/keytool-%{name}.1*
|
||||
%{_mandir}/man1/orbd-%{name}.1*
|
||||
%{_mandir}/man1/pack200-%{name}.1*
|
||||
%{_mandir}/man1/rmid-%{name}.1*
|
||||
%{_mandir}/man1/rmiregistry-%{name}.1*
|
||||
%{_mandir}/man1/servertool-%{name}.1*
|
||||
%{_mandir}/man1/tnameserv-%{name}.1*
|
||||
%{_mandir}/man1/unpack200-%{name}.1*
|
||||
%{_jvmdir}/%{jredir}/lib/security/nss.cfg
|
||||
%{_jvmdir}/%{jredir}/lib/audio/
|
||||
%{_jvmdir}/%{jredir}/lib/security/US_export_policy.jar
|
||||
%{_jvmdir}/%{jredir}/lib/security/local_policy.jar
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root,-)
|
||||
%doc %{buildoutputdir}/images/j2sdk-image/ASSEMBLY_EXCEPTION
|
||||
%doc %{buildoutputdir}/images/j2sdk-image/LICENSE
|
||||
%doc %{buildoutputdir}/images/j2sdk-image/THIRD_PARTY_README
|
||||
%dir %{_jvmdir}/%{sdkdir}/bin
|
||||
%dir %{_jvmdir}/%{sdkdir}/include
|
||||
%dir %{_jvmdir}/%{sdkdir}/lib
|
||||
%ifarch %{jit_arches}
|
||||
%dir %{_jvmdir}/%{sdkdir}/tapset
|
||||
%endif
|
||||
%{_jvmdir}/%{sdkdir}/bin/*
|
||||
%{_jvmdir}/%{sdkdir}/include/*
|
||||
%{_jvmdir}/%{sdkdir}/lib/*
|
||||
%ifarch %{jit_arches}
|
||||
%{_jvmdir}/%{sdkdir}/tapset/*.stp
|
||||
%endif
|
||||
%{_jvmdir}/%{sdklnk}
|
||||
%{_jvmjardir}/%{sdklnk}
|
||||
%{_datadir}/applications/*jconsole.desktop
|
||||
%{_datadir}/applications/*policytool.desktop
|
||||
%{_mandir}/man1/appletviewer-%{name}.1*
|
||||
%{_mandir}/man1/extcheck-%{name}.1*
|
||||
%{_mandir}/man1/idlj-%{name}.1*
|
||||
%{_mandir}/man1/jar-%{name}.1*
|
||||
%{_mandir}/man1/jarsigner-%{name}.1*
|
||||
%{_mandir}/man1/javac-%{name}.1*
|
||||
%{_mandir}/man1/javadoc-%{name}.1*
|
||||
%{_mandir}/man1/javah-%{name}.1*
|
||||
%{_mandir}/man1/javap-%{name}.1*
|
||||
%{_mandir}/man1/jconsole-%{name}.1*
|
||||
%ifarch %{jit_arches} # Only in u4+
|
||||
%{_mandir}/man1/jcmd-%{name}.1*
|
||||
%endif
|
||||
%{_mandir}/man1/jdb-%{name}.1*
|
||||
%{_mandir}/man1/jhat-%{name}.1*
|
||||
%{_mandir}/man1/jinfo-%{name}.1*
|
||||
%{_mandir}/man1/jmap-%{name}.1*
|
||||
%{_mandir}/man1/jps-%{name}.1*
|
||||
%{_mandir}/man1/jrunscript-%{name}.1*
|
||||
%{_mandir}/man1/jsadebugd-%{name}.1*
|
||||
%{_mandir}/man1/jstack-%{name}.1*
|
||||
%{_mandir}/man1/jstat-%{name}.1*
|
||||
%{_mandir}/man1/jstatd-%{name}.1*
|
||||
%{_mandir}/man1/native2ascii-%{name}.1*
|
||||
%{_mandir}/man1/policytool-%{name}.1*
|
||||
%{_mandir}/man1/rmic-%{name}.1*
|
||||
%{_mandir}/man1/schemagen-%{name}.1*
|
||||
%{_mandir}/man1/serialver-%{name}.1*
|
||||
%{_mandir}/man1/wsgen-%{name}.1*
|
||||
%{_mandir}/man1/wsimport-%{name}.1*
|
||||
%{_mandir}/man1/xjc-%{name}.1*
|
||||
%ifarch %{jit_arches}
|
||||
%{tapsetroot}
|
||||
%endif
|
||||
|
||||
%files demo -f %{name}-demo.files
|
||||
%defattr(-,root,root,-)
|
||||
%doc %{buildoutputdir}/images/j2sdk-image/jre/LICENSE
|
||||
|
||||
%files src
|
||||
%defattr(-,root,root,-)
|
||||
%doc README.src
|
||||
%{_jvmdir}/%{sdkdir}/src.zip
|
||||
|
||||
%files javadoc
|
||||
%defattr(-,root,root,-)
|
||||
%doc %{_javadocdir}/%{name}
|
||||
%doc %{buildoutputdir}/images/j2sdk-image/jre/LICENSE
|
||||
|
||||
%changelog
|
||||
* Tue Mar 12 2013 Omair Majid <omajid@redhat.com> 1:1.8.0.0-0.1.b79.f19
|
||||
- Update to jdk8-b79
|
||||
- Initial version for Fedora 19
|
||||
|
||||
* Tue Sep 04 2012 Andrew John Hughes <gnu.andrew@redhat.com> - 1:1.8.0.0-b53.1
|
||||
- Initial build from java-1.7.0-openjdk RPM
|
4
nss.cfg
Normal file
4
nss.cfg
Normal file
@ -0,0 +1,4 @@
|
||||
name = NSS
|
||||
nssLibraryDirectory =
|
||||
nssDbMode = noDb
|
||||
attributes = compatibility
|
127
remove-intree-libraries.sh
Normal file
127
remove-intree-libraries.sh
Normal file
@ -0,0 +1,127 @@
|
||||
#!/bin/sh
|
||||
|
||||
ZIP_SRC=jdk8/jdk/src/share/native/java/util/zip/zlib-*
|
||||
JPEG_SRC=jdk8/jdk/src/share/native/sun/awt/image/jpeg
|
||||
GIF_SRC=jdk8/jdk/src/share/native/sun/awt/giflib
|
||||
PNG_SRC=jdk8/jdk/src/share/native/sun/awt/libpng
|
||||
LCMS_SRC=jdk8/jdk/src/share/native/sun/java2d/cmm/lcms
|
||||
|
||||
echo "Removing built-in libs (they will be linked)"
|
||||
|
||||
echo "Removing zlib"
|
||||
if [ ! -d ${ZIP_SRC} ]; then
|
||||
echo "${ZIP_SRC} does not exist. Refusing to proceed."
|
||||
exit 1
|
||||
fi
|
||||
rm -rvf ${ZIP_SRC}
|
||||
|
||||
echo "Removing libjpeg"
|
||||
if [ ! -f ${JPEG_SRC}/jdhuff.c ]; then # some file that sound definitely exist
|
||||
echo "${JPEG_SRC} does not contain jpeg sources. Refusing to proceed."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
rm -vf ${JPEG_SRC}/jcomapi.c
|
||||
rm -vf ${JPEG_SRC}/jdapimin.c
|
||||
rm -vf ${JPEG_SRC}/jdapistd.c
|
||||
rm -vf ${JPEG_SRC}/jdcoefct.c
|
||||
rm -vf ${JPEG_SRC}/jdcolor.c
|
||||
rm -vf ${JPEG_SRC}/jdct.h
|
||||
rm -vf ${JPEG_SRC}/jddctmgr.c
|
||||
rm -vf ${JPEG_SRC}/jdhuff.c
|
||||
rm -vf ${JPEG_SRC}/jdhuff.h
|
||||
rm -vf ${JPEG_SRC}/jdinput.c
|
||||
rm -vf ${JPEG_SRC}/jdmainct.c
|
||||
rm -vf ${JPEG_SRC}/jdmarker.c
|
||||
rm -vf ${JPEG_SRC}/jdmaster.c
|
||||
rm -vf ${JPEG_SRC}/jdmerge.c
|
||||
rm -vf ${JPEG_SRC}/jdphuff.c
|
||||
rm -vf ${JPEG_SRC}/jdpostct.c
|
||||
rm -vf ${JPEG_SRC}/jdsample.c
|
||||
rm -vf ${JPEG_SRC}/jerror.c
|
||||
rm -vf ${JPEG_SRC}/jerror.h
|
||||
rm -vf ${JPEG_SRC}/jidctflt.c
|
||||
rm -vf ${JPEG_SRC}/jidctfst.c
|
||||
rm -vf ${JPEG_SRC}/jidctint.c
|
||||
rm -vf ${JPEG_SRC}/jidctred.c
|
||||
rm -vf ${JPEG_SRC}/jinclude.h
|
||||
rm -vf ${JPEG_SRC}/jmemmgr.c
|
||||
rm -vf ${JPEG_SRC}/jmemsys.h
|
||||
rm -vf ${JPEG_SRC}/jmemnobs.c
|
||||
rm -vf ${JPEG_SRC}/jmorecfg.h
|
||||
rm -vf ${JPEG_SRC}/jpegint.h
|
||||
rm -vf ${JPEG_SRC}/jpeglib.h
|
||||
rm -vf ${JPEG_SRC}/jquant1.c
|
||||
rm -vf ${JPEG_SRC}/jquant2.c
|
||||
rm -vf ${JPEG_SRC}/jutils.c
|
||||
rm -vf ${JPEG_SRC}/jcapimin.c
|
||||
rm -vf ${JPEG_SRC}/jcapistd.c
|
||||
rm -vf ${JPEG_SRC}/jccoefct.c
|
||||
rm -vf ${JPEG_SRC}/jccolor.c
|
||||
rm -vf ${JPEG_SRC}/jcdctmgr.c
|
||||
rm -vf ${JPEG_SRC}/jchuff.c
|
||||
rm -vf ${JPEG_SRC}/jchuff.h
|
||||
rm -vf ${JPEG_SRC}/jcinit.c
|
||||
rm -vf ${JPEG_SRC}/jconfig.h
|
||||
rm -vf ${JPEG_SRC}/jcmainct.c
|
||||
rm -vf ${JPEG_SRC}/jcmarker.c
|
||||
rm -vf ${JPEG_SRC}/jcmaster.c
|
||||
rm -vf ${JPEG_SRC}/jcparam.c
|
||||
rm -vf ${JPEG_SRC}/jcphuff.c
|
||||
rm -vf ${JPEG_SRC}/jcprepct.c
|
||||
rm -vf ${JPEG_SRC}/jcsample.c
|
||||
rm -vf ${JPEG_SRC}/jctrans.c
|
||||
rm -vf ${JPEG_SRC}/jdtrans.c
|
||||
rm -vf ${JPEG_SRC}/jfdctflt.c
|
||||
rm -vf ${JPEG_SRC}/jfdctfst.c
|
||||
rm -vf ${JPEG_SRC}/jfdctint.c
|
||||
rm -vf ${JPEG_SRC}/jversion.h
|
||||
rm -vf ${JPEG_SRC}/README
|
||||
|
||||
echo "Removing giflib"
|
||||
if [ ! -d ${GIF_SRC} ]; then
|
||||
echo "${GIF_SRC} does not exist. Refusing to proceed."
|
||||
exit 1
|
||||
fi
|
||||
rm -rvf ${GIF_SRC}
|
||||
|
||||
echo "Removing libpng"
|
||||
if [ ! -d ${PNG_SRC} ]; then
|
||||
echo "${PNG_SRC} does not exist. Refusing to proceed."
|
||||
exit 1
|
||||
fi
|
||||
rm -rvf ${PNG_SRC}
|
||||
|
||||
echo "Removing lcms"
|
||||
if [ ! -d ${LCMS_SRC} ]; then
|
||||
echo "${LCMS_SRC} does not exist. Refusing to proceed."
|
||||
exit 1
|
||||
fi
|
||||
rm -vf ${LCMS_SRC}/cmscam02.c
|
||||
rm -vf ${LCMS_SRC}/cmscgats.c
|
||||
rm -vf ${LCMS_SRC}/cmscnvrt.c
|
||||
rm -vf ${LCMS_SRC}/cmserr.c
|
||||
rm -vf ${LCMS_SRC}/cmsgamma.c
|
||||
rm -vf ${LCMS_SRC}/cmsgmt.c
|
||||
rm -vf ${LCMS_SRC}/cmshalf.c
|
||||
rm -vf ${LCMS_SRC}/cmsintrp.c
|
||||
rm -vf ${LCMS_SRC}/cmsio0.c
|
||||
rm -vf ${LCMS_SRC}/cmsio1.c
|
||||
rm -vf ${LCMS_SRC}/cmslut.c
|
||||
rm -vf ${LCMS_SRC}/cmsmd5.c
|
||||
rm -vf ${LCMS_SRC}/cmsmtrx.c
|
||||
rm -vf ${LCMS_SRC}/cmsnamed.c
|
||||
rm -vf ${LCMS_SRC}/cmsopt.c
|
||||
rm -vf ${LCMS_SRC}/cmspack.c
|
||||
rm -vf ${LCMS_SRC}/cmspcs.c
|
||||
rm -vf ${LCMS_SRC}/cmsplugin.c
|
||||
rm -vf ${LCMS_SRC}/cmsps2.c
|
||||
rm -vf ${LCMS_SRC}/cmssamp.c
|
||||
rm -vf ${LCMS_SRC}/cmssm.c
|
||||
rm -vf ${LCMS_SRC}/cmstypes.c
|
||||
rm -vf ${LCMS_SRC}/cmsvirt.c
|
||||
rm -vf ${LCMS_SRC}/cmswtpnt.c
|
||||
rm -vf ${LCMS_SRC}/cmsxform.c
|
||||
rm -vf ${LCMS_SRC}/lcms2.h
|
||||
rm -vf ${LCMS_SRC}/lcms2_internal.h
|
||||
rm -vf ${LCMS_SRC}/lcms2_plugin.h
|
157
rhino.patch
Normal file
157
rhino.patch
Normal file
@ -0,0 +1,157 @@
|
||||
diff --git a/make/com/sun/Makefile b/make/com/sun/Makefile
|
||||
--- jdk8/jdk/make/com/sun/Makefile
|
||||
+++ jdk8/jdk/make/com/sun/Makefile
|
||||
@@ -31,13 +31,6 @@
|
||||
PRODUCT = sun
|
||||
include $(BUILDDIR)/common/Defs.gmk
|
||||
|
||||
-ifndef OPENJDK
|
||||
- ORG_EXISTS := $(call DirExists,$(CLOSED_SRC)/share/classes/sun/org,,)
|
||||
- ifneq ("$(ORG_EXISTS)", "")
|
||||
- SCRIPT_SUBDIR = script
|
||||
- endif
|
||||
-endif
|
||||
-
|
||||
# jarsigner is part of JRE
|
||||
SUBDIRS = java security net/ssl jarsigner
|
||||
|
||||
@@ -45,7 +38,7 @@
|
||||
SUBDIRS_desktop = image
|
||||
SUBDIRS_enterprise = crypto/provider jndi \
|
||||
org rowset net/httpserver
|
||||
-SUBDIRS_misc = $(SCRIPT_SUBDIR) tracing servicetag nio demo
|
||||
+SUBDIRS_misc = script tracing servicetag nio demo
|
||||
|
||||
SUBDIRS_tools = tools
|
||||
|
||||
diff --git a/make/com/sun/script/Makefile b/make/com/sun/script/Makefile
|
||||
--- jdk8/jdk/make/com/sun/script/Makefile
|
||||
+++ jdk8/jdk/make/com/sun/script/Makefile
|
||||
@@ -31,6 +31,8 @@
|
||||
|
||||
AUTO_FILES_JAVA_DIRS = com/sun/script
|
||||
|
||||
+OTHER_JAVACFLAGS = -classpath $(RHINO_JAR)
|
||||
+
|
||||
#
|
||||
# Files that need to be copied
|
||||
#
|
||||
diff --git a/make/common/Release.gmk b/make/common/Release.gmk
|
||||
--- jdk8/jdk/make/common/Release.gmk
|
||||
+++ jdk8/jdk/make/common/Release.gmk
|
||||
@@ -813,6 +813,7 @@
|
||||
$(CP) $(RT_JAR) $(JRE_IMAGE_DIR)/lib/rt.jar
|
||||
$(CP) $(RESOURCES_JAR) $(JRE_IMAGE_DIR)/lib/resources.jar
|
||||
$(CP) $(JSSE_JAR) $(JRE_IMAGE_DIR)/lib/jsse.jar
|
||||
+ $(CP) $(RHINO_JAR) $(JRE_IMAGE_DIR)/lib/rhino.jar
|
||||
ifneq ($(JFR_JAR),)
|
||||
$(CP) $(JFR_JAR) $(JRE_IMAGE_DIR)/lib/jfr.jar
|
||||
endif
|
||||
diff --git a/src/share/classes/com/sun/script/javascript/ExternalScriptable.java b/src/share/classes/com/sun/script/javascript/ExternalScriptable.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/script/javascript/ExternalScriptable.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/script/javascript/ExternalScriptable.java
|
||||
@@ -24,7 +24,7 @@
|
||||
*/
|
||||
|
||||
package com.sun.script.javascript;
|
||||
-import sun.org.mozilla.javascript.internal.*;
|
||||
+import sun.org.mozilla.javascript.*;
|
||||
import javax.script.*;
|
||||
import java.util.*;
|
||||
|
||||
diff --git a/src/share/classes/com/sun/script/javascript/JSAdapter.java b/src/share/classes/com/sun/script/javascript/JSAdapter.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/script/javascript/JSAdapter.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/script/javascript/JSAdapter.java
|
||||
@@ -25,7 +25,7 @@
|
||||
|
||||
package com.sun.script.javascript;
|
||||
|
||||
-import sun.org.mozilla.javascript.internal.*;
|
||||
+import sun.org.mozilla.javascript.*;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
diff --git a/src/share/classes/com/sun/script/javascript/JavaAdapter.java b/src/share/classes/com/sun/script/javascript/JavaAdapter.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/script/javascript/JavaAdapter.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/script/javascript/JavaAdapter.java
|
||||
@@ -26,7 +26,7 @@
|
||||
package com.sun.script.javascript;
|
||||
|
||||
import javax.script.Invocable;
|
||||
-import sun.org.mozilla.javascript.internal.*;
|
||||
+import sun.org.mozilla.javascript.*;
|
||||
|
||||
/**
|
||||
* This class implements Rhino-like JavaAdapter to help implement a Java
|
||||
diff --git a/src/share/classes/com/sun/script/javascript/RhinoClassShutter.java b/src/share/classes/com/sun/script/javascript/RhinoClassShutter.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoClassShutter.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoClassShutter.java
|
||||
@@ -26,7 +26,7 @@
|
||||
package com.sun.script.javascript;
|
||||
|
||||
import java.util.*;
|
||||
-import sun.org.mozilla.javascript.internal.*;
|
||||
+import sun.org.mozilla.javascript.*;
|
||||
|
||||
/**
|
||||
* This class prevents script access to certain sensitive classes.
|
||||
diff --git a/src/share/classes/com/sun/script/javascript/RhinoCompiledScript.java b/src/share/classes/com/sun/script/javascript/RhinoCompiledScript.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoCompiledScript.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoCompiledScript.java
|
||||
@@ -25,7 +25,7 @@
|
||||
|
||||
package com.sun.script.javascript;
|
||||
import javax.script.*;
|
||||
-import sun.org.mozilla.javascript.internal.*;
|
||||
+import sun.org.mozilla.javascript.*;
|
||||
|
||||
/**
|
||||
* Represents compiled JavaScript code.
|
||||
diff --git a/src/share/classes/com/sun/script/javascript/RhinoScriptEngine.java b/src/share/classes/com/sun/script/javascript/RhinoScriptEngine.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoScriptEngine.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoScriptEngine.java
|
||||
@@ -26,7 +26,7 @@
|
||||
package com.sun.script.javascript;
|
||||
import com.sun.script.util.*;
|
||||
import javax.script.*;
|
||||
-import sun.org.mozilla.javascript.internal.*;
|
||||
+import sun.org.mozilla.javascript.*;
|
||||
import java.lang.reflect.Method;
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
diff --git a/src/share/classes/com/sun/script/javascript/RhinoScriptEngineFactory.java b/src/share/classes/com/sun/script/javascript/RhinoScriptEngineFactory.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoScriptEngineFactory.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoScriptEngineFactory.java
|
||||
@@ -26,7 +26,7 @@
|
||||
package com.sun.script.javascript;
|
||||
import javax.script.*;
|
||||
import java.util.*;
|
||||
-import sun.org.mozilla.javascript.internal.*;
|
||||
+import sun.org.mozilla.javascript.*;
|
||||
import com.sun.script.util.*;
|
||||
|
||||
/**
|
||||
diff --git a/src/share/classes/com/sun/script/javascript/RhinoTopLevel.java b/src/share/classes/com/sun/script/javascript/RhinoTopLevel.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoTopLevel.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoTopLevel.java
|
||||
@@ -25,7 +25,7 @@
|
||||
|
||||
package com.sun.script.javascript;
|
||||
|
||||
-import sun.org.mozilla.javascript.internal.*;
|
||||
+import sun.org.mozilla.javascript.*;
|
||||
import javax.script.*;
|
||||
|
||||
/**
|
||||
diff --git a/src/share/classes/com/sun/script/javascript/RhinoWrapFactory.java b/src/share/classes/com/sun/script/javascript/RhinoWrapFactory.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoWrapFactory.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/script/javascript/RhinoWrapFactory.java
|
||||
@@ -27,7 +27,7 @@
|
||||
|
||||
import java.lang.reflect.*;
|
||||
import static sun.security.util.SecurityConstants.*;
|
||||
-import sun.org.mozilla.javascript.internal.*;
|
||||
+import sun.org.mozilla.javascript.*;
|
||||
|
||||
/**
|
||||
* This wrap factory is used for security reasons. JSR 223 script
|
4
sources
4
sources
@ -0,0 +1,4 @@
|
||||
53f5d8cfe1c1aa478cb0fb64ba149967 class-rewriter.tar.gz
|
||||
e1d19c1a7e103b9b3c35a94628ded3b5 desktop-files.tar.gz
|
||||
71577c85c00f488465e0732cdfee73a7 jdk8-b79.tar.gz
|
||||
94ca5a45c3cb3b85c4577d0891166007 systemtap-tapset.tar.gz
|
104
system-giflib.patch
Normal file
104
system-giflib.patch
Normal file
@ -0,0 +1,104 @@
|
||||
diff --git a/common/autoconf/libraries.m4 b/common/autoconf/libraries.m4
|
||||
--- jdk8/common/autoconf/libraries.m4
|
||||
+++ jdk8/common/autoconf/libraries.m4
|
||||
@@ -499,11 +499,40 @@
|
||||
# Check for the gif library
|
||||
#
|
||||
|
||||
-USE_EXTERNAL_LIBJPEG=true
|
||||
-AC_CHECK_LIB(gif, main, [],
|
||||
- [ USE_EXTERNAL_LIBGIF=false
|
||||
- AC_MSG_NOTICE([Will use gif decoder bundled with the OpenJDK source])
|
||||
- ])
|
||||
+AC_ARG_WITH(giflib, [AS_HELP_STRING([--with-giflib],
|
||||
+ [use giflib from build system or OpenJDK source (system, bundled) @<:@bundled@:>@])])
|
||||
+
|
||||
+AC_CHECK_LIB(gif, DGifGetCode,
|
||||
+ [ GIFLIB_FOUND=yes ],
|
||||
+ [ GIFLIB_FOUND=no ])
|
||||
+
|
||||
+AC_MSG_CHECKING([for which giflib to use])
|
||||
+
|
||||
+# default is bundled
|
||||
+DEFAULT_GIFLIB=bundled
|
||||
+
|
||||
+#
|
||||
+# if user didn't specify, use DEFAULT_GIFLIB
|
||||
+#
|
||||
+if test "x${with_giflib}" = "x"; then
|
||||
+ with_giflib=${DEFAULT_GIFLIB}
|
||||
+fi
|
||||
+
|
||||
+
|
||||
+if test "x${with_giflib}" = "xbundled"; then
|
||||
+ USE_EXTERNAL_LIBGIF=false
|
||||
+ AC_MSG_RESULT([bundled])
|
||||
+elif test "x${with_giflib}" = "xsystem"; then
|
||||
+ if test "x${GIFLIB_FOUND}" = "xyes"; then
|
||||
+ USE_EXTERNAL_LIBGIF=true
|
||||
+ AC_MSG_RESULT([system])
|
||||
+ else
|
||||
+ AC_MSG_RESULT([system not found])
|
||||
+ AC_MSG_ERROR([--with-giflib=system specified, but no giflib found!])
|
||||
+ fi
|
||||
+else
|
||||
+ AC_MSG_ERROR([Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'])
|
||||
+fi
|
||||
AC_SUBST(USE_EXTERNAL_LIBGIF)
|
||||
|
||||
###############################################################################
|
||||
diff --git a/makefiles/CompileNativeLibraries.gmk b/makefiles/CompileNativeLibraries.gmk
|
||||
--- jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
+++ jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
@@ -2385,18 +2385,23 @@
|
||||
|
||||
ifndef BUILD_HEADLESS_ONLY
|
||||
LIBSPLASHSCREEN_DIRS:=\
|
||||
- $(JDK_TOPDIR)/src/share/native/sun/awt/giflib \
|
||||
$(JDK_TOPDIR)/src/share/native/sun/awt/image/jpeg \
|
||||
$(JDK_TOPDIR)/src/share/native/sun/awt/libpng \
|
||||
$(JDK_TOPDIR)/src/share/native/sun/awt/splashscreen
|
||||
|
||||
+ifeq ($(USE_EXTERNAL_LIBGIF),true)
|
||||
+ LIBGIF := -lgif
|
||||
+else
|
||||
+ LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/share/native/sun/awt/giflib
|
||||
+ LIBGIF_CFLAGS := -I$(JDK_TOPDIR)/src/share/native/sun/awt/giflib
|
||||
+endif
|
||||
+
|
||||
ifneq ($(OPENJDK_TARGET_OS), macosx)
|
||||
LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt/splashscreen
|
||||
else
|
||||
LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/macosx/native/sun/awt/splashscreen
|
||||
endif
|
||||
|
||||
-
|
||||
LIBSPLASHSCREEN_CFLAGS:=-DSPLASHSCREEN -DPNG_NO_MMX_CODE \
|
||||
$(foreach dir,$(LIBSPLASHSCREEN_DIRS),-I$(dir))
|
||||
|
||||
@@ -2448,11 +2453,11 @@
|
||||
EXCLUDE_FILES:=imageioJPEG.c jpegdecoder.c pngtest.c,\
|
||||
LANG:=C,\
|
||||
OPTIMIZATION:=LOW, \
|
||||
- CFLAGS:=$(LIBSPLASHSCREEN_CFLAGS) $(CFLAGS_JDKLIB),\
|
||||
+ CFLAGS:=$(LIBSPLASHSCREEN_CFLAGS) $(CFLAGS_JDKLIB) -I$(LIBGIF_CFLAGS),\
|
||||
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsplashscreen/mapfile-vers, \
|
||||
LDFLAGS:=$(LDFLAGS_JDKLIB) \
|
||||
$(call SET_SHARED_LIBRARY_ORIGIN),\
|
||||
- LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ),\
|
||||
+ LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ) $(LIBGIF),\
|
||||
LDFLAGS_SUFFIX_solaris:=-lc,\
|
||||
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
|
||||
RC_FLAGS:=$(RC_FLAGS)\
|
||||
diff --git a/src/share/native/sun/awt/splashscreen/splashscreen_gif.c b/src/share/native/sun/awt/splashscreen/splashscreen_gif.c
|
||||
--- jdk8/jdk/src/share/native/sun/awt/splashscreen/splashscreen_gif.c
|
||||
+++ jdk8/jdk/src/share/native/sun/awt/splashscreen/splashscreen_gif.c
|
||||
@@ -26,7 +26,7 @@
|
||||
#include "splashscreen_impl.h"
|
||||
#include "splashscreen_gfx.h"
|
||||
|
||||
-#include "../giflib/gif_lib.h"
|
||||
+#include "gif_lib.h"
|
||||
|
||||
#define GIF_TRANSPARENT 0x01
|
||||
#define GIF_USER_INPUT 0x02
|
101
system-lcms.patch
Normal file
101
system-lcms.patch
Normal file
@ -0,0 +1,101 @@
|
||||
diff --git a/common/autoconf/libraries.m4 b/common/autoconf/libraries.m4
|
||||
--- jdk8/common/autoconf/libraries.m4
|
||||
+++ jdk8/common/autoconf/libraries.m4
|
||||
@@ -607,6 +607,46 @@
|
||||
|
||||
###############################################################################
|
||||
#
|
||||
+# Check for the lcms2 library
|
||||
+#
|
||||
+
|
||||
+AC_ARG_WITH(lcms, [AS_HELP_STRING([--with-lcms],
|
||||
+ [use lcms2 from build system or OpenJDK source (system, bundled) @<:@bundled@:>@])])
|
||||
+
|
||||
+AC_CHECK_LIB(lcms2, cmsOpenProfileFromFile,
|
||||
+ [ LCMS_FOUND=yes ],
|
||||
+ [ LCMS_FOUND=no ])
|
||||
+
|
||||
+AC_MSG_CHECKING([for which lcms to use])
|
||||
+
|
||||
+DEFAULT_LCMS=bundled
|
||||
+
|
||||
+#
|
||||
+# If user didn't specify, use DEFAULT_LCMS
|
||||
+#
|
||||
+if test "x${with_lcms}" = "x"; then
|
||||
+ with_lcms=${DEFAULT_LCMS}
|
||||
+fi
|
||||
+
|
||||
+if test "x${with_lcms}" = "xbundled"; then
|
||||
+ USE_EXTERNAL_LCMS=false
|
||||
+ AC_MSG_RESULT([bundled])
|
||||
+elif test "x${with_lcms}" = "xsystem"; then
|
||||
+ if test "x${LCMS_FOUND}" = "xyes"; then
|
||||
+ USE_EXTERNAL_LCMS=true
|
||||
+ AC_MSG_RESULT([system])
|
||||
+ else
|
||||
+ AC_MSG_RESULT([system not found])
|
||||
+ AC_MSG_ERROR([--with-lcms=system specified, but no lcms found!])
|
||||
+ fi
|
||||
+else
|
||||
+ AC_MSG_ERROR([Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'])
|
||||
+fi
|
||||
+
|
||||
+AC_SUBST(USE_EXTERNAL_LCMS)
|
||||
+
|
||||
+###############################################################################
|
||||
+#
|
||||
# Check for the zlib library
|
||||
#
|
||||
|
||||
diff --git a/makefiles/CompileNativeLibraries.gmk b/makefiles/CompileNativeLibraries.gmk
|
||||
--- jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
+++ jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
@@ -1213,8 +1213,8 @@
|
||||
|
||||
ifdef OPENJDK
|
||||
# TODO: Update awt lib path when awt is converted
|
||||
- $(eval $(call SetupNativeCompilation,BUILD_LIBLCMS,\
|
||||
- LIBRARY:=lcms,\
|
||||
+ $(eval $(call SetupNativeCompilation,BUILD_LIBJAVALCMS,\
|
||||
+ LIBRARY:=javalcms,\
|
||||
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
|
||||
SRC:=$(JDK_TOPDIR)/src/share/native/sun/java2d/cmm/lcms,\
|
||||
LANG:=C,\
|
||||
@@ -1232,18 +1232,18 @@
|
||||
LDFLAGS_windows:=$(WIN_AWT_LIB) $(WIN_JAVA_LIB),\
|
||||
LDFLAGS_SUFFIX_solaris:=-lawt -ljava -ljvm -lc,\
|
||||
LDFLAGS_SUFFIX_macosx:=$(LIBM) -lawt -ljava -ljvm,\
|
||||
- LDFLAGS_SUFFIX_linux:=-lm -lawt -ljava -ljvm,\
|
||||
+ LDFLAGS_SUFFIX_linux:=-lm -lawt -ljava -ljvm -llcms2,\
|
||||
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
|
||||
RC_FLAGS:=$(RC_FLAGS)\
|
||||
- -D "JDK_FNAME=lcms.dll" \
|
||||
- -D "JDK_INTERNAL_NAME=lcms" \
|
||||
+ -D "JDK_FNAME=javalcms.dll" \
|
||||
+ -D "JDK_INTERNAL_NAME=javalcms" \
|
||||
-D "JDK_FTYPE=0x2L",\
|
||||
OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/liblcms,\
|
||||
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
|
||||
|
||||
- BUILD_LIBRARIES += $(BUILD_LIBLCMS)
|
||||
-
|
||||
- $(BUILD_LIBLCMS) : $(BUILD_LIBAWT)
|
||||
+ BUILD_LIBRARIES += $(BUILD_LIBJAVALCMS)
|
||||
+
|
||||
+ $(BUILD_LIBJAVALCMS) : $(BUILD_LIBAWT)
|
||||
endif
|
||||
|
||||
##########################################################################################
|
||||
diff --git a/src/share/classes/sun/java2d/cmm/lcms/LCMS.java b/src/share/classes/sun/java2d/cmm/lcms/LCMS.java
|
||||
--- jdk8/jdk/src/share/classes/sun/java2d/cmm/lcms/LCMS.java
|
||||
+++ jdk8/jdk/src/share/classes/sun/java2d/cmm/lcms/LCMS.java
|
||||
@@ -95,7 +95,7 @@
|
||||
* disposer frameworks
|
||||
*/
|
||||
System.loadLibrary("awt");
|
||||
- System.loadLibrary("lcms");
|
||||
+ System.loadLibrary("javalcms");
|
||||
return null;
|
||||
}
|
||||
}
|
207
system-libjpeg.patch
Normal file
207
system-libjpeg.patch
Normal file
@ -0,0 +1,207 @@
|
||||
diff --git a/common/autoconf/libraries.m4 b/common/autoconf/libraries.m4
|
||||
--- jdk8/common/autoconf/libraries.m4
|
||||
+++ jdk8/common/autoconf/libraries.m4
|
||||
@@ -487,11 +487,40 @@
|
||||
# Check for the jpeg library
|
||||
#
|
||||
|
||||
-USE_EXTERNAL_LIBJPEG=true
|
||||
-AC_CHECK_LIB(jpeg, main, [],
|
||||
- [ USE_EXTERNAL_LIBJPEG=false
|
||||
- AC_MSG_NOTICE([Will use jpeg decoder bundled with the OpenJDK source])
|
||||
- ])
|
||||
+AC_ARG_WITH(libjpeg, [AS_HELP_STRING([--with-libjpeg],
|
||||
+ [use libjpeg from build system or OpenJDK sources (system, bundled) @<:@bundled@:>@])])
|
||||
+
|
||||
+AC_CHECK_LIB(jpeg, jpeg_destroy_compress,
|
||||
+ [ LIBJPEG_FOUND=yes ],
|
||||
+ [ LIBJPEG_FOUND=no ])
|
||||
+
|
||||
+AC_MSG_CHECKING([for which libjpeg to use])
|
||||
+
|
||||
+# default is bundled
|
||||
+DEFAULT_LIBJPEG=bundled
|
||||
+
|
||||
+#
|
||||
+# if user didn't specify, use DEFAULT_LIBJPEG
|
||||
+#
|
||||
+if test "x${with_libjpeg}" = "x"; then
|
||||
+ with_libjpeg=${DEFAULT_LIBJPEG}
|
||||
+fi
|
||||
+
|
||||
+if test "x${with_libjpeg}" = "xbundled"; then
|
||||
+ USE_EXTERNAL_LIBJPEG=false
|
||||
+ AC_MSG_RESULT([bundled])
|
||||
+elif test "x${with_libjpeg}" = "xsystem"; then
|
||||
+ if test "x${LIBJPEG_FOUND}" = "xyes"; then
|
||||
+ USE_EXTERNAL_LIBJPEG=true
|
||||
+ AC_MSG_RESULT([system])
|
||||
+ else
|
||||
+ AC_MSG_RESULT([system not found])
|
||||
+ AC_MSG_ERROR([--with-libjpeg=system specified, but no libjpeg found])
|
||||
+ fi
|
||||
+else
|
||||
+ AC_MSG_ERROR([Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'])
|
||||
+fi
|
||||
+
|
||||
AC_SUBST(USE_EXTERNAL_LIBJPEG)
|
||||
|
||||
###############################################################################
|
||||
diff --git a/makefiles/CompileNativeLibraries.gmk b/makefiles/CompileNativeLibraries.gmk
|
||||
--- jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
+++ jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
@@ -1249,17 +1249,17 @@
|
||||
##########################################################################################
|
||||
|
||||
ifdef OPENJDK
|
||||
- BUILD_LIBJPEG_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjpeg/mapfile-vers
|
||||
+ BUILD_LIBJAVAJPEG_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjpeg/mapfile-vers
|
||||
else
|
||||
- BUILD_LIBJPEG_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjpeg/mapfile-vers-closed
|
||||
- BUILD_LIBJPEG_CLOSED_SRC:=$(JDK_TOPDIR)/src/closed/share/native/sun/awt/image/jpeg
|
||||
- BUILD_LIBJPEG_CLOSED_INCLUDES:=-I$(BUILD_LIBJPEG_CLOSED_SRC)
|
||||
+ BUILD_LIBJAVAJPEG_MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libjpeg/mapfile-vers-closed
|
||||
+ BUILD_LIBJAVAJPEG_CLOSED_SRC:=$(JDK_TOPDIR)/src/closed/share/native/sun/awt/image/jpeg
|
||||
+ BUILD_LIBJAVAJPEG_CLOSED_INCLUDES:=-I$(BUILD_LIBJAVAJPEG_CLOSED_SRC)
|
||||
endif
|
||||
|
||||
-BUILD_LIBJPEG_REORDER:=
|
||||
+BUILD_LIBJAVAJPEG_REORDER:=
|
||||
ifeq ($(OPENJDK_TARGET_OS), solaris)
|
||||
ifneq ($(OPENJDK_TARGET_CPU), x86_64)
|
||||
- BUILD_LIBJPEG_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libjpeg/reorder-$(OPENJDK_TARGET_CPU)
|
||||
+ BUILD_LIBJAVAJPEG_REORDER:=$(JDK_TOPDIR)/makefiles/mapfiles/libjpeg/reorder-$(OPENJDK_TARGET_CPU)
|
||||
endif
|
||||
endif
|
||||
|
||||
@@ -1274,37 +1274,37 @@
|
||||
# $(shell $(EXPR) $(CC_MAJORVER) \> 4 \| \
|
||||
# \( $(CC_MAJORVER) = 4 \& $(CC_MINORVER) \>= 3 \) )
|
||||
# ifeq ($(CC_43_OR_NEWER),1)
|
||||
-# BUILD_LIBJPEG_CFLAGS_linux += -Wno-clobbered
|
||||
+# BUILD_LIBJAVAJPEG_CFLAGS_linux += -Wno-clobbered
|
||||
# endif
|
||||
#endif
|
||||
|
||||
-$(eval $(call SetupNativeCompilation,BUILD_LIBJPEG,\
|
||||
- LIBRARY:=jpeg, \
|
||||
+$(eval $(call SetupNativeCompilation,BUILD_LIBJAVAJPEG,\
|
||||
+ LIBRARY:=javajpeg, \
|
||||
OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
|
||||
- SRC:=$(BUILD_LIBJPEG_CLOSED_SRC) \
|
||||
+ SRC:=$(BUILD_LIBJAVAJPEG_CLOSED_SRC) \
|
||||
$(JDK_TOPDIR)/src/share/native/sun/awt/image/jpeg,\
|
||||
LANG:=C,\
|
||||
OPTIMIZATION:=HIGHEST, \
|
||||
CFLAGS:=$(CFLAGS_JDKLIB) \
|
||||
- $(BUILD_LIBJPEG_CLOSED_INCLUDES) \
|
||||
+ $(BUILD_LIBJAVAJPEG_CLOSED_INCLUDES) \
|
||||
-I$(JDK_TOPDIR)/src/share/native/sun/awt/image/jpeg,\
|
||||
- MAPFILE:=$(BUILD_LIBJPEG_MAPFILE), \
|
||||
- LDFLAGS:=$(LDFLAGS_JDKLIB) \
|
||||
+ MAPFILE:=$(BUILD_LIBJAVAJPEG_MAPFILE), \
|
||||
+ LDFLAGS:=$(LDFLAGS_JDKLIB) -ljpeg \
|
||||
$(call SET_SHARED_LIBRARY_ORIGIN),\
|
||||
LDFLAGS_windows:=$(WIN_JAVA_LIB) jvm.lib,\
|
||||
LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\
|
||||
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
|
||||
RC_FLAGS:=$(RC_FLAGS)\
|
||||
- -D "JDK_FNAME=jpeg.dll" \
|
||||
- -D "JDK_INTERNAL_NAME=jpeg" \
|
||||
+ -D "JDK_FNAME=javajpeg.dll" \
|
||||
+ -D "JDK_INTERNAL_NAME=javajpeg" \
|
||||
-D "JDK_FTYPE=0x2L",\
|
||||
- REORDER:=$(BUILD_LIBJPEG_REORDER),\
|
||||
- OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjpeg,\
|
||||
+ REORDER:=$(BUILD_LIBJAVAJPEG_REORDER),\
|
||||
+ OBJECT_DIR:=$(JDK_OUTPUTDIR)/objs/libjavajpeg,\
|
||||
DEBUG_SYMBOLS:=$(WINDOWS_ONLY)))
|
||||
|
||||
-$(BUILD_LIBJPEG) : $(BUILD_LIBJAVA)
|
||||
-
|
||||
-BUILD_LIBRARIES += $(BUILD_LIBJPEG)
|
||||
+$(BUILD_LIBJAVAJPEG) : $(BUILD_LIBJAVA)
|
||||
+
|
||||
+BUILD_LIBRARIES += $(BUILD_LIBJAVAJPEG)
|
||||
|
||||
##########################################################################################
|
||||
|
||||
@@ -2441,7 +2441,7 @@
|
||||
-F/System/Library/Frameworks/JavaVM.framework/Frameworks \
|
||||
-framework JavaNativeFoundation
|
||||
else ifneq ($(OPENJDK_TARGET_OS), windows)
|
||||
- LIBSPLASHSCREEN_LDFLAGS_SUFFIX += -L$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR) -lX11 -lXext $(LIBM) -lpthread
|
||||
+ LIBSPLASHSCREEN_LDFLAGS_SUFFIX += -L$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR) -lX11 -lXext $(LIBM) -lpthread -ljpeg
|
||||
else # OPENJDK_TARGET_OS
|
||||
LIBSPLASHSCREEN_LDFLAGS_SUFFIX += kernel32.lib user32.lib gdi32.lib delayimp.lib -DELAYLOAD:user32.dll
|
||||
endif # OPENJDK_TARGET_OS
|
||||
@@ -2457,7 +2457,7 @@
|
||||
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsplashscreen/mapfile-vers, \
|
||||
LDFLAGS:=$(LDFLAGS_JDKLIB) \
|
||||
$(call SET_SHARED_LIBRARY_ORIGIN),\
|
||||
- LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ) $(LIBGIF),\
|
||||
+ LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ) $(LIBGIF) -ljpeg,\
|
||||
LDFLAGS_SUFFIX_solaris:=-lc,\
|
||||
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
|
||||
RC_FLAGS:=$(RC_FLAGS)\
|
||||
diff --git a/src/share/classes/com/sun/imageio/plugins/jpeg/JPEGImageReader.java b/src/share/classes/com/sun/imageio/plugins/jpeg/JPEGImageReader.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/imageio/plugins/jpeg/JPEGImageReader.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/imageio/plugins/jpeg/JPEGImageReader.java
|
||||
@@ -89,7 +89,7 @@
|
||||
java.security.AccessController.doPrivileged(
|
||||
new java.security.PrivilegedAction<Void>() {
|
||||
public Void run() {
|
||||
- System.loadLibrary("jpeg");
|
||||
+ System.loadLibrary("javajpeg");
|
||||
return null;
|
||||
}
|
||||
});
|
||||
diff --git a/src/share/classes/com/sun/imageio/plugins/jpeg/JPEGImageWriter.java b/src/share/classes/com/sun/imageio/plugins/jpeg/JPEGImageWriter.java
|
||||
--- jdk8/jdk/src/share/classes/com/sun/imageio/plugins/jpeg/JPEGImageWriter.java
|
||||
+++ jdk8/jdk/src/share/classes/com/sun/imageio/plugins/jpeg/JPEGImageWriter.java
|
||||
@@ -179,7 +179,7 @@
|
||||
java.security.AccessController.doPrivileged(
|
||||
new java.security.PrivilegedAction<Void>() {
|
||||
public Void run() {
|
||||
- System.loadLibrary("jpeg");
|
||||
+ System.loadLibrary("javajpeg");
|
||||
return null;
|
||||
}
|
||||
});
|
||||
diff --git a/src/share/classes/sun/awt/image/JPEGImageDecoder.java b/src/share/classes/sun/awt/image/JPEGImageDecoder.java
|
||||
--- jdk8/jdk/src/share/classes/sun/awt/image/JPEGImageDecoder.java
|
||||
+++ jdk8/jdk/src/share/classes/sun/awt/image/JPEGImageDecoder.java
|
||||
@@ -56,7 +56,7 @@
|
||||
java.security.AccessController.doPrivileged(
|
||||
new java.security.PrivilegedAction<Void>() {
|
||||
public Void run() {
|
||||
- System.loadLibrary("jpeg");
|
||||
+ System.loadLibrary("javajpeg");
|
||||
return null;
|
||||
}
|
||||
});
|
||||
diff --git a/src/share/native/sun/awt/splashscreen/splashscreen_jpeg.c b/src/share/native/sun/awt/splashscreen/splashscreen_jpeg.c
|
||||
--- jdk8/jdk/src/share/native/sun/awt/splashscreen/splashscreen_jpeg.c
|
||||
+++ jdk8/jdk/src/share/native/sun/awt/splashscreen/splashscreen_jpeg.c
|
||||
@@ -25,7 +25,6 @@
|
||||
|
||||
#include "splashscreen_impl.h"
|
||||
|
||||
-#include "jinclude.h"
|
||||
#include "jpeglib.h"
|
||||
#include "jerror.h"
|
||||
|
||||
@@ -107,11 +106,11 @@
|
||||
if (cinfo->src == NULL) { /* first time for this JPEG object? */
|
||||
cinfo->src = (struct jpeg_source_mgr *)
|
||||
(*cinfo->mem->alloc_small) ((j_common_ptr) cinfo,
|
||||
- JPOOL_PERMANENT, SIZEOF(stream_source_mgr));
|
||||
+ JPOOL_PERMANENT, sizeof(stream_source_mgr));
|
||||
src = (stream_src_ptr) cinfo->src;
|
||||
src->buffer = (JOCTET *)
|
||||
(*cinfo->mem->alloc_small) ((j_common_ptr) cinfo,
|
||||
- JPOOL_PERMANENT, INPUT_BUF_SIZE * SIZEOF(JOCTET));
|
||||
+ JPOOL_PERMANENT, INPUT_BUF_SIZE * sizeof(JOCTET));
|
||||
}
|
||||
|
||||
src = (stream_src_ptr) cinfo->src;
|
83
system-libpng.patch
Normal file
83
system-libpng.patch
Normal file
@ -0,0 +1,83 @@
|
||||
diff --git a/common/autoconf/libraries.m4 b/common/autoconf/libraries.m4
|
||||
--- jdk8/common/autoconf/libraries.m4
|
||||
+++ jdk8/common/autoconf/libraries.m4
|
||||
@@ -566,6 +566,47 @@
|
||||
|
||||
###############################################################################
|
||||
#
|
||||
+# Check for the png library
|
||||
+#
|
||||
+
|
||||
+AC_ARG_WITH(libpng, [AS_HELP_STRING([--with-libpng],
|
||||
+ [use libpng from build system or OpenJDK source (system, bundled) @<:@bundled@:>@])])
|
||||
+
|
||||
+AC_CHECK_LIB(png, png_sig_cmp,
|
||||
+ [ LIBPNG_FOUND=yes ],
|
||||
+ [ LIBPNG_FOUND=no ])
|
||||
+
|
||||
+AC_MSG_CHECKING([for which libpng to use])
|
||||
+
|
||||
+# default is bundled
|
||||
+DEFAULT_LIBPNG=bundled
|
||||
+
|
||||
+#
|
||||
+# if user didn't specify, use DEFAULT_LIBPNG
|
||||
+#
|
||||
+if test "x${with_libpng}" = "x"; then
|
||||
+ with_libpng=${DEFAULT_libpng}
|
||||
+fi
|
||||
+
|
||||
+
|
||||
+if test "x${with_libpng}" = "xbundled"; then
|
||||
+ USE_EXTERNAL_LIBPNG=false
|
||||
+ AC_MSG_RESULT([bundled])
|
||||
+elif test "x${with_libpng}" = "xsystem"; then
|
||||
+ if test "x${LIBPNG_FOUND}" = "xyes"; then
|
||||
+ USE_EXTERNAL_LIBPNG=true
|
||||
+ AC_MSG_RESULT([system])
|
||||
+ else
|
||||
+ AC_MSG_RESULT([system not found])
|
||||
+ AC_MSG_ERROR([--with-libpng=system specified, but no libpng found!])
|
||||
+ fi
|
||||
+else
|
||||
+ AC_MSG_ERROR([Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'])
|
||||
+fi
|
||||
+AC_SUBST(USE_EXTERNAL_LIBPNG)
|
||||
+
|
||||
+###############################################################################
|
||||
+#
|
||||
# Check for the zlib library
|
||||
#
|
||||
|
||||
diff --git a/makefiles/CompileNativeLibraries.gmk b/makefiles/CompileNativeLibraries.gmk
|
||||
--- jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
+++ jdk8/jdk/makefiles/CompileNativeLibraries.gmk
|
||||
@@ -2386,7 +2386,6 @@
|
||||
ifndef BUILD_HEADLESS_ONLY
|
||||
LIBSPLASHSCREEN_DIRS:=\
|
||||
$(JDK_TOPDIR)/src/share/native/sun/awt/image/jpeg \
|
||||
- $(JDK_TOPDIR)/src/share/native/sun/awt/libpng \
|
||||
$(JDK_TOPDIR)/src/share/native/sun/awt/splashscreen
|
||||
|
||||
ifeq ($(USE_EXTERNAL_LIBGIF),true)
|
||||
@@ -2457,7 +2456,7 @@
|
||||
MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsplashscreen/mapfile-vers, \
|
||||
LDFLAGS:=$(LDFLAGS_JDKLIB) \
|
||||
$(call SET_SHARED_LIBRARY_ORIGIN),\
|
||||
- LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ) $(LIBGIF) -ljpeg,\
|
||||
+ LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ) $(LIBGIF) -ljpeg -lpng,\
|
||||
LDFLAGS_SUFFIX_solaris:=-lc,\
|
||||
VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
|
||||
RC_FLAGS:=$(RC_FLAGS)\
|
||||
diff --git a/src/share/native/sun/awt/splashscreen/splashscreen_png.c b/src/share/native/sun/awt/splashscreen/splashscreen_png.c
|
||||
--- jdk8/jdk/src/share/native/sun/awt/splashscreen/splashscreen_png.c
|
||||
+++ jdk8/jdk/src/share/native/sun/awt/splashscreen/splashscreen_png.c
|
||||
@@ -25,7 +25,7 @@
|
||||
|
||||
#include "splashscreen_impl.h"
|
||||
|
||||
-#include "../libpng/png.h"
|
||||
+#include <png.h>
|
||||
|
||||
#include <setjmp.h>
|
||||
|
Loading…
Reference in New Issue
Block a user