android4.1.1系统编译全过程
android4.1.1系统编译全过程 一、编译环境:首先介绍编译中使用的工具:虚拟机: vmare 9 下载地址:http://blog.csdn.net/hudan2714/article/details/7902654linux平台:ubuntu 12.04 64位jdk: sun-java6-jdk (
OSError: libGL.so: cannot open shared object file: No such file or directory
may appear on Linux systems when you try to launch VNL for the first time. To solve it, create (as administrator) a new link in /usr/lib:
sudo ln -s /usr/lib/libGL.so.1.2 /usr/lib/libGL.so
If you have a 64-bit Linux, use /usr/lib64 instead.
First check that you actually have "libGL.so.1.2" in /usr/lib or /usr/lib64; it might be called "libGL.so.1" or something else instead, or located in another directory, depending on the video drivers. You can use
locate libGL
to find the correct file to link to.
而我使用的是ubuntu 12.04 bit-64位,在/usr/lib/并没有libGL.so文件。
可以使用locate libGL查找此文件。结果:

找出了这么多,当然是选择64位平台下的libGL了。


但是针对这几个,不知道要选择哪一个好,还请高手指点。
Failed to load libGL.so
error libGL.so: wrong ELF class: ELFCLASS64
linux系统是64位的,这个命令不支持64位
最佳解决方案,把oralce-lib环境变量设置为lib32即可

最后选择ln还36位
代码:hudan@ubuntu:~/android/source/android4.1.1/out$ sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1.2 /usr/lib/libGL.so

直接参数-ramdisk ramdisk.img去掉,结果模拟器跑起来了,但不能把内核启动起来。
no ABI error , when creating an Android virtual device
E: Could not get lock /var/lib/dpkg/lock - open (11: Resource temporarily unavailable)
E: Unable to lock the administration directory (/var/lib/dpkg/), is another process using it?
sh: gperf: not found
target Generated: libwebcore <= external/webkit/Source/JavaScriptCore/create_regex_tables
Generating CSSPropertyNames.h <= CSSPropertyNames.in
sh: gperf: not found
calling gperf failed: 32512 at ./makeprop.pl line 140.
make: *** [out/target/product/generic/obj/STATIC_LIBRARIES/libwebcore_intermediates/Source/WebCore/css/CSSPropertyNames.h] Error 25
make: *** Deleting file `out/target/product/generic/obj/STATIC_LIBRARIES/libwebcore_intermediates/Source/WebCore/css/CSSPropertyNames.h'
解决方法:sudo apt-get install gperf
n file included from /usr/include/stdlib.h:25,
/usr/include/features.h:323: 致命错误: bits/predefs.h:没有那个文件或目录编译中断。
make: *** [out/host/linux-x86/obj/EXECUTABLES/acp_intermediates/acp.o] 错误 1
make: *** [out/host/linux-86/obj/STATIC_LIBRARIES/libcts_audio_quality_intermediates/src/Adb.o] Error 1
安装:libc6-dev-i386
make: *** [out/target/product/generic/obj/SHARED_LIBRARIES/libwebcore_intermediates/LINKED/libwebcore.so] Error 1
make: *** Waiting for unfinished jobs....
make: *** [out/target/common/obj/APPS/android.core.tests.libcore.package.dalvik.no-core-tests-res_intermediates/noproguard.classes-with-local.dex] Error 130
上次make或或者mmm的时候生成一些错误的东西
可以使用:make clean 再重新make
解决:rm out/target/common/obj/APPS/ -r (如果还是有这样的错误,就只能clean了)
致命错误: zlib.h:没有那个文件或目录
g++: g++: selected multilib '32' not installed
sudo apt-get install libc6-dev ia32-libs lib32ncurses5-dev x11proto-core-dev libx11-dev lib32readline-gplv2-dev lib32z-dev libgl1-mesa-dev mingw32 tofrodos python-markdown libxml2-utils
sudo apt-get install g++-4.4-multilib
/usr/bin/ld: cannot find -lz
collect2: ld returned 1 exit status
make: *** [out/host/linux-x86/obj/EXECUTABLES/aapt_intermediates/aapt] Error 1
缺少lib32z1-dev,安装即可:apt-get install lib32z1-dev
/usr/bin/ld: cannot find -lncurses
collect2: ld 返回 1
首先到usr/lib/目录下寻找libncurses开头的文件
1.如果没有那就是缺少库文件
解决方法:
有这样一个结果:
libncurses5-dev - developer's libraries and docs for ncurses
安装libncurses
2.如果有这个文件,那么就不缺少库,只是文件类型的问题
查看此库应该不是以so结尾的,输入下面的代码,创建连接即可
sudo ln -rf libncurses(*****) libncurses.so
/usr/bin/ld: cannot find -lstdc++
collect2: ld returned 1 exit status
make: *** [out/host/linux-x86/obj/lib/libneo_util.so] 错误 1
缺少g++-multilib库,安装即可: apt-get install g++-multilib
解决: /usr/bin/ld: cannot find -lstdc++
查找 文件名中 有 libstdc 字段的文件:
1) 查找 libstdc++.so 文件。
/opt/matlab/sys/os/glnxa64/README.libstdc++
/opt/matlab/sys/os/glnxa64/libstdc++.so
sudo ln -s /usr/lib/x86_64-linux-gnu/libstdc++.so.6 /usr/lib/libstdc++.so
更多推荐



所有评论(0)