Home > Environment > [Android] installation of NDK

Installation of [Android] NDK

Note when you have installed the Android NDK in Eclipse you have installed on MacOSX.
(In order to use the make command in the ndk-build command, that you install, etc. Xcode)
Download Android NDK

  1. File Download the following
  2. Unzip the downloaded file, and stores it in the appropriate folder (example: User / username / Developer)

Installation of CDT (C / C ++ Development Tooling)

  1. I open the> "Install New Software ..." - "Help"
  2. I choose the - "http://download.eclipse.org/release/helios Helios" to: "working on"
  3. The check When the list is displayed from the "programming language" to those described below, to install
    • C / C ++ Development Tools
    • C / C ++ Library API Documentation Hover Help (incubation)

Additional environment variable

  1. I open the .bash_profile
    • vim ~ / .bash_profile
  2. Add to "PATH" where to store the NDK (example NDK location: / Users / username / Developer / android-ndk-mac)
    ANDROIDNDK_HOME=/Users/username/Developer/android-ndk-mac PATH=$PATH:${ANDROIDNDK_HOME} 
  3. .bash_profile was reread, to reflect the changes
    • source ~ / .bash_profile
  4. I check whether the environment variable is reflected
    • printenv PATH
  5. (If, in the first place I want to append a sentence below the last line in .bash_profile you did not exist environment variable "PATH")
     export PATH 

build hello-jni library

It is confirmed that the preferences are in place to try to build the samples that are included in the NDK.

  1. Go to the directory of the hello-jni (example: / Users / username / Developer / android-ndk-mac / sample / hello-jni /)
    • cd / Users / username / Developer / android-ndk-mac / sample / hello-jni /
  2. to build in ndk-build command (if successful will output like below)
     Gdbserver : [arm-linux-androideabi-4.4.3] libs/armeabi/gdbserver Gdbsetup : libs/armeabi/gdb.setup Compile thumb : hello-jni <= hello-jni.c SharedLibrary : libhello-jni.so Install : libhello-jni.so => libs/armeabi/libhello-jni.so 
ツイート Tweets

Comments: 0

Comment form
and stores the entered information

Trackbacks: 1

Trackback URL for this article
Send trackbacks source list
[Android] NDK installation of - MoonWing than
pingback - that it was hooked in Titanium Module 1.8 system and (make module) | development memo Attouehi 4月14日年2014 than

[...] Http://Mwlab.Net/2011/02/macosx_install_ndk.Html [...]

Home > Environment > [Android] installation of NDK

Japanese flagEnglish flag

I back to the top of the page