I keep getting this error when I try an Android build:
Error building Player: Win32Exception: ApplicationName=‘C:\Users\jimmy’s girl\Desktop\SDK files\adt-bundle-windows-x86_64-20131030\sdk\build-tools\android-4.4\aapt.exe’, CommandLine=‘package --auto-add-overlay -v -f -m -J gen -M AndroidManifest.xml -S “res” -I “C:/Users/jimmy’s girl/Desktop/SDK files/adt-bundle-windows-x86_64-20131030/sdk/platforms/android-19\android.jar” -F bin/resources.ap_’, CurrentDirectory=‘Temp/StagingArea’
What I’ve tried: Installed both 32 and 64 bit of jdk. Re-installed Unity and adt bundle. Installed all tools in the sdk and latest versions. I’ve tried to build different projects. Searched the forums for answers. I’m at a loss.
Are you using the r22 of android SDK, if so, Google decided to move the aapt.exe from tools directory to build-tools//aapt.exe
A quick solution for this is co copy the aapt.exe file from build-tools and paste as shortcut on tools directory. Keep the shortcut name as aapt.exe
dudes !!! just erase all the:
folders that are inside the build-tools folder (appdata>local>android>sdk>build=tools)
also delete al folders that are inside the “platforms” folder (appdata>local>android>sdk>platforms)
Then start unity again … and build your file !!
now it will popup with a msg that you need to update files for continuing the build (.apk file)
and it will install the correct build-tool and the correct platform itself !!
I ended up smashing my computer in half. Bought a new one, now it works
I followed the tutorial that said I only needed to install whatever was required for the OS version I was running on (Android 6.0 in my case), so I only installed that.
You also have to install the corresponding Tools, which is where aapt.exe is. I installed extra things, looking for the right stuff, but I think I highlighted the important ones for my version:
Solci’s post above is a great solution. If aapt.exe is not in \build-tools folder, you will need to update to a newer version of the Android SDK Build Tools from the Android SDK Manager
I know it’s a bit late to answer , but i know some people might still have this problem.
none of the solutions worked for me, then i realized i had two sub-folders in build-tools folder , one was “25.0.1” and the other was “27.0.3” , when i moved the “27.0.3” folder out of the directory , then i could successfully build my project.