blob: aea57a2361cc8109ec9c8f9fbe9c63f467db9b0a [file] [log] [blame]
The Android Open Source Project55a2c712009-03-03 19:29:09 -08001<?xml version="1.0" encoding="UTF-8"?>
2<project name="PROJECT_NAME" default="help">
3
Xavier Ducrohet51036712011-08-23 16:28:21 -07004 <!-- The local.properties file is created and updated by the 'android' tool.
5 It contains the path to the SDK. It should *NOT* be checked into
6 Version Control Systems. -->
Xavier Ducrohete9fddda2011-11-23 15:08:24 -08007 <property file="local.properties" />
The Android Open Source Project55a2c712009-03-03 19:29:09 -08008
Xavier Ducrohet51036712011-08-23 16:28:21 -07009 <!-- The ant.properties file can be created by you. It is only edited by the
10 'android' tool to add properties to it.
11 This is the place to change some Ant specific build properties.
The Android Open Source Project55a2c712009-03-03 19:29:09 -080012 Here are some properties you may want to change/update:
13
Piotr Gurgul4e8d9f12009-08-22 14:45:00 -070014 source.dir
Xavier Ducrohet9520e972010-04-28 15:35:12 -070015 The name of the source directory. Default is 'src'.
Piotr Gurgul4e8d9f12009-08-22 14:45:00 -070016 out.dir
Xavier Ducrohet9520e972010-04-28 15:35:12 -070017 The name of the output directory. Default is 'bin'.
The Android Open Source Project55a2c712009-03-03 19:29:09 -080018
Xavier Ducrohet51036712011-08-23 16:28:21 -070019 For other overridable properties, look at the beginning of the rules
20 files in the SDK, at tools/ant/build.xml
21
Xavier Ducrohet9520e972010-04-28 15:35:12 -070022 Properties related to the SDK location or the project target should
23 be updated using the 'android' tool with the 'update' action.
The Android Open Source Project55a2c712009-03-03 19:29:09 -080024
Xavier Ducrohet9520e972010-04-28 15:35:12 -070025 This file is an integral part of the build system for your
Xavier Ducrohetf180ab62010-06-08 18:16:36 -070026 application and should be checked into Version Control Systems.
The Android Open Source Project55a2c712009-03-03 19:29:09 -080027
28 -->
Xavier Ducrohet51036712011-08-23 16:28:21 -070029 <property file="ant.properties" />
The Android Open Source Project55a2c712009-03-03 19:29:09 -080030
Xavier Ducrohet249dc012012-05-25 16:27:34 -070031 <!-- if sdk.dir was not set from one of the property file, then
32 get it from the ANDROID_HOME env var.
33 This must be done before we load project.properties since
34 the proguard config can use sdk.dir -->
35 <property environment="env" />
36 <condition property="sdk.dir" value="${env.ANDROID_HOME}">
37 <isset property="env.ANDROID_HOME" />
38 </condition>
39
Xavier Ducrohet51036712011-08-23 16:28:21 -070040 <!-- The project.properties file is created and updated by the 'android'
Xavier Ducrohet9520e972010-04-28 15:35:12 -070041 tool, as well as ADT.
Xavier Ducrohet51036712011-08-23 16:28:21 -070042
43 This contains project specific properties such as project target, and library
44 dependencies. Lower level build properties are stored in ant.properties
45 (or in .classpath for Eclipse projects).
46
Xavier Ducrohet9520e972010-04-28 15:35:12 -070047 This file is an integral part of the build system for your
Xavier Ducrohetf180ab62010-06-08 18:16:36 -070048 application and should be checked into Version Control Systems. -->
Xavier Ducrohet51036712011-08-23 16:28:21 -070049 <loadproperties srcFile="project.properties" />
The Android Open Source Project55a2c712009-03-03 19:29:09 -080050
Xavier Ducrohetbabf25c2011-02-14 15:52:12 -080051 <!-- quick check on sdk.dir -->
52 <fail
Xavier Ducrohet1daa8f92012-03-29 19:28:25 -070053 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."
Xavier Ducrohetbabf25c2011-02-14 15:52:12 -080054 unless="sdk.dir"
55 />
Xavier Ducrohet96f99e92011-02-08 13:50:01 -080056
Xavier Ducrohet63bf7132011-12-07 16:48:11 -080057 <!--
58 Import per project custom build rules if present at the root of the project.
59 This is the place to put custom intermediary targets such as:
60 -pre-build
61 -pre-compile
62 -post-compile (This is typically used for code obfuscation.
63 Compiled code location: ${out.classes.absolute.dir}
64 If this is not done in place, override ${out.dex.input.absolute.dir})
65 -post-package
66 -post-build
67 -pre-clean
68 -->
69 <import file="custom_rules.xml" optional="true" />
Xavier Ducrohet9520e972010-04-28 15:35:12 -070070
Xavier Ducrohetbabf25c2011-02-14 15:52:12 -080071 <!-- Import the actual build file.
Xavier Ducrohet271701c2009-08-07 10:40:24 -070072
Xavier Ducrohet9520e972010-04-28 15:35:12 -070073 To customize existing targets, there are two options:
74 - Customize only one target:
75 - copy/paste the target into this file, *before* the
Xavier Ducrohetbabf25c2011-02-14 15:52:12 -080076 <import> task.
Xavier Ducrohet9520e972010-04-28 15:35:12 -070077 - customize it to your needs.
Xavier Ducrohetbabf25c2011-02-14 15:52:12 -080078 - Customize the whole content of build.xml
Xavier Ducrohet9520e972010-04-28 15:35:12 -070079 - copy/paste the content of the rules files (minus the top node)
Xavier Ducrohetbabf25c2011-02-14 15:52:12 -080080 into this file, replacing the <import> task.
Xavier Ducrohet9520e972010-04-28 15:35:12 -070081 - customize to your needs.
Xavier Ducrohetbabf25c2011-02-14 15:52:12 -080082
83 ***********************
84 ****** IMPORTANT ******
85 ***********************
Xavier Ducrohet69ff1312011-08-22 20:10:38 -070086 In all cases you must update the value of version-tag below to read 'custom' instead of an integer,
87 in order to avoid having your file be overridden by tools such as "android update project"
The Android Open Source Project55a2c712009-03-03 19:29:09 -080088 -->
Xavier Ducrohet69ff1312011-08-22 20:10:38 -070089 <!-- version-tag: VERSION_TAG -->
Xavier Ducrohetbabf25c2011-02-14 15:52:12 -080090 <import file="${sdk.dir}/tools/ant/build.xml" />
Piotr Gurgulb0b67262009-09-01 21:58:52 -070091
The Android Open Source Project55a2c712009-03-03 19:29:09 -080092</project>