现在的位置: 首页 > 综合 > 正文

从webkit转到android下开发浏览器

2013年03月02日 ⁄ 综合 ⁄ 共 5028字 ⁄ 字号 评论关闭

1. http://www.jjos.org/android/2010/05/10/312_webkit-webkit-for-android.html

2. http://mogoweb.net/archives/182

external: install chinese input method(http://www.2cto.com/os/201207/144189.html)

Build Environment:

System: Ubuntu 64bit 12.04, and do the upgrate

Platform: X86 Emulator

Code version: Android4.0

When I follow this guide build the android, I meet some error:

1. Cann't find the libgl1-mesa-glx:i386

Resolution: (http://www.rover12421.com/2013/08/12/ubuntu-12-04-on-libgl1-mesa-glx-i386-installation-problems.html?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+Rover12421+(Rover12421+%27s+Blog))

using the libgl1-mesa-glx-lts-quantal:i386 to replace thelibgl1-mesa-glx:i386

[Notice] Do not follow the instruction to install the libglapi-mesa:i386 or libgl1-mesa-dri:i386, otherwise after you reboot your system, it will crash.

If you have install the libgl1-mesa-glx:i386,
and restart the system and encounted the crash, please do not be worry, you still have the opportunity to recover your system.

step 1: restart your computer and select the ubuntu recovery mode,

stetp 2: select the enable the networking

step 3: select the root item.

step 4: in the terminal, remove the new installed libaries, and install the removed libaries. if you don't know which libaries you should to operate, please check this blog:http://www.rover12421.com/2013/08/12/ubuntu-12-04-on-libgl1-mesa-glx-i386-installation-problems.html?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+Rover12421+(Rover12421+%27s+Blog).

step 5: after finish doing this work, please restart your computer, then your system will be recovery.


if you still have any questions about this, please send me message, I will reply you in my free time.

2. Cann't install the sun-java6-jdk. 

Resolution:
install the sun-java6-sdk(http://hi.baidu.com/funnyscu/item/7802a0db29156bfdca0c398e)

step 1:利用root身份编辑sources.list文件

sudo gedit  /etc/apt/sources.list

step 2:在sources.list文件末尾添加如下源:

deb http://us.archive.ubuntu.com/ubuntu/ hardy multiverse

step 3:保存sources.list后在终端进行更新操作

sudo apt-get update

step 4:执行如下命令安装jdk6

sudo apt-get install sun-java6-jdk

3. Wrong Java Version


If you are attempting to build froyo or earlier with Java 1.6, or gingerbread or laterwith Java 1.5,make will abort with a message such as

************************************************************
You are attempting to build with the incorrect version
of java.

Your version is: WRONG_VERSION.
The correct version is: RIGHT_VERSION.

Please follow the machine setup instructions at
    https://source.android.com/source/download.html
************************************************************

After check using the java -version  and $PATH commands do the check, i find that it select  the open-jdk, but we need the sun-java-jdk, so change the system defaut jdk,

Resolution:

on this command, which lets you choose which Java installation to make the default:

sudo update-alternatives --config java

There are 2 choices for the alternative java (providing /usr/bin/java).

  Selection    Path                                           Priority   Status
------------------------------------------------------------
* 0            /usr/lib/jvm/java-6-openjdk-i386/jre/bin/java   1061      auto mode
  1            /usr/lib/jvm/java-6-openjdk-i386/jre/bin/java   1061      manual mode
  2            /usr/lib/jvm/java-7-oracle/jre/bin/java         1         manual mode

4.  Build meet the build error:

host C++: obbtool <= frameworks/base/tools/obbtool/Main.cpp
<command-line>:0:0: error: "_FORTIFY_SOURCE" redefined [-Werror]

Resolution:(http://blog.csdn.net/xumercury/article/details/7746229)

修改源码目录下/build/core/combo/HOST_linux-x86.mk文件:

将以下语句

HOST_GLOBAL_CFLAGS += -D_FORTIFY_SOURCE=0

修改为

HOST_GLOBAL_CFLAGS += -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0

5. Build meet the build error:

external/oprofile/libpp/format_output.h:94:22: error: reference ‘counts’ c

Resolution:(http://blog.sina.com.cn/s/blog_9815359e01018vjr.html)

把:

mutable counts_t & counts;
改为:
counts_t & counts;

6. Build meet the build error:

make: *** [out/host/linux-x86/obj/STATIC_LIBRARIES/libgtest_host_intermediates/gtest-all.o] Error 1

Resolution:(http://www.cnblogs.com/crazymod/archive/2012/05/18/2508062.html)

add

#include <cstddef>

in the external/gtest/include/gtest/internal/gtest-param-util.h

7. Build meet the build error:

make: *** [out/host/linux-x86/obj/EXECUTABLES/test-librsloader_intermediates/test-librsloader] 错误 1


Resolution:(http://blog.csdn.net/yrnaaa/article/details/7745680)

在external/llvm/llvm-host-build.mk中增加如下代码:
LOCAL_LDLIBS := -lpthread -ldl

8. Build meet the build error:

"acp: file 'out/host/linux-x86/obj/EXECUTABLES/vm-tests_intermediates/tests/data' does not exist"

Resolution:(http://tassardge.blog.163.com/blog/static/17230170820106127300562/)

按照这个提示创建对应的目录即可

9. Running error

android emulator: command not found

Resolution:(http://zhidao.baidu.com/question/330933056.html)

step 1 gedit /home/username/.bashrc

input

export PATH=$PATH:/your android path/out/host/linux-x86/bin

export ANDROID_PRODUCT_OUT=/your android path/out/target/product/generic

step 2
excute the source /home/username/.bashrc command in your terminal.

10. Running error

emulator: WARNING: system partition size adjusted to match image file (129 MB > 66 MB)

Resolution:(http://www.2cto.com/os/201205/130064.html)

emulator -partition-size 1024

11. Running error

NAND: could not open file /Android_40/out/target/product/generic/system.img, Permission denied

Resolution:

sudo chmod -R a+x out/

sudo chmod -R 777 out/stepsteps

【上篇】
【下篇】

抱歉!评论已关闭.