Is there way to write JNI binding for Kotlin/JVM u...
# kotlin-native
a
Is there way to write JNI binding for Kotlin/JVM under Kotlin/Native (instead of C++)?
r
Not at the moment. There is an internal API within cinterop, I've seen multiple persons showing some interest in polishing it to allow external usage, but no actual activity for that.
n
I might be reading the question wrong, but I'm using
@CName
in K/N and invoking it from JVM with no issues.
s
@natario1 do you have any examples/sample code?
@Animesh Sahu you might wanna star/reply to this: https://youtrack.jetbrains.com/issue/KT-39144
n
If you google "kotlin native jni" you should find examples and blog posts.
g
but I’m using 
@CName
 in K/N and invoking it from JVM with no issues
But it requires writing JNI manually, this is the whole problem of this approach
But if original question is “is it possible to write JNI binding for K/N methods”, then yes, no issue there