Failed to attach: GDB server could not be found on the device

I have been hassling with this problem for the last day.

VS2010 and VS2013.

Yesterday I didn’t have a device so I was using the emulator and every time I got this error:

Failed to attach: GDB server could not be found on the device, /data/data/com.labs.test1/lib/gdbserver. It must be included with the application…

I had created an Android Native application using the wizard. I might have tried another type too but I forget.

I thought maybe because it wasn’t a physical device so today I tried a LG Optimus one LG500 and the same error. The error happens on the starting gdb server step.

I read all the forums here yesterday and Googled a lot but can’t work it out yet.

What can I do to fix this?

Hi Stuggy,
It seems that you are using release build for debug.could you check your build config?
Could you check project properties: AntBuild>AntBuildType> ?

No it is debug build. For example if I create a new application from the wizard and create a new Android native application then build and launch without changing anything I get the error.

Also after digging around I noticed that the AndroidManifest.xml doesn’t appear to be a normal xml file. The file is locatate at S:\AndroidNative6\Tegra-Android\Debug\AndroidNative6\AndroidManifest.xml. It opens as binary type data in an xml viewer. The manifest at S:\Androidnative6\Androidnative6 opens fine.

Another AndroidManifest from another app opens fine. I don’t know if this is expected behavior.

While we are at it does the data/data in the first screen cap above make sense?

OK I made some progress. I don’t know if this was something I should have known but changing the target architecture under project | general properties so that it matches the device appears to have got it working.

Maybe there could be a clearer explanation when it doesn’t work?

Hi Stuggy,

Thank you for reporting this! The message does seem to be unclear, I’ll create a ticket in our internal issue tracker regarding that.