将qtopiacore4.3.4移植到MIPS板上

将qtopiacore4.3.4移植到MIPS板上

kernel: rethat 2.6
gcc: gcc-3.4.2
交叉编译:mipsel-linux-gcc
target:MIPS

交叉编译qtopia-core
下载解压qtopia-core-opensource-src-4.3.4.tar.gz
#cd qtopia-core-opensource-src-4.3.4
#export QTDIR=$PWD
#export PATH=$PATH:$QTDIR/bin
#export LD_LIBRARY_PATH=$QTDIR/lib:$LD_LIBRARY_PATH
#./configure -xplatform qws/linux-mips-g++ -embedded mips  -no -largefile -little-endian -depths

4,8,16,32  -qt-mouse-linuxtp -qt-gif -qt-libpng -qt-zlib -qt-libmng -qt-libjpeg

#gmake
#gmake install
瘦身
由于MIPS的flash空间小,所以要瘦身;

使用strip对库文件、可执行文件进行操作,库文件、可执行文件中的一些与正常运行无关的调试信息和符号信息会被剔除掉,而且操作前和操作后文件 的大小变化特别明显,一般可以减少1/3或更多,所以在嵌入式的平台上是非常有用的。但是在开发过程并不提倡这一做法,因为使用strip后,使用gdb 时就无法获得调试信息了。

先用file 命令检查是否已被strip了;

eg:file libQtGui.so.4.3.4

        mipsel-linux-strip libQtGui.so.4.3.4

 

测试中出错

出错一
# ./helloworld -qws                                                                   
QWSServerSocket::init: Function not implemented                                
QWSServerSocket: unable to create socket.                                      
QWSServerPrivate::initServer: server socket not listening: Illegal seek        
Failed to bind to /tmp/qtembedded-0/QtEmbedded-0


解决方法:
重新配置内核:# make menuconfig
选中:Networking——>Networlding options——>Unix domain sockets
保存
重新烧写板子,运行。


出错二
QFontDatabase: Cannot find font directory /usr/local/Trolltech/QtopiaCore-4.3.4-
mips/lib/fonts - is Qt installed correctly?


解决方法:
创建/usr/local/Trolltech
ln -s /mnt/sd/usr/QtopiaCore-4.3.4-mips .


出错三
./helloworld: can't resolve symbol '__ctype_b_loc'

解决方法:
缺少库 ;查看依赖库  readelf -d helloworld
 find -name *.so.*


出错四
QScreenLinuxFb::connect: No such device or address
Error opening framebuffer device /dev/fb0

 

解决
加framebuffer驱动
解压最新版的mrua,
# make kernel   //重新编译 llad.ko  em8xxx.ko
# make apps     //在bin下生成osdbuf_control fb_test
将em8xxx.ko、osdbuf_control、fb_test复制到板子上
 
 make kernel是会遇到错误
 出错:
 /usr/qtopia4/mrua_SMP8634_2.8.0.1_facsprod_legacy_dev.mips.nodts/MRUA_src/lib//librmjpeg.so: undefined reference to `__ctype_b'
 /usr/qtopia4/mrua_SMP8634_2.8.0.1_facsprod_legacy_dev.mips.nodts/MRUA_src/lib//librmhttp.so: undefined reference to `__ctype_tolower'
 /usr/qtopia4/mrua_SMP8634_2.8.0.1_facsprod_legacy_dev.mips.nodts/MRUA_src/lib//libsamples.so: undefined reference to `__ctype_tolower'

 解决方法:
 到/usr/qtopia4/mrua_SMP8634_2.8.0.1_facsprod_legacy_dev.mips.nodts/MRUA_src/lib/下运行
 # make librmjpeg.so
 # make librmhttp.so
 # make libsamples.so

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值