【问题标题】:Cant build react native project for android in windows 10无法在 Windows 10 中为 android 构建反应原生项目
【发布时间】:2017-04-24 02:18:55
【问题描述】:

当我尝试构建我的项目时,它给了我这个错误

    Checking the license for package Android SDK Build-Tools 23.0.1 in C:\Users\ASUS\AppData\Local\Android\Sdk\tools\licenses
Warning: License for package Android SDK Build-Tools 23.0.1 not accepted.
Checking the license for package Android SDK Platform 23 in C:\Users\ASUS\AppData\Local\Android\Sdk\tools\licenses
Warning: License for package Android SDK Platform 23 not accepted.

FAILURE: Build failed with an exception.

* What went wrong:
A problem occurred configuring project ':app'.
> You have not accepted the license agreements of the following SDK components:
[Android SDK Platform 23, Android SDK Build-Tools 23.0.1].
Before building your project, you need to accept the license agreements and complete the installation of the missing components using the Android Studio SDK Manager.
Alternatively, to learn how to transfer the license agreements from one workstation to another, go to http://d.android.com/r/studio-ui/export-licenses.html

但我尝试将许可证添加到 sdk 路径它没有工作。我更新了我所有的 skd 平台和 sdk 工具。但我仍然收到这个错误。我该如何解决这个问题。

【问题讨论】:

    标签: javascript android facebook react-native cross-platform


    【解决方案1】:

    使用 Android 工具目录中的 android.bat 并使用它安装所有依赖项。然后在下载/安装时会要求您接受许可证。

    【讨论】:

    • 如何从Android.bat文件安装依赖?
    • 只需运行 android.bat 文件 - 您将看到一个 UI,您可以在其中选择所需的依赖项。然后,您将安装 Android SDK Platform 23。
    • 我运行了bat文件,但是没有打开任何界面,消失了
    猜你喜欢
    • 2021-10-27
    • 2020-07-09
    • 1970-01-01
    • 2016-05-09
    • 2020-01-23
    • 1970-01-01
    • 2022-10-23
    • 2020-05-28
    • 2016-12-01
    相关资源
    最近更新 更多