The NDK includes a set of cross-toolchains (compilers, linkers, etc..) that can generate native ARM binaries on Linux, OS X, and Windows (with Cygwin) platforms.
It provides a set of system headers for stable native APIs that are guaranteed to be supported in all later releases of the platform:
- libc (C library) headers
- libm (math library) headers
- JNI interface headers
- libz (Zlib compression) headers
- liblog (Android logging) header
- OpenGL ES 1.1 and OpenGL ES 2.0 (3D graphics libraries) headers
- libjnigraphics (Pixel buffer access) header (for Android 2.2 and above).
- A Minimal set of headers for C++ support
- OpenSL ES native audio libraries
- Android native application APIS
Installing the NDK
Develop on eclipse:
if installed successful, you could create c++ on new project
write a first NDK
1. new a android project.
2. in this project, select “new\otehr\convert to a C/C++ project”
3 select your project and select convert to c or c++ “c++ project”
4. create 3 folders, “native”,”libs”,”obj”
5. update path and symbols, select “Properties\c/c++ General\ Paths and symbols”,
add your xxx/native to tere, and remove xxx, like below image
good reference: http://marakana.com/forums/android/examples/49.html