diff options
author | Francisco Pimenta <fpimenta@google.com> | 2016-04-06 14:06:17 -0700 |
---|---|---|
committer | Francisco Pimenta <fpimenta@google.com> | 2016-04-06 17:13:27 -0700 |
commit | 398b1f3c56e89b82933e3ee4f01323f9a6596ab7 (patch) | |
tree | 15601017ca5ee6cc68d9278c76f0f58652eceb44 /build.gradle | |
parent | ae2cd1536163c0166679e6b4d64ba2df28588ff3 (diff) | |
download | chips-398b1f3c56e89b82933e3ee4f01323f9a6596ab7.tar.gz |
Removed gradle reference to sdk and build tools
Build tools have just been updated to 23.0.3
with this change build files are simplified and
resilient to changes in target sdk and build tools.
Change-Id: If0991ba7ace83d71f8ff3c1f3764b7c5bc93cce2
Diffstat (limited to 'build.gradle')
-rw-r--r-- | build.gradle | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/build.gradle b/build.gradle index c2fdf17..b0e1708 100644 --- a/build.gradle +++ b/build.gradle @@ -1,7 +1,23 @@ -apply plugin: 'dist' +import org.gradle.api.artifacts.Dependency; -ext { - deps = ['support-v4': project(':support-v4')] +apply plugin: 'com.android.library' + +android { + sourceSets.main { + manifest.srcFile 'AndroidManifest.xml' + java.srcDirs = ['src'] + res.srcDirs = ['res'] + } +} + +dependencies { + compile findDependency(':support-v4', 'com.android.support:support-v4:23.3.+') } -apply from: 'rules.gradle' +Dependency findDependency(String projectName, String moduleName) { + if (findProject(projectName) != null) { + return project(projectName); + } + + return dependencies.create(moduleName) +} |