You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

96 lines
3.2 KiB

  1. apply plugin: 'com.android.application'
  2. android {
  3. compileSdkVersion 22
  4. buildToolsVersion "22.0.1"
  5. defaultConfig {
  6. applicationId "com.zzcx.xmdriver2"
  7. minSdkVersion 15
  8. targetSdkVersion 22
  9. versionCode 2
  10. versionName "2.0"
  11. ndk {
  12. //选择要添加的对应cpu类型的.so库。
  13. abiFilters 'armeabi', 'armeabi-v7a', 'armeabi-v8a'
  14. // 还可以添加 'x86', 'x86_64', 'mips', 'mips64'
  15. }
  16. //极光推送测试:276a46fa9ab87d4a02a270ec
  17. //极光推送正式环境:02d54f12a09002cd7bda5161
  18. manifestPlaceholders = [
  19. JPUSH_PKGNAME : applicationId,
  20. JPUSH_APPKEY : "276a46fa9ab87d4a02a270ec", //JPush上注册的包名对应的appkey.
  21. JPUSH_CHANNEL : "developer-default", //暂时填写默认值即可.
  22. ]
  23. }
  24. packagingOptions {
  25. exclude 'META-INF/maven/com.belerweb/pinyin4j/pom.xml'
  26. exclude 'META-INF/maven/com.belerweb/pinyin4j/pom.properties'
  27. }
  28. buildTypes {
  29. release {
  30. minifyEnabled false
  31. proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
  32. }
  33. }
  34. task nativeLibsToJar(type: Zip, description: "create a jar archive of the native libs") {
  35. destinationDir file("src/main/libs")
  36. baseName "Native_Libs2"
  37. extension "jar"
  38. from fileTree(dir: "src/main/libs", include: "**/*.so")
  39. into "lib"
  40. }
  41. tasks.withType(JavaCompile) {
  42. compileTask -> compileTask.dependsOn(nativeLibsToJar)
  43. }
  44. packagingOptions{
  45. exclude'META-INF/DEPENDENCIES.txt'
  46. exclude'META-INF/LICENSE.txt'
  47. exclude'META-INF/NOTICE.txt'
  48. exclude'META-INF/NOTICE'
  49. exclude'META-INF/LICENSE'
  50. exclude'META-INF/DEPENDENCIES'
  51. exclude'META-INF/notice.txt'
  52. exclude'META-INF/license.txt'
  53. exclude'META-INF/dependencies.txt'
  54. exclude'META-INF/LGPL2.1'
  55. }
  56. sourceSets{
  57. main{
  58. jniLibs.srcDir(['libs'])
  59. }
  60. }
  61. }
  62. dependencies {
  63. compile fileTree(include: ['*.jar'], dir: 'src/main/libs')
  64. //compile fileTree(include: ['*.jar'], dir: 'libs')
  65. testCompile 'junit:junit:4.12'
  66. compile 'com.google.android.gms:play-services-appindexing:8.1.0'
  67. compile files('src/main/libs/simple_eventbus.jar')
  68. compile files('src/main/libs/AMap_Location_V2.4.1_20160414.jar')
  69. compile files('src/main/jniLibs/AMap3DMap_3.3.3_AMapNavi_1.9.1_20160726.jar')
  70. compile 'com.android.support:appcompat-v7:22.2.0'
  71. compile 'com.android.support:design:22.2.0'
  72. compile 'com.github.bumptech.glide:glide:3.6.0'
  73. compile 'de.hdodenhof:circleimageview:1.3.0'
  74. compile 'com.android.support:recyclerview-v7:22.2.0'
  75. compile 'com.github.jalasoft:HttpClient:1.0.5'
  76. compile files('src/main/java/jniLibs/AMap3DMap_3.3.3_AMapNavi_1.9.1_20160726.jar')
  77. compile 'com.alibaba:fastjson:1.2.20'
  78. compile files('libs/AMap_Location_V3.1.0_20161027.jar')
  79. compile files('libs/AMap_Search_V3.6.0_20161110.jar')
  80. compile files('libs/Android_Map3D_SDK_V4.1.2_20161104.jar')
  81. compile files('libs/Volley.jar')
  82. compile 'cn.jiguang:jpush:2.1.8' // 极光推送,此处以SDK 2.1.8版本为例
  83. }