forked from r3gis3r/CSipSimple
-
Notifications
You must be signed in to change notification settings - Fork 0
/
nightly.build.xml
121 lines (106 loc) · 3.24 KB
/
nightly.build.xml
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
<project default="trunk">
<property name="css.tmp_libs_dir" value="../tmp_libs"/>
<!-- Exclude all built libs files -->
<target name="exclude_all_libs">
<move todir="${css.tmp_libs_dir}">
<fileset dir="libs" >
<include name="*/**"/>
</fileset>
</move>
</target>
<!-- Copy libs files to project libs folder -->
<target name="use_arch">
<echo>Copy libs for ${css.arch}</echo>
<move todir="libs">
<fileset dir="${css.tmp_libs_dir}">
<include name="${css.arch}/*"/>
</fileset>
</move>
</target>
<!-- Flag csipsimple so that it is known as distributed by a channel -->
<target name="flag_channel">
<echo>Flag channel ${css.channel}</echo>
<replaceregexp file="AndroidManifest.xml"
flags="m"
match='(meta-data[\t\r\n ]*android:name="app_channel"[\t\r\n ]*android:value=")[^"]*(")'
replace='\1${css.channel}\2' />
</target>
<!-- Flag csipsimple so that it's known as a kind of distribution -->
<target name="flag_type">
<echo>Flag type ${css.type}</echo>
<replaceregexp file="AndroidManifest.xml"
flags="m"
match='(meta-data[\t\r\n ]*android:name="app_type"[\t\r\n ]*android:value=")[^"]*(")'
replace='\1${css.type}\2' />
</target>
<!-- Flag the app as a nightly build -->
<target name="nightly">
<replaceregexp file="AndroidManifest.xml"
match='android:icon="@drawable/ic_launcher_phone"'
replace='android:icon="@drawable/ic_launcher_nightly"' />
<antcall target="flag_type" >
<param name="css.type" value="nightly" />
</antcall>
</target>
<!-- Trunk build -->
<target name="trunk">
<antcall target="nightly" />
<antcall target="exclude_all_libs" />
<antcall target="use_arch" >
<param name="css.arch" value="armeabi"/>
</antcall>
<antcall target="use_arch" >
<param name="css.arch" value="armeabi-v7a"/>
</antcall>
<antcall target="use_arch" >
<param name="css.arch" value="x86"/>
</antcall>
<antcall target="flag_channel" >
<param name="css.channel" value="trunk"/>
</antcall>
</target>
<!-- Only armeabi build -->
<target name="armeabi">
<antcall target="nightly" />
<antcall target="exclude_all_libs" />
<antcall target="use_arch" >
<param name="css.arch" value="armeabi"/>
</antcall>
<antcall target="flag_channel" >
<param name="css.channel" value="armeabi"/>
</antcall>
</target>
<!-- Only armeabi-v7a build -->
<target name="armeabi-v7a">
<antcall target="nightly" />
<antcall target="exclude_all_libs" />
<antcall target="use_arch" >
<param name="css.arch" value="armeabi-v7a"/>
</antcall>
<antcall target="flag_channel" >
<param name="css.channel" value="armeabi-v7a"/>
</antcall>
</target>
<!-- Only x86 build -->
<target name="x86">
<antcall target="nightly" />
<antcall target="exclude_all_libs" />
<antcall target="use_arch" >
<param name="css.arch" value="x86"/>
</antcall>
<antcall target="flag_channel" >
<param name="css.channel" value="x86"/>
</antcall>
</target>
<!-- Only mips build -->
<target name="mips">
<antcall target="nightly" />
<antcall target="exclude_all_libs" />
<antcall target="use_arch" >
<param name="css.arch" value="mips"/>
</antcall>
<antcall target="flag_channel" >
<param name="css.channel" value="mips"/>
</antcall>
</target>
</project>