aboutsummaryrefslogtreecommitdiffstats
path: root/java
diff options
context:
space:
mode:
authorglewis <glewis@FreeBSD.org>2007-08-07 01:23:31 +0800
committerglewis <glewis@FreeBSD.org>2007-08-07 01:23:31 +0800
commitd59c7ad3d7460a0e9dca0ceecd6d0d8164c9f343 (patch)
treece868fffb04a072ea17ef02e6acc9617897e74c9 /java
parent43be6111685c0584e9281ea5eda88bf5563d9cf2 (diff)
downloadfreebsd-ports-gnome-d59c7ad3d7460a0e9dca0ceecd6d0d8164c9f343.tar.gz
freebsd-ports-gnome-d59c7ad3d7460a0e9dca0ceecd6d0d8164c9f343.tar.zst
freebsd-ports-gnome-d59c7ad3d7460a0e9dca0ceecd6d0d8164c9f343.zip
. Make BUILD_DEPENDS against the Diablo JDK, not the Linux JDK. [2]
. Add some more make environment variables to control the build of the debug versions. [1] . Allow the setting of ALT_PARALLEL_BUILD_JOBS. [1] . Install more of the Gnome desktop files, and provide them with the correct path for the installation. [1] . Add ${LOCALBASE}/lib to the default library path in HotSpot. [1] . Backwards compatibility in time zone updates. [1] . Bump PORTREVISION. Submitted by: jkim [1] Inspired by: scf [2]
Diffstat (limited to 'java')
-rw-r--r--java/jdk16/Makefile52
-rw-r--r--java/jdk16/files/patch-deploy-applications-sun-java.desktop15
-rw-r--r--java/jdk16/files/patch-deploy-applications-sun-javaws.desktop15
-rw-r--r--java/jdk16/files/patch-deploy-controlpanel-sun_java.desktop15
-rw-r--r--java/jdk16/files/patch-hotspot-vm-os_bsd.cpp13
5 files changed, 97 insertions, 13 deletions
diff --git a/java/jdk16/Makefile b/java/jdk16/Makefile
index 035127e2b70a..459bf0894acd 100644
--- a/java/jdk16/Makefile
+++ b/java/jdk16/Makefile
@@ -7,6 +7,7 @@
PORTNAME= jdk
PORTVERSION= ${JDK_VERSION}.${JDK_UPDATE_VERSION}p${JDK_PATCHSET_VERSION}
+PORTREVISION= 1
CATEGORIES= java devel
MASTER_SITES= # http://download.java.net/tiger/
# http://www.eyesbeyond.com/freebsddom/java/jdk16.html
@@ -17,7 +18,7 @@ EXTRACT_ONLY= ${JRL_SRCFILE} ${JRL_BINFILE} ${JRL_MOZFILE}
MAINTAINER= glewis@FreeBSD.org
COMMENT= Java Development Kit 1.6.0
-BUILD_DEPENDS= zip:${PORTSDIR}/archivers/zip \
+BUILD_DEPENDS= zip:${PORTSDIR}/archivers/zip \
${X11BASE}/lib/libXm.so:${PORTSDIR}/x11-toolkits/open-motif
RUN_DEPENDS= javavm:${PORTSDIR}/java/javavmwrapper
LIB_DEPENDS= cups.2:${PORTSDIR}/print/cups-base
@@ -66,7 +67,7 @@ TZUPDATE_TZVERSION= 2007f
SUN_LINUX_JDK_VERSION= 1.6.0
.if !defined(WITH_LINUX_BOOTSTRAP)
-NATIVE_BOOTSTRAP_JDKS+= ${LOCALBASE}/diablo-jdk1.5.0 \
+NATIVE_BOOTSTRAP_JDKS+= ${LOCALBASE}/diablo-jdk1.5.0 \
${LOCALBASE}/jdk1.6.0 \
${LOCALBASE}/jdk1.5.0
.endif
@@ -114,7 +115,7 @@ WITH_LINUX_BOOTSTRAP= YES
BOOTSTRAPJDKDIR?= ${LOCALBASE}/linux-sun-jdk${SUN_LINUX_JDK_VERSION}
.endif
-BUILD_DEPENDS+= ${BOOTSTRAPJDKDIR}/bin/javac:${PORTSDIR}/java/linux-sun-jdk16
+BUILD_DEPENDS+= ${BOOTSTRAPJDKDIR}/bin/javac:${PORTSDIR}/java/diablo-jdk15
.if defined(WITHOUT_WEB)
MAKE_ENV+= DONT_BUILD_DEPLOY="YES"
@@ -135,23 +136,36 @@ MAKE_ENV+= ALT_BOOTDIR="${BOOTSTRAPJDKDIR}" \
CLASSPATH="" \
LD_LIBRARY_PATH="" \
MAKEFLAGS="" \
- SKIP_COMPARE_IMAGES="YES" \
+ SKIP_COMPARE_IMAGES="true" \
+ SKIP_FASTDEBUG_BUILD="true" \
LOCALBASE="${LOCALBASE}" \
X11BASE="${X11BASE}" \
PTHREAD_LIBS="${PTHREAD_LIBS}"
+
+.if defined(WITH_DEBUG)
+MAKE_ENV+= SKIP_DEBUG_BUILD="false"
+.endif
+
.if !defined(WITH_IPV6)
MAKE_ENV+= DONT_ENABLE_IPV6="YES"
.endif
+
.if defined(HOTSPOT_BUILD_JOBS)
-MAKE_ENV+= HOTSPOT_BUILD_JOBS=${HOTSPOT_BUILD_JOBS}
+MAKE_ENV+= HOTSPOT_BUILD_JOBS="${HOTSPOT_BUILD_JOBS}"
+.endif
+
+.if defined(PARALLEL_BUILD_JOBS)
+MAKE_ENV+= ALT_PARALLEL_BUILD_JOBS="${PARALLEL_BUILD_JOBS}"
.endif
ALL_TARGET= all
PLIST_FILES= jdk${JDK_VERSION}/jre/.systemPrefs/.system.lock \
- jdk${JDK_VERSION}/jre/.systemPrefs/.systemRootModFile
+ jdk${JDK_VERSION}/jre/.systemPrefs/.systemRootModFile \
+ share/applications/sun-java16.desktop \
+ share/applications/sun-javaws16.desktop
.if !defined(WITHOUT_WEB)
-PLIST_FILES+= share/applications/sun_java16.desktop
+PLIST_FILES+= share/applications/sun-jcontrol16.desktop
.endif
PLIST_DIRS= jdk${JDK_VERSION}/jre/.systemPrefs
@@ -165,6 +179,7 @@ JDKIMAGEDIR= ${WRKSRC}/../build/bsd-${HOTSPOTARCH}/j2sdk-image
JDKIMAGEDIR_G= ${WRKSRC}/../build/bsd-${HOTSPOTARCH}/j2sdk-debug-image
LOCAL_FILES= ../../hotspot/make/jprt.config \
+ ../../hotspot/src/os/bsd/vm/os_bsd.cpp \
../../j2se/src/share/classes/com/sun/java/swing/plaf/gtk/Metacity.java \
../../j2se/src/share/classes/sun/net/www/MimeTable.java \
../../j2se/src/share/classes/sun/net/www/protocol/doc/DocURLConnection.java \
@@ -172,9 +187,14 @@ LOCAL_FILES= ../../hotspot/make/jprt.config \
../../j2se/src/solaris/bin/java-rmi.cgi.sh \
../../j2se/src/solaris/bin/java_md.c \
../../j2se/src/solaris/classes/sun/security/smartcardio/PlatformPCSC.java
+
X11_FILES= ../../j2se/src/share/classes/com/sun/java/swing/plaf/gtk/Metacity.java \
../../j2se/src/solaris/native/sun/awt/fontpath.c
+DESKTOP_FILES= ../../deploy/src/desktop/freedesktop/applications/sun-java.desktop \
+ ../../deploy/src/desktop/freedesktop/applications/sun-javaws.desktop \
+ ../../deploy/src/plugin/solaris/controlpanel/sun_java.desktop
+
# Check for JDK sources and patch file
.if !defined(PACKAGE_BUILDING) && (!exists(${DISTDIR}/${JRL_SRCFILE}) || !exists(${DISTDIR}/${JRL_BINFILE}) || !exists(${DISTDIR}/${JRL_MOZFILE}) || (defined(WITH_POLICY) && !exists(${DISTDIR}/${POLICYFILE})) || (defined(WITH_TZUPDATE) && !exists(${DISTDIR}/${TZUPDATEFILE})) || !exists(${DISTDIR}/${PATCHSETFILE}))#{
ECHO_MSG=/usr/bin/printf
@@ -279,9 +299,11 @@ post-patch:
${REINPLACE_CMD} -e "s:%%X11BASE%%:${X11BASE}:" \
${WRKSRC}/$${file}; \
done
-# ${REINPLACE_CMD} -e "s:%%PREFIX%%:${PREFIX}:g" \
-# -e "s:%%JDK_VERSION%%:${JDK_VERSION}:g"\
-# ${WRKSRC}/../../deploy/src/plugin/solaris/controlpanel/sun_java.desktop
+ @for file in ${DESKTOP_FILES}; do \
+ ${REINPLACE_CMD} -e "s:%%PREFIX%%:${PREFIX}:g" \
+ -e "s:%%JDK_VERSION%%:${JDK_VERSION}:g" \
+ ${WRKSRC}/$${file}; \
+ done
.if defined(WITH_LINUX_BOOTSTRAP)
pre-build:
@@ -333,7 +355,7 @@ post-build:
.if defined(WITH_TZUPDATE)
@# Update time zones
@-${JDKIMAGEDIR}/bin/java -jar \
- ${WRKDIR}/tzupdater-${TZUPDATE_VERSION}-${TZUPDATE_TZVERSION}/tzupdater.jar -u
+ ${WRKDIR}/tzupdater-${TZUPDATE_VERSION}-${TZUPDATE_TZVERSION}/tzupdater.jar -u -bc
@-${RM} -rf ${JDKIMAGEDIR}/jre/lib/zi.tzdata*
.endif
@@ -341,9 +363,13 @@ do-install:
${MKDIR} ${PREFIX}/jdk${JDK_VERSION}
cd ${JDKIMAGEDIR} && ${FIND} . \
| ${CPIO} -pdmu -R ${LIBOWN}:${LIBGRP} ${PREFIX}/jdk${JDK_VERSION}
+ ${INSTALL_DATA} ${JDKIMAGEDIR}/jre/lib/desktop/applications/sun-java.desktop \
+ ${PREFIX}/share/applications/sun-java16.desktop
+ ${INSTALL_DATA} ${JDKIMAGEDIR}/jre/lib/desktop/applications/sun-javaws.desktop \
+ ${PREFIX}/share/applications/sun-javaws16.desktop
.if !defined(WITHOUT_WEB)
- ${INSTALL_DATA} ${JDKIMAGEDIR}/jre/plugin/desktop/sun_java.desktop \
- ${PREFIX}/share/applications/sun_java16.desktop
+ ${INSTALL_DATA} ${JDKIMAGEDIR}/jre/lib/desktop/applications/sun_java.desktop \
+ ${PREFIX}/share/applications/sun-jcontrol16.desktop
.endif
@${ECHO_MSG} "@unexec ${LOCALBASE}/bin/unregistervm ${PREFIX}/jdk${JDK_VERSION}/bin/java" >> ${TMPPLIST}
@${FIND} -s ${JDKIMAGEDIR} -not -type d | \
diff --git a/java/jdk16/files/patch-deploy-applications-sun-java.desktop b/java/jdk16/files/patch-deploy-applications-sun-java.desktop
new file mode 100644
index 000000000000..74f9f176855a
--- /dev/null
+++ b/java/jdk16/files/patch-deploy-applications-sun-java.desktop
@@ -0,0 +1,15 @@
+$FreeBSD$
+
+--- ../../deploy/src/desktop/freedesktop/applications/sun-java.desktop.orig Thu Apr 12 04:55:27 2007
++++ ../../deploy/src/desktop/freedesktop/applications/sun-java.desktop Wed Jun 13 16:57:20 2007
+@@ -18,8 +18,8 @@
+ Encoding=UTF-8
+ Name=Java
+ Comment=Java Virtual Machine
+-Exec=java -jar
+-Icon=sun-java.png
++Exec=%%PREFIX%%/jdk%%JDK_VERSION%%/bin/java -jar
++Icon=%%PREFIX%%/jdk%%JDK_VERSION%%/jre/lib/desktop/icons/hicolor/48x48/apps/sun-java.png
+ Terminal=false
+ Type=Application
+ NoDisplay=true
diff --git a/java/jdk16/files/patch-deploy-applications-sun-javaws.desktop b/java/jdk16/files/patch-deploy-applications-sun-javaws.desktop
new file mode 100644
index 000000000000..905ac89a8790
--- /dev/null
+++ b/java/jdk16/files/patch-deploy-applications-sun-javaws.desktop
@@ -0,0 +1,15 @@
+$FreeBSD$
+
+--- ../../deploy/src/desktop/freedesktop/applications/sun-javaws.desktop.orig Thu Apr 12 04:55:27 2007
++++ ../../deploy/src/desktop/freedesktop/applications/sun-javaws.desktop Wed Jun 13 16:58:15 2007
+@@ -15,8 +15,8 @@
+ Encoding=UTF-8
+ Name=JavaWS
+ Comment=Java Web Start
+-Exec=javaws
+-Icon=sun-javaws.png
++Exec=%%PREFIX%%/jdk%%JDK_VERSION%%/bin/javaws
++Icon=%%PREFIX%%/jdk%%JDK_VERSION%%/jre/lib/desktop/icons/hicolor/48x48/apps/sun-javaws.png
+ Terminal=false
+ Type=Application
+ NoDisplay=true
diff --git a/java/jdk16/files/patch-deploy-controlpanel-sun_java.desktop b/java/jdk16/files/patch-deploy-controlpanel-sun_java.desktop
new file mode 100644
index 000000000000..2d0908e7aa0d
--- /dev/null
+++ b/java/jdk16/files/patch-deploy-controlpanel-sun_java.desktop
@@ -0,0 +1,15 @@
+$FreeBSD$
+
+--- ../../deploy/src/plugin/solaris/controlpanel/sun_java.desktop.orig Wed Jun 13 16:44:31 2007
++++ ../../deploy/src/plugin/solaris/controlpanel/sun_java.desktop Wed Jun 13 16:59:32 2007
+@@ -15,8 +15,8 @@
+ Encoding=UTF-8
+ Name=Java
+ Comment=Java Control Panel
+-Exec=jcontrol
+-Icon=sun-jcontrol.png
++Exec=%%PREFIX%%/jdk%%JDK_VERSION%%/bin/jcontrol
++Icon=%%PREFIX%%/jdk%%JDK_VERSION%%/jre/lib/desktop/icons/hicolor/48x48/apps/sun-jcontrol.png
+ Terminal=false
+ Type=Application
+ Categories=Application;Settings;Java;
diff --git a/java/jdk16/files/patch-hotspot-vm-os_bsd.cpp b/java/jdk16/files/patch-hotspot-vm-os_bsd.cpp
new file mode 100644
index 000000000000..c006ad9e9459
--- /dev/null
+++ b/java/jdk16/files/patch-hotspot-vm-os_bsd.cpp
@@ -0,0 +1,13 @@
+$FreeBSD$
+
+--- ../../hotspot/src/os/bsd/vm/os_bsd.cpp.orig Wed Jun 13 16:16:36 2007
++++ ../../hotspot/src/os/bsd/vm/os_bsd.cpp Wed Jun 13 16:36:13 2007
+@@ -364,7 +364,7 @@
+ * 7: The default directories, normally /lib and /usr/lib.
+ */
+ #ifndef DEFAULT_LIBPATH
+-#define DEFAULT_LIBPATH "/lib:/usr/lib"
++#define DEFAULT_LIBPATH "/lib:/usr/lib:%%LOCALBASE%%/lib"
+ #endif
+
+ #define EXTENSIONS_DIR "/lib/ext"