Debugging a project that uses JNI Invocation

I am new to IntelliJ and just started using version 11. I have a project that relies on JNI and uses C++ code to launch a JVM before executing the JAVA code. Is there a configuration or perhaps a plug-in that will allow me to debug this project? I would be happy just being able to debug the JAVA code since that is where the meat of the project lives, but a solution that could do both would be great.  Thanks.

3 comments
Comment actions Permalink

You can modify C++ code to make it pass debug options (-Xdebug etc.) to a JVM, and then use Remote debug configuration to connect to it.

0
Comment actions Permalink

Thanks, I will try that. Do you know of any good recourses/examples of this type of setup?

0
Comment actions Permalink

No, but that shouldn't be hard.
Just create run/debug configuration (Run | Edit Configurations | [+] | Remote), and IDEA will suggest you debugging options to pass to JVM.

0

Please sign in to leave a comment.