Serious problems with Tegra Android Developer Pack on OSX 10.8.3

Please let me know if you need any more information.

Thanks,

Vince


Environment OSX 10.8.3, Jelly Bean 4.2.2, Nexus 7 (also 4 & 10)

Repro Steps:

Download Tegra Android Developer Pack from
https://developer.nvidia.com/tegra-resources

Install Tegra Android Developer Pack with default options
Start Eclipse from Finder

set NDK path in eclipse preferences (perhaps this could be set automatically by the installer?)
set AndroidManifest.xml debuggable=true (IMHO, this should be default for sample applications)

clean all projects

First error:
ndk-build: no such file or directory

NDKROOT is set by the NVidia installer in .bashrc and .bash_profile but those variables are not picked up by Eclipse started by the Launcher

Workaround: start eclipse from a terminal window

$ NVPACK/eclipse/Eclipse.app/Contents/MacOS/eclipse

Second error:

11:22:26 **** Clean-only build of configuration Default for project NativeBasic ****
/bin/bash /Users/vharron/NVPACK/android-ndk-r8d/ndk-build NDK_DEBUG=1 V=1 clean
Invalid attribute name:
package
/Users/vharron/NVPACK/android-ndk-r8d/build/gmsl/__gmsl:512: *** non-numeric second argument to `wordlist’ function: ‘’. Stop.

11:22:26 Build Finished (took 72ms)

Workaround: unknown

Right click “NativeGlobe” project

Run As… “Android Application” works!

Set breakpoints at
native_globe.cpp:40
(First line of code in) void android_main(struct android_app* app)

First code in
GlobeApp.cpp:431
(First line of code in) bool GlobeApp::renderGL(const float current_time)

(It’s odd to me that the project builds when I toggle breakpoints)

Right click on “NativeGlobe”

Debug As… Android Native Application
Third error Source builds, but application is not launched.

Debug As… Android NDK Application

Source builds, but application is launched,
Fourth error: but breakpoints don’t work

(snip)
NDK: Are you sure your NDK_MODULE_PATH variable is properly defined?
(snip)
NDK: Starting up gdbserver :12345 --attach 2605 6.673
GdbServerReceiver: /system/bin/sh: gdbserver: not found
NDK: Gdbserver not started properly
NDK: Launch error: Failed to connect to remote VM

So I did some googling and tried adding NDK_MODULE_PATH line to NativeGlobe/jni/Android.mk (why not have this line in by default?)

#----------------------------------------------------------------------------------
LOCAL_PATH := (subst //,/,(call my-dir))
include (CLEAR_VARS) NDK_MODULE_PATH := (LOCAL_PATH)
LOCAL_MODULE := native_globe

Clean build

Debug As… Android NDK Application

Console output:
(snip)
NDK: Starting up gdbserver :12345 --attach 2605 6.673
GdbServerReceiver: /system/bin/sh: gdbserver: not found
NDK: Gdbserver not started properly
NDK: Launch error: Failed to connect to remote VM

Fifth error: A lot of the error text went away, but breakpoints still don’t work.
error5.txt (2.75 KB)
error4.txt (14.7 KB)

The security restrictions on this site are driving me crazy, keep rejecting my posts.

(snip)

Hi Vince,

Sorry for the inconvenience. I’m looking into your issues now. I’ll let you know if I require any more information.

-Jeff

Hi, Vince
for first error:
you need to logout-login to make the env effective

for second error:
that’s a defect we missed, please run dos2unix or something like that to AndroidManifest.xml of NativeBasic

for third&&fourth error:
Debug As… Android NDK Application is what our eclipse plugin provides.
by default, it use system’s gdbserver, that means your devices should be rooted and you need to have gdbserver in $PATH. e.g in /system/bin. You can modify it to use apk bundled gdbserver. Debug As->Debug Configuration->Android NDK Application->your app->Debugger->Gdbserver Settings

Hi Vince -

Please let us know if you continue to have issues.

Cheers!

I was using the Tegra Android Developer Pack in eclipse to debug my native c++ android application and it was working fine till i upgraded to Xcode 5. After that every time i try to debug as “Android NDK Application” i get the error:

NDK: Gdbserver not started properly
NDK: Launch error: Failed to connect to remote VM

I am pretty sure that upgrading to Xcode 5 is responsible for this error; I just can’t figure out how to fix it. I have tried using the option “APK Bundled” under Gdbserer settings, but it just gets stuck at “waiting for debugger to settle” no matter how long i leave it on for. How do i fix this?

Thanks.