How to pass compiler arguments to Kotlin Compiler with Gradle

后端 未结 3 1231
暖寄归人
暖寄归人 2020-12-06 09:29

I\'m compiling a Kotlin library jar with Gradle using the Kotlin gradle plugin:

apply plugin: \'kotlin\'

I\'m trying to find a way to pass a sim

3条回答
  •  感情败类
    2020-12-06 10:22

    Try this:

    compileKotlin {
        kotlinOptions.includeRuntime = true
    }
    

    UPD btw this exact option includeRuntime couldn't work because it is not Gradle way. There are many options to build jar with dependencies in Gradle: Gradle – Create a Jar file with dependencies, Gradle Shadow

提交回复
热议问题