title: Unity: Build failure, unable to update the SDK
body: <p>Unity Latest update 2018.3 <br>
  SDK Tools and Platforms up to date according to SDK Manager. <br>
  Trying to build and run Android Build Settings.</p>
  
  <p>After updating the SDK, Unity still asks me to update the SDK by pressing a button built into the software. After I do this it tells me:</p>
  
  <blockquote>
    <p>Unable to update the SDK. Please run the SDK Manager manually to make
    sure you have the latest set of tools and the required platforms
    installed. See console log for details.</p>
  </blockquote>
  
  <p>When I take a look at the console, it tells me:</p>
  
  <pre><code>CommandInvokationFailure: Unable to update the SDK. Please run the SDK Manager manually to make sure you have the latest set of tools and the required platforms installed. 
  C:\Program Files (x86)\Android\android-sdk\tempToolsDir\bin\sdkmanager.bat --sdk_root=C:\Program Files (x86)\Android\android-sdk tools platform-tools "build-tools;28.0.3"
  
  stderr[
  Error: Failed to find package Files
  Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8
  ]
  stdout[
  
  ]
  exit code: 1
  UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at &lt;e1c3953b4cf040ddb1400046b1c34897&gt;:0)
  UnityEditor.Android.Command.RunWithStdin (System.Diagnostics.ProcessStartInfo psi, System.String errorMsg, System.Collections.Generic.IEnumerable`1[T] input) (at &lt;e1c3953b4cf040ddb1400046b1c34897&gt;:0)
  UnityEditor.Android.AndroidSDKTools.RunAndroidSdkTool (System.String toolName, System.String arguments, System.Boolean updateCommand, System.String errorMsg, System.String toolsDir) (at &lt;e1c3953b4cf040ddb1400046b1c34897&gt;:0)
  UnityEditor.Android.AndroidSDKTools.UpdateSDK (UnityEditor.Android.AndroidJavaTools javaTools) (at &lt;e1c3953b4cf040ddb1400046b1c34897&gt;:0)
  UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKComponentDetector.Update (UnityEditor.Android.AndroidSDKTools sdkTools, UnityEditor.Android.AndroidJavaTools javaTools, System.Version minVersion, UnityEditor.Android.PostProcessor.ProgressHandler onProgress) (at &lt;e1c3953b4cf040ddb1400046b1c34897&gt;:0)
  UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK.EnsureSDKComponentVersion (UnityEditor.Android.AndroidJavaTools javaTools, System.Version minVersion, UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK+SDKComponentDetector detector) (at &lt;e1c3953b4cf040ddb1400046b1c34897&gt;:0)
  UnityEditor.Android.PostProcessor.Tasks.CheckAndroidSDK.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at &lt;e1c3953b4cf040ddb1400046b1c34897&gt;:0)
  UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at &lt;e1c3953b4cf040ddb1400046b1c34897&gt;:0)
  UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
  </code></pre>
  
  <p>I have updated the SDK manually, it also gave me an error there. I fixed it doing this trick: <br> <a href="https://stackoverflow.com/questions/43796568/cant-update-tools-android-sdk-command-line-tools-for-windows">Can&#39;t update \tools - Android SDK Command Line Tools for Windows</a></p>
  
  <p>Anyway, I ran Unity with administrator, I ran the cmd with administrator for the manual updates and yet it still wont build. Help needed, thanks.</p>
  
  <p><a href="https://i.stack.imgur.com/4Cb99.png" rel="nofollow noreferrer">SCREENSHOT: Unity SDK Update for Android build</a></p>