Changeset 15259


Ignore:
Timestamp:
04/28/20 06:37:35 (2 years ago)
Author:
Mark Evenson
Message:

build: support abcl.properties creation openjdk{6,7,8,11,13,14}

Additionally add test for openjdk14 to the Travis-CI build.

Improve script for creating build properties, which may be invoked
like:

bash ci/create-abcl-properties.bash openjdk8

Currently this script has baked-in "knowledge" of options for various
platforms for now, but will eventually directly transcribe from the
"facts" in <file:abcl.rdf>.

  • * *

Update RDF

Location:
trunk/abcl
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/abcl/.travis.yml

    r15256 r15259  
    2828  - ABCL_JDK=openjdk8
    2929  - ABCL_JDK=openjdk11
     30  - ABCL_JDK=openjdk14
    3031
    3132install:
  • trunk/abcl/README

    r15197 r15259  
    14214264bit desktop/server machine running Java 8 or 11.  The file contains
    143143incomplete documentation on how it may be edited for subsequent
    144 customization.
     144customization.  As an alternative to copying the prototype, if one has
     145a version of bash locally, one may issue via Ant
     146
     147    ant abcl.properties.autoconfigure.openjdk.11
     148
     149or from the shell as
     150
     151    bash ci/create-abcl-properties.bash openjdk11
     152
     153Currently upported platforms are 'openjdk6', 'openjdk7', 'openjdk8',
     154'openjdk11', 'openjdk13', and 'openjdk14'.
    145155
    146156
  • trunk/abcl/abcl.properties.in

    r15254 r15259  
    2727
    2828#<>
     29# <java/runtime> ( openjdk11, openjdk13, openjdk14 ) ;
     30#
     31#java.options=-XX:+UnlockExperimentalVMOptions -XX:+UseZGC -Xmx<size> -Xlog:gc
     32
     33#<>
    2934#  <java/runtime> openjdk11 ;
    3035#  rdfs:seeAlso <https://blog.gceasy.io/2020/03/18/7-jvm-arguments-of-highly-effective-applications/> ;
    31 #java.options=-XX:+UseZGC
     36#java.options=-XX:CompileThreshold=10
    3237
    3338#<>
  • trunk/abcl/abcl.rdf

    r15221 r15259  
    179179[abcl:run _:supported]
    180180  a rdf:Bag ;
    181   rdf:_6   java:6 ;
    182   rdf:_7   java:7 ;
    183   rdf:_8   java:8 ;
    184   rdf:_11  java:11 ;
    185 
    186 rdfs:comment """
    187 Compatible Java runtimes.
    188 """ .
     181  rdf:_6   openjdk:6 ;
     182  rdf:_7   openjdk:7 ;
     183  rdf:_8   openjdk:8 ;
     184  rdf:_11  openjdk:11 ;
     185  rdf:_13  openjdk:13 ;
     186  rdf:_14  openjdk:14 ;
     187  rdfs:comment "Compatible Java runtimes" .
     188
     189[abcl:run _:options]
     190  :base "-XShowSettings:vm -DFile.encoding="UTF-8";
     191  openjdk:6
     192  openjdk:8 "-XX:+AggressiveOpts" ;
     193  openjdk:11 "-XX:CompileThreshold=10" ;
     194  openjdk:13 "-XX:CompileThreshold=10" ;
     195  openjdk:14 "-XX:CompileThreshold=10" ;
     196  rdfs:comment "Java platform runtime options" .
     197
     198[abcl:build _:options]
     199   :target "1.8" ;
     200   :source "1.6" ;
     201   :encoding "UTF-8" ;
     202   :debug "true" ;
     203   rdfs:comment "Java build options" .
    189204
    190205[abcl:build _:supported]
    191206  a rdf:Bag ;
    192   rdf:_8   java:8 ;
    193   rdf:_11  java:11 ;
    194 
    195 rdfs:comment """
    196 Platforms on which building is most supported. 
    197 """ .
     207  rdf:_6   openjdk:6 ;
     208  rdf:_6     :deprecated ;       
     209  rdf:_7   openjdk:7 ;
     210  rdf:_7     :deprecated ;       
     211  rdf:_8   openjdk:8 ;
     212  rdf:_8     :deprecated ;       
     213  rdf:_11  openjdk:11 ;
     214  rdf:_13  openjdk:13 ;
     215  rdf:_14  openjdk:14 ;
     216  rdfs:comment "Supported build platforms" .
     217
    198218
    199219 
  • trunk/abcl/build.xml

    r15255 r15259  
    12451245    </target>
    12461246
     1247    <target name="abcl.properties.autoconfigure.openjdk.11">
     1248      <exec executable="/usr/bin/env">
     1249        <arg value="bash"/>
     1250        <arg value="ci/create-abcl-properties.bash"/>
     1251       
     1252        <arg value="openjdk11"/>
     1253      </exec>
     1254    </target>
     1255         
    12471256    <import file="etc/ant/netbeans-build.xml"
    12481257            optional="true"/>
  • trunk/abcl/ci/create-abcl-properties.bash

    r15256 r15259  
    11#!/usr/bin/env bash
     2DIR="$(cd -P "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
    23
    34jdk=$1
     
    67fi
    78
     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
    818case $jdk in
    9     openjdk8)
     19    6|openjdk6)
     20        options="-d64 -XX:+CMSClassUnloadingEnabled -XX:MaxPermSize=1g -XX:+UseConcMarkSweepGC"
     21        abcl_javac_source=1.6
     22        ;;
     23    7|openjdk7)
     24  options="-d64 -XX:+UseG1GC"
     25        abcl_javac_source=1.7
     26  ;;
     27    8|openjdk8)
    1028        options="-XX:+UseG1GC -XX:+AggressiveOpts -XX:CompileThreshold=10"
    1129        ;;
    12     openjdk11)
     30    11|openjdk11)
    1331        options="-XX:CompileThreshold=10"
     32        ;;
     33    # untested: weakly unsupported
     34    12|openjdk12)
     35        options="-XX:CompileThreshold=10"
     36        ;;
     37    13|openjdk13)
     38        options="-XX:CompileThreshold=10"
     39        ;;
     40    14|openjdk14)
     41        options="-XX:CompileThreshold=10 ${zgc}"
    1442        ;;
    1543esac
    1644
    17 cat abcl.properties.in | awk -F = -v options="$options" '/^java.options/ {print $0 " " options; next}; {print $0}' > abcl.properties
     45cat ${root}/abcl.properties.in | awk -F = -v options="$options" -v source="$abcl_javac_source" '/^java.options/ {print $0 " " options; next}; /^abcl.javac.source/ {print "abcl.javac.source=" source; next}; {print $0}' > ${root}/abcl.properties
    1846
     47echo "Finished configuring for $jdk into <${prop_out}>."
  • trunk/abcl/ci/install-adoptjdk.bash

    r15250 r15259  
    2525                    dist="https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.6%2B10/OpenJDK11U-jdk_x64_mac_hotspot_11.0.6_10.tar.gz"
    2626                    ;;
     27                openjdk14)
     28                    topdir=jdk-14.0.1+7
     29                    dist="https://github.com/AdoptOpenJDK/openjdk14-binaries/releases/download/jdk-14.0.1%2B7/OpenJDK14U-jdk_x64_mac_hotspot_14.0.1_7.tar.gz"
     30                    ;;
    2731            esac
    2832            ;;
     
    3640                    topdir=jdk-11.0.6+10
    3741                    dist="https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.6%2B10/OpenJDK11U-jdk_x64_linux_hotspot_11.0.6_10.tar.gz"
     42                    ;;
     43                openjdk14)
     44                    topdir=jdk-14.0.1+7
     45                    dist="https://github.com/AdoptOpenJDK/openjdk14-binaries/releases/download/jdk-14.0.1%2B7/OpenJDK14U-jdk_x64_linux_hotspot_14.0.1_7.tar.gz"
    3846                    ;;
    3947            esac
Note: See TracChangeset for help on using the changeset viewer.