1 import com.google.protobuf.gradle.proto 2 3 /** 4 * This is an adaptation of the build.gradle found in external/android_onboarding. 5 * There are certain classes that must be modified in order to work with the sysui studio build. 6 */ <lambda>null7plugins { 8 id(libs.plugins.android.library.get().pluginId) 9 id(libs.plugins.kotlin.android.get().pluginId) 10 id(libs.plugins.kotlin.kapt.get().pluginId) 11 id(libs.plugins.protobuf.get().pluginId) 12 } 13 14 val top = extra["ANDROID_TOP"].toString() 15 val moduleDir = 16 "$top/external/android_onboarding/src/com/android/onboarding/nodes" 17 <lambda>null18android { 19 namespace = "com.android.onboarding.nodes" 20 defaultConfig { 21 vectorDrawables.useSupportLibrary = true 22 } 23 24 buildTypes { 25 release { 26 isMinifyEnabled = false 27 } 28 } 29 30 sourceSets { 31 named("main") { 32 java.srcDirs(listOf("src", symlinkedSources(moduleDir))) 33 proto { 34 setSrcDirs(listOf(moduleDir)) 35 } 36 } 37 } 38 } 39 <lambda>null40dependencies { 41 implementation(libs.protobuf.javalite) 42 api("androidx.activity:activity-ktx") 43 api(libs.guava) 44 api(project(":android_onboarding.contracts.annotations")) 45 api(project(":android_onboarding.flags")) 46 } 47 <lambda>null48protobuf { 49 // Configure the protoc executable 50 protoc { 51 artifact = "${libs.protobuf.protoc.get()}" 52 } 53 generateProtoTasks { 54 all().configureEach { 55 builtins { 56 register("java") { 57 option("lite") 58 } 59 } 60 } 61 } 62 } 63