小编典典

Android上的React Native无法找到构建工具

reactjs

是什么引起以下问题?我的Android SDK版本不受支持吗?

Starting JS server...                                                                     
Building and installing the app on the device (cd android && gradlew.bat installDebug)...

FAILURE: Build failed with an exception.

* What went wrong:                                                                        
A problem occurred configuring project ':app'.                                            
> failed to find Build Tools revision 23.0.1

阅读 308

收藏
2020-07-22

共1个答案

小编典典

可能您需要更新构建工具。

当我尝试从图形界面进行更新时遇到了问题,它没有显示确切的次要版本,因此无法更新。

通过查看终端提供的版本来解决此问题:

android list sdk -a



[...]
Packages available for installation or update: 156
1- Android SDK Tools, revision 24.4
2- Android SDK Platform-tools, revision 23.0.1
3- Android SDK Platform-tools, revision 23.1 rc1
4- Android SDK Build-tools, revision 23.0.1

[…]

并使用以下命令安装正确的版本:

android update sdk -a -u -t 4
2020-07-22