source: trunk/abcl/ci/create-abcl-properties.bash @ 15378

Last change on this file since 15378 was 15378, checked in by Mark Evenson, 2 years ago

Patches and CI changes for running on openjdk15

Use openjdk15 as latest version instead of openjdk14 under Travis CI.

Allow for java.version that reports an integer without a patchlevel
which is needed for running openjdk15.

File size: 1.7 KB
Line 
1#!/usr/bin/env bash
2DIR="$(cd -P "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
3
4jdk=$1
5if [[ -z $jdk ]]; then
6    jdk=openjdk8
7fi
8
9root="${DIR}/.."
10prop_in="${root}/abcl.properties.in"
11prop_out="${root}/abcl.properties"
12echo "Configuring for $jdk from <${prop_in}>."
13
14# Unused
15# zgc="-XX:+UnlockExperimentalVMOptions -XX:+UseZGC -Xmx<size> -Xlog:gc"
16
17abcl_javac_source=1.8
18case $jdk in
19    6|openjdk6)
20        options="-d64 -XX:+CMSClassUnloadingEnabled -XX:MaxPermSize=1g -XX:+UseConcMarkSweepGC"
21        abcl_javac_target=1.6
22  abcl_javac_source=1.6
23        ;;
24    7|openjdk7)
25  options="-d64 -XX:+UseG1GC"
26        abcl_javac_target=1.7
27  abcl_javac_source=1.7
28  ;;
29    8|openjdk8)
30        options="-XX:+UseG1GC -XX:+AggressiveOpts -XX:CompileThreshold=10"
31  abcl_javac_target=1.8
32  abcl_javac_source=1.8
33        ;;
34    11|openjdk11)
35        options="-XX:CompileThreshold=10"
36  abcl_javac_target=11
37  abcl_javac_source=1.8
38        ;;
39    # untested: weakly unsupported
40    12|openjdk12)
41        options="-XX:CompileThreshold=10"
42  abcl_javac_target=12
43  abcl_javac_source=1.8
44        ;;
45    13|openjdk13)
46        options="-XX:CompileThreshold=10"
47  abcl_javac_target=13
48  abcl_javac_source=1.8
49        ;;
50    14|openjdk14)
51        options="-XX:CompileThreshold=10 ${zgc}"
52  abcl_javac_target=14
53  abcl_javac_source=1.8
54        ;;
55    15|openjdk15)
56        options="-XX:CompileThreshold=10 ${zgc}"
57  abcl_javac_target=15
58  abcl_javac_source=1.8
59        ;;
60esac
61
62cat ${root}/abcl.properties.in \
63    | awk -F = \
64    -v options="$options" \
65    -v target="$abcl_javac_target" \
66    -v source="$abcl_javac_source" \
67       -f ${DIR}/create-abcl-properties.awk \
68  > ${root}/abcl.properties
69
70echo "Finished configuring for $jdk into <${prop_out}>."
Note: See TracBrowser for help on using the repository browser.