带gradle的多项目错误依赖

osh3o9ms  于 2021-07-06  发布在  Java
关注(0)|答案(0)|浏览(258)

当我加上 compile(project(":engine")) 对于社会项目,我犯了错误,我不知道为什么。但当我加上 compile(project(":social")) 引擎项目一切工作设置.gradle.kts

rootProject.name = "projectdc"
include("engine", "social", "music", "twitch")

build.gradle.kts(社会项目)

repositories {
    mavenCentral()
    mavenLocal()
    jcenter()

}

dependencies {
      compile(project(":engine"))
}

当我加上这行 compile(project(":engine")) 我有个错误:

Circular dependency between the following tasks:
:engine:classes
\--- :engine:compileJava
     +--- :engine:compileKotlin
     |    +--- :engine:jar
     |    |    +--- :engine:classes (*)
     |    |    +--- :engine:compileKotlin (*)
     |    |    \--- :engine:inspectClassesForKotlinIC
     |    |         \--- :engine:classes (*)
     |    \--- :social:jar
     |         +--- :social:classes
     |         |    \--- :social:compileJava
     |         |         +--- :engine:jar (*)
     |         |         +--- :social:compileKotlin
     |         |         |    +--- :engine:jar (*)
     |         |         |    \--- :social:jar (*)
     |         |         \--- :social:jar (*)
     |         +--- :social:compileKotlin (*)
     |         \--- :social:inspectClassesForKotlinIC
     |              \--- :social:classes (*)
     +--- :engine:jar (*)
     \--- :social:jar (*)

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题