When I run my android project in Intellij IDEA using an AVD I get this error
android-apt-compiler: Cannot run program "/Users/myAccount/Documents/android-sdk-macosx/platform-tools/aapt": error=2, No such file or directory
Can anyone help? Thanks in advance!
Yeah according to Simon in Android Hello-World compile error: Intellij cannot find aapt "It appears that the latest update to the r22 SDK release moved aapt and the lib jar from the platform-tools to the build-tools directory. While we wait for JetBrains to release an update, here's a quick fix using a couple of symbolic links for Unix users:
From your AndroidSDK/platform-tools directory, run the following:
ln -s ../build-tools/17.0.0/aapt aapt
ln -s ../build-tools/17.0.0/lib lib
...and IntelliJ should be able to compile as normal. "
Unfortunately copying is the easier way around this on windows... unless you use something like
mklink /H C:\Users\Tom\androidsdk\build-tools\17.0.0\aapt.exe C:\Users\Tom\androidsdk\platform-tools\aapt.exe
in the command prompt to attempt to make a hard link window's style of the file to your platform tools folder.
caveat I haven't tried this though...
我通过将所有文件从android-sdk / build-tools / 17.0.0复制到platform-tools文件夹来解决WIn上的这个问题。
i was successfully resolving on mac 10.8
copied only aapt and lib\\dx.jar and dx
from build-tools/18.0.1 to platform-tools
i copied only aapt.exe
and lib\\dx.jar
from build-tools\\android-4.2.2
to
platform-tools
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.