NDK is not configured issue in android studio

后端 未结 6 926
Happy的楠姐
Happy的楠姐 2021-01-01 10:53

My Application is built successfully on Eclipse but fails to Build on android studio. It returns the error code Ndk is not Configured. Then I\'ve added ndk path

相关标签:
6条回答
  • 2021-01-01 11:35

    This is the problem faced by Android studio users in Windows environment. First for NDK not Configured problem

    Go to local.properties file and give ndk path... for ex :

    #Wed Mar 18 14:10:33 IST 2015
    sdk.dir=C\:\\Users\\admin\\AppData\\Local\\Android\\sdk1
    ndk.dir=C\:\\Users\\admin\\AppData\\Local\\Android\\ndk
    

    Then for the Next Problem or Error...

    Goto JNI Folder and create an empty c file by any name... Then your problem will be solved...

    Some Quick links about this are http://ph0b.com/android-studio-gradle-and-ndk-integration/ And https://code.google.com/p/android/issues/detail?id=66937

    0 讨论(0)
  • 2021-01-01 11:39

    Goto Files -> Project Structure -> SDK Location

    Android NDK Location is at the bottom right of the window.

    0 讨论(0)
  • Go to option File->Project Structure

    Select SDK Location->Android NDK Location and choose NDK listed in dropdown

    0 讨论(0)
  • 2021-01-01 11:45

    I use Android Studio 1.4.1.

    Below is my local.properties

    ndk.dir=C:\Users\BestQ\AppData\Local\Android\Sdk\ndk-bundle sdk.dir=C:\Users\BestQ\AppData\Local\Android\Sdk

    It work well.

    0 讨论(0)
  • 2021-01-01 11:46

    For whatever reason, setting ndk.dir on the properties file is not working for me. However, setting/exporting the variable ANDROID_NDK_HOME prior to launching android studio did the trick.

    Bash syntax (paths below are specific to my installation)

    export ANDROID_HOME=/opt/android-sdk-linux
    export ANDROID_NDK_HOME=$ANDROID_HOME/ndk-bundle
    

    Environment

    Ubuntu Linux x64/GNU bash, version 4.4/Android Studio 2.2.3
    
    0 讨论(0)
  • 2021-01-01 11:51

    My issue was caused by the target file not being found (in my case, a git sub-module needed to be checked out), so ensure all the referenced files exist on the specified path.

    0 讨论(0)
提交回复
热议问题