qt4的移植

来源:互联网 发布:linux 目录权限递归 编辑:程序博客网 时间:2024/05/21 22:52

  参考链接
   http://blog.csdn.net/jiaqi_327/article/details/20131441

1     移植成功后,将程序进行交叉编译后在板上运行时报 错
       error while loading shared libraries: libQtCore.so.4: cannot handle TLS data

       解决方法:
      这个错误并不是缺少libQtCore.so.4库,而是制作文件系统 gcc版本与编译qt的gcc版本不同导致,所以解决方法
      是统一其版本

2   在执行./configureshi时遇到
     You have not explicitly asked to use pkg-config and are cross-compiling.
     pkg-config will not be used to automatically query cflag/lib parameters for
     dependencies
     The tslib functionality test failed!
     You might need to modify the include and library search paths by editing
     QMAKE_INCDIR and QMAKE_LIBDIR in
     解决方案:
     这个是我粗心大意,在执行configure之前要配置
     mkspecs/qws/linux-mips-g++/qmake.conf,配置内容如下:

  

     QMAKE_CC                = mipsel-linux-gcc -lts  QMAKE_CXX               = mipsel-linux-g++ -lts  QMAKE_CFLAGS           += -pipe  QMAKE_CXXFLAGS         += -pipe  QMAKE_LINK              = mipsel-linux-g++ -lts  QMAKE_LINK_SHLIB        = mipsel-linux-g++ -lts
  我在修改时把
  QMAKE_CFLAGS           += -pipe

 写成
  QMAKE_CFLAGS           += pipe
所以出错了

3   之前在移植时由于权限没统一,所以各种报错,解决方法是移植统一使用最高权限,即在root用户下执行 ,
      注意root用户的交叉编译工具连有无,没得自己在~/.bashrc下添加 
      export PATH=/opt/gcc-4.3-ls232-softfloat/bin:$PATH
      gcc的版本最好使用4.0以上,否则编译不过
             



0 0
原创粉丝点击