好不容易配好SDK,并且模拟器也开起来了,运行demo时出现:
Installed Build Tools revision 32.0.0 is corrupted. Remove and install again using the SDK Manager.
解决方案一:
参考:Installed Build Tools revision 32.0.0 is corrupted._皖赣城的博客-CSDN博客
方案是:找到你安装的sdk目录,将build tools/32.0.0文件夹下的d8改成dx, 将build tools/32.0.0/lib文件夹下d8.jar文件改成dx.jar
现在上面的问题解决了,但又出现了新的问题:
Manifest merger failed : Apps targeting Android 12 and higher are required to specify an explicit
大概是提示android版本问题,需要android12及以上的版本
项目manifests目录下的AndroidManifests.xml文件,在<activity>标签里加上
android:exported="true"