The JUCE cross-platform C++ framework, with DISTRHO/KXStudio specific changes
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.

112 lines
2.9KB

  1. apply plugin: 'com.android.application'
  2. def ndkVersionString = "25.2.9519653"
  3. android {
  4. compileSdkVersion 33
  5. ndkVersion ndkVersionString
  6. namespace "com.juce.networkgraphicsdemo"
  7. externalNativeBuild {
  8. cmake {
  9. path "CMakeLists.txt"
  10. version "3.22.1"
  11. }
  12. }
  13. signingConfigs {
  14. juceSigning {
  15. storeFile file("${System.properties['user.home']}${File.separator}.android${File.separator}debug.keystore")
  16. storePassword "android"
  17. keyAlias "androiddebugkey"
  18. keyPassword "android"
  19. storeType "jks"
  20. }
  21. }
  22. defaultConfig {
  23. applicationId "com.juce.networkgraphicsdemo"
  24. minSdkVersion 16
  25. targetSdkVersion 33
  26. externalNativeBuild {
  27. cmake {
  28. arguments "-DANDROID_TOOLCHAIN=clang", "-DANDROID_PLATFORM=android-16", "-DANDROID_STL=c++_static", "-DANDROID_CPP_FEATURES=exceptions rtti", "-DANDROID_ARM_MODE=arm", "-DANDROID_ARM_NEON=TRUE", "-DCMAKE_CXX_STANDARD=17", "-DCMAKE_CXX_EXTENSIONS=OFF"
  29. }
  30. }
  31. }
  32. buildTypes {
  33. debug {
  34. initWith debug
  35. debuggable true
  36. jniDebuggable true
  37. signingConfig signingConfigs.juceSigning
  38. }
  39. release {
  40. initWith release
  41. debuggable false
  42. jniDebuggable false
  43. signingConfig signingConfigs.juceSigning
  44. }
  45. }
  46. flavorDimensions "default"
  47. productFlavors {
  48. debug_ {
  49. ndk {
  50. abiFilters "armeabi-v7a", "x86", "arm64-v8a", "x86_64"
  51. }
  52. externalNativeBuild {
  53. cmake {
  54. cFlags "-Ofast"
  55. cppFlags "-Ofast"
  56. arguments "-DJUCE_BUILD_CONFIGURATION=DEBUG"
  57. }
  58. }
  59. dimension "default"
  60. }
  61. release_ {
  62. externalNativeBuild {
  63. cmake {
  64. cFlags "-O3"
  65. cppFlags "-O3"
  66. arguments "-DJUCE_BUILD_CONFIGURATION=RELEASE"
  67. }
  68. }
  69. dimension "default"
  70. }
  71. }
  72. variantFilter { variant ->
  73. def names = variant.flavors*.name
  74. if (names.contains ("debug_")
  75. && variant.buildType.name != "debug") {
  76. setIgnore(true)
  77. }
  78. if (names.contains ("release_")
  79. && variant.buildType.name != "release") {
  80. setIgnore(true)
  81. }
  82. }
  83. sourceSets {
  84. main.java.srcDirs +=
  85. ["../../../../../modules/juce_core/native/javacore/init",
  86. "../../../../../modules/juce_core/native/javacore/app",
  87. "../../../../../modules/juce_gui_basics/native/javaopt/app"]
  88. main.res.srcDirs +=
  89. []
  90. }
  91. repositories {
  92. }
  93. dependencies {
  94. }
  95. }