How to debug Kotlin Native application?

Answered

I have a Kotlin native application that I can build and run on a Mac, but I can't debug it. Running using the gradle `runDebugExecutableNative` task works, but breakpoints don't work even if I start it with the debug button.

I have installed the "Native Debugging Support" plugin, but there is no clue on how to use it. In the "Add run configuration" there is no template for Kotlin Native, only "Kotlin" (presumably JVM) and "Kotlin Script".

I have IntelliJ IDEA 2021.3.1 (Ultimate Edition) and am using Kotlin 1.6.10.

Can someone point me in the right direction?

 

0
5 comments
Avatar
Permanently deleted user

There is a problem with Native Debugging Support plugin, covered by this issue in Kotlin's official tracker: https://youtrack.jetbrains.com/issue/KT-51196.

0

I just tried to debug the hellow world progam after having it created with the current version of IntelliJ. Building and running it, is no problem. But When I want to debug it, I get: 

Cannot invoke "com.intellij.xdebugger.XDebugProcess.createValueMarkerProvider()" because "this.myDebugProcess" is null

0

Did you install "Native Debugging Support" plugin?

0

Yes, Native Debugging Support plugin is installed. If it helps: My OS is Debian Sid.

0

Thank you! Please, file an issue https://kotl.in/issue and attach your project and `idea.log`.

0

Please sign in to leave a comment.