Skip to content

Commit 062a1dc

Browse files
authored
Update external sub target dist to upper level as a common target (#5939)
* Copy Dockefile to TEST_ROOT Signed-off-by: Sophia Guo <[email protected]> * Move comment job to uplevel Signed-off-by: Sophia Guo <[email protected]> * Try not use antcall Signed-off-by: Sophia Guo <[email protected]> * Update dist target and move to upper level as a common target Also remove unused targets Signed-off-by: Sophia Guo <[email protected]> * Only archive Dockerfile under jvmtest Signed-off-by: Sophia Guo <[email protected]> --------- Signed-off-by: Sophia Guo <[email protected]>
1 parent dddcbec commit 062a1dc

File tree

33 files changed

+41
-375
lines changed

33 files changed

+41
-375
lines changed

buildenv/jenkins/JenkinsfileBase

+1-1
Original file line numberDiff line numberDiff line change
@@ -933,7 +933,7 @@ def post(output_name) {
933933
}
934934

935935
if (env.BUILD_LIST.startsWith('external')) {
936-
archiveFile("**/Dockerfile.*", true)
936+
archiveFile("**/jvmtest/**/Dockerfile.*", true)
937937
}
938938

939939
if (params.ARCHIVE_TEST_RESULTS && !env.JDK_VERSION.contains(',') && env.BUILD_LIST.contains('jck')) {

external/aot/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
1814
<target name="prepare_base_image" depends="move_scripts,clean_image" description="prepare the base image">
1915
<echo message="Executing external.sh --prepare --dir ${TEST} --tag ${dockerImageTag} --version ${JDK_VERSION} --impl ${JDK_IMPL} --base_docker_registry_url 'docker.io' --base_docker_registry_dir 'default' --docker_args ${extra_docker_args} " />
2016
<exec executable="bash" failonerror="true">
@@ -37,13 +33,5 @@
3733
</exec>
3834
</target>
3935

40-
<target name="dist" depends="prepare_base_image" description="generate the distribution">
41-
<copy todir="${DEST}">
42-
<fileset dir="${src}" includes="*.xml, *.mk, *.sh"/>
43-
</copy>
44-
</target>
45-
46-
<target name="build">
47-
<antcall target="dist" inheritall="true" />
48-
</target>
36+
<target name="build" depends="prepare_base_image, copy_dest" />
4937
</project>

external/build.xml

+8
Original file line numberDiff line numberDiff line change
@@ -114,4 +114,12 @@
114114
<arg value="${extra_docker_args}"/>
115115
</exec>
116116
</target>
117+
<target name="copy_dest" >
118+
<copy todir="${DEST}">
119+
<fileset dir="${src}" includes="*.xml, *.mk, *.sh"/>
120+
</copy>
121+
<copy todir="${src}">
122+
<fileset dir="${DEST}" includes="**/Dockerfile.*"/>
123+
</copy>
124+
</target>
117125
</project>

external/camel/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="move_scripts,clean_image,build_image,copy_dest" />
2715
</project>

external/criu-functional/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
1814
<target name="prepare_base_image" depends="move_scripts,clean_image" description="prepare the base image">
1915
<echo message="Executing external.sh --prepare --dir ${TEST} --tag ${dockerImageTag} --version ${JDK_VERSION} --impl ${JDK_IMPL} --base_docker_registry_url 'docker.io' --base_docker_registry_dir 'default' --docker_args ${extra_docker_args} " />
2016
<exec executable="bash" failonerror="true">
@@ -37,13 +33,5 @@
3733
</exec>
3834
</target>
3935

40-
<target name="dist" depends="prepare_base_image,build_image" description="generate the distribution">
41-
<copy todir="${DEST}">
42-
<fileset dir="${src}" includes="*.xml, *.mk"/>
43-
</copy>
44-
</target>
45-
46-
<target name="build">
47-
<antcall target="dist" inheritall="true" />
48-
</target>
36+
<target name="build" depends="prepare_base_image,build_image,copy_dest" />
4937
</project>

external/criu-portable-checkpoint/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
1814
<target name="prepare_base_image" depends="move_scripts,clean_image" description="prepare the base image">
1915
<echo message="Executing external.sh --prepare --dir ${TEST} --tag ${dockerImageTag} --version ${JDK_VERSION} --impl ${JDK_IMPL} --base_docker_registry_url 'docker.io' --base_docker_registry_dir 'default' --docker_args ${extra_docker_args} " />
2016
<exec executable="bash" failonerror="true">
@@ -37,13 +33,5 @@
3733
</exec>
3834
</target>
3935

40-
<target name="dist" depends="prepare_base_image,build_image" description="generate the distribution">
41-
<copy todir="${DEST}">
42-
<fileset dir="${src}" includes="*.xml, *.mk"/>
43-
</copy>
44-
</target>
45-
46-
<target name="build">
47-
<antcall target="dist" inheritall="true" />
48-
</target>
36+
<target name="build" depends="prepare_base_image,build_image,copy_dest" />
4937
</project>

external/criu-portable-restore/build.xml

+1-12
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,6 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
14+
<target name="build" depends="move_scripts,clean_image,copy_dest" />
1715

18-
<target name="dist" depends="move_scripts,clean_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
2716
</project>

external/criu-ubi-portable-checkpoint/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
1814
<target name="prepare_base_image" depends="move_scripts,clean_image" description="prepare the base image">
1915
<echo message="Executing external.sh --prepare --dir ${TEST} --tag ${dockerImageTag} --version ${JDK_VERSION} --impl ${JDK_IMPL} --base_docker_registry_url '${env.DOCKER_REGISTRY_URL}' --base_docker_registry_dir 'ubi8-with-criu/${env.SPEC}-ubi8-criu' --docker_args ${extra_docker_args} " />
2016
<exec executable="bash" failonerror="true">
@@ -59,13 +55,5 @@
5955
</exec>
6056
</target>
6157

62-
<target name="dist" depends="build_image" description="generate the distribution">
63-
<copy todir="${DEST}">
64-
<fileset dir="${src}" includes="*.xml, *.mk"/>
65-
</copy>
66-
</target>
67-
68-
<target name="build">
69-
<antcall target="dist" inheritall="true" />
70-
</target>
58+
<target name="build" depends="build_image, copy_dest" />
7159
</project>

external/criu-ubi-portable-restore/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="move_scripts,clean_image,copy_dest" />
2715
</project>

external/criu/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk, *.sh"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="copy_dest" />
2715
</project>

external/derby/build.xml

+1-5
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,7 @@
1515
<mkdir dir="${DEST}"/>
1616
</target>
1717

18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
18+
<target name="dist" depends="move_scripts,clean_image,build_image,copy_dest" description="generate the distribution" />
2319

2420
<target name="build">
2521
<!-- Temporarily disable for openj9 and ibm due to ibm_git/runtimes/infrastructure/issues/6056 -->

external/elasticsearch/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="move_scripts,clean_image,build_image,copy_dest" />
2715
</project>

external/external_custom/build.xml

+1-9
Original file line numberDiff line numberDiff line change
@@ -24,15 +24,7 @@
2424
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
2525
<property name="src" location="." />
2626

27-
<target name="init">
28-
<mkdir dir="${DEST}"/>
29-
</target>
30-
31-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
32-
<copy todir="${DEST}">
33-
<fileset dir="${src}" includes="*.xml, *.mk"/>
34-
</copy>
35-
</target>
27+
<target name="dist" depends="move_scripts,clean_image,build_image,copy_dest" description="generate the distribution" />
3628

3729
<target name="build">
3830
<if>

external/functional-test/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="move_scripts,clean_image,build_image,copy_dest" />
2715
</project>

external/jacoco/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="move_scripts,clean_image,build_image,copy_dest" />
2715
</project>

external/jenkins/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build" >
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="move_scripts,clean_image,build_image,copy_dest" />
2715
</project>

external/kafka/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="move_scripts,clean_image,build_image,copy_dest" />
2715
</project>

external/lucene-solr/build.xml

+1-9
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,7 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
14+
<target name="dist" depends="move_scripts,clean_image,build_image,copy_dest" description="generate the distribution" />
2315

2416
<target name="build">
2517
<!-- Temporarily disable for openj9 and ibm due to ibm_git/runtimes/infrastructure/issues/6056 -->

external/netty/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="move_scripts,clean_image,build_image,copy_dest" />
2715
</project>

external/openliberty-mp-tck/build.xml

+2-6
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,8 @@
1515
<mkdir dir="${DEST}"/>
1616
</target>
1717

18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
18+
<target name="dist" depends="move_scripts,clean_image,build_image,copy_dest" description="generate the distribution" />
19+
2420
<target name="build">
2521
<!-- Temporarily disable for openj9 and ibm due to ibm_git/runtimes/infrastructure/issues/6056 -->
2622
<if>

external/payara-mp-tck/build.xml

+1-13
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,5 @@
1111
<property name="DEST" value="${BUILD_ROOT}/external/${TEST}" />
1212
<property name="src" location="." />
1313

14-
<target name="init">
15-
<mkdir dir="${DEST}"/>
16-
</target>
17-
18-
<target name="dist" depends="move_scripts,clean_image,build_image" description="generate the distribution">
19-
<copy todir="${DEST}">
20-
<fileset dir="${src}" includes="*.xml, *.mk"/>
21-
</copy>
22-
</target>
23-
24-
<target name="build">
25-
<antcall target="dist" inheritall="true" />
26-
</target>
14+
<target name="build" depends="move_scripts,clean_image,build_image,copy_dest" />
2715
</project>

0 commit comments

Comments
 (0)