Are `project(":foo")` style dependencies supported...
# multiplatform
s
Are
project(":foo")
style dependencies supported when the callee is a
kotlin("jvm")
project and the project
foo
is a multiplatform project?
d
Yes! I'm doing this myself.
s
What if that
foo
is just a common module? It’s literally just annotations in my case.
Nevermind, I forgot to register the mpp as a jvm project (doh)
r
I’ve seen some things fail to resolve in IDEA when you do that but it builds from gradle. https://youtrack.jetbrains.com/issue/KT-29082
a
I had to explicitly add a “org.jetbrains.kotlin.platform.type” attribute to my jvm “callee” subproject in order to avoid a Gradle “unable to pick variant” issue (whereas the js dependent subproject was fine)
r
That's probably a different issue. When you have multiple targets of the same platform type, you need to disambiguate. That's true regardless of whether it's a project dependency. https://kotlinlang.org/docs/reference/building-mpp-with-gradle.html#disambiguating-targets
☝🏼 1