build.gradle 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. apply plugin: 'com.android.application'
  2. android {
  3. namespace = "com.onechip.mini7.pad"
  4. compileSdk = rootProject.ext.compileSdkVersion
  5. ndkVersion "27.0.12077973"
  6. defaultConfig {
  7. applicationId "com.onechip.mini7.pad"
  8. minSdkVersion rootProject.ext.minSdkVersion
  9. targetSdkVersion rootProject.ext.targetSdkVersion
  10. versionCode 1062101
  11. versionName "1.6.21.1"
  12. testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
  13. ndk {
  14. abiFilters "arm64-v8a"
  15. }
  16. externalNativeBuild {
  17. cmake {
  18. arguments "-DANDROID_STL=c++_shared"
  19. }
  20. }
  21. aaptOptions {
  22. // Files and dirs to omit from the packaged assets dir, modified to accommodate modern web apps.
  23. // Default: https://android.googlesource.com/platform/frameworks/base/+/282e181b58cf72b6ca770dc7ca5f91f135444502/tools/aapt/AaptAssets.cpp#61
  24. ignoreAssetsPattern = '!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~'
  25. }
  26. }
  27. externalNativeBuild {
  28. cmake {
  29. path "src/main/cpp/CMakeLists.txt"
  30. version "3.22.1"
  31. }
  32. }
  33. buildTypes {
  34. release {
  35. minifyEnabled false
  36. proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
  37. }
  38. }
  39. }
  40. repositories {
  41. flatDir{
  42. dirs '../capacitor-cordova-android-plugins/src/main/libs', 'libs'
  43. }
  44. }
  45. dependencies {
  46. implementation fileTree(include: ['*.jar'], dir: 'libs')
  47. implementation "androidx.appcompat:appcompat:$androidxAppCompatVersion"
  48. implementation "androidx.coordinatorlayout:coordinatorlayout:$androidxCoordinatorLayoutVersion"
  49. implementation "androidx.core:core-splashscreen:$coreSplashScreenVersion"
  50. implementation project(':capacitor-android')
  51. implementation 'com.microsoft.onnxruntime:onnxruntime-android:1.22.0'
  52. implementation 'com.github.mik3y:usb-serial-for-android:3.10.0'
  53. implementation 'org.lsposed.hiddenapibypass:hiddenapibypass:4.3'
  54. testImplementation "junit:junit:$junitVersion"
  55. androidTestImplementation "androidx.test.ext:junit:$androidxJunitVersion"
  56. androidTestImplementation "androidx.test.espresso:espresso-core:$androidxEspressoCoreVersion"
  57. implementation project(':capacitor-cordova-android-plugins')
  58. }
  59. apply from: 'capacitor.build.gradle'
  60. try {
  61. def servicesJSON = file('google-services.json')
  62. if (servicesJSON.text) {
  63. apply plugin: 'com.google.gms.google-services'
  64. }
  65. } catch(Exception e) {
  66. logger.info("google-services.json not found, google-services plugin not applied. Push Notifications won't work")
  67. }