码迷,mamicode.com
首页 > 其他好文 > 详细

解决AAPT无法编译APK的问题

时间:2015-02-23 21:16:22      阅读:231      评论:0      收藏:0      [点我收藏+]

标签:android   64位   adt   aapt   ubuntu   

错误:

在Ubuntu 12.04 64位系统上运行Eclipse + ADT,报如下错误:

Error executing aapt. Please check aapt is present at /home/null/dev/sdk/build-tools/19.0.3/aapt	


原因:

没有安装32位库


解决方法:

Step-1. 修改Ubuntu更新源

$ sudo vi /etc/apt/sources.list
为如下内容
deb http://mirrors.aliyun.com/ubuntu/ precise main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ precise-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ precise-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ precise-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ precise-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ precise main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ precise-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ precise-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ precise-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ precise-backports main restricted universe multiverse

然后运行:

$ sudo apt-get clean
$ sudo apt-get update --fix-missing
$ sudo apt-get upgrade

Step-2. 安装32位库

sudo apt-get install ia32-libs
sudo apt-get install lib32z1

重启Ecipse,AAPT就可以编译通过了。

解决AAPT无法编译APK的问题

标签:android   64位   adt   aapt   ubuntu   

原文地址:http://blog.csdn.net/programs/article/details/43917685

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!