Android Studio 3.0 Compile Issue (Cannot choose between Configurations)

后端 未结 10 817
再見小時候
再見小時候 2020-11-30 04:34

Issue with latest 3.0 build (Beta 2) My project has 1 sub module by a 3rd party so I only have access to their build.gradle.

My project has 3 flavours, snap, uat, pr

10条回答
  •  挽巷
    挽巷 (楼主)
    2020-11-30 04:52

    In my, similar, case the solution was:

    build.gradle:

    android {
        defaultConfig {
            // because I have two project flavors in that library
            missingDimensionStrategy 'project', 'myProjectName' 
            // because I have a "full" and a "debug" flavor in that library
            missingDimensionStrategy 'mode', 'full'
        }
        buildTypes {
            debug { ... }
            release { ... }
        }
    }
    dependencies {
        // because the project(path:'', configuration:'') did not work in this case
        implementation project(':myModuleName1')
        implementation project(':myModuleName2')
    }
    

    Maybe this helps others ending up here with a similar problem.

提交回复
热议问题