build.gradle 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. // Non functional android library used to provide Android Studio editor support to the project.
  2. plugins {
  3. id 'com.android.library'
  4. id 'org.jetbrains.kotlin.android'
  5. }
  6. android {
  7. compileSdkVersion versions.compileSdk
  8. buildToolsVersion versions.buildTools
  9. ndkVersion versions.ndkVersion
  10. namespace = "org.godotengine.godot"
  11. defaultConfig {
  12. minSdkVersion versions.minSdk
  13. targetSdkVersion versions.targetSdk
  14. }
  15. compileOptions {
  16. sourceCompatibility versions.javaVersion
  17. targetCompatibility versions.javaVersion
  18. }
  19. kotlinOptions {
  20. jvmTarget = versions.javaVersion
  21. }
  22. packagingOptions {
  23. exclude 'META-INF/LICENSE'
  24. exclude 'META-INF/NOTICE'
  25. }
  26. sourceSets {
  27. main {
  28. manifest.srcFile 'AndroidManifest.xml'
  29. }
  30. }
  31. externalNativeBuild {
  32. cmake {
  33. path "CMakeLists.txt"
  34. }
  35. }
  36. libraryVariants.all { variant ->
  37. def buildType = variant.buildType.name.capitalize()
  38. def taskPrefix = ""
  39. if (project.path != ":") {
  40. taskPrefix = project.path + ":"
  41. }
  42. // Disable the externalNativeBuild* task as it would cause build failures since the cmake build
  43. // files is only setup for editing support.
  44. gradle.startParameter.excludedTaskNames += taskPrefix + "externalNativeBuild" + buildType
  45. }
  46. }
  47. dependencies {}