FreeBSD Bugzilla – Attachment 204640 Details for
Bug 237054
java/openjdk11: Needs to be integrated into bsd.java.mk
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
patch for bsd.default-versions.mk and bsd.java.mk
bsd_mk.patch (text/plain), 9.05 KB, created by
Tommy P
on 2019-05-27 04:41:48 UTC
(
hide
)
Description:
patch for bsd.default-versions.mk and bsd.java.mk
Filename:
MIME Type:
Creator:
Tommy P
Created:
2019-05-27 04:41:48 UTC
Size:
9.05 KB
patch
obsolete
>--- bsd.default-versions.mk.ori 2019-05-26 15:40:04.521450000 -0700 >+++ bsd.default-versions.mk 2019-05-26 17:06:12.971350000 -0700 >@@ -47,6 +47,8 @@ > GCC_DEFAULT?= 8 > # Possible values: 7, 8, 9, agpl > GHOSTSCRIPT_DEFAULT?= agpl >+# Possible values: 1.6 1.7 1.8 11 12 - defaults to latest LTS >+JAVA_DEFAULT?=11 > # Possible values: 2.0.0 > LAZARUS_DEFAULT?= 2.0.0 > .if ${ARCH} == amd64 >--- bsd.java.mk.ori 2019-05-25 22:50:03.353710000 -0700 >+++ bsd.java.mk 2019-05-26 21:13:09.651507000 -0700 >@@ -25,7 +25,7 @@ > # > # JAVA_VERSION List of space-separated suitable java versions for the > # port. An optional "+" allows you to specify a range of >-# versions. (allowed values: 1.6[+] 1.7[+] 1.8[+]) >+# versions. (allowed values: 1.6[+] 1.7[+] 1.8[+] 11[+] 12[+]) > # > # JAVA_OS List of space-separated suitable JDK port operating systems > # for the port. (allowed values: native linux) >@@ -52,9 +52,9 @@ > #------------------------------------------------------------------------------- > # Variables defined for the port: > # >-# JAVA_PORT The name of the JDK port. (e.g. 'java/openjdk6') >+# JAVA_PORT The name of the JDK port. (e.g. 'java/openjdk11') > # >-# JAVA_PORT_VERSION The version of the JDK port. (e.g. '1.6') >+# JAVA_PORT_VERSION The version of the JDK port. (e.g. '11') > # > # JAVA_PORT_OS The operating system used by the JDK port. (e.g. 'linux') > # >@@ -67,23 +67,24 @@ > # (e.g. 'OpenJDK BSD Porting Team') > # > # JAVA_HOME Path to the installation directory of the JDK. (e.g. >-# '/usr/local/openjdk6') >+# '/usr/local/openjdk11') > # > # JAVAC Path to the Java compiler to use. (e.g. >-# '/usr/local/openjdk6/bin/javac' or '/usr/local/bin/javac') >+# '/usr/local/openjdk11/bin/javac' or '/usr/local/bin/javac') > # > # JAR Path to the JAR tool to use. (e.g. >-# '/usr/local/openjdk6/bin/jar' or '/usr/local/bin/fastjar') >+# '/usr/local/openjdk11/bin/jar' or '/usr/local/bin/fastjar') > # > # APPLETVIEWER Path to the appletviewer utility. (e.g. > # '/usr/local/linux-jdk1.7.0/bin/appletviewer') > # > # JAVA Path to the java executable. Use this for executing Java >-# programs. (e.g. '/usr/local/openjdk6/bin/java') >+# programs. (e.g. '/usr/local/openjdk11/bin/java') > # > # JAVADOC Path to the javadoc utility program. > # > # JAVAH Path to the javah program. >+# Removed in Java 10 > # > # JAVAP Path to the javap program. > # >@@ -114,8 +115,8 @@ > #------------------------------------------------------------------------------- > # Porter's hints > # >-# To retrieve the Major version number from JAVA_PORT_VERSION (e.g. "1.6"): >-# -> ${JAVA_PORT_VERSION:C/^([0-9])\.([0-9])(.*)$/\1.\2/} >+# To retrieve the Major version number from JAVA_PORT_VERSION (e.g. "11"): >+# -> ${JAVA_PORT_VERSION:C/^([0-9]+(\.[0-9])?)(.*)/\1/} > # > #------------------------------------------------------------------------------- > # There are the following stages: >@@ -159,39 +160,41 @@ > . endif > > # The complete list of Java versions, os and vendors supported. >-__JAVA_VERSION_LIST= 1.6 1.7 1.8 1.9 >+__JAVA_VERSION_LIST= 1.6 1.7 1.8 11 12 > _JAVA_VERSION_LIST= ${__JAVA_VERSION_LIST} ${__JAVA_VERSION_LIST:S/$/+/} > _JAVA_OS_LIST= native linux >-_JAVA_VENDOR_LIST= openjdk oracle sun >+_JAVA_VENDOR_LIST= openjdk oracle > > # Set all meta-information about JDK ports: > # port location, corresponding JAVA_HOME, JDK version, OS, vendor > _JAVA_PORT_NATIVE_OPENJDK_JDK_1_6_INFO= PORT=java/openjdk6 HOME=${LOCALBASE}/openjdk6 \ >- VERSION=1.6.0 OS=native VENDOR=openjdk >+ VERSION=1.6 OS=native VENDOR=openjdk > _JAVA_PORT_NATIVE_OPENJDK_JDK_1_7_INFO= PORT=java/openjdk7 HOME=${LOCALBASE}/openjdk7 \ >- VERSION=1.7.0 OS=native VENDOR=openjdk >+ VERSION=1.7 OS=native VENDOR=openjdk > _JAVA_PORT_NATIVE_OPENJDK_JDK_1_8_INFO= PORT=java/openjdk8 HOME=${LOCALBASE}/openjdk8 \ >- VERSION=1.8.0 OS=native VENDOR=openjdk >+ VERSION=1.8 OS=native VENDOR=openjdk >+_JAVA_PORT_NATIVE_OPENJDK_JDK_11_INFO= PORT=java/openjdk11 HOME=${LOCALBASE}/openjdk11 \ >+ VERSION=11 OS=native VENDOR=openjdk >+_JAVA_PORT_NATIVE_OPENJDK_JDK_12_INFO= PORT=java/openjdk12 HOME=${LOCALBASE}/openjdk12 \ >+ VERSION=12 OS=native VENDOR=openjdk > _JAVA_PORT_LINUX_ORACLE_JDK_1_8_INFO= PORT=java/linux-oracle-jdk18 HOME=${LOCALBASE}/linux-oracle-jdk1.8.0 \ >- VERSION=1.8.0 OS=linux VENDOR=oracle >-_JAVA_PORT_LINUX_ORACLE_JDK_1_9_INFO= PORT=java/linux-oracle-jdk9 HOME=${LOCALBASE}/linux-oracle-jdk9 \ >- VERSION=1.9.0 OS=linux VENDOR=oracle >+ VERSION=1.8 OS=linux VENDOR=oracle > > # Verbose description for each VENDOR > _JAVA_VENDOR_openjdk= "OpenJDK BSD Porting Team" > _JAVA_VENDOR_oracle= Oracle >-_JAVA_VENDOR_sun= Sun > > # Verbose description for each OS > _JAVA_OS_native= Native > _JAVA_OS_linux= Linux > > # List all JDK ports in order of preference >-__JAVA_PORTS_ALL= JAVA_PORT_NATIVE_OPENJDK_JDK_1_8 \ >+__JAVA_PORTS_ALL= JAVA_PORT_NATIVE_OPENJDK_JDK_12 \ >+ JAVA_PORT_NATIVE_OPENJDK_JDK_11 \ >+ JAVA_PORT_NATIVE_OPENJDK_JDK_1_8 \ > JAVA_PORT_NATIVE_OPENJDK_JDK_1_7 \ > JAVA_PORT_NATIVE_OPENJDK_JDK_1_6 \ >- JAVA_PORT_LINUX_ORACLE_JDK_1_8 \ >- JAVA_PORT_LINUX_ORACLE_JDK_1_9 >+ JAVA_PORT_LINUX_ORACLE_JDK_1_8 > _JAVA_PORTS_ALL= ${JAVA_PREFERRED_PORTS} \ > ${__JAVA_PORTS_ALL} > >@@ -217,6 +220,7 @@ > > # Error checking: JAVA_VERSION > .if defined(JAVA_VERSION) >+JAVA_VERSION_MIN= ${JAVA_VERSION:S/+//} > .if !defined(_JAVA_VERSION_LIST_REGEXP) > _JAVA_VERSION_LIST_REGEXP= ${_JAVA_VERSION_LIST:C/\+/\\+/:ts|} > .endif >@@ -224,6 +228,11 @@ > check-makevars:: > @( test ! -z "${JAVA_VERSION}" && ( ${ECHO_CMD} "${JAVA_VERSION}" | ${TR} " " "\n" | ${GREP} -Eq "${_JAVA_VERSION_LIST_REGEXP}")) || \ > (${ECHO_CMD} "${PKGNAME}: Makefile error: \"${JAVA_VERSION}\" is not a valid value for JAVA_VERSION. It should be one or more of: ${__JAVA_VERSION_LIST} (with an optional \"+\" suffix.)"; ${FALSE}) >+# warn user if JAVA_DEFAULT is less than JAVA_VERSION_MIN and that would be using JAVA_VERSION_MIN instead for the port >+ @( test ${JAVA_DEFAULT} < ${JAVA_VERSION_MIN} && ( ${ECHO_CMD} "${JAVA_DEFAULT} is less than required port version ${JAVA_VERSION_MIN}. Using version the port's required version ${JAVA_VERSION_MIN} instead."); ${TRUE}) >+. if ${JAVA_DEFAULT} < ${JAVA_VERSION_MIN} >+JAVA_DEFAULT= ${JAVA_VERSION_MIN} >+. endif > .endif > > # Error checking: JAVA_VENDOR >@@ -264,7 +273,7 @@ > . undef _JAVA_PORTS_INSTALLED > . undef _JAVA_PORTS_POSSIBLE > . if defined(JAVA_VERSION) >-_JAVA_VERSION= ${JAVA_VERSION:S/1.6+/1.6 1.7+/:S/1.7+/1.7 1.8+/:S/1.8+/1.8 1.9+/:S/1.9+/1.9/} >+_JAVA_VERSION= ${JAVA_VERSION:S/1.6+/1.6 1.7+/:S/1.7+/1.7 1.8+/:S/1.8+/1.8 11+/:S/11+/11 12+/:S/12+/12/} > . else > _JAVA_VERSION= ${__JAVA_VERSION_LIST} > . endif >@@ -282,7 +291,7 @@ > . for A_JAVA_PORT in ${_JAVA_PORTS_ALL} > A_JAVA_PORT_INFO:= ${A_JAVA_PORT:S/^/\${_/:S/$/_INFO}/} > A_JAVA_PORT_HOME= ${A_JAVA_PORT_INFO:MHOME=*:S,HOME=,,} >-A_JAVA_PORT_VERSION= ${A_JAVA_PORT_INFO:MVERSION=*:C/VERSION=([0-9])\.([0-9])(.*)/\1.\2/} >+A_JAVA_PORT_VERSION= ${A_JAVA_PORT_INFO:MVERSION=*:C/VERSION=([0-9]+(\.[0-9])?)(.*)/\1/} > A_JAVA_PORT_OS= ${A_JAVA_PORT_INFO:MOS=*:S,OS=,,} > A_JAVA_PORT_VENDOR= ${A_JAVA_PORT_INFO:MVENDOR=*:S,VENDOR=,,} > .if !defined(_JAVA_PORTS_INSTALLED) && exists(${A_JAVA_PORT_HOME}/${_JDK_FILE}) >@@ -317,7 +326,6 @@ > # Find an installed JDK port that matches the requirements of the port > > . undef _JAVA_PORTS_INSTALLED_POSSIBLE >- > . for A_JAVA_PORT in ${_JAVA_PORTS_POSSIBLE} > __JAVA_PORTS_INSTALLED_POSSIBLE+= ${_JAVA_PORTS_INSTALLED:M${A_JAVA_PORT}} > . endfor >@@ -326,6 +334,7 @@ > . if ${_JAVA_PORTS_INSTALLED_POSSIBLE} != "" > . for i in ${_JAVA_PORTS_INSTALLED_POSSIBLE} > . if !defined(_JAVA_PORTS_INSTALLED_POSSIBLE_shortcircuit) >+# possibly add logic to upgrade / downgrade JDK for some scenarios? > _JAVA_PORT= $i > _JAVA_PORTS_INSTALLED_POSSIBLE_shortcircuit= 1 > . endif >@@ -335,7 +344,11 @@ > . for i in ${_JAVA_PORTS_POSSIBLE} > . if !defined(_JAVA_PORTS_POSSIBLE_shortcircuit) > _JAVA_PORT= $i >+_JAVA_PORT_INFO:= ${_JAVA_PORT:S/^/\${_/:S/$/_INFO}/} >+_JAVA_PORT_VERSION= ${_JAVA_PORT_INFO:MVERSION=*:S,VERSION=,,} >+. if ${JAVA_DEFAULT} == ${_JAVA_PORT_VERSION} > _JAVA_PORTS_POSSIBLE_shortcircuit= 1 >+. endif > . endif > . endfor > . endif >@@ -419,6 +432,7 @@ > JAR?= ${JAVA_HOME}/bin/jar > JAVA?= ${JAVA_HOME}/bin/java > JAVADOC?= ${JAVA_HOME}/bin/javadoc >+# javah removed in Java 10 > JAVAH?= ${JAVA_HOME}/bin/javah > JAVAP?= ${JAVA_HOME}/bin/javap > JAVA_N2A?= ${JAVA_HOME}/bin/native2ascii >@@ -447,6 +461,9 @@ > @${ECHO_CMD} "JAVA_RUN= ${JAVA_RUN}" > @${ECHO_CMD} "JAVA_EXTRACT= ${JAVA_EXTRACT}" > @${ECHO_CMD} >+ @${ECHO_CMD} "JAVA_VERSION_MIN= ${JAVA_VERSION_MIN}" >+ @${ECHO_CMD} "JAVA_DEFAULT= ${JAVA_DEFAULT}" >+ @${ECHO_CMD} > @${ECHO_CMD} "# JDK port dependency selection process:" > @${ECHO_CMD} "_JAVA_PORTS_POSSIBLE= ${_JAVA_PORTS_POSSIBLE}" > @${ECHO_CMD} "_JAVA_PORTS_INSTALLED= ${_JAVA_PORTS_INSTALLED}"
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 237054
:
204462
|
204463
| 204640 |
204819