blob: c662fecd2ab7f27edfcc269a68b8534d8534ae86 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
<#-- This build script is a bootstrapper for the "real" android build script that
is contained in templates/base. It includes only what's necessary for Android Studio
to recognize this as an Android project and start the template engine. -->
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:0.4.2'
}
}
apply plugin: 'android'
android {
<#-- Note that target SDK is hardcoded in this template. We expect all samples
to always use the most current SDK as their target. -->
compileSdkVersion 17
buildToolsVersion "17.0.0"
defaultConfig {
minSdkVersion ${sample.minSdk}
targetSdkVersion 17
}
}
task preflight (dependsOn: parent.preflight) {}
// Inject a preflight task into each variant so we have a place to hook tasks
// that need to run before any of the android build tasks.
<#noparse>
android.applicationVariants.each { variant ->
tasks.getByPath("prepare${variant.name.capitalize()}Dependencies").dependsOn preflight
}
</#noparse>
|