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.

107 lines
3.1KB

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