zipalign:加载共享库时出错:libc ++.so:无法打开共享对象文件:无此类文件或目录 [英] zipalign: error while loading shared libraries: libc++.so: cannot open shared object file: No such file or directory
问题描述
我正在尝试构建android应用.当我运行zip align工具优化APK时,出现以下错误消息:
I am trying to build android app. When I run the zip align tool to optimize the APK, I get this error message:
zipalign: error while loading shared libraries: libc++.so: cannot open shared object file: No such file or directory
我尝试安装libc ++
I tried to install libc++
sudo aptitude install libc++
它说:找不到软件包"libc +".
it says: Couldn't find package "libc+".
我的终端机快照
推荐答案
如果您的系统是64位的,则
If your system is 64-bits, there should be a folder lib64 on the path of
[android-path]/build-tools/[version]/
lib64中的文件是
The files in lib64 are
[ec2-user 25.0.2]$ ll lib64/
total 51628
-rwxrwxrwx 1 ec2-user ec2-user 30712616 Dec 23 07:22 libLLVM.so
-rwxrwxrwx 1 ec2-user ec2-user 482522 Dec 23 07:22 libbcc.so
-rwxrwxrwx 1 ec2-user ec2-user 433914 Dec 23 07:22 libbcinfo.so
-rwxrwxrwx 1 ec2-user ec2-user 1211614 Dec 23 07:22 libc++.so
-rwxrwxrwx 1 ec2-user ec2-user 20019608 Dec 23 07:22 libclang.so
只需将文件夹lib64和zipalign程序一起复制到目标路径,即可正确运行zipalign.
对我有用.我猜zipalign对lib64文件夹中的文件有依赖性.
Just copy the folder lib64 and zipalign program together to the destination path, and you can run the zipalign correctly.
It worked for me. I guess the zipalign has a dependency on the files in lib64 folder.
这篇关于zipalign:加载共享库时出错:libc ++.so:无法打开共享对象文件:无此类文件或目录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!