-
Notifications
You must be signed in to change notification settings - Fork 3
/
android.xml
39 lines (36 loc) · 1.61 KB
/
android.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
<?xml version="1.0" encoding="UTF-8" standalone="no"?><!DOCTYPE project>
<project default="android-compile" name="Android Compiler">
<mkdir dir="build/" />
<property name="androidBat" value="build/android-sdk-windows/tools/android.bat" />
<property name="androidtarget" value="1" />
<target name="InitProject">
<record name="build/android.txt" action="start" append="false" />
<available file="build/android.zip" property="isAvailable" />
</target>
<target name="download" depends="InitProject" unless="isAvailable">
<echo>SDK missing</echo>
<get description="get Android-SDK" src="http://dl.google.com/android/android-sdk_r24.4.1-windows.zip" dest="build/android.zip" />
<unzip src="build/android.zip" dest="build" />
<exec executable="cmd">
<arg value="/C"/>
<arg line="echo y | call ${androidBat} update sdk -u -s"/>
</exec>
</target>
<target name="sdkExist" depends="InitProject" if="isAvailable">
<echo>SDK exists</echo>
<echo>Create Project</echo>
<exec executable="${androidBat}">
<!--<arg line="list targets"/>-->
<arg line="create project -n NetworkParser -p build/NetworkParserAndroid -t android-23 -k de.uniks.networkparser -a NPApp"/>
</exec>
</target>
<target name="android-compile" depends="download, sdkExist" description="Compile NetworkParser to Android">
<delete dir="build/NetworkParserAndroid/src"></delete>
<mkdir dir="build/NetworkParserAndroid/src" />
<copy todir="build/NetworkParserAndroid/src">
<fileset dir="src/main/java/">
</fileset>
</copy>
<ant antfile="build.xml" target="debug" inheritrefs="true" dir="build/NetworkParserAndroid/" />
</target>
</project>