I'm trying to add
.jar
dependencies to my multiplatform project without luck so far.
In a regular Gradle project for Jvm, everything is fine, adding the
fileTree
to my
dependencies
section works.
In a multiplatform Gradle project (using
.gradle.kts
) in the
jvmMain
section, Gradle syncs properly, the content listed by the
fileTree
is correct (checked thanks to printed
fileTree(...).files
) but nothing resolves in the IDE completion after.
If I manually tweak the module dependencies in the IntelliJ UI (thus editing the under the hood
.iml
project definition), I get access to the expected types in my
*.jar
but it fails at runtime (I guess it's normal, the launch is using Gradle I assume).
If I tweak the runtime classpath in
tasks.named<JavaExec>("run")
and launch in command line, it works.
I also tried adding the
fileTree
dependency to the
kotlin.jvm.dependencies
section without more success.
So, I'm wondering why the
dependencies
section of
jvmMain
ignores the jar files provided as
implementation
.