summaryrefslogtreecommitdiff
path: root/java/jdk15/Makefile
diff options
context:
space:
mode:
authorAlexey Zelkin <phantom@FreeBSD.org>2003-03-06 23:18:24 +0000
committerAlexey Zelkin <phantom@FreeBSD.org>2003-03-06 23:18:24 +0000
commit6513eda595f341f26ea392a3602463e995beda7d (patch)
tree9380c69b25a8802366101414b96e535a079bf20e /java/jdk15/Makefile
parentMore manual pkg-comment cleanups. (diff)
I am pleased to announce first public -beta patchset of FreeBSD/Java port
for JDK 1.4.1. This is complete and close to production quality native JDK with both working client and server native JVMs. Local micro benchmarks shown very little difference between Linux and FreeBSD JVMs in speed. One of important points of this patchset that it marks point when we are very close to passing of Sun TCK tests. Currently about 20 of >27000 tests are known to be broken (tests were run at -STABLE). If testing of this patchset will be smooth and founding of this work will be continued we may expect to have binary distribution of JDK 1.4.1 in April or begining of May. BUT, don't forget that even TCK tests can't cover all possible problems and this is -beta patchset. Keep your eyes open and report your problems to freebsd-java mailing list or to me directly! * About supported FreeBSD releases: Altough 4.8-RELEASE will be first officially supported FreeBSD release, you may use JDK 1.4.1-p3 at stock post-02-Feb-2003 -STABLE or -CURRENT. You also may use it at post-07-Jan-2003 -STABLE and -CURRENT (including 5.0-RELEASE), but it's required to apply libc_r patch, distributed with patchset3 archive, and rebuild libc_r first. * About compiler: This port is supposed to be built with stock FreeBSD compiler (3.2.[12] for -CURRENT and 2.95.4 for -STABLE)! * Following issues are known, but not yet addressed: . IPv6 networking. IPv6 support is disabled in this patchset. . Asian languages support. Patches are welcome! . K6 (586-class) processors support. There're issues with building on old K6 processors. If you've problems with 586-class machines other than K6 - please let me know. . Mozilla plugin is not yet ported. * Following areas should be used with increased attention: . Java Virtual Machine Profiling Interface (JVMPI) . Java Virtual Machine Debugging Interface (JVMDI) . Host Porting Interface (HPI) If you have problems with these interfaces please let me know. * THANKS! I would thank very much to FreeBSD Foundation, without which support and sponsorship JDK 1.4.1 port would not happen in such timeframes (less than 2 months). Sponsored by: FreeBSD Foundation Approved by: portmgr
Notes
Notes: svn path=/head/; revision=77039
Diffstat (limited to 'java/jdk15/Makefile')
-rw-r--r--java/jdk15/Makefile203
1 files changed, 37 insertions, 166 deletions
diff --git a/java/jdk15/Makefile b/java/jdk15/Makefile
index 034053061605..c669cc52d1f6 100644
--- a/java/jdk15/Makefile
+++ b/java/jdk15/Makefile
@@ -1,85 +1,65 @@
-# New ports collection makefile for: jdk13
-# Date created: 10 October 2000
-# Whom: Maxim Sobolev <sobomax@FreeBSD.org>
+# New ports collection makefile for: jdk14
+# Date created: 6 March 2003
+# Whom: Alexey Zelkin <phantom@FreeBSD.org>
#
# $FreeBSD$
#
PORTNAME= jdk
PORTVERSION= ${JDK_VERSION}p${JDK_PATCHSET_VERSION}
-PORTREVISION= 1
CATEGORIES= java devel
MASTER_SITES= # http://www.sun.com/software/java2/download.html
-# http://www.eyesbeyond.com/freebsddom/java/jdk13.html
-SRCFILE= j2sdk-${JDK_VERSION:S/./_/g}-src${EXTRACT_SUFX}
-PATCHSETFILE= bsd-jdk131-patches-${JDK_PATCHSET_VERSION}.tar.gz
+# http://www.eyesbeyond.com/freebsddom/java/jdk14.html
+SRCFILE= j2sdk-${JDK_VERSION:S/./_/g}-src-scsl.zip
+PATCHSETFILE= bsd-jdk14-patches-${JDK_PATCHSET_VERSION}.tar.gz
DISTFILES= ${SRCFILE} ${PATCHSETFILE}
-MAINTAINER= glewis@FreeBSD.org
-COMMENT= Java Development Kit 1.3
+MAINTAINER= phantom@FreeBSD.org
+COMMENT= Java Development Kit 1.4.1
BUILD_DEPENDS= gm4:${PORTSDIR}/devel/m4 \
zip:${PORTSDIR}/archivers/zip \
${X11BASE}/lib/libXm.so:${PORTSDIR}/x11-toolkits/open-motif
.if !defined(NATIVE_BOOTSTRAP)
-BUILD_DEPENDS+= ${JDK13DIR}/bin/javac:${PORTSDIR}/java/linux-sun-jdk13
-.endif
-.if !defined(WITHOUT_PLUGIN)
-BUILD_DEPENDS+= msgfmt:${PORTSDIR}/devel/gettext
-LIB_DEPENDS= glib12.3:$(PORTSDIR)/devel/glib12 \
- gtk12.2:$(PORTSDIR)/x11-toolkits/gtk12 \
- nspr4.1:$(PORTSDIR)/devel/nspr
+BUILD_DEPENDS+= ${JDK14DIR}/bin/javac:${PORTSDIR}/java/linux-sun-jdk14
.endif
RUN_DEPENDS= javavm:${PORTSDIR}/java/javavmwrapper \
${X11BASE}/lib/libXm.so:${PORTSDIR}/x11-toolkits/open-motif \
${X11BASE}/lib/X11/fonts/URW/fonts.dir:${PORTSDIR}/x11-fonts/urwfonts
-.if defined(WITH_JAPANESE_FONTS)
-RUN_DEPENDS+= ${X11BASE}/lib/X11/fonts/TrueType/fonts.dir.kochi:${PORTSDIR}/japanese/kochi-ttfonts
-.endif
-.if defined(WITH_RUSSIAN_FONTS)
-RUN_DEPENDS+= ${X11BASE}/lib/X11/fonts/webfonts/fonts.dir:${PORTSDIR}/x11-fonts/webfonts
-.endif
-.if defined(WITH_CHINESE_FONTS)
-RUN_DEPENDS+= ${LOCALBASE}/share/fonts/TrueType/arphic:${PORTSDIR}/chinese/arphicttf
-.endif
-
-WRKSRC= ${WRKDIR}/j2sdk1.3.1/make
+WRKSRC= ${WRKDIR}/control/make
-JDK_VERSION= 1.3.1
-JDK_PATCHSET_VERSION= 8
+JDK_VERSION= 1.4.1
+JDK_PATCHSET_VERSION= 3
.if defined(NATIVE_BOOTSTRAP)
-JDK13DIR?= ${LOCALBASE}/jdk${JDK_VERSION}
+JDK14DIR?= ${LOCALBASE}/jdk${JDK_VERSION}
.else
-JDK13DIR?= ${LOCALBASE}/linux-sun-jdk${JDK_VERSION}
+JDK14DIR?= ${LOCALBASE}/linux-sun-jdk${JDK_VERSION}
.endif
+# workaround to handle both 'zip' and 'tar.gz' distfiles
+USE_ZIP= YES
+EXTRACT_ONLY= ${SRCFILE}
+
ONLY_FOR_ARCHS= i386
-USE_GMAKE= yes
+USE_GMAKE= YES
RESTRICTED= "Redistribution of pre-compiled binaries is not permitted"
NO_CDROM= "Redistribution of pre-compiled binaries is not permitted"
-MAKE_ENV= ALT_BOOTDIR="${JDK13DIR}" \
+MAKE_ENV= ALT_BOOTDIR="${JDK14DIR}" \
ALT_MOTIF_DIR="${X11BASE}" \
- OPENWINHOME="${X11BASE}" \
SYS_CFLAGS="${CFLAGS}" \
+ JAVAWS_OPTIONAL="YES" \
+ NO_DOCS="YES" \
+ LANG="C" \
+ JAVA_HOME="" \
CLASSPATH="" \
- LD_LIBRARY_PATH="" \
- JAVA_COMPILER=""
-.if !defined(WITHOUT_PLUGIN)
-MAKE_ENV += LIBG_HDRS="${LOCALBASE}/include/glib12" \
- GTK_HDRS="${X11BASE}/include/gtk12" \
- LIBIDL_HDRS=
-.endif
-.if !defined(WITHOUT_PLUGIN)
-ALL_TARGET= all plugin images
-.else
-ALL_TARGET= all images
-.endif
+ LD_LIBRARY_PATH=""
+ALL_TARGET= all
PLIST_SUB+= JDK_VERSION=${JDK_VERSION}
-JDKIMAGEDIR= ${WRKSRC}/../build/bsd-i386/jdk-image-i386
-JDKIMAGEDIR_G= ${WRKSRC}/../build/bsd-i386/jdk-debug-image-i386
+JDKIMAGEDIR= ${WRKSRC}/../build/bsd-i586/j2sdk-image
+JDKIMAGEDIR_G= ${WRKSRC}/../build/bsd-i586/j2sdk-debug-image
SORT?= /usr/bin/sort
CPIO?= /usr/bin/cpio
@@ -91,47 +71,8 @@ PKGNAMESUFFIX= -nodebug
PLIST_SUB+= DEBUG:=""
.endif
-.if defined(WITH_NATIVE_THREADS) || defined(WITH_HOTSPOT)
-PLIST_SUB+= NATIVE:=""
-MAKE_ARGS+= HPIS="green native"
-.else
-PLIST_SUB+= NATIVE:="@comment "
-.endif
-
-.if defined(WITHOUT_PLUGIN)
-PLIST_SUB+= PLUGIN:="@comment "
-.else
-PLIST_SUB+= PLUGIN:=""
-.endif
-
-.if defined(WITH_HOTSPOT)
-PLIST_SUB+= HOTSPOT:=""
-USE_REINPLACE= yes
-.if defined(NODEBUG)
-HOTSPOT_TARGETS=product1 product
-.else
-HOTSPOT_TARGETS=compiler1 compiler2
-.endif
-.else
-PLIST_SUB+= HOTSPOT:="@comment "
-.endif
-
.include <bsd.port.pre.mk>
-.if defined(WITH_HOTSPOT) && ${OSVERSION} < 500039
-USE_GCC= 3.2
-BUILD_DEPENDS+= gcc32:${PORTSDIR}/lang/gcc32
-MAKE_ENV+= ALT_COMPILER_PATH=${LOCALBASE}/bin
-HOTSPOT_BUILD= ../ext/plugin/build/solaris/GNUmakefile \
- ../../hotspot1.3.1/build/linux/makefiles/adlc.make \
- ../../hotspot1.3.1/build/linux/platform_i486
-.endif
-
-.if ${OSVERSION} < 460101 || ( ${OSVERSION} >= 500000 && ${OSVERSION} < 500038 )
-BUILD_DEPENDS+= gtar:${PORTSDIR}/archivers/gtar
-TAR= gtar # Necessary for proper extraction of sources
-.endif
-
# Check for JDK sources
.if !exists(${DISTDIR}/${SRCFILE}) && !defined(PACKAGE_BUILDING)
ECHO_MSG=/usr/bin/printf
@@ -153,56 +94,24 @@ IGNORE= :\n\
The source distribution exists on your system, but due to\n\
licensing restrictions you still need to download the\n\
patchset, ${PATCHSETFILE}, from\n\
-http://www.eyesbeyond.com/freebsddom/java/jdk13.html.\n\
+http://www.eyesbeyond.com/freebsddom/java/jdk14.html.\n\
Please place the patchset in ${DISTDIR}.\n
.endif
-# HotSpot and/or native threads require a recent version of FreeBSD
-.if ( defined(WITH_NATIVE_THREADS) || defined(WITH_HOTSPOT) ) && ( ${OSVERSION} < 470101 || ( ${OSVERSION} >= 500000 && ${OSVERSION} < 500043 ) )
+# JDK 1.4.1 require recent version of FreeBSD due to recent libc_r updates.
+# These checks are not prefect but it's better than nothing.
+.if (${OSVERSION} < 470101 || ( ${OSVERSION} >= 500000 && ${OSVERSION} < 500043 ))
ECHO_MSG=/usr/bin/printf
IGNORE= :\n\
You must have a version of FreeBSD later than 4.7-STABLE February 2003\n\
-or 5-CURRENT February 2003 to use either native threads or HotSpot.\n
-.endif
-
-# Warn user about HotSpot build
-.if defined(WITH_HOTSPOT)
-pre-everything:
- @${ECHO_MSG} ""
- @${ECHO_MSG} "You have set WITH_HOTSPOT to enable the build of the HotSpot VM."
- @${ECHO_MSG} "Please note that HotSpot development is still experimental and is"
- @${ECHO_MSG} "not suitable for use in a production environment."
- @${ECHO_MSG} "To use the browser plugin with HotSpot you will need to set the"
- @${ECHO_MSG} "THREADS_FLAG environment variable when running the browser, e.g."
- @${ECHO_MSG} " setenv THREADS_FLAG native"
- @${ECHO_MSG} "Compiling HotSpot into the JDK will also currently make the"
- @${ECHO_MSG} "Classic VM unusable."
- @${ECHO_MSG} ""
+or 5-CURRENT February 2003 to compile and use JDK 1.4.1.\n
.endif
pre-patch:
@cd ${WRKDIR} && \
+ ${GZIP_CMD} -dc ${DISTDIR}/${PATCHSETFILE} | ${TAR} -xf - && \
${CHMOD} -R u+w * && \
- ${MKDIR} j2sdk1.3.1/ext/plugin/oji-plugin/include/bsd/jdk12 && \
- ${MKDIR} j2sdk1.3.1/ext/plugin/oji-plugin/include/solaris/navig5/private && \
- ${MKDIR} j2sdk1.3.1/src/bsd/doc/man && \
- ${MKDIR} hotspot1.3.1/build/bsd && \
- ${MKDIR} hotspot1.3.1/build/bsd/makefiles && \
- ${MKDIR} hotspot1.3.1/build/bsd/package && \
- ${MKDIR} hotspot1.3.1/src/os/bsd/launcher && \
- ${MKDIR} hotspot1.3.1/src/os/bsd/vm && \
- ${MKDIR} hotspot1.3.1/src/os_cpu/bsd_i486/vm && \
- ${PATCH} < ${WRKDIR}/jdk131.patches
-
-post-patch:
-.if defined(WITH_HOTSPOT)
-.if defined(USE_GCC) && ${USE_GCC} == 3.2
- @for file in ${HOTSPOT_BUILD}; do \
- ${REINPLACE_CMD} -e "s:gcc:gcc32:g ; s:g\+\+:g\+\+32:g" ${WRKSRC}/$${file}; \
- done
- @${REINPLACE_CMD} -e "s:PATH[)]gcc:PATH)gcc32:g ; s:PATH[)]g\+\+:PATH)g\+\+32:g" ${WRKSRC}/common/Defs-bsd.gmk
-.endif
-.endif
+ ${PATCH} -p0 < ${WRKDIR}/jdk14.patches
.if !defined(NATIVE_BOOTSTRAP)
pre-build:
@@ -229,35 +138,10 @@ pre-build:
do-build:
# Start of jdk build
@(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${ALL_TARGET})
-.if defined(WITH_HOTSPOT)
- # Start of HotSpot build
- @(cd ${WRKDIR}/hotspot1.3.1/build/linux ; \
- ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${HOTSPOT_TARGETS})
-.endif
post-build:
-.if defined(WITH_HOTSPOT)
- # Copy HotSpot VM to image dir
- ${MKDIR} ${JDKIMAGEDIR}/jre/lib/i386/client
- ${INSTALL_PROGRAM} ${WRKDIR}/hotspot1.3.1/build/linux/linux_i486_compiler1/product/libjvm.so ${JDKIMAGEDIR}/jre/lib/i386/client/
- ${INSTALL_DATA} ${WRKDIR}/hotspot1.3.1/src/share/vm/Xusage.txt ${JDKIMAGEDIR}/jre/lib/i386/client/
- ${MKDIR} ${JDKIMAGEDIR}/jre/lib/i386/server
- ${INSTALL_PROGRAM} ${WRKDIR}/hotspot1.3.1/build/linux/linux_i486_compiler2/product/libjvm.so ${JDKIMAGEDIR}/jre/lib/i386/server/
- ${INSTALL_DATA} ${WRKDIR}/hotspot1.3.1/src/share/vm/Xusage.txt ${JDKIMAGEDIR}/jre/lib/i386/server/
- @(cd ${JDKIMAGEDIR}/jre/lib/i386; ${LN} -sf client hotspot)
-.if !defined(NODEBUG)
- # Copy debug version of HotSpot VM to image dir
- ${MKDIR} ${JDKIMAGEDIR_G}/jre/lib/i386/client
- ${INSTALL_PROGRAM} ${WRKDIR}/hotspot1.3.1/build/linux/linux_i486_compiler1/jvmg/libjvm_g.so ${JDKIMAGEDIR_G}/jre/lib/i386/client/
- ${MKDIR} ${JDKIMAGEDIR_G}/jre/lib/i386/server
- ${INSTALL_PROGRAM} ${WRKDIR}/hotspot1.3.1/build/linux/linux_i486_compiler2/jvmg/libjvm_g.so ${JDKIMAGEDIR_G}/jre/lib/i386/server/
-.endif
-.endif
- # Prune empty dirs
- ${FIND} ${JDKIMAGEDIR} -type d | ${SORT} -r | \
- ${XARGS} ${RMDIR} 2> /dev/null || ${TRUE}
- ${FIND} ${JDKIMAGEDIR_G} -type d | ${SORT} -r | \
- ${XARGS} ${RMDIR} 2> /dev/null || ${TRUE}
+ @# This file serves no purpose (in case of port)
+ @${RM} -f ${JDKIMAGEDIR}/src.zip
.if !defined(NODEBUG)
pre-install:
@@ -275,21 +159,8 @@ do-install:
cd ${JDKIMAGEDIR_G} && ${FIND} . \
| ${CPIO} -pdmu -R ${LIBOWN}:${LIBGRP} ${PREFIX}/jdk${JDK_VERSION}
.endif
- ${MKDIR} ${PREFIX}/jdk${JDK_VERSION}/jre/lib/ext
post-install:
@${LOCALBASE}/bin/registervm "${PREFIX}/jdk${JDK_VERSION}/bin/java # FREEBSD-JDK${JDK_VERSION}"
-.if !defined(WITHOUT_PLUGIN)
- @${ECHO_MSG}
- @${ECHO_MSG} To use the Java plugin with Mozilla you must create a
- @${ECHO_MSG} symbolic link from
- @${ECHO_MSG}
- @${ECHO_MSG} ${PREFIX}/jdk${JDK_VERSION}/jre/plugin/i386/ns600/libjavaplugin_oji.so
- @${ECHO_MSG}
- @${ECHO_MSG} to your Mozilla plugins directory, which is usually found at
- @${ECHO_MSG}
- @${ECHO_MSG} ${X11BASE}/lib/mozilla/plugins
- @${ECHO_MSG}
-.endif
.include <bsd.port.post.mk>