License for package Android SDK Build-Tools 29.0.2not accepted
License for package Android SDK Build-Tools 29.0.2not accepted
移植别人的安卓程序时进行编译发现出现以下问题
License for package Android SDK Build-Tools 29.0.2not accepted
ERROR: Failed to install the following Android SDK packages as some licences have not been accepted.
platforms;android-25 Android SDK Platform 25
build-tools;29.0.2 Android SDK Build-Tools 29.0.2
To build this project, accept the SDK license agreements and install the missing components using the Android Studio SDK Manager.
Alternatively, to transfer the license agreements from one workstation to another, see http://d.android.com/r/studio-ui/export-licenses.html
百度了很多解决方法,发现一些解决办法都是基于旧版本的SDK,比如:
在SDK文件夹中找到bin文件夹后执行
sdkmanager.bat --licenses
然而,最新版的Android Studio 3.6.1并不没有这个文件夹。。。
因此,解决办法还是要从Android Studio源头做起
1.打开SDK manager
2.在sdk tool中勾选:show details
然后勾选上缺少的SDK版本号
3.点击OK 进行安州即可解决