移植qt4.7.0到mini2440段错误解决办法

引用自:http://www.friendlyarm.net/forum/topic/1854

Cheetah 2010-11-27 04:31:14

Macro:
thanks for your reply.
I had tried the "-O1 and -O0",that doesnt help.
the last 2 days, I tried cross-compile libfreetype and change the Qt
configure parameter as "-system-freetype",and result the same fault.

finally I found the cause for this fault.
that is font-related。。
here is three way to avoid this:
a):
delete all ttf fonts in $QTDIR/lib/font (rm -f $QTDIR/lib/font/*.ttf)
or
b):
add a parameter “-fn somefont”to your excuteble program.
like this: $./your_program -qws -fn somfont

or
c):modify your source file.
add a line like this“app.setfont("somefont",15)” after your QApplication
object created.

in these 3 ways.just take one choice can avoid the fault.

the cause maybe in where Qt take the default fonts failed and fallback to a
ttf format font,that problem maybe happens。



when the above program runs Ok,but once you the close the
program,a segfault still will happens 。

can't find out why 。。。。

你可能感兴趣的:(移植qt4.7.0到mini2440段错误解决办法)