Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Installed Build Tools revision 28.0.3 is corrupted. How to fix this error

When I make a new proyect, then Build-make project or try to Run App in an emulator with sdk api level 28 (Android 9.0 Pie), the Build Output window always show me this error:

Installed Build Tools revision 28.0.3 is corrupted. Remove and install again using the SDK Manager. 

I removed and reinstalled the sdk several times, and always gives me the same error. I'm using Android Studio 3.6.3 with build:gradle:3.6.3.

like image 963
armen Avatar asked Apr 26 '20 00:04

armen


People also ask

Do you have android build tools installed at?

Android SDK Build-Tools is a component of the Android SDK required for building Android apps. It's installed in the <sdk>/build-tools/ directory.

How do you update buildToolsVersion?

If you want to change the Build Tools version in your project, that is specified in project's build. gradle file (in the 'app' module). Open the file and either add or update the Build Tools version you want to use by adding/updating the following property in the 'android' section: android { buildToolsVersion "27.0.


2 Answers

1) Open the SDK manager by clicking on the icon in the top right of Android Studio. (Or go to File > Settings > Appearance & Behavior > System Settings > Android SDK)

2) Open SDK Tools tab

3) At the bottom-right, click "Show Package Details"

4) Find Android SDK Build-Tools and uncheck the checkbox next to 28.0.3

5) Click apply in the bottom of the window. That will delete the component.

6) Now check the checkbox next to 28.0.3

7) Click apply in the bottom of the window. That will reinstall it.

SDK Tools Screenshot

like image 176
TrackRunner Avatar answered Sep 18 '22 08:09

TrackRunner


I tried

e.g. Open Your SDK Path: C:\Users\Administrator\AppData\Local\Android\Sdk\build-tools

  • rename android-S -> 31.0.0-rc5
  • copy build-tools\30.0.3\dx.bat -> 31.0.0-rc5\dx.bat
  • copy build-tools\30.0.3\lib\dx.jar -> 31.0.0-rc5\lib\dx.jar

then the build should succeed.

like image 33
Qiuyan Su Avatar answered Sep 20 '22 08:09

Qiuyan Su