Android NDK: Could not find application project directory

Posted Mars-xq

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Android NDK: Could not find application project directory相关的知识,希望对你有一定的参考价值。

参考:

Android问题集锦之四十:Android NDK: Could not find application project directory

一、问题

执行ndK-build报错:

> ndK-build

android NDK: Could not find application project directory !
Android NDK: Please define the NDK_PROJECT_PATH variable to point to it.

二、解决:

2.1 Android.mk / Application.mk 放到jni目录

直接执行即可:

ndk-build

2.2 Android.mk / Application.mk 不在 jni 目录,如放在 android 目录:

Application.mkApplication.mk 在同级目录,

然后在 Application.mk 中添加:

APP_BUILD_SCRIPT := Android.mk

最后执行命令:

cd android

ndk-build NDK_PROJECT_PATH=.       NDK_APPLICATION_MK=Application.mk
# 或
ndk-build NDK_PROJECT_PATH=$(pwd)/ NDK_APPLICATION_MK=$(pwd)/Application.mk

以上是关于Android NDK: Could not find application project directory的主要内容,如果未能解决你的问题,请参考以下文章

eclipse android ndk 提示Type 'JNIEnv' could not be resolved 等信息解决办法

错误记录NDK 配置错误 ( C/C++ debug|arm64-v8a : Could not get version from cmake.dir path )

Android Studio新建项目出错,Error:(22, 0) Could not find method android() for arguments

Got fatal error 1236 from master when reading data from binary log: 'Could not find first log fi

怎样解决电脑开机出现this application failed to start because it could not fi

Got fatal error 1236 from master when reading data from binary log: 'Could not find first log fi