diff options
Diffstat (limited to 'docker/ant')
14 files changed, 192 insertions, 12 deletions
diff --git a/docker/ant/Dockerfile b/docker/ant/Dockerfile index 69b465e8..57a2faf9 100644 --- a/docker/ant/Dockerfile +++ b/docker/ant/Dockerfile @@ -1,10 +1,13 @@ FROM ubuntu:18.04 as downloader -ARG jdk=12 +ARG jdk=13 ADD provision/jdk/java-${jdk}.sh provision/jdk/java-${jdk}.sh RUN provision/jdk/java-${jdk}.sh -ARG ant=1.10.6 +ARG lombokjar=lombok.jar +ADD https://projectlombok.org/downloads/${lombokjar} /lombok.jar + +ARG ant=1.10.7 ADD provision/ant/ant-${ant}.sh provision/ant/ant-${ant}.sh RUN provision/ant/ant-${ant}.sh @@ -19,11 +22,11 @@ WORKDIR workspace ADD shared/ ./ -ARG jdk=12 +ARG jdk=13 ADD ant/files/jdk-${jdk} ./ -ARG lombokjar=lombok.jar -ADD https://projectlombok.org/downloads/${lombokjar} lombok.jar +COPY --from=downloader /lombok.jar /workspace/classpath/lombok.jar +COPY --from=downloader /lombok.jar /workspace/modules/lombok.jar ENV JDK_VERSION=${jdk} ENV JAVA_HOME=/opt/jdk diff --git a/docker/ant/files/jdk-10/build.xml b/docker/ant/files/jdk-10/classpath/build.xml index 3f181ed9..3f181ed9 100644 --- a/docker/ant/files/jdk-10/build.xml +++ b/docker/ant/files/jdk-10/classpath/build.xml diff --git a/docker/ant/files/jdk-10/modules/build.xml b/docker/ant/files/jdk-10/modules/build.xml new file mode 100644 index 00000000..01decd3f --- /dev/null +++ b/docker/ant/files/jdk-10/modules/build.xml @@ -0,0 +1,35 @@ +<project name="example" default="dist" basedir="."> + <property name="src" location="src/main/java"/> + <property name="build" location="build"/> + <property name="dist" location="dist"/> + <property name="build.sysclasspath" value="ignore"/> + + <target name="init"> + <tstamp/> + <mkdir dir="${build}"/> + </target> + + <target name="compile" depends="init" description="compile the source"> + <javac classpath="lombok.jar" modulepath="lombok.jar" srcdir="${src}" destdir="${build}" fork="true"> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.model=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"/> + </javac> + </target> + + <target name="dist" depends="compile" description="generate the distribution"> + <mkdir dir="${dist}/lib"/> + <jar jarfile="${dist}/lib/example-${DSTAMP}.jar" basedir="${build}"/> + </target> + + <target name="clean" description="clean up"> + <delete dir="${build}"/> + <delete dir="${dist}"/> + </target> +</project>
\ No newline at end of file diff --git a/docker/ant/files/jdk-11/classpath/build.xml b/docker/ant/files/jdk-11/classpath/build.xml new file mode 100644 index 00000000..01decd3f --- /dev/null +++ b/docker/ant/files/jdk-11/classpath/build.xml @@ -0,0 +1,35 @@ +<project name="example" default="dist" basedir="."> + <property name="src" location="src/main/java"/> + <property name="build" location="build"/> + <property name="dist" location="dist"/> + <property name="build.sysclasspath" value="ignore"/> + + <target name="init"> + <tstamp/> + <mkdir dir="${build}"/> + </target> + + <target name="compile" depends="init" description="compile the source"> + <javac classpath="lombok.jar" modulepath="lombok.jar" srcdir="${src}" destdir="${build}" fork="true"> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.model=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"/> + </javac> + </target> + + <target name="dist" depends="compile" description="generate the distribution"> + <mkdir dir="${dist}/lib"/> + <jar jarfile="${dist}/lib/example-${DSTAMP}.jar" basedir="${build}"/> + </target> + + <target name="clean" description="clean up"> + <delete dir="${build}"/> + <delete dir="${dist}"/> + </target> +</project>
\ No newline at end of file diff --git a/docker/ant/files/jdk-11/build.xml b/docker/ant/files/jdk-11/modules/build.xml index 3f181ed9..3f181ed9 100644 --- a/docker/ant/files/jdk-11/build.xml +++ b/docker/ant/files/jdk-11/modules/build.xml diff --git a/docker/ant/files/jdk-12/build.xml b/docker/ant/files/jdk-12/classpath/build.xml index 3f181ed9..3f181ed9 100644 --- a/docker/ant/files/jdk-12/build.xml +++ b/docker/ant/files/jdk-12/classpath/build.xml diff --git a/docker/ant/files/jdk-12/modules/build.xml b/docker/ant/files/jdk-12/modules/build.xml new file mode 100644 index 00000000..01decd3f --- /dev/null +++ b/docker/ant/files/jdk-12/modules/build.xml @@ -0,0 +1,35 @@ +<project name="example" default="dist" basedir="."> + <property name="src" location="src/main/java"/> + <property name="build" location="build"/> + <property name="dist" location="dist"/> + <property name="build.sysclasspath" value="ignore"/> + + <target name="init"> + <tstamp/> + <mkdir dir="${build}"/> + </target> + + <target name="compile" depends="init" description="compile the source"> + <javac classpath="lombok.jar" modulepath="lombok.jar" srcdir="${src}" destdir="${build}" fork="true"> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.model=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"/> + </javac> + </target> + + <target name="dist" depends="compile" description="generate the distribution"> + <mkdir dir="${dist}/lib"/> + <jar jarfile="${dist}/lib/example-${DSTAMP}.jar" basedir="${build}"/> + </target> + + <target name="clean" description="clean up"> + <delete dir="${build}"/> + <delete dir="${dist}"/> + </target> +</project>
\ No newline at end of file diff --git a/docker/ant/files/jdk-13/classpath/build.xml b/docker/ant/files/jdk-13/classpath/build.xml new file mode 100644 index 00000000..01decd3f --- /dev/null +++ b/docker/ant/files/jdk-13/classpath/build.xml @@ -0,0 +1,35 @@ +<project name="example" default="dist" basedir="."> + <property name="src" location="src/main/java"/> + <property name="build" location="build"/> + <property name="dist" location="dist"/> + <property name="build.sysclasspath" value="ignore"/> + + <target name="init"> + <tstamp/> + <mkdir dir="${build}"/> + </target> + + <target name="compile" depends="init" description="compile the source"> + <javac classpath="lombok.jar" modulepath="lombok.jar" srcdir="${src}" destdir="${build}" fork="true"> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.model=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"/> + </javac> + </target> + + <target name="dist" depends="compile" description="generate the distribution"> + <mkdir dir="${dist}/lib"/> + <jar jarfile="${dist}/lib/example-${DSTAMP}.jar" basedir="${build}"/> + </target> + + <target name="clean" description="clean up"> + <delete dir="${build}"/> + <delete dir="${dist}"/> + </target> +</project>
\ No newline at end of file diff --git a/docker/ant/files/jdk-13/build.xml b/docker/ant/files/jdk-13/modules/build.xml index 3f181ed9..3f181ed9 100644 --- a/docker/ant/files/jdk-13/build.xml +++ b/docker/ant/files/jdk-13/modules/build.xml diff --git a/docker/ant/files/jdk-8/build.xml b/docker/ant/files/jdk-8/classpath/build.xml index 2fc38879..2fc38879 100644 --- a/docker/ant/files/jdk-8/build.xml +++ b/docker/ant/files/jdk-8/classpath/build.xml diff --git a/docker/ant/files/jdk-8/modules/readme.txt b/docker/ant/files/jdk-8/modules/readme.txt new file mode 100644 index 00000000..89aea537 --- /dev/null +++ b/docker/ant/files/jdk-8/modules/readme.txt @@ -0,0 +1 @@ +unsupported
\ No newline at end of file diff --git a/docker/ant/files/jdk-9/build.xml b/docker/ant/files/jdk-9/classpath/build.xml index 3f181ed9..3f181ed9 100644 --- a/docker/ant/files/jdk-9/build.xml +++ b/docker/ant/files/jdk-9/classpath/build.xml diff --git a/docker/ant/files/jdk-9/modules/build.xml b/docker/ant/files/jdk-9/modules/build.xml new file mode 100644 index 00000000..01decd3f --- /dev/null +++ b/docker/ant/files/jdk-9/modules/build.xml @@ -0,0 +1,35 @@ +<project name="example" default="dist" basedir="."> + <property name="src" location="src/main/java"/> + <property name="build" location="build"/> + <property name="dist" location="dist"/> + <property name="build.sysclasspath" value="ignore"/> + + <target name="init"> + <tstamp/> + <mkdir dir="${build}"/> + </target> + + <target name="compile" depends="init" description="compile the source"> + <javac classpath="lombok.jar" modulepath="lombok.jar" srcdir="${src}" destdir="${build}" fork="true"> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.model=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED"/> + <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"/> + </javac> + </target> + + <target name="dist" depends="compile" description="generate the distribution"> + <mkdir dir="${dist}/lib"/> + <jar jarfile="${dist}/lib/example-${DSTAMP}.jar" basedir="${build}"/> + </target> + + <target name="clean" description="clean up"> + <delete dir="${build}"/> + <delete dir="${dist}"/> + </target> +</project>
\ No newline at end of file diff --git a/docker/ant/readme.md b/docker/ant/readme.md index 8983213e..7dce84e3 100644 --- a/docker/ant/readme.md +++ b/docker/ant/readme.md @@ -2,29 +2,30 @@ [_(general configuration and options)_](../readme.md) -### `ARG ant=1.10.6` +### `ARG ant=1.10.7` The ant version to be used. Supported values: -- `1.10.6` (default) -- `1.10.1` (default) +- `1.10.7` (default) +- `1.10.6` +- `1.10.1` ## Example build commands: (To be executed from the `<lombokhome>/docker` directory) ``` -docker build -t lombok-ant-jdk12 -f ant/Dockerfile . +docker build -t lombok-ant-jdk13 -f ant/Dockerfile . -docker build -t lombok-ant-jdk12 --build-arg lombokjar=lombok-1.16.20.jar -f ant/Dockerfile . +docker build -t lombok-ant-jdk13 --build-arg lombokjar=lombok-1.16.20.jar -f ant/Dockerfile . ``` ## Example run commands: ``` -docker run -it lombok-ant-jdk12 +docker run -it lombok-ant-jdk13 -docker run --rm -it -v /<lombokhome>/dist/lombok.jar:/workspace/lombok.jar lombok-ant-jdk12 +docker run --rm -it -v /<lombokhome>/dist/lombok.jar:/workspace/lombok.jar lombok-ant-jdk13 ``` ## Example container commands: |