package Ġcom . so y wiz . kir pt er . gradle Ċ Ċ import Ġorg . gradle . api .* Ċ import Ġorg . gradle . api . artifacts .* Ċ import Ġorg . gradle . api . provider .* Ċ import Ġorg . jetbrains . kotlin . gradle . plugin .* Ċ import Ġjava . util . logging .* Ċ Ċ @ Suppress (" unused ") Ċ class ĠK ir pt er Gradle Plugin Ġ: ĠKotlin Compiler Plugin Support Plugin Ġ{ Ċ ĉ override Ġfun Ġapply ( target : ĠProject ) Ġ{ Ċĉ ĉ target . logger . info (" K ir pt er Gradle Plugin . apply ") Ċĉ ĉ target . configurations . maybe Create (" kir pt er ") Ċ ĉ } ĊĊ ĉ override Ġfun Ġis Applicable ( kotlin Compilation : ĠKotlin Compilation < *> ): ĠBoolean Ġ= Ġtrue ĊĊ ĉ override Ġfun Ġget Compiler Plugin Id (): ĠString Ġ= ĠBuild Config . K OT LIN _ PLUGIN _ ID ĊĊ ĉ override Ġfun Ġget Plugin Artifact (): ĠSub plugin Artifact Ġ{ Ċĉ ĉ return ĠSub plugin Artifact ( Ċĉĉ ĉ groupId Ġ= ĠBuild Config . AR TI FACT _ GROUP , Ċĉĉ ĉ artifactId Ġ= ĠBuild Config . AR TI FACT _ NAME , Ċĉĉ ĉ version Ġ= ĠBuild Config . AR TI FACT _ VERSION Ċĉ ĉ ) Ċ ĉ } ĊĊ ĉ override Ġfun Ġget Plugin Artifact For Native (): ĠSub plugin Artifact Ġ= Ġget Plugin Artifact () ĊĊ ĉ override Ġfun Ġapply To Compilation ( kotlin Compilation : ĠKotlin Compilation < *> ): ĠProvider < List < Sub plugin Option >> Ġ{ Ċĉ ĉ val Ġtarget Ġ= Ġkotlin Compilation . target Ċĉ ĉ val Ġproject Ġ= Ġtarget . project Ċĉ ĉ project . logger . info (" K Dyn Lib Gradle Plugin . apply To Compilation : Ġ'${ target . platform Type }' ") ĊĊĉ ĉ val Ġoptions Ġ= ĠlistOf ( Ċĉĉ ĉ Sub plugin Option (" target Name ", Ġtarget . target Name ), Ċĉĉ ĉ Sub plugin Option (" platform Type ", Ġtarget . platform Type . toString ()), Ċĉĉ ĉ Files Sub plugin Option (" ap classpath ", Ġproject . configurations . maybe Create (" kir pt er "). toList ()), Ċĉ ĉ ) ĊĊĉ ĉ val Ġconfig : ĠConfiguration Ġ= Ġproject . configurations . maybe Create (" kir pt er ") ĊĊĉ ĉ // println ( config . build Dependencies ) ĊĊĉ ĉ kotlin Compilation . compile Kotlin Task . depends On ( config . build Dependencies ) ĊĊĉ ĉ // println (" apply To Compilation : Ġ$ options ") Ċĉ ĉ // println (": Ġ${ project . configurations . maybe Create (" kir pt er "). toList () }") ĊĊĉ ĉ return Ġproject . provider Ġ{ Ġoptions Ġ} Ċ ĉ } Ċ }