-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbuild.xml
More file actions
81 lines (67 loc) · 2.9 KB
/
Copy pathbuild.xml
File metadata and controls
81 lines (67 loc) · 2.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project basedir="." default="clean_build" name="offline-signer">
<property name="workspace" value="."/>
<property name="source" value="${workspace}/src"/>
<property name="dependencies" value="${workspace}/lib"/>
<property name="build-dir" value="${workspace}/build"/>
<property name="built-sources" value="${build-dir}/main"/>
<property name="built-jar" value="${workspace}/dist"/>
<property name="jar-name" value="offline-signer"/>
<property name="test" value="${workspace}/test"/>
<property name="test-reports" value="${workspace}/reports"/>
<property name="built-tests" value="${build-dir}/test"/>
<path id="classpath-test">
<pathelement location="${dependencies}/aion-types-22a3be9.jar"/>
<pathelement location="${dependencies}/util4j-674e4b5.jar"/>
<pathelement location="${dependencies}/guava-25.1-jre.jar"/>
<pathelement location="${dependencies}/junit-4.12.jar"/>
<pathelement location="${dependencies}/hamcrest-all-1.3.jar"/>
<pathelement location="${dependencies}/ed25519.jar"/>
<pathelement location="${dependencies}/modRlp.jar"/>
</path>
<target name="clean_build" depends="clean, build"/>
<target name="test_build" depends="clean_build">
<mkdir dir="${built-tests}"/>
<javac debug="true" debuglevel="source,lines,vars" includeantruntime="false" release="10"
srcdir="${test}" destdir="${built-tests}" includes="**/*.java,module-info.java">
<classpath>
<pathelement location="${built-sources}"/>
<path refid="classpath-test"/>
</classpath>
</javac>
</target>
<target name="test" depends="test_build">
<mkdir dir="${test-reports}"/>
<junit printsummary="on" haltonfailure="true" fork="true" dir="${workspace}">
<classpath>
<pathelement location="${built-sources}"/>
<pathelement location="${built-tests}"/>
<path refid="classpath-test"/>
</classpath>
<formatter type="plain" usefile="false"/>
<formatter type="xml"/>
<batchtest todir="${test-reports}">
<fileset dir="${test}" includes="**/*Test.java"/>
</batchtest>
</junit>
</target>
<target name="build">
<mkdir dir="${built-sources}"/>
<javac debug="true" debuglevel="source,lines,vars" includeantruntime="false" release="10" srcdir="${source}" destdir="${built-sources}" includes="**/*.java,module-info.java">
<modulepath>
<pathelement location="${dependencies}/ed25519.jar"/>
<pathelement location="${dependencies}/modRlp.jar"/>
</modulepath>
</javac>
<jar destfile="${built-sources}/${jar-name}.jar" filesetmanifest="mergewithoutmain" basedir="${built-sources}"/>
<move includeemptydirs="false" todir="${built-jar}">
<file file="${built-sources}/${jar-name}.jar"/>
</move>
<echo message=" "/>
<echo message="Newly built jar can be found at: ${built-jar}/${jar-name}.jar"/>
</target>
<target name="clean">
<delete dir="${build-dir}"/>
<delete dir="${built-jar}"/>
</target>
</project>