build.gradle 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. buildscript {
  2. repositories {
  3. mavenCentral()
  4. }
  5. dependencies {
  6. classpath 'com.android.tools.build:gradle:1.5.0'
  7. }
  8. }
  9. apply plugin: 'com.android.application'
  10. repositories {
  11. mavenCentral()
  12. flatDir {
  13. dirs 'libs'
  14. }
  15. }
  16. dependencies {
  17. compile name: 'touch-image-view'
  18. compile project(':owncloud-android-library')
  19. compile 'com.android.support:support-v4:23.1.1'
  20. compile 'com.jakewharton:disklrucache:2.0.2'
  21. compile 'com.android.support:appcompat-v7:23.1.1'
  22. }
  23. android {
  24. compileSdkVersion 23
  25. buildToolsVersion "23.0.2"
  26. // as long as ownCloud uses Apache HTTP
  27. // http://developer.android.com/about/versions/marshmallow/android-6.0-changes.html#behavior-apache-http-client
  28. useLibrary 'org.apache.http.legacy'
  29. sourceSets {
  30. main {
  31. manifest.srcFile 'AndroidManifest.xml'
  32. java.srcDirs = ['src']
  33. resources.srcDirs = ['src']
  34. aidl.srcDirs = ['src']
  35. renderscript.srcDirs = ['src']
  36. res.srcDirs = ['res']
  37. assets.srcDirs = ['res']
  38. }
  39. // Move the tests to tests/java, tests/res, etc...
  40. instrumentTest.setRoot('tests')
  41. // Move the build types to build-types/<type>
  42. // For instance, build-types/debug/java, build-types/debug/AndroidManifest.xml, ...
  43. // This moves them out of them default location under src/<type>/... which would
  44. // conflict with src/ being used by the main source set.
  45. // Adding new build types or product flavors should be accompanied
  46. // by a similar customization.
  47. debug.setRoot('build-types/debug')
  48. release.setRoot('build-types/release')
  49. }
  50. compileOptions {
  51. sourceCompatibility JavaVersion.VERSION_1_7
  52. targetCompatibility JavaVersion.VERSION_1_7
  53. }
  54. lintOptions {
  55. abortOnError false
  56. }
  57. packagingOptions {
  58. exclude 'META-INF/LICENSE.txt'
  59. }
  60. }