search

Home  >  Q&A  >  body text

java - mac下配置ndk环境变量

我下载的最新AndroidStudio,安装了ndk ,但是没配置ndk环境变量
命令行输入:ndk-build,没有报错而是弹出Xcode未安装的提示框,并且一段提示

carmeloMac:build carmelo$ ndk-build
xcode-select: note: no developer tools were found at '/Applications/Xcode.app', requesting install. Choose an option in the dialog to download the command line developer tools.

这什么情况啊?

然后我配置下ndk的环境变量,还是一样提示!

export PATH=$PATH:/Users/carmelo/Android/sdk/ndk-bundle
export  ANDROID_NDK_ROOT=/Users/carmelo/Android/sdk/ndk-bundle

PHP中文网PHP中文网2806 days ago738

reply all(3)I'll reply

  • PHPz

    PHPz2017-04-18 10:51:31

    The prompt is very clear, if it is missing developer tools,并不是缺少 NDK just install it

    reply
    0
  • PHPz

    PHPz2017-04-18 10:51:31

    The root cause was found in the official Android ndk documentation:
    Running the ndk-build script is equivalent to running the following command:

    $GNUMAKE -f <ndk>/build/core/build-local.mk
    <parameters>
    $GNUMAKE points to GNU Make 3.81 or newer, <ndk> points to the NDK installation directory. You can use this information to call ndk-build from other shell scripts or even your own Make files.

    reply
    0
  • PHP中文网

    PHP中文网2017-04-18 10:51:31

    http://blog.csdn.net/github_3... You can refer to

    reply
    0
  • Cancelreply