2007-11-09 10:27:55 -05:00
|
|
|
# $OpenBSD: Makefile,v 1.10 2007/11/09 15:27:55 kurt Exp $
|
2007-05-08 13:06:18 -04:00
|
|
|
|
|
|
|
SHARED_ONLY= Yes
|
|
|
|
ONLY_FOR_ARCHS= i386 amd64
|
|
|
|
|
2007-09-15 22:52:56 -04:00
|
|
|
COMMENT-main= Java2(TM) Standard Edition Dev Kit v${V}
|
|
|
|
COMMENT-jre= Java2(TM) Standard Edition Runtime Environment v${V}
|
2007-05-08 13:06:18 -04:00
|
|
|
V= 1.7.0
|
2007-09-06 11:46:18 -04:00
|
|
|
B= b19
|
|
|
|
D= 30_aug_2007
|
2007-07-13 18:52:35 -04:00
|
|
|
DISTFILES= jdk-7-ea-src-${B}-jrl-${D}.jar \
|
2007-09-06 11:46:18 -04:00
|
|
|
jdk-7-ea-bin-${B}-jrl-${D}.jar
|
2007-07-13 18:52:35 -04:00
|
|
|
PKGNAME= jdk-${V}.${B}
|
2007-11-06 22:53:53 -05:00
|
|
|
PKGNAME-main= jdk-${V}.${B}p0
|
|
|
|
PKGNAME-jre= jre-${V}.${B}p0
|
2007-05-08 13:06:18 -04:00
|
|
|
|
|
|
|
CATEGORIES= devel/jdk java
|
|
|
|
|
2007-09-06 11:46:18 -04:00
|
|
|
MULTI_PACKAGES= -main -jre
|
|
|
|
|
|
|
|
FLAVORS= with_ipv6
|
|
|
|
FLAVOR?=
|
|
|
|
|
2007-07-13 18:52:35 -04:00
|
|
|
HOMEPAGE= https://jdk7.dev.java.net/
|
2007-09-06 11:46:18 -04:00
|
|
|
MASTER_SITES= http://www.java.net/download/jdk7/ \
|
2007-11-07 12:17:41 -05:00
|
|
|
http://www.java.net/download/jdk7/archive/$B/ \
|
2007-09-06 11:46:18 -04:00
|
|
|
http://www.intricatesoftware.com/distfiles/
|
2007-05-08 13:06:18 -04:00
|
|
|
|
|
|
|
MAINTAINER= Kurt Miller <kurt@openbsd.org>
|
|
|
|
|
2007-07-13 18:52:35 -04:00
|
|
|
# Java Research License
|
|
|
|
# http://www.java.net/jrl.csp
|
2007-09-15 22:52:56 -04:00
|
|
|
PERMIT_PACKAGE_CDROM= JRL
|
|
|
|
PERMIT_PACKAGE_FTP= JRL
|
|
|
|
PERMIT_DISTFILES_CDROM= JRL
|
|
|
|
PERMIT_DISTFILES_FTP= JRL
|
2007-05-08 13:06:18 -04:00
|
|
|
|
|
|
|
NO_REGRESS= Yes
|
|
|
|
|
2007-09-06 11:46:18 -04:00
|
|
|
BUILD_DEPENDS= :jdk-1.5.0*:devel/jdk/1.5 \
|
2007-07-13 18:52:35 -04:00
|
|
|
::archivers/zip \
|
2007-09-06 11:46:18 -04:00
|
|
|
::archivers/unzip \
|
|
|
|
::print/cups
|
2007-05-08 13:06:18 -04:00
|
|
|
USE_MOTIF= openmotif
|
|
|
|
MODULES= converters/libiconv
|
2007-09-06 11:46:18 -04:00
|
|
|
WANTLIB= X11 Xext Xi Xp Xt Xtst c freetype m ossaudio \
|
|
|
|
pthread stdc++
|
2007-05-08 13:06:18 -04:00
|
|
|
|
|
|
|
USE_GMAKE= Yes
|
|
|
|
|
|
|
|
ALT_BOOTDIR= ${LOCALBASE}/jdk-1.5.0
|
|
|
|
|
|
|
|
MAKE_ENV= ALT_BOOTDIR=${ALT_BOOTDIR} \
|
2007-09-06 11:46:18 -04:00
|
|
|
ALT_MOTIF_DIR=${LOCALBASE} \
|
|
|
|
ALT_FREETYPE_HEADERS_PATH=${X11BASE}/include \
|
|
|
|
ALT_FREETYPE_LIB_PATH=${X11BASE}/lib \
|
|
|
|
SKIP_COMPARE_IMAGES=true \
|
|
|
|
BUILD_INSTALL=false \
|
|
|
|
NO_DOCS=true \
|
|
|
|
CC="${CC}" \
|
|
|
|
CXX="${CXX}" \
|
2007-05-08 13:06:18 -04:00
|
|
|
DEFAULT_LIBPATH="/usr/lib:${X11BASE}/lib:${LOCALBASE}/lib" \
|
|
|
|
USERNAME=${USER} \
|
2007-09-06 11:46:18 -04:00
|
|
|
HOTSPOT_BUILD_JOBS=`sysctl -n hw.ncpu` \
|
|
|
|
SKIP_FASTDEBUG_BUILD=true \
|
|
|
|
BUILD_DEPLOY=false \
|
|
|
|
USE_FREETYPE=true
|
2007-05-08 13:06:18 -04:00
|
|
|
|
2007-09-06 11:46:18 -04:00
|
|
|
.if !${FLAVOR:L:Mwith_ipv6}
|
|
|
|
MAKE_ENV+= DONT_ENABLE_IPV6="YES"
|
|
|
|
.endif
|
2007-05-08 13:06:18 -04:00
|
|
|
|
2007-09-06 11:46:18 -04:00
|
|
|
JDKHOME= jdk-1.7.0
|
|
|
|
JREHOME= jre-1.7.0
|
|
|
|
|
|
|
|
SUBST_VARS= JDKHOME JREHOME
|
2007-05-08 13:06:18 -04:00
|
|
|
|
2007-07-13 18:52:35 -04:00
|
|
|
WRKDIST= ${WRKDIR}
|
2007-09-06 11:46:18 -04:00
|
|
|
WRKBUILD= ${WRKDIST}/control/make
|
|
|
|
JVMARCH= ${MACHINE_ARCH:S/i386/i586/}
|
|
|
|
JDKIMAGEDIR= ${WRKDIST}/control/build/bsd-${JVMARCH}/j2sdk-image
|
|
|
|
JREIMAGEDIR= ${WRKDIST}/control/build/bsd-${JVMARCH}/j2re-image
|
2007-05-08 13:06:18 -04:00
|
|
|
|
|
|
|
.if ${MACHINE_ARCH} == "i386"
|
|
|
|
PKG_ARGS+= -Dclient_vm=1
|
|
|
|
.else
|
|
|
|
PKG_ARGS+= -Dclient_vm=0
|
|
|
|
.endif
|
|
|
|
|
2007-07-13 18:52:35 -04:00
|
|
|
COPYDIRS= hotspot/src/os/linux/launcher \
|
|
|
|
hotspot/src/os/linux/vm \
|
|
|
|
hotspot/src/os_cpu/linux_amd64/vm \
|
|
|
|
hotspot/src/os_cpu/linux_i486/vm \
|
|
|
|
hotspot/build/linux \
|
|
|
|
hotspot/build/linux/makefiles \
|
|
|
|
install/make/installer/binaries/linux \
|
2007-09-06 11:46:18 -04:00
|
|
|
j2se/src/linux/doc/man
|
2007-07-13 18:52:35 -04:00
|
|
|
|
|
|
|
COPYFILES= control/make/common/Defs-linux.gmk \
|
|
|
|
install/make/common/Defs-linux.gmk \
|
|
|
|
j2se/make/common/Defs-linux.gmk \
|
|
|
|
j2se/make/common/shared/Defs-linux.gmk \
|
|
|
|
j2se/make/java/nio/mapfile-linux \
|
|
|
|
j2se/make/netbeans/common/architectures/name-Linux.properties \
|
|
|
|
j2se/make/sun/awt/mapfile-vers-linux \
|
|
|
|
j2se/make/tools/sharing/classlist.linux \
|
|
|
|
j2se/src/closed/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.properties \
|
|
|
|
j2se/src/closed/solaris/native/com/sun/media/sound/engine/HAE_API_LinuxOS.c \
|
|
|
|
j2se/src/closed/solaris/native/com/sun/media/sound/engine/HAE_API_LinuxOS_Capture.c \
|
|
|
|
j2se/src/solaris/classes/java/lang/UNIXProcess.java.linux \
|
|
|
|
j2se/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.properties \
|
|
|
|
j2se/src/solaris/classes/sun/tools/attach/LinuxAttachProvider.java \
|
2007-09-06 11:46:18 -04:00
|
|
|
j2se/src/solaris/hpi/include/largefile_linux.h
|
|
|
|
|
|
|
|
.include <bsd.own.mk>
|
|
|
|
|
|
|
|
ACCEPT_JRL_LICENSE ?= No
|
|
|
|
|
|
|
|
.if ${ACCEPT_JRL_LICENSE:L} != "yes"
|
2007-11-09 10:27:55 -05:00
|
|
|
BROKEN += \n
|
|
|
|
BROKEN += You must read and accept Sun's JRL license located\n
|
|
|
|
BROKEN += at ${FILESDIR}/JavaResearchLicense.txt\n
|
|
|
|
BROKEN += To indicate your acceptance of the JRL add ACCEPT_JRL_LICENSE=Yes\n
|
|
|
|
BROKEN += to /etc/mk.conf and restart the build
|
2007-09-06 11:46:18 -04:00
|
|
|
.endif
|
2007-07-13 18:52:35 -04:00
|
|
|
|
|
|
|
do-extract:
|
2007-09-06 11:46:18 -04:00
|
|
|
@rm -rf ${WRKDIR}/tmp && mkdir ${WRKDIR}/tmp && \
|
2007-07-13 18:52:35 -04:00
|
|
|
${CC} ${CFLAGS} -o ${WRKDIR}/tmp/x_x2zip ${FILESDIR}/x_x2zip.c
|
|
|
|
.for jar in ${DISTFILES}
|
|
|
|
@cd ${WRKDIR}/tmp && \
|
|
|
|
unzip -qo ${FULLDISTDIR}/${jar} X_X && \
|
|
|
|
./x_x2zip "YES I ACCEPT THE CLICK THROUGH LICENSE. " X_X && \
|
|
|
|
cd ${WRKDIR} && \
|
|
|
|
unzip -q ${WRKDIR}/tmp/X_X.zip -x */lib*.so
|
|
|
|
.endfor
|
|
|
|
@rm -rf ${WRKDIR}/tmp
|
|
|
|
|
|
|
|
# create initial bsd src from linux src (except for threads_solaris.c)
|
2007-05-08 13:06:18 -04:00
|
|
|
pre-patch:
|
|
|
|
@for d in ${COPYDIRS}; do \
|
|
|
|
mkdir -p `echo ${WRKDIST}/$$d | sed 's/linux/bsd/g;'`; \
|
|
|
|
cd ${WRKDIST}/$$d; \
|
|
|
|
for f in *; do \
|
|
|
|
if [ -f $$f ]; then \
|
|
|
|
t=`echo ${WRKDIST}/$$d/$$f | sed 's/linux/bsd/g;'`; \
|
|
|
|
sed 's/linux/bsd/g; s/Linux/Bsd/g' < $$f > $$t; \
|
|
|
|
fi; \
|
|
|
|
done; \
|
|
|
|
done
|
2007-07-13 18:52:35 -04:00
|
|
|
@for f in ${COPYFILES}; do \
|
|
|
|
t=`echo $$f | sed 's/linux/bsd/g; s/Linux/Bsd/g'`; \
|
|
|
|
sed 's/linux/bsd/g; s/Linux/Bsd/g' < ${WRKDIST}/$$f > ${WRKDIST}/$$t; \
|
|
|
|
done
|
|
|
|
@sed 's/solaris/bsd/g; s/Solaris/Bsd/g' \
|
|
|
|
< ${WRKDIST}/j2se/src/solaris/hpi/native_threads/src/threads_solaris.c \
|
|
|
|
> ${WRKDIST}/j2se/src/solaris/hpi/native_threads/src/threads_bsd.c
|
2007-05-08 13:06:18 -04:00
|
|
|
|
2007-09-06 11:46:18 -04:00
|
|
|
post-build:
|
|
|
|
@rm -rf ${JDKIMAGEDIR}/man/ja \
|
|
|
|
${JDKIMAGEDIR}/man/ja_JP.eucJP \
|
|
|
|
${JREIMAGEDIR}/man/ja \
|
|
|
|
${JREIMAGEDIR}/man/ja_JP.eucJP
|
|
|
|
|
2007-05-08 13:06:18 -04:00
|
|
|
do-install:
|
|
|
|
${INSTALL_DATA_DIR} ${PREFIX}/${JDKHOME}
|
2007-09-06 11:46:18 -04:00
|
|
|
cd ${JDKIMAGEDIR} && tar -cf - * | tar -C ${PREFIX}/${JDKHOME} -xf -
|
|
|
|
${INSTALL_DATA_DIR} ${PREFIX}/${JREHOME}
|
|
|
|
cd ${JREIMAGEDIR} && tar -cf - * | tar -C ${PREFIX}/${JREHOME} -xf -
|
|
|
|
|
2007-05-08 13:06:18 -04:00
|
|
|
|
|
|
|
.include <bsd.port.mk>
|