自动化交叉编译Webkit

来源:互联网 发布:天猫订购软件 编辑:程序博客网 时间:2024/05/29 06:54

重要信息
最后支持DFB的GTK+版本是2.16,不过GTK-DFB的稳定版本是2.10
 WEBKITGTK maillist:http://www.mail-archive.com/webkit-gtk@lists.webkit.org/msg01516.html

http://www.directfb.org/wiki/index.php/Projects%3aGTK_on_DirectFB


http://webkitgtk.org/releases/
http://ftp.gnome.org/pub/gnome/sources/gtk+/2.10/

http://webkitgtk.org/releases/ 

webkitgtk-1.11.91.tar.xz
the most recent stable release of gtk+ was 2.10.13 
http://ftp.gnome.org/pub/gnome/sources/gtk+/2.10/ 
gtk+-2.10.13.tar.gz 
Felix Shi12:33
http://www.directfb.org/wiki/index.php/Projects%3aGTK_on_DirectFB 

可能的后端:

openWRT

参考Tiny Linux Core,这玩意带了X11也就6M
 Tiny X
是6M还是10M反正 


https://gist.github.com/namhyung/99588

http://webkit.sed.hu/blog/20091111/compiling-webkitgtk-scratchbox-arm-platform

 

成功编译gtk-dfb的配置示例:http://www.raspberrypi.org/phpBB3/viewtopic.php?t=11772&p=144694

在编译的过程中,遇到过下面的错误:

1. cann't find the cairo_surface

解决方案:由于是采用dfb作为后端,而webkitgtk默认是没有支持的,合并这个patch.https://bugs.webkit.org/show_bug.cgi?id=116717

 

2. 找不到x11相关的头文件。

解决方案:

step1. 在./Source/WebCore/bridge/npruntime_internal.h中用#if defined(MOZ_X11)来替代#ifdef XP_UNIX,具体参考https://bugs.webkit.org/show_bug.cgi?id=113687

step2. 在./Source/autotools/SetupAutoconfHeader.m4中去掉XP_UNIX的定义

正宗的解法参考这个
方法1.https://bugs.webkit.org/attachment.cgi?id=20705&action=prettypatch
方法2.

https://mail.mozilla.org/pipermail/plugin-futures/2012-April/000518.html

方法3. https://trac.macports.org/ticket/39898

3. 找不到依赖库提供的头文件

解决方案有几种:

a. 直接在安装前缀的目录下查找对应的头文件,手动做对应的软链接。

b. 写一个patch的shell 文件用来做对应的链接

c. 我估计应该在配置依赖库时应该是可以通过配置某些参数来实现的,等有空时在研究。

 

4.  编译gtk时提示

Can't link to Pango. Pango is required to build

解决方案:使用-rpath-link来指定依赖库的路径。详细解释看这里http://blog.chinaunix.net/uid-12532446-id-3165271.html

5. 编译webkitgtk时出现如下错误: 

/home/youtao/webkit-lib/include/jmorecfg.h:263:16:error: expected identifier before numeric constant
/home/youtao/webkit-lib/include/jmorecfg.h:263:16: error: expected '}' beforenumeric constant
/home/youtao/webkit-lib/include/jmorecfg.h:263:16: error: expectedunqualified-id before numeric constant
/home/youtao/webkit-lib/include/jmorecfg.h:263:38: error: 'boolean' does notname a type



解决方案:这是jpeg头文件的一个bug,

Editfile: /usr/local/include/jmorecfg.h

change line:

typedef enum { FALSE = 0 , TRUE = 1 } boolean;

to:

#if defined TRUE && defined FALSEtypedef bool boolean;#elsetypedef enum { FALSE = 0, TRUE = 1 } boolean;#endif

 

6. EditorClientGtk.cpp fatal error:webkitmarshal.h: No such file or directory



解决方案: 

touch ./Source/WebKit/gtk/webkitmarshal.list, 如果还是不行,请把用户切到LINUX系统当前的用户下尝试。
参考自https://bugs.webkit.org/show_bug.cgi?id=50534

 

7. build error which dependency the xslt feature, but we have disable it in the configurate phase.


解决方案:到Source/WTF/wtf/FeatureDefines.h中注释掉 xslt的定义

 


如何调试crash的问题,具体请参考
ulimit -c unlimited
http://www.cnblogs.com/li-hao/archive/2011/09/25/2190278.html


原创粉丝点击