Download NDKA mirror site in the domestic download speed is relatively fast http://wear.techbrood.com/tools/sdk/ndk/#Installing
There are many 1 scenarios for setting up an environment online. Eclipse + ADT + NDK 2. Androidstudio + NDK3. VS + NDK4. VS + visualgdb (can be used after installation, VISUALGDB charge) 5. Editor (e.g. Sublime) + NDK
However, before setting up the above environment, we will first configure the Ndk_root.
Configure Ndk_root
Add environment variable Ndk_root to: E:\Android\android-ndk-r10b
Added under environment variable PATH:%ndk_root%;
When the environment variable is configured, enter Ndk_build in the CMD directory to display the relevant message using the Ndk_build + editor + makefile You can start developing
Eclipse Environment Setup1. Set the NDK path
Android Tools->add Native Support
At this time the project will be more than one Jni folder, JNI under the Android.mk and My-ndk.cpp files. ANDROID.MK is the NDK project Makefile,my-ndk.cpp is the NDK source files this time can be imported from the NDK Samples directory hello_jni import source code to compile, remember is copy to the current project directory
eclipse highlighting, smart tips questions:The first time not smart tips, this time to run the project, there is a highlight and smart tips
Configure includeSometimes you have to add some libraries or header files to the directory: Eclipse right-click Project Properties->c++ general-> Paths and Symbols:
E:\android\android-ndk-r10b\platforms\android-19\arch-arm\usr\includee:\android\android-ndk-r10b\sources\ Cxx-stl\gnu-libstdc++\4.6\libs\armeabi-v7a\includee:\android\android-ndk-r10b\sources\cxx-stl\gnu-libstdc++\ 4.6\include
From for notes (Wiz)
NDK Learning One: Environment building Eclipse article