aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorPiotr Gurgul <pgurgul@google.com>2009-09-22 17:28:26 -0700
committerPiotr Gurgul <pgurgul@google.com>2009-09-22 17:31:14 -0700
commit41fb47df08e1d583b0878e2542c5bf802cd1e6d1 (patch)
tree6034aa238eb1353965936f7bfc27748f95c700e5 /scripts
parent604899634a60a8ef71db4ea19d3fa0dbc4315d47 (diff)
downloadsdk-41fb47df08e1d583b0878e2542c5bf802cd1e6d1.zip
sdk-41fb47df08e1d583b0878e2542c5bf802cd1e6d1.tar.gz
sdk-41fb47df08e1d583b0878e2542c5bf802cd1e6d1.tar.bz2
Add legacy support for application.package property
application.package in android_rules.xml and android_test_rules.xml has been replaced by manifest.package which value is taken from AndroidManifest.xml. This is because old versions of build.properties contain already application.package property which has precedence over the extracted one and overrides it. Change-Id: I909e145926169922ec6ec0e179ad88c413aa85b2
Diffstat (limited to 'scripts')
-rw-r--r--scripts/android_rules.xml10
-rw-r--r--scripts/android_test_rules.xml6
2 files changed, 8 insertions, 8 deletions
diff --git a/scripts/android_rules.xml b/scripts/android_rules.xml
index 4d74ae2..a14345b 100644
--- a/scripts/android_rules.xml
+++ b/scripts/android_rules.xml
@@ -31,7 +31,7 @@
<property name="android.tools.dir" location="${sdk.dir}/tools" />
<!-- Name of the application package extracted from manifest file -->
<xpath input="AndroidManifest.xml" expression="/manifest/@package"
- output="application.package" />
+ output="manifest.package" />
<!-- Input directories -->
<property name="source.dir" value="src" />
@@ -336,22 +336,22 @@
<target name="-uninstall-check">
<condition property="uninstall.run">
- <isset property="application.package" />
+ <isset property="manifest.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>Unable to run 'ant uninstall', manifest.package property is not defined.
</echo>
</target>
<!-- Uninstalls the package from the default emulator/device -->
<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 ${manifest.package} from the default emulator or device...</echo>
<exec executable="${adb}" failonerror="true">
<arg value="uninstall" />
- <arg value="${application.package}" />
+ <arg value="${manifest.package}" />
</exec>
</target>
diff --git a/scripts/android_test_rules.xml b/scripts/android_test_rules.xml
index 60518df..fd8a521 100644
--- a/scripts/android_test_rules.xml
+++ b/scripts/android_test_rules.xml
@@ -10,12 +10,12 @@
<property name="test.runner" value="android.test.InstrumentationTestRunner" />
<!-- Application package of the tested project extracted from its manifest file -->
<xpath input="${tested.project.absolute.dir}/AndroidManifest.xml"
- expression="/manifest/@package" output="tested.application.package" />
+ expression="/manifest/@package" output="tested.manifest.package" />
<!-- TODO: make it more configurable in the next CL's - now it is default for auto-generated
project -->
<property name="emma.dump.file"
- value="/data/data/${tested.application.package}/files/coverage.ec" />
+ value="/data/data/${tested.manifest.package}/files/coverage.ec" />
<macrodef name="run-tests-helper">
<attribute name="emma.enabled" default="false" />
@@ -31,7 +31,7 @@
<arg value="coverage" />
<arg value="@{emma.enabled}" />
<extra-instrument-args />
- <arg value="${application.package}/${test.runner}" />
+ <arg value="${manifest.package}/${test.runner}" />
</exec>
</sequential>
</macrodef>