Android Studio First project Project Sync Error, Android NDK location is not valid.Install NDK and sync project ???

373 views
Skip to first unread message

Randy

unread,
Mar 17, 2017, 2:43:43 AM3/17/17
to android-ndk
I am new in this environment, 

I just installed the Android Studio, and when I have inizialized a new blank project it shows the following error:

Project Sync Error
Android NDK location is not valid.
Install NDK and sync project (link type highlighted)

How can I solve it because it seems a native problem.

I click the link it "install " something but the problem remains...

Help please...

Gerry Fan

unread,
Mar 24, 2017, 4:19:05 PM3/24/17
to android-ndk
Maybe refer to this one:

Another "shortcut" [sometimes may not be short]:
  0) download NDK and unzip it to somewhere from: https://developer.android.com/ndk/downloads/index.html
  1) open ${your_project_dir}/local.properties
        you should already see SDK directory config there; add your NDK's manually with your own local downloaded NDK directory:
            ndk.dir=your/own/ndk/directory
 2) then you could sync it again

(the other way is to configure your studio IDE to your SDK and NDK locations from "File --> Project Structure"


Question: if your project does not have native code, it should not ask for NDK location though. could you confirm?

thanks
Reply all
Reply to author
Forward
0 new messages