【问题标题】:React Native android build failed. SDK location not foundReact Native android 构建失败。未找到 SDK 位置
【发布时间】:2015-12-14 13:26:43
【问题描述】:

我开始运行android时出现错误

What went wrong:
A problem occurred evaluating project ':app'.  
> SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable.

【问题讨论】:

  • 这发生在我的第一个 hello world 中,即使 env 变量设置正确,我所做的是,在 android studio 中打开 android 文件夹并点击运行按钮(绿色播放图标)它有效,确保你的地铁在你这样做的时候正在运行,我认为它正在发生,因为我在安装后没有打开 android studio,当我在 andriod studio 中打开 android 文件夹时,我注意到它更新了一些东西,现在甚至 npm run安卓运行良好

标签: android react-native


【解决方案1】:

如果你安装了android studio,只需使用Android Studio打开Project/android,它就会通知你在项目中切换SDK位置路径。

【讨论】:

    猜你喜欢
    • 2018-03-08
    • 2019-03-21
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-08-12
    • 2016-07-05
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多