-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbuild.xml
More file actions
168 lines (138 loc) · 6.74 KB
/
build.xml
File metadata and controls
168 lines (138 loc) · 6.74 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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
<project name="build.all"
xmlns:ivy="antlib:org.apache.ivy.ant"
default="build" >
<property name="project.name" value="builder" />
<import file="builder/builder.properties.xml" />
<import file="builder/ant-tasks.xml" />
<!-- defaults -->
<property name="test.targets" value="android-10,android-15,android-16" />
<property name="test.target" value="android-10" />
<property name="tester.filter" value="s+m+l" />
<!-- build mode -->
<target name="pre-build-mode">
</target>
<target name="debug" depends="pre-build-mode" unless="build.mode">
<property name="build.mode" value="debug" />
</target>
<target name="instrument" depends="pre-build-mode" unless="build.mode" >
<property name="build.mode" value="instrument" />
<property name="tester.coverage" value="true" />
</target>
<target name="release" depends="pre-build-mode" unless="build.mode" >
<property name="build.mode" value="release" />
</target>
<target name="post-build-mode" >
<property name="bin.dir" location="${drop.dir}/${build.mode}" />
<property name="package.dir" location="${bin.dir}/packaged" />
</target>
<target name="set-build-mode" depends="pre-build-mode, debug, post-build-mode" />
<!-- build -->
<target name="buildlist" >
<ivy:buildlist reference="all-projects">
<fileset dir="src" includes="**/build.xml" />
</ivy:buildlist>
<propertyregex property="formatted-projects"
input="${toString:all-projects}"
regexp="[;:]"
replace="${line.separator}"
global="true" />
<echo>${formatted-projects}</echo>
</target>
<target name="build" depends="set-build-mode, buildlist" >
<mkdir dir="${drop.dir}"/>
<subant target="${build.mode}" buildpathref="all-projects" />
</target>
<target name="subclean" depends="buildlist" >
<subant target="clean" buildpathref="all-projects" />
</target>
<target name="clean" depends="buildlist, subclean">
<delete dir="${drop.dir}" />
</target>
<target name="pmd" depends="buildlist, debug">
<subant target="pmd" buildpathref="all-projects" >
<property name="build.mode" value="${build.mode}" />
</subant>
</target>
<target name="cpd" depends="buildlist, debug">
<subant target="cpd" buildpathref="all-projects" >
<property name="build.mode" value="${build.mode}" />
</subant>
</target>
<target name="findbugs" depends="buildlist, debug">
<subant target="findbugs" buildpathref="all-projects" >
<property name="build.mode" value="${build.mode}" />
</subant>
</target>
<target name="lint" depends="buildlist, debug">
<subant target="lint" buildpathref="all-projects" >
<property name="build.mode" value="${build.mode}" />
</subant>
</target>
<!-- test -->
<target name="kill-all" >
<rbm-stop-all-emulators />
</target>
<target name="test" depends="set-build-mode" >
<ant antfile="${builder.dir}/test.manager.xml"
target="create-test-report" inheritall="true" inheritrefs="true">
<property name="build.mode" value="${build.mode}" />
</ant>
</target>
<target name="test-on-emulator" depends="set-build-mode">
<ant antfile="${builder.dir}/test.manager.emulator.xml"
target="test-on-emulator" inheritall="true" inheritrefs="true">
<property name="build.mode" value="${build.mode}" />
<property name="test.target" value="${test.target}" />
</ant>
</target>
<target name="test-on-all-emulators" depends="set-build-mode" >
<ant antfile="${builder.dir}/test.manager.emulator.xml"
target="test-on-all-emulators" inheritall="true" inheritrefs="true" >
<property name="build.mode" value="${build.mode}" />
<property name="test.targets" value="${test.targets}" />
</ant>
</target>
<target name="package" depends="set-build-mode" >
<property file="version.properties" />
<property name="version.file.suffix" value="v${jar.version}" />
<delete dir="${package.dir}" />
<mkdir dir="${package.dir}" />
<jarjar jarfile="${package.dir}/com.robomorphine.strictmode.jar">
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.common.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.r09.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.r11.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.r12.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.r13.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.r14.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.r15.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.r16.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.r17.jar"/>
<zipfileset src="${bin.dir}/com.robomorphine.strictmode.lib.prebuilt.r18.jar"/>
<manifest>
<attribute name="Built-By" value="${user.name}"/>
<attribute name="Implementation-Vendor" value="${vendor}"/>
<attribute name="Implementation-Title" value="robomorphine-strictmode"/>
<attribute name="Implementation-Version" value="${jar.version}"/>
</manifest>
</jarjar>
<jarjar jarfile="${package.dir}/com.robomorphine.strictmode-src.jar">
<fileset dir="${root.dir}/src/strictmode-lib/src"/>
<fileset dir="src/strictmode-lib/android-prebuilt/common/src"/>
<fileset dir="src/strictmode-lib/android-prebuilt/r09/src"/>
<fileset dir="src/strictmode-lib/android-prebuilt/r11/src"/>
<fileset dir="src/strictmode-lib/android-prebuilt/r12/src"/>
<fileset dir="src/strictmode-lib/android-prebuilt/r13/src"/>
<fileset dir="src/strictmode-lib/android-prebuilt/r14/src"/>
<fileset dir="src/strictmode-lib/android-prebuilt/r15/src"/>
<fileset dir="src/strictmode-lib/android-prebuilt/r16/src"/>
<fileset dir="src/strictmode-lib/android-prebuilt/r17/src"/>
<manifest>
<attribute name="Built-By" value="${user.name}"/>
<attribute name="Implementation-Vendor" value="${vendor}"/>
<attribute name="Implementation-Title" value="robomorphine-strictmode"/>
<attribute name="Implementation-Version" value="${jar.version}"/>
</manifest>
</jarjar>
</target>
</project>