I have a project with a main application and 3 modules. They depend on each other, like
app (android application)
|
|
|
I am using AS 3.0 with BuildTool 3.0.0-alpha5.
I applied the changes described in the document: https://developer.android.com/studio/build/gradle-plugin-3-0-0-migration.html#variant_dependencies
Here is my
build.gradle (application)
apply plugin: 'com.android.application'
android {
...
buildTypes {
debug {}
qa {}
release {}
}
flavorDimensions "default"
productFlavors {
flavor1 {dimension = "default"}
flavor2 {dimension = "default"}
}
}
dependencies {
...
implementation project(path: ':module1')
...
}
Here is my
build.gradle (module1)
apply plugin: 'com.android.library'
android {
...
buildTypes {
debug {}
qa {}
release {}
}
}
dependencies {
...
implementation project(path: ':module2')
...
}
Here is my
build.gradle (module2)
apply plugin: 'com.android.library'
android {
...
buildTypes {
debug {}
qa {}
release {}
}
}
dependencies {
...
implementation project(path: ':module3')
...
}
</ " >
: " flavor1Debug", " qa". "debug" BuildVariant.
Gradle Sync:
:
'module1' 'debug', '' app '' 'qa'
'module1' " "
- , ?