|
37 | 37 | $jdk_version_splitted = split($jdk_version, 'u') |
38 | 38 | $jdk_version_major = $jdk_version_splitted[0] |
39 | 39 | $jdk_version_update = $jdk_version_splitted[1] |
40 | | - # Support of different JDK8 versions with different binary pathes |
41 | | - if Integer($jdk_version_update) >= 371 { |
| 40 | + # Support of different JDK8 versions with different binary patches |
| 41 | + if Integer($jdk_version_update) >= 421 { |
| 42 | + $java_home_path = "/usr/lib/jvm/jdk-1.${jdk_version_major}.0_${jdk_version_update}-oracle-x64" |
| 43 | + $libjvm_content_path = "${java_home_path}/jre/lib/amd64/server/\n" |
| 44 | + $cacert_path = "${java_home_path}/jre/lib/security/cacerts" |
| 45 | + } elsif Integer($jdk_version_update) >= 371 and Integer($jdk_version_update) < 421 { |
42 | 46 | $java_home_path = "/usr/lib/jvm/jdk-1.${jdk_version_major}-oracle-x64" |
43 | 47 | $libjvm_content_path = "${java_home_path}/jre/lib/amd64/server/\n" |
44 | 48 | $cacert_path = "${java_home_path}/jre/lib/security/cacerts" |
|
63 | 67 | # to receive JDK version 11.0.9 |
64 | 68 | $jdk_version_raw = split($jdk_filename_splitted[1], '_') |
65 | 69 | $jdk_version = $jdk_version_raw[0] |
66 | | - $java_home_path = "/usr/java/jdk-${jdk_version}" |
67 | | - $libjvm_content_path = "${java_home_path}/lib/server/\n" |
68 | | - $cacert_path = "${java_home_path}/lib/security/cacerts" |
| 70 | + $jdk_version_splitted = split($jdk_version, '\.') # 11.0.9 |
| 71 | + $jdk_version_major = $jdk_version_splitted[0] |
| 72 | + $jdk_version_minor = $jdk_version_splitted[1] |
| 73 | + $jdk_version_patch = $jdk_version_splitted[2] |
| 74 | + # Support of different JDK8 versions with different binary patches |
| 75 | + if Integer($jdk_version_patch) >= 24 { |
| 76 | + $java_home_path = "/usr/lib/jvm/jdk-${jdk_version}-oracle-x64" |
| 77 | + $libjvm_content_path= "${java_home_path}/lib/server/\n" |
| 78 | + $cacert_path = "${java_home_path}/lib/security/cacerts" |
| 79 | + } else { |
| 80 | + $java_home_path = "/usr/java/jdk-${jdk_version}" |
| 81 | + $libjvm_content_path= "${java_home_path}/lib/server/\n" |
| 82 | + $cacert_path = "${java_home_path}/lib/security/cacerts" |
| 83 | + } |
69 | 84 | } |
70 | 85 | default: { |
71 | 86 | fail('Error: Unknown Java Version. Supported java versions are : ( 8 | 11 )') |
|
0 commit comments