NDK?

Trying to further the development of the Android on the Revue? Talk about it hear and document it on the wiki: http://www.wiki.gtvhacker.com

Moderator: Revue Mod

xsirxx
Android 1.0
Posts: 31
Joined: Thu Aug 04, 2011 10:28 am

NDK?

Post by xsirxx » Fri Oct 28, 2011 10:41 am

Forgive me if this has been asked before but with the release of the official honeycomb update I wanted to know what languages are supported on the revue. I was wondering if the NDK was supported on the revue? Or any C language for that matter. I have been working with a program under MonoDroid that I have not tested on the revue but do to its costs I figured I would look into porting over to the NDK and C++...

--X

hharte
Android 1.0
Posts: 8
Joined: Sat Aug 06, 2011 10:47 am

Re: NDK?

Post by hharte » Tue Nov 01, 2011 5:16 pm

The NDK is not supported on Google TV 2.0. If an app uses the NDK, it will be filtered out in Android Market on Google TV devices. That said, it is possible to compile native code for Google TV; however, shared libraries including libc.so are not available on the device, so you have to statically link. To make things worse, the ABI reported by the device is "none" while it should be something more reasonable like x86.

-Howard
-Howard

---
MagicAndroidApps.com - Home of Better Terminal Emulator Pro, now supporting Google TV.

xsirxx
Android 1.0
Posts: 31
Joined: Thu Aug 04, 2011 10:28 am

Re: NDK?

Post by xsirxx » Wed Nov 02, 2011 4:55 am

So what does that means exactly? Is there a chance you could get it to show up in market or does the program have to be sideloaded? Also is there a way to program with the sdk in. C++ or C#? Does monodroid translate to ndk or sdk?

Thanks a ton for helping me out with this!

--X

hharte
Android 1.0
Posts: 8
Joined: Sat Aug 06, 2011 10:47 am

Re: NDK?

Post by hharte » Wed Nov 02, 2011 11:02 pm

If you use the NDK, your app can be made to work if you statically link your shared library with libc and any other libraries you need. The ABI is "none" so you have to put your shared library in libs/none in your Android project.

You can then side-load the app. But, it will not show up in Market.

I don't know anything about monodroid, sorry.
-Howard

---
MagicAndroidApps.com - Home of Better Terminal Emulator Pro, now supporting Google TV.

hharte
Android 1.0
Posts: 8
Joined: Sat Aug 06, 2011 10:47 am

Re: NDK?

Post by hharte » Thu Nov 03, 2011 5:12 pm

Slight update, my Sony box updated to Google TV 2.0 this morning, and I was able to verify that my app Better Terminal Emulator Pro does appear in Market even though it uses native code. I didn't think that would be the case.
-Howard

---
MagicAndroidApps.com - Home of Better Terminal Emulator Pro, now supporting Google TV.

xsirxx
Android 1.0
Posts: 31
Joined: Thu Aug 04, 2011 10:28 am

Re: NDK?

Post by xsirxx » Fri Nov 04, 2011 9:48 am

you serious? So what all did you have to do? What language did you use, C or C++? And does it run? Because thats phenominal news..

Brad

mcd2000
Ice Cream Sandwich
Posts: 459
Joined: Wed Aug 03, 2011 5:52 am
GTV Device Owned: Vizio Co-Star
Location: Russia, Saint-Petersburg
Contact:

Re: NDK?

Post by mcd2000 » Sat Nov 05, 2011 8:32 am

hharte wrote:Slight update, my Sony box updated to Google TV 2.0 this morning, and I was able to verify that my app Better Terminal Emulator Pro does appear in Market even though it uses native code. I didn't think that would be the case.
Could you, please, provide a sample script for building a "helloworld" library? I've noticed that not all required .a libs are avaliable in the NDK to build a static library. Thanks.
Did you use ndk-build to do this?
ViMu Player
ViMu/GTVBox Google+ page
My devices: Logitech Revue, Sony NSZ-GT1, Sony NSZ-GS7, Vizio Co-Star, Hisense Pulse (rooted), ASUS Qube and some others...

hharte
Android 1.0
Posts: 8
Joined: Sat Aug 06, 2011 10:47 am

Re: NDK?

Post by hharte » Mon Nov 07, 2011 8:15 pm

I used the NDK described here:
http://gtvhacker.com/index.php/Logitech_Revue_Technical

I didn't have any luck with the official NDKr6.x86 (couldnt get it to statically link.). But I did not try with r6b yet.

And of course it works, that is how Better Terminal Emulator Pro is working on Google TV.
-Howard

---
MagicAndroidApps.com - Home of Better Terminal Emulator Pro, now supporting Google TV.

mcd2000
Ice Cream Sandwich
Posts: 459
Joined: Wed Aug 03, 2011 5:52 am
GTV Device Owned: Vizio Co-Star
Location: Russia, Saint-Petersburg
Contact:

Re: NDK?

Post by mcd2000 » Tue Nov 08, 2011 1:20 pm

hharte wrote:I used the NDK described here:
http://gtvhacker.com/index.php/Logitech_Revue_Technical
Wow! It works! Some kind of... I actually could not deal with all the makefiles and just fixed the last linker command (changed all .so references to .a). Don't think this is the right way. Anyways, It works. Thanks very much.
ViMu Player
ViMu/GTVBox Google+ page
My devices: Logitech Revue, Sony NSZ-GT1, Sony NSZ-GS7, Vizio Co-Star, Hisense Pulse (rooted), ASUS Qube and some others...

M1cha
Android 1.0
Posts: 39
Joined: Sat Oct 08, 2011 8:42 am

Re: NDK?

Post by M1cha » Mon Nov 21, 2011 8:58 am

I cannot install the NDK. I get the following error:
Step 2: Extract the SDK

bzip2: Compressed file ends unexpectedly;
perhaps it is corrupted? *Possible* reason follows.
bzip2: Inappropriate ioctl for device
Input file = (stdin), output file = (stdout)

It is possible that the compressed file(s) have become corrupted.
You can use the -tvv option to test integrity of such files.

You can use the `bzip2recover' program to attempt to recover
data from undamaged sections of corrupted files.

tar: Child returned status 2
tar: Error is not recoverable: exiting now
Does anyone have a solution to this?
I already re-executed the script (and the download) but it doesn't helps :(

Post Reply
 

 

cron

Login  •  Register