aboutsummaryrefslogtreecommitdiff
path: root/java
diff options
context:
space:
mode:
authorJung-uk Kim <jkim@FreeBSD.org>2014-05-15 23:53:56 +0000
committerJung-uk Kim <jkim@FreeBSD.org>2014-05-15 23:53:56 +0000
commit86dcea5c7a52542294c97de392803937ec111cc4 (patch)
tree09fee9460bece1c50eafaa981e3da6030f7d4695 /java
parent821f22db1dcb6443dd4de9a73f0d8b3266928127 (diff)
downloadports-86dcea5c7a52542294c97de392803937ec111cc4.tar.gz
ports-86dcea5c7a52542294c97de392803937ec111cc4.zip
Notes
Diffstat (limited to 'java')
-rw-r--r--java/openjdk8-jre/Makefile2
-rw-r--r--java/openjdk8/Makefile12
-rw-r--r--java/openjdk8/files/patch-bsd60
-rw-r--r--java/openjdk8/files/patch-bsd-test11
-rw-r--r--java/openjdk8/files/patch-jdk-make-lib-Awt2dLibraries.gmk20
-rw-r--r--java/openjdk8/files/patch-jdk-src-share-classes-sun-applet-AppletPanel.java40
-rw-r--r--java/openjdk8/files/patch-jdk-src-share-classes-sun-applet-AppletViewerPanel.java66
7 files changed, 177 insertions, 34 deletions
diff --git a/java/openjdk8-jre/Makefile b/java/openjdk8-jre/Makefile
index ed77d0ce548d..dc495a9405e6 100644
--- a/java/openjdk8-jre/Makefile
+++ b/java/openjdk8-jre/Makefile
@@ -1,6 +1,6 @@
# $FreeBSD$
-PORTREVISION= 0
+PORTREVISION= 1
PKGNAMESUFFIX= ${JDK_MAJOR_VERSION}-jre
COMMENT= Java Runtime Environment ${JDK_MAJOR_VERSION}
diff --git a/java/openjdk8/Makefile b/java/openjdk8/Makefile
index d7fcc053c155..b5ab1545262f 100644
--- a/java/openjdk8/Makefile
+++ b/java/openjdk8/Makefile
@@ -2,7 +2,7 @@
PORTNAME= openjdk
PORTVERSION= ${JDK_MAJOR_VERSION}.${JDK_UPDATE_VERSION}.${JDK_BUILD_NUMBER:S/^0//}
-PORTREVISION?= 4
+PORTREVISION?= 5
CATEGORIES= java devel
MASTER_SITES= http://download.java.net/openjdk/jdk${JDK_MAJOR_VERSION}/promoted/b${JDK_BUILD_NUMBER}/:jdk \
https://adopt-openjdk.ci.cloudbees.com/job/jtreg/${JTREG_JENKINS_BUILD}/artifact/:jtreg \
@@ -96,6 +96,8 @@ TZUPDATE_DESC= Update the time zone data
POLICY_CONFIGURE_ENABLE=unlimited-crypto
TZUPDATE_RUN_DEPENDS= ${LOCALBASE}/share/java/zi:${PORTSDIR}/java/java-zoneinfo
+JAVAVMS_COMMENT= OpenJDK${JDK_MAJOR_VERSION}
+
.if !defined(BUILD_JRE)
OPTIONS_DEFINE+= TEST
OPTIONS_DEFAULT+= RELEASE
@@ -113,6 +115,7 @@ TEST_CONFIGURE_ON= --with-jtreg=${WRKDIR}/jtreg
TEST_DISTFILES= jtreg${JTREG_VERSION}-${JTREG_BUILD_NUMBER}.tar.gz:jtreg
.else
CONFIGURE_ARGS+= --disable-debug-symbols
+JAVAVMS_COMMENT+= JRE
.endif
.include <bsd.port.options.mk>
@@ -197,6 +200,7 @@ post-patch:
${WRKSRC}/jdk/src/bsd/doc/man/*.1
@${REINPLACE_CMD} -e 's|%%ICONV_CPPFLAGS%%|${ICONV_CPPFLAGS}|' \
-e 's|%%ICONV_LDFLAGS%%|${ICONV_LDFLAGS}|' \
+ ${WRKSRC}/jdk/make/lib/Awt2dLibraries.gmk \
${WRKSRC}/jdk/make/lib/CoreLibraries.gmk \
${WRKSRC}/jdk/make/lib/ServiceabilityLibraries.gmk
@${CHMOD} 755 ${WRKSRC}/configure
@@ -237,10 +241,6 @@ do-install:
${SED} -e 's#^${STAGEDIR}${PREFIX}/##' >> ${TMPPLIST}
@${FIND} ${STAGEDIR}${INSTALLDIR} -type d | ${SORT} -r | \
${SED} -e 's,^${STAGEDIR}${PREFIX}/,@dirrm ,' >> ${TMPPLIST}
-.if !defined(BUILD_JRE)
- @${ECHO} "@exec ${LOCALBASE}/bin/registervm '${INSTALLDIR}/bin/java # OpenJDK${JDK_MAJOR_VERSION}'" >> ${TMPPLIST}
-.else
- @${ECHO} "@exec ${LOCALBASE}/bin/registervm '${INSTALLDIR}/bin/java # OpenJDK${JDK_MAJOR_VERSION} JRE'" >> ${TMPPLIST}
-.endif
+ @${ECHO} "@exec ${LOCALBASE}/bin/registervm '${INSTALLDIR}/bin/java # ${JAVAVMS_COMMENT}'" >> ${TMPPLIST}
.include <bsd.port.post.mk>
diff --git a/java/openjdk8/files/patch-bsd b/java/openjdk8/files/patch-bsd
index f7f65e750fd0..931c288e74e3 100644
--- a/java/openjdk8/files/patch-bsd
+++ b/java/openjdk8/files/patch-bsd
@@ -141,33 +141,41 @@
CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DLINUX"
--- hotspot/make/bsd/makefiles/build_vm_def.sh
+++ hotspot/make/bsd/makefiles/build_vm_def.sh
-@@ -1,12 +1,22 @@
+@@ -1,12 +1,28 @@
#!/bin/sh
# If we're cross compiling use that path for nm
-if [ "$CROSS_COMPILE_ARCH" != "" ]; then
+-NM=$ALT_COMPILER_PATH/nm
+if [ "$CROSS_COMPILE_ARCH" != "" ]; then
- NM=$ALT_COMPILER_PATH/nm
++ NM=$ALT_COMPILER_PATH/nm
else
- NM=nm
+-NM=nm
++ NM=nm
fi
-$NM -Uj $* | awk '
- { if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3 }
- '
-+if [ "$(uname -s)" = Darwin ]; then
-+ $NM -Uj $* | awk '
-+ { if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3 }
-+ '
-+ exit
-+fi
-+$NM --defined-only $* \
-+ | awk '{
-+ if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3 ";"
-+ if ($3 ~ /^UseSharedSpaces$/) print "\t" $3 ";"
-+ if ($3 ~ /^_ZN9Arguments17SharedArchivePathE$/) print "\t" $3 ";"
-+ }' \
-+ | sort -u
++case "$(uname -s)" in
++Darwin )
++ $NM -Uj $@ | awk '{
++ if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3
++ }' ;;
++OpenBSD )
++ $NM $@ | awk '{
++ if ($2 == "U") next
++ if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3 ";"
++ if ($3 ~ /^UseSharedSpaces$/) print "\t" $3 ";"
++ if ($3 ~ /^_ZN9Arguments17SharedArchivePathE$/) print "\t" $3 ";"
++ }' | sort -u ;;
++* )
++ $NM --defined-only $@ | awk '{
++ if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3 ";"
++ if ($3 ~ /^UseSharedSpaces$/) print "\t" $3 ";"
++ if ($3 ~ /^_ZN9Arguments17SharedArchivePathE$/) print "\t" $3 ";"
++ }' | sort -u ;;
++esac
--- hotspot/make/bsd/makefiles/debug.make
+++ hotspot/make/bsd/makefiles/debug.make
@@ -35,7 +35,10 @@
@@ -4408,6 +4416,15 @@
OBJECT_DIR := $(JDK_OUTPUTDIR)/objs/libawt_headless, \
DEBUG_SYMBOLS := $(DEBUG_ALL_BINARIES)))
+@@ -1245,6 +1266,8 @@
+ else ifeq ($(OPENJDK_TARGET_OS), solaris)
+ # Solaris still uses OPENWIN_LIB ..
+ LIBSPLASHSCREEN_LDFLAGS_SUFFIX += -L$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR) -lX11 -lXext $(LIBM) -lpthread
++ else ifeq ($(OPENJDK_TARGET_OS), bsd)
++ LIBSPLASHSCREEN_LDFLAGS_SUFFIX += $(X_LIBS) -lX11 -lXext $(LIBM) -liconv -pthread
+ else # .. all other Unixes can use X_LIBS
+ LIBSPLASHSCREEN_LDFLAGS_SUFFIX += $(X_LIBS) -lX11 -lXext $(LIBM) -lpthread
+ endif
--- jdk/make/lib/CoreLibraries.gmk
+++ jdk/make/lib/CoreLibraries.gmk
@@ -81,7 +81,7 @@
@@ -9990,14 +10007,3 @@
ifneq (,$$($1_BIN))
$$(error BIN has been replaced with OBJECT_DIR)
---- nashorn/test/script/jfx.js
-+++ nashorn/test/script/jfx.js
-@@ -89,7 +89,7 @@
- var sb = new StringBuffer(goldenDir);
- if (OSInfo.getOSType() == OSType.WINDOWS) {
- f2 = new File(sb.append(fsep + "windows.png").toString());
-- } else if (OSInfo.getOSType() == OSType.LINUX) {
-+ } else if (OSInfo.getOSType() == OSType.LINUX || OSInfo.getOSType() == OSType.BSD) {
- f2 = new File(sb.append(fsep + "linux.png").toString());
- } else if (OSInfo.getOSType() == OSType.MACOSX) {
- f2 = new File(sb.append(fsep + "macosx.png").toString());
diff --git a/java/openjdk8/files/patch-bsd-test b/java/openjdk8/files/patch-bsd-test
index 06131e2e94da..bcbc59eeac96 100644
--- a/java/openjdk8/files/patch-bsd-test
+++ b/java/openjdk8/files/patch-bsd-test
@@ -1361,3 +1361,14 @@
PS=":"
FS="/"
;;
+--- nashorn/test/script/jfx.js
++++ nashorn/test/script/jfx.js
+@@ -89,7 +89,7 @@
+ var sb = new StringBuffer(goldenDir);
+ if (OSInfo.getOSType() == OSType.WINDOWS) {
+ f2 = new File(sb.append(fsep + "windows.png").toString());
+- } else if (OSInfo.getOSType() == OSType.LINUX) {
++ } else if (OSInfo.getOSType() == OSType.LINUX || OSInfo.getOSType() == OSType.BSD) {
+ f2 = new File(sb.append(fsep + "linux.png").toString());
+ } else if (OSInfo.getOSType() == OSType.MACOSX) {
+ f2 = new File(sb.append(fsep + "macosx.png").toString());
diff --git a/java/openjdk8/files/patch-jdk-make-lib-Awt2dLibraries.gmk b/java/openjdk8/files/patch-jdk-make-lib-Awt2dLibraries.gmk
new file mode 100644
index 000000000000..9982af85d462
--- /dev/null
+++ b/java/openjdk8/files/patch-jdk-make-lib-Awt2dLibraries.gmk
@@ -0,0 +1,20 @@
+--- jdk/make/lib/Awt2dLibraries.gmk
++++ jdk/make/lib/Awt2dLibraries.gmk
+@@ -1243,6 +1243,8 @@
+ LIBSPLASHSCREEN_CFLAGS += -DWITH_WIN32
+ else ifeq ($(OPENJDK_TARGET_OS), solaris)
+ LIBSPLASHSCREEN_CFLAGS += -DWITH_X11 -I$(OPENWIN_HOME)/include -I$(OPENWIN_HOME)/include/X11/extensions
++ else ifeq ($(OPENJDK_TARGET_OS), bsd)
++ LIBSPLASHSCREEN_CFLAGS += -DWITH_X11 $(X_CFLAGS) %%ICONV_CPPFLAGS%%
+ else
+ LIBSPLASHSCREEN_CFLAGS += -DWITH_X11 $(X_CFLAGS)
+ endif
+@@ -1267,7 +1269,7 @@
+ # Solaris still uses OPENWIN_LIB ..
+ LIBSPLASHSCREEN_LDFLAGS_SUFFIX += -L$(OPENWIN_LIB)$(OPENJDK_TARGET_CPU_ISADIR) -lX11 -lXext $(LIBM) -lpthread
+ else ifeq ($(OPENJDK_TARGET_OS), bsd)
+- LIBSPLASHSCREEN_LDFLAGS_SUFFIX += $(X_LIBS) -lX11 -lXext $(LIBM) -liconv -pthread
++ LIBSPLASHSCREEN_LDFLAGS_SUFFIX += $(X_LIBS) -lX11 -lXext $(LIBM) %%ICONV_LDFLAGS%% -pthread
+ else # .. all other Unixes can use X_LIBS
+ LIBSPLASHSCREEN_LDFLAGS_SUFFIX += $(X_LIBS) -lX11 -lXext $(LIBM) -lpthread
+ endif
diff --git a/java/openjdk8/files/patch-jdk-src-share-classes-sun-applet-AppletPanel.java b/java/openjdk8/files/patch-jdk-src-share-classes-sun-applet-AppletPanel.java
new file mode 100644
index 000000000000..d83e9c730707
--- /dev/null
+++ b/java/openjdk8/files/patch-jdk-src-share-classes-sun-applet-AppletPanel.java
@@ -0,0 +1,40 @@
+--- jdk/src/share/classes/sun/applet/AppletPanel.java
++++ jdk/src/share/classes/sun/applet/AppletPanel.java
+@@ -68,7 +68,7 @@
+ /**
+ * The applet (if loaded).
+ */
+- Applet applet;
++ protected Applet applet;
+
+ /**
+ * Applet will allow initialization. Should be
+@@ -162,7 +162,8 @@
+ * Creates a thread to run the applet. This method is called
+ * each time an applet is loaded and reloaded.
+ */
+- synchronized void createAppletThread() {
++ //Overridden by NetxPanel.
++ protected synchronized void createAppletThread() {
+ // Create a thread group for the applet, and start a new
+ // thread to load the applet.
+ String nm = "applet-" + getCode();
+@@ -306,7 +307,7 @@
+ /**
+ * Get an event from the queue.
+ */
+- synchronized AppletEvent getNextEvent() throws InterruptedException {
++ protected synchronized AppletEvent getNextEvent() throws InterruptedException {
+ while (queue == null || queue.isEmpty()) {
+ wait();
+ }
+@@ -692,7 +693,8 @@
+ * applet event processing so that it can be gracefully interrupted from
+ * things like HotJava.
+ */
+- private void runLoader() {
++ //Overridden by NetxPanel.
++ protected void runLoader() {
+ if (status != APPLET_DISPOSE) {
+ showAppletStatus("notdisposed");
+ return;
diff --git a/java/openjdk8/files/patch-jdk-src-share-classes-sun-applet-AppletViewerPanel.java b/java/openjdk8/files/patch-jdk-src-share-classes-sun-applet-AppletViewerPanel.java
new file mode 100644
index 000000000000..402f0bcc50a3
--- /dev/null
+++ b/java/openjdk8/files/patch-jdk-src-share-classes-sun-applet-AppletViewerPanel.java
@@ -0,0 +1,66 @@
+--- jdk/src/share/classes/sun/applet/AppletViewerPanel.java
++++ jdk/src/share/classes/sun/applet/AppletViewerPanel.java
+@@ -42,25 +42,25 @@
+ *
+ * @author Arthur van Hoff
+ */
+-class AppletViewerPanel extends AppletPanel {
++public class AppletViewerPanel extends AppletPanel {
+
+ /* Are we debugging? */
+- static boolean debug = false;
++ protected static boolean debug = false;
+
+ /**
+ * The document url.
+ */
+- URL documentURL;
++ protected URL documentURL;
+
+ /**
+ * The base url.
+ */
+- URL baseURL;
++ protected URL baseURL;
+
+ /**
+ * The attributes of the applet.
+ */
+- Hashtable atts;
++ protected Hashtable<String,String> atts;
+
+ /*
+ * JDK 1.1 serialVersionUID
+@@ -70,7 +70,7 @@
+ /**
+ * Construct an applet viewer and start the applet.
+ */
+- AppletViewerPanel(URL documentURL, Hashtable atts) {
++ protected AppletViewerPanel(URL documentURL, Hashtable<String,String> atts) {
+ this.documentURL = documentURL;
+ this.atts = atts;
+
+@@ -106,7 +106,7 @@
+ * Get an applet parameter.
+ */
+ public String getParameter(String name) {
+- return (String)atts.get(name.toLowerCase());
++ return atts.get(name.toLowerCase());
+ }
+
+ /**
+@@ -202,12 +202,12 @@
+ return (AppletContext)getParent();
+ }
+
+- static void debug(String s) {
++ protected static void debug(String s) {
+ if(debug)
+ System.err.println("AppletViewerPanel:::" + s);
+ }
+
+- static void debug(String s, Throwable t) {
++ protected static void debug(String s, Throwable t) {
+ if(debug) {
+ t.printStackTrace();
+ debug(s);