


The required attributes are described below. If this option is not available the C/C++ extension is not installed and none of this is going to work.Ĭonfigure the debugger settings for the project. Open the Debug menu and click Add Configuration.Ĭhoose C/C++ (gdb) Launch as the configuration type. If the project does not specify the APP_OPTIM setting, setting NDK_DEBUG as described above will automatically disable optimizations.īefore debugging the first time, open the project workspace in VSCode and perform the following steps: Optimization can be disabled by passing APP_OPTIM=debug on the ndk-build command line, or by modifying it in the project's Application.mk file. While debugging optimized code it possible, it will be a more limited and difficult debugging experience. This will need to be copied to the target device to enable the debugger connection.Īlso, if the project's Application.mk file specifies the APP_OPTIM setting, it must be set to debug to disable compiler optimizations. This can be achieved by passing NDK_DEBUG=1 on the ndk-build command line, or by adding it to the project's Application.mk file. Enabling NDK_DEBUG also causes ndk-build to copy the correct version of gdbserver to the project's output directory. Used as default when native.abiMap is not specified in launch config.A build of the target project with debugging enabled. android-debug.abiMap: Map of ABI to custom string.Used as default when native.abiSupported is not specified in launch config. android-debug.abiSupported: List of supported ABIs for the app.android-debug.ndkRoot: Location for Android NDK on your machine.android-debug.sdkRoot: Location for Android SDK on your machine.The following settings can be set as per your requirements and setup. See Launch Configuration Options for more details. Language Support for Java(TM) by Red Hat extension for java debuggingįor a simple Android app with both Java and Native code, the following config should get you started. If you have these installed at custom locations, see Configurations.ĭebugger for Java extension for java debugging Select from connected devices or start an existing emulator for debugging.Īndroid SDK to be installed along with platform-tools and optionally Android NDK for native code debugging.Dynamic support for specifying and selecting ABIs to support various fat and split apk configurations.

Specify one or more locations to search for your so files, or source paths for Java.Please find or create issues on GitHub if you find something is not working as expected.ĭebug Android apps in VS Code, with Native, Java or Dual debugging.
