build.gradle 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. apply from: configPath
  2. apply from: "$scriptPath/android_app.gradle"
  3. apply from: protobufNanoConfig
  4. apply from: frameworkDependencies
  5. android {
  6. namespace 'com.android.launcher3'
  7. defaultConfig {
  8. versionCode 30
  9. versionName "11.0"
  10. }
  11. flavorDimensions = ["app", "recents"]
  12. productFlavors {
  13. aosp {
  14. dimension "app"
  15. }
  16. withQuickstep {
  17. dimension "recents"
  18. }
  19. }
  20. sourceSets {
  21. main {
  22. res.srcDirs = ["$launcherCode/res"]
  23. java.srcDir "$launcherCode/src"
  24. java.srcDir "$launcherCode/src_plugins"
  25. java.srcDir "$launcherCode/src_build_config"
  26. manifest.srcFile "$launcherCode/AndroidManifest-common.xml"
  27. proto {
  28. srcDir "$launcherCode/protos/"
  29. srcDir "$launcherCode/proto_overrides/"
  30. }
  31. }
  32. aosp {
  33. java.srcDir "$launcherCode/src_flags"
  34. java.srcDir "$launcherCode/src_shortcuts_overrides"
  35. }
  36. aospWithQuickstep {
  37. manifest.srcFile "$launcherCode/quickstep/AndroidManifest-launcher.xml"
  38. }
  39. withQuickstep {
  40. java.srcDir "$launcherCode/quickstep/src"
  41. java.srcDir "$launcherCode/quickstep/recents_ui_overrides/src"
  42. res.srcDir "$launcherCode/quickstep/res"
  43. res.srcDir "$launcherCode/quickstep/recents_ui_overrides/res"
  44. manifest.srcFile "$launcherCode/quickstep/AndroidManifest.xml"
  45. }
  46. }
  47. compileOptions {
  48. sourceCompatibility JavaVersion.VERSION_1_8
  49. targetCompatibility JavaVersion.VERSION_1_8
  50. }
  51. }
  52. final String ANDROID_X_VERSION = '1.0.0'
  53. dependencies {
  54. implementation "androidx.core:core:1.2.0"
  55. implementation "androidx.fragment:fragment:1.2.0"
  56. implementation "androidx.dynamicanimation:dynamicanimation:${ANDROID_X_VERSION}"
  57. implementation "androidx.recyclerview:recyclerview:${ANDROID_X_VERSION}"
  58. implementation "androidx.preference:preference:${ANDROID_X_VERSION}"
  59. implementation "com.google.protobuf:protobuf-javalite:3.21.1"
  60. implementation project(':1100_r48:IconLoader')
  61. implementation project(':1100_r48:LauncherLogProtosLite')
  62. implementation project(':1100_r48:SystemUI:PluginCoreLib')
  63. implementation project(':1100_r48:SystemUI:SystemUISharedLib')
  64. implementation project(':1100_r48:SystemUI:SysUiStatsLog')
  65. }
  66. protobuf {
  67. generateProtoTasks {
  68. all().each { task ->
  69. task.builtins {
  70. javanano {
  71. option "java_package=launcher_log_extension.proto|com.android.launcher3.userevent.nano"
  72. option "java_package=launcher_log.proto|com.android.launcher3.userevent.nano"
  73. option "java_package=launcher_dump.proto|com.android.launcher3.model.nano"
  74. option "enum_style=java"
  75. }
  76. }
  77. }
  78. }
  79. }