How to mix Java and kotlin when using ant?

I'm aware of an example using maven, but how can achieve the same with ant ?

Thanks.

outersky

First, you run the Kotlin compiler on the Kotlin sources you have, adding Java sources to the class path. It generates class files for the Kotlin code. Next, you run the Java compiler on the Java sources having the output of the Kotlin compiler on the class path: Java compiler sees the Kotlin classes and works fine.

It works.

But I found out that , if I compiled twice,  it recompiled all kotlin source files even though nothing is changed.

Yes, incremental compilation is not supported yet

see