Android Studio 无法构建新项目,等待从属 aapt 进程时超时

Android Studio 无法构建新项目,等待从属 aapt 进程时超时

问题描述:

我已经安装了 Android Studio 1.2,并创建了一个新项目.当我尝试构建时,它挂起.这是在 Gradle 控制台中,还有大约 20 个其他副本,在 png-cruncher_ 之后有不同的数字:

I've installed Android Studio 1.2, and created a new project. When I attempt to build, it hangs. This is in the Gradle Console, along with about 20 other copies, with different numbers after png-cruncher_:

Exception in thread "png-cruncher_2" java.lang.RuntimeException: Timed out while waiting for slave aapt process, try setting environment variable SLAVE_AAPT_TIMEOUT to a value bigger than 5 seconds
at com.android.builder.png.AaptProcess.waitForReady(AaptProcess.java:104)
at com.android.builder.png.QueuedCruncher$1.creation(QueuedCruncher.java:107)
at com.android.builder.tasks.WorkQueue.run(WorkQueue.java:204)
at java.lang.Thread.run(Thread.java:745)

我在使用 AMD64 的 Debian Jessie 时遇到了同样的问题.我这样做了,并且有效:

I had the same problem with Debian Jessie for AMD64. I did this, and it works:

sudo dpkg --add-architecture i386
sudo apt-get update
sudo apt-get install libncurses5:i386 libstdc++6:i386 zlib1g:i386