`

Getting Started with the NDK

 
阅读更多

http://developer.android.com/sdk/ndk/index.html

 

Once you've installed the NDK successfully, take a few minutes to read the documentation included in the NDK. You can find the documentation in the <ndk>/docs/ directory. In particular, please read the OVERVIEW.HTML document completely, so that you understand the intent of the NDK and how to use it.

If you used a previous version of the NDK, take a moment to review the list of NDK changes in the CHANGES.HTML document.

Here's the general outline of how you work with the NDK tools:

  1. Place your native sources under <project>/jni/...
  2. Create <project>/jni/Android.mk to describe your native sources to the NDK build system
  3. Optional: Create <project>/jni/Application.mk .
  4. Build your native code by running the 'ndk-build' script from your project's directory. It is located in the top-level NDK directory:
    cd <project>
    <ndk>/ndk-build
    

    The build tools copy the stripped, shared libraries needed by your application to the proper location in the application's project directory.

  5. Finally, compile your application using the SDK tools in the usual way. The SDK build tools will package the shared libraries in the application's deployable .apk file.

For complete information on all of the steps listed above, please see the documentation included with the NDK package.

 

-----------------------------------------------

Reference:

http://code.google.com/p/mingw-and-ndk/

如果遇到如下错误
make: *** [clean-installed-binaries] Error 127
看看你的PATH环境变量是否包括C:\cygwin\bin ,如果有,去掉。

 

分享到:
评论

相关推荐

    Pro Android C with the NDK.

    android 的C和C++开发Pro Android C with the NDK

    Pro Android C++ with the NDK.apress.2012

    Chapter 1: Getting Started with C++ on Android Chapter 2: Exploring the Android NDK Chapter 3: Communicating with Native Code using JNI Chapter 4: Auto-Generate JNI Code Using SWIG Chapter 5: Logging,...

    Android C++高级编程使用NDK [ Pro Android C++ with the NDK ]书源码

    《Android C++高级编程使用NDK》是一本深入探讨如何在Android平台上利用C++进行高效开发的专业书籍。这本书源码的提供,对于开发者来说是一份宝贵的参考资料,它涵盖了多个章节的示例代码,帮助读者更好地理解和实践...

    Pro Android C++ with the NDK

    Pro Android C++ with the NDK Native Development Kit) is an advanced tutorial and professional reference for today's more sophisticated app developers now porting, developing or employing C++ and ...

    Developing_Multimedia_Applications_with_NDK.pdf

    本文档《Developing_Multimedia_Applications_with_NDK.pdf》重点介绍了如何利用NDK(Native Development Kit)开发安卓的多媒体应用程序。内容覆盖了使用ffmpeg库移植到Android,获取媒体信息,视频帧的解码与显示...

    android-ndk-r18b-windows-x86_64中toolchains中相关的包

    完美解决 No toolchains found in the NDK toolchains folder for ABI with prefix: mips64el-linux-android,mips64el-linux-android-4.9

    AndroidStudio ndk mips64el-linux-android-4.9

    当出现"Error: No toolchains found in the NDK toolchains folder for ABI with prefix: mips64el-linux-android"时,意味着Android Studio无法找到对应的工具链来编译针对MIPS64处理器的代码。 首先,我们来理解...

    NDK相关书籍

    《NDK相关书籍》主要涵盖了两个重要的学习资源:《Pro Android C++ with the NDK》和《Android NDK Beginner’s Guide》,这两本书都是深入探讨Android NDK开发的宝贵教材。NDK(Native Development Kit)是Android...

    pro_android_cpp_with_the_ndk.pdf

    1.1.5 在Windows平台上下载并安装AndroidNDK 1.1.6 在Windows平台上下载并安装Eclipse 1.2 AppleMacOSX 1.2.1 在Mac平台上安装Xcode 1.2.2 验证Mac平台的Java开发包 1.2.3 验证Mac平台上的ApacheANT 1.2.4 验证GNU...

    解决方案: No toolchains found in the NDK toolchains folder for ABI with prefix: mips64el-linux-android

    这个问题的最根本原因是因为本地的 NDK 版本过高,而之前的工程在编译时使用的是老版本的 Gradle 插件,这样在打开工程进行同步时,老版本的插件会检查 NDK 中的两个工具链: mips64el-linux-android-4.9 mipsel-...

    NDK Google android ndk

    ### Android NDK详解 #### 一、Android NDK概述 Android NDK(Native Development Kit)是一组工具集合,旨在让Android应用开发者能够将C或C++编写的原生代码集成到其应用程序中。这一功能对于那些希望利用底层...

Global site tag (gtag.js) - Google Analytics