summaryrefslogtreecommitdiffstats
path: root/tools/scripts
diff options
context:
space:
mode:
authorPiotr Gurgul <pgurgul@google.com>2009-08-24 23:06:56 -0700
committerPiotr Gurgul <pgurgul@google.com>2009-08-24 23:06:56 -0700
commit2968aa302061af725e26e69eb3e88d746d9b7a0d (patch)
tree985e94a1f4e8520308a1eb739bb97d29f18e0ef2 /tools/scripts
parent424b833edfc655cb8e23fd508a3b0d0a8968ab55 (diff)
downloadandroid_development-2968aa302061af725e26e69eb3e88d746d9b7a0d.tar.gz
android_development-2968aa302061af725e26e69eb3e88d746d9b7a0d.tar.bz2
android_development-2968aa302061af725e26e69eb3e88d746d9b7a0d.zip
Ant properties names changed
application-package to application.package sdk-location to sdk.dir android-jar to android.jar android-aidl to android.aidl in order to make their names compliant with the ant standards and rest of the property names. Properties names in alias rules deliberately ommited in this CL. Some minor style changes introduced.
Diffstat (limited to 'tools/scripts')
-rw-r--r--tools/scripts/android_rules.xml52
-rw-r--r--tools/scripts/build.template16
2 files changed, 34 insertions, 34 deletions
diff --git a/tools/scripts/android_rules.xml b/tools/scripts/android_rules.xml
index b8a53806d..4d41cae3c 100644
--- a/tools/scripts/android_rules.xml
+++ b/tools/scripts/android_rules.xml
@@ -6,7 +6,7 @@
com.android.ant.AndroidInitTask
The following properties are put in place by the importing task:
- android-jar, android-aidl, aapt, aidl, and dx
+ android.jar, android.aidl, aapt, aidl, and dx
Additionnaly, the task sets up the following classpath reference:
android.target.classpath
@@ -16,15 +16,15 @@
<!-- Custom tasks -->
<taskdef name="aaptexec"
classname="com.android.ant.AaptExecLoopTask"
- classpathref="android.antlibs"/>
+ classpathref="android.antlibs" />
<taskdef name="apkbuilder"
classname="com.android.ant.ApkBuilderTask"
- classpathref="android.antlibs"/>
+ classpathref="android.antlibs" />
<!-- Properties -->
- <property name="android.tools.dir" location="${sdk-location}/tools" />
+ <property name="android.tools.dir" location="${sdk.dir}/tools" />
<!-- Input directories -->
<property name="source.dir" location="src" />
@@ -45,22 +45,22 @@
<!-- Out directory for a parent project if this project is an instrumentation project -->
<property name="main.out.dir" location="../${out.dir}" />
- <property name="main.out.classes.dir" location="${main.out.dir}/classes"/>
+ <property name="main.out.classes.dir" location="${main.out.dir}/classes" />
<!-- Intermediate files -->
<property name="dex.file.name" value="classes.dex" />
<property name="intermediate.dex.file" location="${out.dir}/${dex.file.name}" />
<!-- The final package file to generate -->
- <property name="out.debug.unaligned.package" location="${out.dir}/${ant.project.name}-debug-unaligned.apk"/>
- <property name="out.debug.package" location="${out.dir}/${ant.project.name}-debug.apk"/>
- <property name="out.unsigned.package" location="${out.dir}/${ant.project.name}-unsigned.apk"/>
- <property name="out.unaligned.package" location="${out.dir}/${ant.project.name}-unaligned.apk"/>
- <property name="out.release.package" location="${out.dir}/${ant.project.name}-release.apk"/>
+ <property name="out.debug.unaligned.package" location="${out.dir}/${ant.project.name}-debug-unaligned.apk" />
+ <property name="out.debug.package" location="${out.dir}/${ant.project.name}-debug.apk" />
+ <property name="out.unsigned.package" location="${out.dir}/${ant.project.name}-unsigned.apk" />
+ <property name="out.unaligned.package" location="${out.dir}/${ant.project.name}-unaligned.apk" />
+ <property name="out.release.package" location="${out.dir}/${ant.project.name}-release.apk" />
<!-- Tools -->
- <condition property="exe" value=".exe" else=""><os family="windows"/></condition>
- <property name="adb" location="${android.tools.dir}/adb${exe}"/>
+ <condition property="exe" value=".exe" else=""><os family="windows" /></condition>
+ <property name="adb" location="${android.tools.dir}/adb${exe}" />
<property name="zipalign" location="${android.tools.dir}/zipalign${exe}" />
<!-- Rules -->
@@ -88,7 +88,7 @@
<arg value="-S" />
<arg path="${resource.dir}" />
<arg value="-I" />
- <arg path="${android-jar}" />
+ <arg path="${android.jar}" />
</exec>
</target>
@@ -96,11 +96,11 @@
<target name="-aidl" depends="-dirs">
<echo>Compiling aidl files into Java classes...</echo>
<apply executable="${aidl}" failonerror="true">
- <arg value="-p${android-aidl}" />
+ <arg value="-p${android.aidl}" />
<arg value="-I${source.dir}" />
<arg value="-o${gen.dir}" />
<fileset dir="${source.dir}">
- <include name="**/*.aidl"/>
+ <include name="**/*.aidl" />
</fileset>
</apply>
</target>
@@ -114,8 +114,8 @@
<src path="${source.dir}" />
<src path="${gen.dir}" />
<classpath>
- <fileset dir="${external.libs.dir}" includes="*.jar"/>
- <pathelement path="${main.out.classes.dir}"/>
+ <fileset dir="${external.libs.dir}" includes="*.jar" />
+ <pathelement path="${main.out.classes.dir}" />
</classpath>
</javac>
</target>
@@ -127,7 +127,7 @@
<arg value="--dex" />
<arg value="--output=${intermediate.dex.file}" />
<arg path="${out.classes.dir}" />
- <fileset dir="${external.libs.dir}" includes="*.jar"/>
+ <fileset dir="${external.libs.dir}" includes="*.jar" />
</apply>
</target>
@@ -143,7 +143,7 @@
manifest="AndroidManifest.xml"
resources="${resource.dir}"
assets="${asset.dir}"
- androidjar="${android-jar}"
+ androidjar="${android.jar}"
outfolder="${out.dir}"
basename="${ant.project.name}" />
</target>
@@ -207,10 +207,10 @@
<!-- Gets passwords -->
<input
message="Please enter keystore password (store:${key.store}):"
- addproperty="key.store.password"/>
+ addproperty="key.store.password" />
<input
message="Please enter password for alias '${key.alias}':"
- addproperty="key.alias.password"/>
+ addproperty="key.alias.password" />
<!-- Signs the APK -->
<echo>Signing final apk...</echo>
@@ -220,7 +220,7 @@
keystore="${key.store}"
storepass="${key.store.password}"
alias="${key.alias}"
- keypass="${key.alias.password}"/>
+ keypass="${key.alias.password}" />
<!-- Zip aligns the APK -->
<echo>Running zip align on final apk...</echo>
@@ -255,19 +255,19 @@
<!-- Uninstalls the package from the default emulator/device -->
<target name="-uninstall-check">
<condition property="uninstall.run">
- <isset property="application-package" />
+ <isset property="application.package" />
</condition>
</target>
<target name="-uninstall-error" depends="-uninstall-check" unless="uninstall.run">
- <echo>Unable to run 'ant uninstall', application-package is not defined in build.properties</echo>
+ <echo>Unable to run 'ant uninstall', application.package is not defined in build.properties</echo>
</target>
<target name="uninstall" depends="-uninstall-error" if="uninstall.run" description="Uninstalls the application from a running emulator or device.">
- <echo>Uninstalling ${application-package} from the default emulator or device...</echo>
+ <echo>Uninstalling ${application.package} from the default emulator or device...</echo>
<exec executable="${adb}" failonerror="true">
<arg value="uninstall" />
- <arg value="${application-package}" />
+ <arg value="${application.package}" />
</exec>
</target>
diff --git a/tools/scripts/build.template b/tools/scripts/build.template
index 8a9ea7326..ca1595416 100644
--- a/tools/scripts/build.template
+++ b/tools/scripts/build.template
@@ -11,7 +11,7 @@
used by the Ant rules.
Here are some properties you may want to change/update:
- application-package
+ application.package
the name of your application package as defined in the manifest. Used by the
'uninstall' rule.
source.dir
@@ -29,7 +29,7 @@
<property file="build.properties" />
<!-- The default.properties file is created and updated by the 'android' tool, as well
- as ADT.
+ as ADT.
This file is an integral part of the build system for your application and
should be checked in in Version Control Systems. -->
<property file="default.properties" />
@@ -37,11 +37,11 @@
<!-- Custom Android task to deal with the project target, and import the proper rules.
This requires ant 1.6.0 or above. -->
<path id="android.antlibs">
- <pathelement path="${sdk-location}/tools/lib/anttasks.jar" />
- <pathelement path="${sdk-location}/tools/lib/sdklib.jar" />
- <pathelement path="${sdk-location}/tools/lib/androidprefs.jar" />
- <pathelement path="${sdk-location}/tools/lib/apkbuilder.jar" />
- <pathelement path="${sdk-location}/tools/lib/jarutils.jar" />
+ <pathelement path="${sdk.dir}/tools/lib/anttasks.jar" />
+ <pathelement path="${sdk.dir}/tools/lib/sdklib.jar" />
+ <pathelement path="${sdk.dir}/tools/lib/androidprefs.jar" />
+ <pathelement path="${sdk.dir}/tools/lib/apkbuilder.jar" />
+ <pathelement path="${sdk.dir}/tools/lib/jarutils.jar" />
</path>
<taskdef name="setup"
@@ -58,7 +58,7 @@
- copy the content of the main node <project> from android_rules.xml
- paste it in this build.xml below the <setup /> task.
- disable the import by changing the setup task below to <setup import="false" />
-
+
This will ensure that the properties are setup correctly but that your customized
build steps are used.
-->