summaryrefslogtreecommitdiffstats
path: root/java
diff options
context:
space:
mode:
authorphantom <phantom@FreeBSD.org>2003-11-12 12:38:03 +0000
committerphantom <phantom@FreeBSD.org>2003-11-12 12:38:03 +0000
commit326d7af4e0a93d436e1ee2faf5d80eb4d36e2592 (patch)
treefd581daa55769640bc63cc6eaed169735a4f9071 /java
parent6dbaf7f641272137fca4f343e6386f9add920987 (diff)
downloadFreeBSD-ports-326d7af4e0a93d436e1ee2faf5d80eb4d36e2592.zip
FreeBSD-ports-326d7af4e0a93d436e1ee2faf5d80eb4d36e2592.tar.gz
Fix bootstrap jdk detection process, so it work in case if no valid jdk
installed. Previously BUILD_DEPENDS was not set correctly. Add all possible choices for 1.4.1/1.4.2 JDKs while auto-detecting.
Diffstat (limited to 'java')
-rw-r--r--java/jdk14/Makefile15
-rw-r--r--java/jdk15/Makefile15
-rw-r--r--java/jdk16/Makefile15
3 files changed, 33 insertions, 12 deletions
diff --git a/java/jdk14/Makefile b/java/jdk14/Makefile
index 7ca61b4..a9c405a 100644
--- a/java/jdk14/Makefile
+++ b/java/jdk14/Makefile
@@ -33,6 +33,8 @@ WRKSRC= ${WRKDIR}/control/make
JDK_VERSION= 1.4.2
JDK_PATCHSET_VERSION= 5
+SUN_LINUX_JDK_VERSION= 1.4.2_02
+
.if !defined(WITH_LINUX_BOOTSTRAP)
NATIVE_BOOTSTRAP_JDKS= ${LOCALBASE}/jdk1.4.2 \
${LOCALBASE}/jdk1.4.1
@@ -41,10 +43,13 @@ NATIVE_BOOTSTRAP_JDKS= ${LOCALBASE}/jdk1.4.2 \
LINUX_BOOTSTRAP_JDKS= ${LOCALBASE}/linux-sun-jdk1.4.2_02 \
${LOCALBASE}/linux-sun-jdk1.4.2_01 \
${LOCALBASE}/linux-sun-jdk1.4.2 \
+ ${LOCALBASE}/linux-sun-jdk1.4.1_02 \
+ ${LOCALBASE}/linux-sun-jdk1.4.1_01 \
${LOCALBASE}/linux-sun-jdk1.4.1
.include <bsd.port.pre.mk>
+# do we have valid native jdk installed?
.if !defined(WITH_LINUX_BOOTSTRAP)
.for CJDK in ${NATIVE_BOOTSTRAP_JDKS}
. if !defined(JDK14DIR) && exists(${CJDK}/bin/javac)
@@ -53,21 +58,23 @@ JDK14DIR= ${CJDK}
.endfor
.endif
+# do we have valid linux jdk installed?
.if !defined(JDK14DIR)
-_NEED_BOOTSRAP_JDK= YES
.for CJDK in ${LINUX_BOOTSTRAP_JDKS}
. if !defined(JDK14DIR) && exists(${CJDK}/bin/javac)
JDK14DIR= ${CJDK}
WITH_LINUX_BOOTSTRAP= YES
-.undef NEED_BOOTSTRAP_JDK
. endif
.endfor
.endif
-.if defined(_NEED_BOOTSTRAP_JDK)
-BUILD_DEPENDS+= ${JDK14DIR}/bin/javac:${PORTSDIR}/java/linux-sun-jdk14
+# if no valid jdk found, set dependency
+.if !defined(JDK14DIR)
+JDK14DIR?= ${LOCALBASE}/linux-sun-jdk${SUN_LINUX_JDK_VERSION}
.endif
+BUILD_DEPENDS+= ${JDK14DIR}/bin/javac:${PORTSDIR}/java/linux-sun-jdk14
+
# workaround to handle both 'zip' and 'tar.gz' distfiles
USE_ZIP= YES
USE_REINPLACE= YES
diff --git a/java/jdk15/Makefile b/java/jdk15/Makefile
index 7ca61b4..a9c405a 100644
--- a/java/jdk15/Makefile
+++ b/java/jdk15/Makefile
@@ -33,6 +33,8 @@ WRKSRC= ${WRKDIR}/control/make
JDK_VERSION= 1.4.2
JDK_PATCHSET_VERSION= 5
+SUN_LINUX_JDK_VERSION= 1.4.2_02
+
.if !defined(WITH_LINUX_BOOTSTRAP)
NATIVE_BOOTSTRAP_JDKS= ${LOCALBASE}/jdk1.4.2 \
${LOCALBASE}/jdk1.4.1
@@ -41,10 +43,13 @@ NATIVE_BOOTSTRAP_JDKS= ${LOCALBASE}/jdk1.4.2 \
LINUX_BOOTSTRAP_JDKS= ${LOCALBASE}/linux-sun-jdk1.4.2_02 \
${LOCALBASE}/linux-sun-jdk1.4.2_01 \
${LOCALBASE}/linux-sun-jdk1.4.2 \
+ ${LOCALBASE}/linux-sun-jdk1.4.1_02 \
+ ${LOCALBASE}/linux-sun-jdk1.4.1_01 \
${LOCALBASE}/linux-sun-jdk1.4.1
.include <bsd.port.pre.mk>
+# do we have valid native jdk installed?
.if !defined(WITH_LINUX_BOOTSTRAP)
.for CJDK in ${NATIVE_BOOTSTRAP_JDKS}
. if !defined(JDK14DIR) && exists(${CJDK}/bin/javac)
@@ -53,21 +58,23 @@ JDK14DIR= ${CJDK}
.endfor
.endif
+# do we have valid linux jdk installed?
.if !defined(JDK14DIR)
-_NEED_BOOTSRAP_JDK= YES
.for CJDK in ${LINUX_BOOTSTRAP_JDKS}
. if !defined(JDK14DIR) && exists(${CJDK}/bin/javac)
JDK14DIR= ${CJDK}
WITH_LINUX_BOOTSTRAP= YES
-.undef NEED_BOOTSTRAP_JDK
. endif
.endfor
.endif
-.if defined(_NEED_BOOTSTRAP_JDK)
-BUILD_DEPENDS+= ${JDK14DIR}/bin/javac:${PORTSDIR}/java/linux-sun-jdk14
+# if no valid jdk found, set dependency
+.if !defined(JDK14DIR)
+JDK14DIR?= ${LOCALBASE}/linux-sun-jdk${SUN_LINUX_JDK_VERSION}
.endif
+BUILD_DEPENDS+= ${JDK14DIR}/bin/javac:${PORTSDIR}/java/linux-sun-jdk14
+
# workaround to handle both 'zip' and 'tar.gz' distfiles
USE_ZIP= YES
USE_REINPLACE= YES
diff --git a/java/jdk16/Makefile b/java/jdk16/Makefile
index 7ca61b4..a9c405a 100644
--- a/java/jdk16/Makefile
+++ b/java/jdk16/Makefile
@@ -33,6 +33,8 @@ WRKSRC= ${WRKDIR}/control/make
JDK_VERSION= 1.4.2
JDK_PATCHSET_VERSION= 5
+SUN_LINUX_JDK_VERSION= 1.4.2_02
+
.if !defined(WITH_LINUX_BOOTSTRAP)
NATIVE_BOOTSTRAP_JDKS= ${LOCALBASE}/jdk1.4.2 \
${LOCALBASE}/jdk1.4.1
@@ -41,10 +43,13 @@ NATIVE_BOOTSTRAP_JDKS= ${LOCALBASE}/jdk1.4.2 \
LINUX_BOOTSTRAP_JDKS= ${LOCALBASE}/linux-sun-jdk1.4.2_02 \
${LOCALBASE}/linux-sun-jdk1.4.2_01 \
${LOCALBASE}/linux-sun-jdk1.4.2 \
+ ${LOCALBASE}/linux-sun-jdk1.4.1_02 \
+ ${LOCALBASE}/linux-sun-jdk1.4.1_01 \
${LOCALBASE}/linux-sun-jdk1.4.1
.include <bsd.port.pre.mk>
+# do we have valid native jdk installed?
.if !defined(WITH_LINUX_BOOTSTRAP)
.for CJDK in ${NATIVE_BOOTSTRAP_JDKS}
. if !defined(JDK14DIR) && exists(${CJDK}/bin/javac)
@@ -53,21 +58,23 @@ JDK14DIR= ${CJDK}
.endfor
.endif
+# do we have valid linux jdk installed?
.if !defined(JDK14DIR)
-_NEED_BOOTSRAP_JDK= YES
.for CJDK in ${LINUX_BOOTSTRAP_JDKS}
. if !defined(JDK14DIR) && exists(${CJDK}/bin/javac)
JDK14DIR= ${CJDK}
WITH_LINUX_BOOTSTRAP= YES
-.undef NEED_BOOTSTRAP_JDK
. endif
.endfor
.endif
-.if defined(_NEED_BOOTSTRAP_JDK)
-BUILD_DEPENDS+= ${JDK14DIR}/bin/javac:${PORTSDIR}/java/linux-sun-jdk14
+# if no valid jdk found, set dependency
+.if !defined(JDK14DIR)
+JDK14DIR?= ${LOCALBASE}/linux-sun-jdk${SUN_LINUX_JDK_VERSION}
.endif
+BUILD_DEPENDS+= ${JDK14DIR}/bin/javac:${PORTSDIR}/java/linux-sun-jdk14
+
# workaround to handle both 'zip' and 'tar.gz' distfiles
USE_ZIP= YES
USE_REINPLACE= YES
OpenPOWER on IntegriCloud