Android Gradle main project and submodule flavors -



Android Gradle main project and submodule flavors -

i have main android project, depends on submodule.

the main project has flavors defined in gradle.

also submodule has few flavors defined. should logical - able have flavors both projects. illustration in submodule:

productflavors { flavorname { } }

but not work - build crashes message saying submodule resources not found in main project. when delete flavors submodule, works fine.

it seems mix build order when flavors defined subproject, true?

what missing? possible both main , sub projects have flavors?

when reference sub-modules dependencies in build.gradle file, sure specify flavor of sub-module referring to:

dependencies { compile project(path: ':module', configuration:'yourflavordebug') }

then sure in build variants, building flavor main module depends on, , should work out.

also sure libraries referencing have in build.gradle well:

publishnondefault true

without android studio doesn't seem able depend on flavors of module. more info here.

android gradle android-productflavors

Comments

Popular posts from this blog

php - Edges appear in image after resizing -

ios8 - iOS custom keyboard - preserve state between appearances -

Delphi change the assembly code of a running process -