NDK Build failing

血红的双手。 提交于 2020-01-05 04:27:08

问题


Am new to working with ndk. Seeing some posts and googling around i found the way to compile my native files using NDK. I installed ndk r7c. However when i used the command ndk-build i got the following error:

/cygdrive/d/android-ndk-r7c-windows/android-ndk-r7c/ndk-build
/cygdrive/d/android-ndk-r7c-windows/android-ndk-r7c/ndk-build: line 40: dirname: command not found
/cygdrive/d/android-ndk-r7c-windows/android-ndk-r7c/ndk-build: line 78: uname: command not found
ERROR: Unknown host operating system:

My directory for the project was:

Haris Riaz@HarisRiaz-PC /cygdrive/d/reader-2/android/jni

Am unable to know the nature of the problem. Please help me whats this error about and how to solve it. Thank You!


回答1:


From Haris Riaz@HarisRiaz-PC I can deduct that you are running on Linux. But according to android-ndk-r7c-windows, you are trying to run a windows version ow the NDK. And ERROR: Unknown host operating system: confirms this. Download Linux version of the NDK from here and you should be fine.



来源:https://stackoverflow.com/questions/15180058/ndk-build-failing

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!