qt-everywhere-opensource-src-4.8.1移植到2440、6410

2019-07-12 19:49发布

首先下载qt-everywhere-opensource-src-4.8.1源码,下载地址: ftp://ftp.qt-project.org/qt/source/

在Linux下编译一定要下载qt-everywhere-opensource-src-4.8.1.tar.gz 不能用qt-everywhere-opensource-src-4.8.1.zip,因为在configure时,会报没有权限和文本编码等错误。
编译Qt之前都需要安装tslib,具体安装方法请看:tslib安装 由于配置的命令比较多,我自己写了一个自动安装脚本: #!/bin/sh export PATH=/opt/FriendlyARM/toolschain/4.4.3/bin:$PATH export TOOLCHAIN=/opt/FriendlyARM/toolschain/4.4.3 export TB_CC_PREFIX=arm-linux- export PKG_CONFIG_PREFIX=$TOOLCHAIN/arm-none-linux-gnueabi export MAKE=/usr/bin/make echo "Delect the exist direction" rm -rf qt-everywhere-opensource-src-4.8.1 rm -rf /opt/Qt4.8.1 echo "Unzip qt source" tar xzvf qt-everywhere-opensource-src-4.8.1.tar.gz cd qt-everywhere-opensource-src-4.8.1 echo "Configure ..." #chmod +x configure #dos2unix configure ./configure -prefix /opt/Qt4.8.1 -opensource -embedded arm -xplatform qws/linux-arm-g++ -depths 16,18,24,32 -no-glib -no-cups -no-largefile -no-accessibility -no-openssl -no-gtkstyle -no-qt3support -no-phonon -no-webkit -no-libtiff -no-libmng -qt-zlib -qt-libpng -qt-libjpeg -no-nis -no-dbus -little-endian -host-little-endian -qt-freetype -qt-gfx-transformed -qt-gfx-vnc -qt-gfx-linuxfb -qt-gfx-multiscreen -qt-kbd-tty -qt-mouse-tslib -I/usr/local/arm/tslib/include -L/usr/local/arm/tslib/lib 2>&1 | tee conf_log echo "Make..." make 2>&1 | tee make_log echo "Inatall..." make install