[英]Unable to build gradle that depend on other module
嘿,我的項目中有很多模塊:
從低級android庫開始
通過基礎android應用程序
productFlavors{ featureON{} featureOFF{} } buildTypes{ release{} debug{} } dependencies{ implementation project(':logic') }
到最終用戶的android應用程序
buildTypes{ release{} debug{} } dependencies{ implementation project(':base_app') }
ext.gradle_version = '3.4.0'
我越來越
ERROR: Unable to resolve dependency for ':client@debug/compileClasspath': Could not resolve project :base_app.
Show Details
Affected Modules: client
ERROR: Unable to resolve dependency for ':client@debugAndroidTest/compileClasspath': Could not resolve project :base_app.
Show Details
Affected Modules: client
ERROR: Unable to resolve dependency for ':client@debugUnitTest/compileClasspath': Could not resolve project :base_app.
Show Details
Affected Modules: client
ERROR: Unable to resolve dependency for ':client@release/compileClasspath': Could not resolve project :base_app.
Show Details
Affected Modules: client
ERROR: Unable to resolve dependency for ':client@releaseUnitTest/compileClasspath': Could not resolve project :base_app.
Show Details
Affected Modules: client
但是,如果我使用它如下
implementation project(path: ':app', configuration: 'default')
gradle運行,但在這種情況下,更改構建變量調試/發布不會更改應用程序中的變體,我需要的是因為我想在'client'中放置更多productFlavor,即featureON{} featureOFF{}
相關問題:
Android應用程序將具有以下模塊。
Android應用模塊
Android庫(aar)
Android java庫(jar)
dependencies {
implementation fileTree(include: ["*.jar"], dir: "libs")
implementation fileTree(include: ["smack-*-${smackVersion}.jar"], dir: smackDir)
implementation(name: "ion-${ionVersion}", ext: "aar")
}
我們不能擁有多個“Android應用模塊”。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.