webkit无法解析主字体并导致Fedora 20出现分段错误

时间:2014-05-19 18:35:44

标签: webkit fedora pygobject pyjamas webkitgtk

webkit3如何在Linux上解析其主要字体?

(在libwebkitgtk-3.0中出现了分段错误。有没有人遇到类似的问题?有没有办法解决它?如何调试或修复它,只需对系统进行最小的更改?)

gdb打印:

Program received signal SIGSEGV, Segmentation fault.
0x74a1bc87 in WebCore::RenderStyle::fontMetrics() const () from /lib/libwebkitgtk-3.0.so.0

安装debuginfo后的gdb回溯:

(gdb) bt
#0  primarySimpleFontData (...) at Source/WebCore/platform/graphics/FontGlyphs.h:123
#1  primaryFont           (...) at Source/WebCore/platform/graphics/Font.h:326
#2  fontMetrics           (...) at Source/WebCore/platform/graphics/Font.h:143
#3  WebCore::RenderStyle::fontMetrics 
                          (...) at Source/WebCore/rendering/style/RenderStyle.cpp:1335
#4  0x74a1bea3 in WebCore::RenderStyle::computedLineHeight 
                          (...) at Source/WebCore/rendering/style/RenderStyle.cpp:1376
#5  0x7488ef06 in WebCore::RenderBlock::lineHeight 
                          (...) at Source/WebCore/rendering/RenderBlock.cpp:6651

步骤导致:

Install pyjs.org following its readme file, set the virtualenv to pyjsroot/mypy. 
Install webkitgtk3 and pygobject3.
Source an environment setting file to set PATHONPATH to pyjsroot:/lib/python2.7/site-packages
Run in pyjsroot "mypy/bin/python examples/helloworld/Hello.py"

编辑:添加了gdb回溯。回溯告诉我webkit无法正确解析“主要字体”。更改标题从旧的“在运行pyjs时在fedora 20上的libwebkitgtk-3.0中的分段”来反映这一点。

1 个答案:

答案 0 :(得分:0)

更改为Frdora 21,分段错误消失了,但它没有正确显示字符。安装了以下包,然后一切正常。

xorg-x11-fonts-ISO8859-1-100dpi

gnu-free-fonts-common
gnu-free-mono-fonts
gnu-free-sans-fonts
gnu-free-serif-fonts

不确定是否需要xorg-x11-fonts-ISO8859-1-100dpi,但它确实带来了依赖性。在gnu-free- *中,需要-common,其他三个中的一个是必需的。如果不安装所有其他三个字符,字符将以任何安装的字体显示。

上述字体也应解决Fedora 20上的问题。