开发者

how to build / compile ndk application?

hi now i am download ndk but i dont know how to build and compile actually i am new for android application....now i am using linux...and i am not well in command line....

embdes@embdes-laptop:~$ cd /home/embdes/projects/android/android-sdk-linux_86
/platform-tools/
embdes@embdes-laptop:~/projects/android/android-sdk-linux_86/platform-tools$ 
./adb shell 
# ls
config
cache
sdcard
acct
mnt
d
etc
system
sys
sbin
proc
init.rc
init.goldfish.rc
init
default.prop
data
root
dev
# cd /sdcard
# ls
LOST.DIR
unnai.mp3
car.3gp
DCIM
cheetah-.3gp
funny.3gp
tshirt.3gp
Girl.3gp
dancing.3gp
b7.j开发者_运维问答peg
girl1.3gp
tv.3gp
sports.3gp
sports1.3gp
sports3.3gp
sport2.3gp
tv.jpeg
tv1.jpeg
global.jpeg
orange.jpeg
images.jpeg
ddddd.jpeg
balloons-lift-car.3gp
3d-little-monster.3gp
smoking.3gp
the.3gp
NO$GBA.2.6a.zip
worldreborn.bin
# 


Read getting started here: http://developer.android.com/sdk/ndk/index.html

also look at samples they explained here: http://developer.android.com/sdk/ndk/overview.html#samples

Here: android/ndk-tutorial/ you will find a tutorial on working with NDK in android.

TO use NDK with eclipse look at here: eclipse-and-android-ndk

Hope this helps.


  1. Download and install ndk

    You can install Ndk from https://developer.android.com/ndk/downloads/index.html At the time of writing ndk-r10e was the latest version and i was on linux 64 bits so i downloaded this - android-ndk-r10e-linux-x86_64.bin

2 after downloading you need to install it

change the permissions

chmod a+x android-ndk-r10e-linux-x86_64.bin

execute

./android-ndk-r10e-linux-x86_64.bin

3 add it to path on linux

export PATH=$PATH:/home/android-ndk-r10e
  1. To run a sample application use hello-jni under samples

    how to build / compile ndk application?

5.goto the project location from terminal and ndk-build

ndk-build 

how to build / compile ndk application?

  1. Run the application in emulator to see results

    how to build / compile ndk application?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜