Debugging Java-Files
-
Hello,
In my project exits a .java file, which I would like to debug. Debugging on .cpp or .qml files is not a problem and works fine.
Is there any additional attitude to follow?
If it helps someone, I also have Android Studio installed on my computer. Maybe this can somehow connect with Qt Creator, but that's just an idea.I do not know how to continue and need your help.
PS: I work with Qt Creator 4.6.2
-
Hello,
In my project exits a .java file, which I would like to debug. Debugging on .cpp or .qml files is not a problem and works fine.
Is there any additional attitude to follow?
If it helps someone, I also have Android Studio installed on my computer. Maybe this can somehow connect with Qt Creator, but that's just an idea.I do not know how to continue and need your help.
PS: I work with Qt Creator 4.6.2
@Robin-Hood , I'm interested as well in this point.
I would like to debug my Java files when I create a QAndroidJNIObjects and run the method callMethod().There is any way to allow that with QTCreator?
-
I suppose that you are creating an Android app.
First, you need to create a project for Android Studio. To do it, simply go to Projects \ Build Settings \ Build Android APK and press the "Create Templates" button on Android section:
Open the generated project with Android Studio. Put breakpoints on the JAVA code.
On Android Studio exists an option for attach to a running app. Debug the app with Qt Creator and attach Android Studio to the app. After attach it, when the cpp code calls the JAVA code, Android Studio stops on the breakpoints.