summaryrefslogtreecommitdiffstats
path: root/tools/scripts
diff options
context:
space:
mode:
authorXavier Ducrohet <xav@android.com>2009-08-25 20:01:56 -0700
committerXavier Ducrohet <xav@android.com>2009-08-26 14:58:56 -0700
commit0614664583142fc9b83288734893a508823b3efd (patch)
treef0003bea3d6294b9b98cf2988ec4480cfc38c171 /tools/scripts
parent2328b4f3f56cd33deef5f9b21673dc072012e0d3 (diff)
downloadandroid_development-0614664583142fc9b83288734893a508823b3efd.tar.gz
android_development-0614664583142fc9b83288734893a508823b3efd.tar.bz2
android_development-0614664583142fc9b83288734893a508823b3efd.zip
Make ApkBuilder create filenames supported by older rules.
'ant install' must know the debug apk filename so newer naming scheme breaks on older rule files (1.5 and earlier). The fix is to check for the presence of the property naming the debug, signed, unaligned package. If the property is present, then we use the new naming scheme ({base}[-{config}]-debug-unaligned.apk), else we use the old one ({base}-[-{config}]-debug.apk). Also merge the install/reinstall targets, since 'adb install -r <file>' works even if the apk was not yet installed. Change-Id: Id0670610a6539a3f48c955756955f950039c3cd0
Diffstat (limited to 'tools/scripts')
-rw-r--r--tools/scripts/android_rules.xml20
1 files changed, 5 insertions, 15 deletions
diff --git a/tools/scripts/android_rules.xml b/tools/scripts/android_rules.xml
index 4a98700e7..64f0e392e 100644
--- a/tools/scripts/android_rules.xml
+++ b/tools/scripts/android_rules.xml
@@ -235,15 +235,7 @@
<!-- Installs the package on the default emulator/device -->
<target name="install" depends="debug"
- description="Installs the debug package onto a running emulator or device. This can only be used if the application has not yet been installed.">
- <echo>Installing ${out.debug.package} onto default emulator or device...</echo>
- <exec executable="${adb}" failonerror="true">
- <arg value="install" />
- <arg path="${out.debug.package}" />
- </exec>
- </target>
-
- <target name="reinstall" depends="debug" description="Installs the debug package on a running emulator or device that already has the application.">
+ description="Installs/reinstalls the debug package onto a running emulator or device. This can only be used if the application has not yet been installed.">
<echo>Installing ${out.debug.package} onto default emulator or device...</echo>
<exec executable="${adb}" failonerror="true">
<arg value="install" />
@@ -286,12 +278,10 @@
<echo> debug: Builds the application and signs it with a debug key.</echo>
<echo> release: Builds the application. The generated apk file must be</echo>
<echo> signed before it is published.</echo>
- <echo> install: Installs the debug package onto a running emulator or</echo>
- <echo> device. This can only be used if the application has</echo>
- <echo> not yet been installed.</echo>
- <echo> reinstall: Installs the debug package on a running emulator or</echo>
- <echo> device that already has the application.</echo>
- <echo> The signatures must match.</echo>
+ <echo> install: Installs/reinstall the debug package onto a running</echo>
+ <echo> emulator or device.</echo>
+ <echo> If the application was previously installed, the</echo>
+ <echo> signatures must match.</echo>
<echo> uninstall: Uninstalls the application from a running emulator or</echo>
<echo> device.</echo>
</target>