问题
Recently installed Android Studio 1.0.1 (old version for some reasons) on Ubuntu 15, and I am trying to create a new project. Whenever I build it I get this error
Cannot run program "/home/user/Android/Sdk/build-tools/23.0.2/aapt": error=2 No such file or directory"
The file exists there.
回答1:
sudo apt-get install lib32stdc++6 lib32z1
回答2:
please check your compileSdkVersion and buildToolsVersion and targetSdkVersion please same the value. simple :
compileSdkVersion "23"
buildToolsVersion "23"
targetSdkVersion "23"
回答3:
I am using react-native for android. I encountered the same problem
Cannot run program "/home/user/Android/Sdk/build-tools/23.0.2/aapt":
error=2 No such file or directory"
but I changed the build tool version to 26.0.2 and it solved build completed without any problem. I barely know why it happened.
来源:https://stackoverflow.com/questions/33427893/can-not-run-android-sdk-build-tools-23-0-2-aapt