2001-08-27 20:58:46 +02:00
# New ports collection makefile for: jdk13
2000-10-13 14:41:25 +02:00
# Date created: 10 October 2000
# Whom: Maxim Sobolev <sobomax@FreeBSD.org>
#
# $FreeBSD$
#
PORTNAME = jdk
2001-08-27 20:58:46 +02:00
PORTVERSION = ${ JDK_VERSION } p${ JDK_PATCHSET_VERSION }
2000-10-13 14:41:25 +02:00
CATEGORIES = java devel
2001-05-03 16:25:51 +02:00
MASTER_SITES = # http://www.sun.com/software/java2/download.html
2001-08-27 20:58:46 +02:00
# http://www.eyesbeyond.com/freebsddom/java/jdk13.html
DISTFILES = j2sdk-${ JDK_VERSION : S /./_/g } -src${ EXTRACT_SUFX } \
bsd-jdk131-patches-${ JDK_PATCHSET_VERSION } .tar.gz
2000-10-13 14:41:25 +02:00
2001-12-14 09:26:44 +01:00
MAINTAINER = java@FreeBSD.org
2000-10-13 14:41:25 +02:00
BUILD_DEPENDS = gm4:${ PORTSDIR } /devel/m4 \
zip:${ PORTSDIR } /archivers/zip \
2001-08-27 20:58:46 +02:00
gtar:${ PORTSDIR } /archivers/gtar \
${ JDK13DIR } /bin/javac:${ PORTSDIR } /java/linux-jdk13 \
${ X11BASE } /lib/libMrm.a:${ PORTSDIR } /x11-toolkits/open-motif-devel
RUN_DEPENDS = javavm:${ PORTSDIR } /java/javavmwrapper
2000-10-13 14:41:25 +02:00
2001-08-27 20:58:46 +02:00
WRKSRC = ${ WRKDIR } /j2sdk1.3.1/make
2000-10-13 14:41:25 +02:00
2001-08-27 20:58:46 +02:00
JDK_VERSION = 1.3.1
2001-10-16 14:43:07 +02:00
JDK_PATCHSET_VERSION = 5
2000-10-13 14:41:25 +02:00
2001-08-27 20:58:46 +02:00
JDK13DIR ?= ${ LOCALBASE } /linux-jdk${ JDK_VERSION }
2000-10-13 14:41:25 +02:00
2000-10-14 13:58:04 +02:00
ONLY_FOR_ARCHS = i386
2000-10-13 14:41:25 +02:00
USE_GMAKE = yes
RESTRICTED = "Redistribution of pre-compiled binaries isn't permitted"
2001-08-27 20:58:46 +02:00
MAKE_ENV = ALT_BOOTDIR = " ${ JDK13DIR } " \
2000-10-13 14:41:25 +02:00
ALT_MOTIF_DIR = " ${ X11BASE } " \
OPENWINHOME = " ${ X11BASE } " \
2000-11-03 17:06:41 +01:00
SYS_CFLAGS = " ${ CFLAGS } " \
CLASSPATH = "" \
2001-08-27 20:58:46 +02:00
LD_LIBRARY_PATH = "" \
2000-11-03 17:06:41 +01:00
JAVA_COMPILER = ""
2001-08-27 20:58:46 +02:00
ALL_TARGET = all images
2001-09-10 13:43:08 +02:00
TAR = gtar # Necessary for proper extraction of sources
2001-08-27 20:58:46 +02:00
BSD_TAR = /usr/bin/tar
2000-10-13 14:41:25 +02:00
PLIST_SUB += JDK_VERSION = ${ JDK_VERSION }
2001-08-27 20:58:46 +02:00
JDKIMAGEDIR = ${ WRKSRC } /../build/bsd-i386/jdk-image-i386
JDKIMAGEDIR_G = ${ WRKSRC } /../build/bsd-i386/jdk-debug-image-i386
2000-10-13 14:41:25 +02:00
. i f d e f i n e d ( N O D E B U G )
PLIST_SUB += DEBUG:= "@comment "
PKGNAMESUFFIX = -nodebug
. e l s e
PLIST_SUB += DEBUG:= ""
. e n d i f
. i f d e f i n e d ( B A T C H ) | | d e f i n e d ( P A C K A G E _ B U I L D I N G )
IGNORE = "You can not legally distribute pre-compiled binaries"
. e n d i f
. i n c l u d e < b s d . p o r t . p r e . m k >
. f o r f i l e i n $ { D I S T F I L E S }
. i f ! e x i s t s ( $ { D I S T D I R } / $ { f i l e } )
2001-08-27 20:58:46 +02:00
IGNORE = You must manually fetch the source distribution and FreeBSD patches ( ${ DISTFILES } ) from http://www.sun.com/software/java2/download.html and http://www.eyesbeyond.com/freebsddom/java/jdk13.html, place it in ${ DISTDIR } and then run make again
2000-10-13 14:41:25 +02:00
. e n d i f
. e n d f o r
pre-patch :
2001-10-16 14:43:07 +02:00
@cd ${ WRKDIR } && \
${ MKDIR } -p j2sdk1.3.1/ext/plugin/oji-plugin/include/bsd/jdk12 && \
${ MKDIR } -p j2sdk1.3.1/ext/plugin/oji-plugin/include/solaris/navig5/private && \
${ MKDIR } -p j2sdk1.3.1/src/bsd/doc/man && \
${ PATCH } < ${ WRKDIR } /jdk131.patches
2000-10-13 14:41:25 +02:00
. i f ! d e f i n e d ( N O D E B U G )
pre-install :
@${ ECHO_MSG }
@${ ECHO_MSG } "Please use \`make -DNODEBUG' if you don't want to install libraries and binaries"
@${ ECHO_MSG } "with debugging support."
@${ ECHO_MSG }
. e n d i f
do-install :
${ MKDIR } ${ PREFIX } /jdk${ JDK_VERSION }
2001-08-27 20:58:46 +02:00
( cd ${ JDKIMAGEDIR } && ${ BSD_TAR } -c -f - .) \
| ( cd ${ PREFIX } /jdk${ JDK_VERSION } && ${ BSD_TAR } --unlink -x -f -)
2000-10-13 14:41:25 +02:00
. i f ! d e f i n e d ( N O D E B U G )
2001-08-27 20:58:46 +02:00
( cd ${ JDKIMAGEDIR_G } && ${ BSD_TAR } -c -f - .) \
| ( cd ${ PREFIX } /jdk${ JDK_VERSION } && ${ BSD_TAR } --unlink -x -f -)
2000-10-13 14:41:25 +02:00
. e n d i f
post-install :
2001-09-10 13:43:08 +02:00
${ LOCALBASE } /bin/registervm " ${ PREFIX } /jdk ${ JDK_VERSION } /bin/java # FREEBSD-JDK ${ JDK_VERSION } "
2000-10-13 14:41:25 +02:00
. i n c l u d e < b s d . p o r t . p o s t . m k >