Published:11/27/2013 Last Updated:11/27/2013
This whitepaper discusses the Android* NDK, a tool set for developing Android* applications with embedded native code. It describes the basic coding structures of NDK applications. It also provides instructions on how to install the NDK, and how to use the NDK to build applications.
The NDK helps the Android* developer include C or C++ code in their applications. It consists of the following components:
The main goals of the NDK include:
Coding in C or C++ does not always result in higher performance of the applications. Instead it always increases the complexity of the code. Outside of the two main goals discussed above, we encourage developers to implement new functionalities solely based on the Android* SDK.
The Android* SDK
Java*
Operating Systems
You can go to http://developer.android.com/sdk/ndk/index.html to find the NDK installation package.
The Android* NDK is based on the Java* Native Interface (JNI) programming framework.
You can build your native code by running "$NDK/ndk-build" script from your project directory, or any of its sub-directories.
The NDK provides a command line script ndk-gdb which can be used to debug the embedded native code.
For Intel® architecture-based Android* platforms, the NDK is a very useful complement to the SDK. It enables the reusability and under some circumstance increases the performance. With these fundamental goals, the NDK provides a set of tools to build, integrate, test, and debug the native source code embedded in the application. On the other hand, the NDK increases the coding complexity. It should be applied only to achieve the goals described here.
* Other names and brands may be claimed as the property of others
Copyright © 2011 Intel Corporation. All rights reserved.
Intel and Atom are trademarks of Intel Corporation in the U.S. and/or other countries.
INFORMATION IN THIS DOCUMENT IS PROVIDED IN CONNECTION WITH INTEL PRODUCTS. NO LICENSE, EXPRESS OR IMPLIED, BY ESTOPPEL OR OTHERWISE, TO ANY INTELLECTUAL PROPERTY RIGHTS IS GRANTED BY THIS DOCUMENT. EXCEPT AS PROVIDED IN INTEL'S TERMS AND CONDITIONS OF SALE FOR SUCH PRODUCTS, INTEL ASSUMES NO LIABILITY WHATSOEVER AND INTEL DISCLAIMS ANY EXPRESS OR IMPLIED WARRANTY, RELATING TO SALE AND/OR USE OF INTEL PRODUCTS INCLUDING LIABILITY OR WARRANTIES RELATING TO FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR INFRINGEMENT OF ANY PATENT, COPYRIGHT OR OTHER INTELLECTUAL PROPERTY RIGHT.
UNLESS OTHERWISE AGREED IN WRITING BY INTEL, THE INTEL PRODUCTS ARE NOT DESIGNED NOR INTENDED FOR ANY APPLICATION IN WHICH THE FAILURE OF THE INTEL PRODUCT COULD CREATE A SITUATION WHERE PERSONAL INJURY OR DEATH MAY OCCUR.
Intel may make changes to specifications and product descriptions at any time, without notice. Designers must not rely on the absence or characteristics of any features or instructions marked "reserved" or "undefined". Intel reserves these for future definition and shall have no responsibility whatsoever for conflicts or incompatibilities arising from future changes to them. The information here is subject to change without notice. Do not finalize a design with this information.
The products described in this document may contain design defects or errors known as errata which may cause the product to deviate from published specifications. Current characterized errata are available on request.
Contact your local Intel sales office or your distributor to obtain the latest specifications and before placing your product order.
Copies of documents which have an order number and are referenced in this document, or other Intel literature, may be obtained by calling 1-800-548-4725, or go to: http://www.intel.com/design/literature.htm
Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.