aboutsummaryrefslogtreecommitdiffstats
path: root/testapps/buildConfigTest/lib1/build.xml
diff options
context:
space:
mode:
Diffstat (limited to 'testapps/buildConfigTest/lib1/build.xml')
-rw-r--r--testapps/buildConfigTest/lib1/build.xml11
1 files changed, 10 insertions, 1 deletions
diff --git a/testapps/buildConfigTest/lib1/build.xml b/testapps/buildConfigTest/lib1/build.xml
index 2a15ae634..a111b4d78 100644
--- a/testapps/buildConfigTest/lib1/build.xml
+++ b/testapps/buildConfigTest/lib1/build.xml
@@ -28,6 +28,15 @@
-->
<property file="ant.properties" />
+ <!-- if sdk.dir was not set from one of the property file, then
+ get it from the ANDROID_HOME env var.
+ This must be done before we load project.properties since
+ the proguard config can use sdk.dir -->
+ <property environment="env" />
+ <condition property="sdk.dir" value="${env.ANDROID_HOME}">
+ <isset property="env.ANDROID_HOME" />
+ </condition>
+
<!-- The project.properties file is created and updated by the 'android'
tool, as well as ADT.
@@ -41,7 +50,7 @@
<!-- quick check on sdk.dir -->
<fail
- message="sdk.dir is missing. Make sure to generate local.properties using 'android update project' or to inject it through an env var"
+ message="sdk.dir is missing. Make sure to generate local.properties using 'android update project' or to inject it through the ANDROID_HOME environment variable."
unless="sdk.dir"
/>