编译安装arm平台qt库qt-everywhere-opensource-src-4.8.5
来源:互联网 发布:java gzip 压缩 乱码 编辑:程序博客网 时间:2024/05/01 02:24
1.安装tslib 请参考郭天祥的tslib1.4 安装手册
2.使用编辑器arm-linux-gcc4.3.2
地址:http://blog.sina.com.cn/s/blog_830cba8a0100wi7a.html
3.编译qt-everywhere-opensource-src-4.8.5
参考地址:http://blog.csdn.net/baliguan163/article/details/11653727
详细的步骤如下:
1.安装交叉编译器 arm-linux-gcc-4.3.2
以下是Arm-linux-gcc-4.3.2安装步骤
下载arm-linux-gcc-4.3.2.tgz(84MB)
安装交叉编译工具链:
注意以上命令必须要有-C而且是大写的后边有个空格也要注意(因为加了 -C /
4、配置下编译环境路径 在控制台下输入 gedit /etc/profile 等一会出来文本编辑器后在文件最后(最后一行)加上下面代码
export PATH=/usr/local/arm/4.3.2/bin:$PATH
5.保存对profile的修改后,执行source /etc/profile就OK了
2.安装tslib
1.解压缩:tar -zxvf tslib1.4.tar.gz
2.运行./autogen.sh
./autogen.sh: 4: autoreconf: not found
是在不同版本的 tslib 下执行 autogen.sh 产生。它们产生的原因一样,是因为没有安装
automake 工具, (ubuntu 8.04)用下面的命令安装好就可以了。
sudo apt-get install autoconf automake libtool
3.运行
./configure --host=arm-linux --prefix=/opt/tslib-1.4 ac_cv_func_malloc_0_nonnull=yes
4.make
在make时出错,提示
In function ‘open’,
inlined from ‘main’ at ts_calibrate.c:229:11:
/usr/include/bits/fcntl2.h:51:24: error: call to ‘__open_missing_mode’ declared with attribute error: open with O_CREAT in second argument needs 3 arguments
make[2]: *** [ts_calibrate.o] Error 1
解决方法:
这是因为open函数的语法不符合最新的gcc,在/tests/ts_calibrate.c中加入open的第三个参数0777:
if ((calfile = getenv("TSLIB_CALIBFILE")) != NULL) {
cal_fd = open (calfile, O_CREAT | O_RDWR, 0777);
} else {
cal_fd = open ("/etc/pointercal", O_CREAT | O_RDWR, 0777);
}
5.make install
编译安装成功如下图:
3.编译qt-everywhere-opensource-src-4.8.5
1.
- ./configure -v -prefix /opt/qt-4.8.5-arm -opensource -confirm-license -embedded arm -release -shared -fast -no-largefile -qt-sql-sqlite -qt3support -no-xmlpatterns -no-glib -no-phonon -no-mmx -no-3dnow -no-sse -no-sse2 -no-svg -webkit -qt-zlib -qt-libtiff -qt-libpng -qt-libjpeg -make libs -make tools -make examples -make demos -make translations -no-nis -no-cups -iconv -no-dbus -xplatform qws/linux-arm-g++ -little-endian -qt-freetype -depths 16,24,32 -qt-gfx-linuxfb -qt-gfx-transformed -qt-gfx-multiscreen -no-gfx-vnc -no-gfx-qvfb -qt-kbd-linuxinput -no-kbd-qvfb -armfpa -no-mouse-qvfb -qt-mouse-linuxtp -qt-mouse-tslib -DQT_QLOCALE_USES_FCVT -I/opt/tslib-1.4/include -L/opt/tslib-1.4/lib
或者 ./configure \
-v \
-prefix /usr/local/Trolltech/QtEmbedded-4.8.5-arm \
-opensource -confirm-license \
-embedded arm \
-release \
-shared \
-fast \
-no-largefile \
-qt-sql-sqlite \
-qt3support \
-no-xmlpatterns \
-no-glib \
-no-phonon \
-no-mmx \
-no-3dnow \
-no-sse \
-no-sse2 \
-no-svg \
-webkit \
-qt-zlib \
-qt-libtiff \
-qt-libpng \
-qt-libjpeg \
-make libs \
-make tools \
-make examples \
-make demos \
-make translations \
-no-nis \
-no-cups \
-iconv \
-no-dbus \
-xplatform qws/linux-arm-g++ \
-little-endian \
-qt-freetype \
-depths 16,24,32 \
-qt-gfx-linuxfb \
-qt-gfx-transformed \
-qt-gfx-multiscreen \
-no-gfx-vnc \
-no-gfx-qvfb \
-qt-kbd-linuxinput \
-no-kbd-qvfb \
-armfpa \
-no-mouse-qvfb \
-qt-mouse-linuxtp \
-qt-mouse-tslib \
-DQT_QLOCALE_USES_FCVT \
-I/usr/local/tslib/include \
-L/usr/local/tslib/lib 写进.sh文件中
You might need to modify the include and library search paths by editingQMAKE_INCDIR and QMAKE_LIBDIR in/home/Raymond/qt-embedded-arm-tslib/mkspecs/qws/linux-arm-g++.
解决办法:
是arm-linux-gcc的路径没有添加到系统变量中
1.修改profile文件:
#vi /etc/profile
在里面加入:export PATH="$PATH:/opt/FriendlyARM/toolschain/4.5.1/bin"
2.修改.bashrc文件:
# vi /root/.bashrc
在里面加入:export PATH="$PATH:/opt/FriendlyARM/toolschain/4.5.1/bin"
注意修改后的更新,如source /etc/profile
2. make
make[1]: 正在进入目录 `/home/duliqun/qt-everywhere-opensource-src-4.8.5/src/corelib'
g++ -c -include .pch/release-shared-emb-arm/QtCore -pipe -I/opt/tslib-1.0/include -fno-exceptions -O2 -fvisibility=hidden -fvisibility-inlines-hidden -Wall -W -D_REENTRANT -fPIC -DQT_SHARED -DQT_QLOCALE_USES_FCVT -DQT_BUILD_CORE_LIB -DQT_NO_USING_NAMESPACE -DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT3_SUPPORT -DQT_MOC_COMPAT -DQT_USE_QSTRINGBUILDER -DELF_INTERPRETER=\"\" -DHB_EXPORT=Q_CORE_EXPORT -DQT_NO_DEBUG -I../../mkspecs/linux-g++ -I. -I../../include -I../../include/QtCore -I.rcc/release-shared-emb-arm -Iglobal -I../3rdparty/zlib -I../3rdparty/harfbuzz/src -I../3rdparty/md5 -I../3rdparty/md4 -I.moc/release-shared-emb-arm -o .obj/release-shared-emb-arm/qabstractanimation.o animation/qabstractanimation.cpp
../../include/QtCore/../../src/corelib/arch/qatomic_armv5.h: Assembler messages:
../../include/QtCore/../../src/corelib/arch/qatomic_armv5.h:131: Error: no such instruction: `swpb %cl,%dl,[%ebp]'
../../include/QtCore/../../src/corelib/arch/qatomic_armv5.h:131: Error: no such instruction: `swpb %dl,%sil,[%ebp]'
{
register char ret;
/*asm volatile("swpb %0,%2,[%3]"
: "=&r"(ret), "=m" (*ptr)
: "r"(newval), "r"(ptr)
: "cc", "memory");*/
ret=*ptr;
*ptr=newval;
return ret;
}
ssl/qsslsocket_openssl_p.h:66:26: 致命错误: openssl/asn1.h:没有那个文件或目录编译中断。
make[1]: *** [.obj/release-shared-emb-arm/qsslcertificate.o] 错误 1
make[1]:正在离开目录 `/home/duliqun/qt-everywhere-opensource-src-4.8.5/src/network'
make: *** [sub-network-make_default] 错误 2
sudo apt-get install libssl-dev
———————————————————————————————————————————————————————————————————
- 配置编译安装arm平台qt库qt-everywhere-opensource-src-4.8.5
- 编译安装arm平台qt库qt-everywhere-opensource-src-4.8.5
- 配置编译安装x86平台qt库qt-everywhere-opensource-src-4.8.5
- s3c2410上搭建QT/Embedded4.8.5开发环境(二)--安装arm平台qt库qt-everywhere-opensource-src-4.8.5
- 编译 qt-everywhere-opensource-src-4.8.1
- 安装qt-everywhere-opensource-src-4.8.6
- DM8168 --交叉编译ARM版 Qt (qt-everywhere-opensource-src-4.8.4)
- 交叉编译ARM版 Qt (qt-everywhere-opensource-src-4.8.4)
- 交叉编译ARM版 Qt (qt-everywhere-opensource-src-4.8.4)
- 交叉编译ARM版Qt(qt-everywhere-opensource-src-4.8.4)
- DM8168 --交叉编译ARM版 Qt (qt-everywhere-opensource-src-4.8.4)
- qt-everywhere-opensource-src-5.6.2 编译
- s3c2410上搭建QT/Embedded4.8.5开发环境(四)--安装intel-x86 X11平台qt库qt-everywhere-opensource-src-4.8.5
- s3c2410上搭建QT/Embedded4.8.5开发环境(三)--安装intel-x86嵌入式平台(基于qvfb)的qt库qt-everywhere-opensource-src-4.8.5
- qt-everywhere-opensource-src-4.8.4 编译出错
- build qt-everywhere-opensource-src-4.8.0
- 交叉编译ARM版 Qt (qt-everywhere-opensource-src-4.7.3)
- 交叉编译ARM版 Qt (qt-everywhere-opensource-src-4.7.3) .
- python Lambda 表达式
- 数论总结(content)
- WampServer中Mysql无法启动
- HDU 2029 Palindromes _easy version(水~)
- Android自学笔记之Button按钮里的属性及用法
- 编译安装arm平台qt库qt-everywhere-opensource-src-4.8.5
- 读取流和写入流的学习(8.28)
- Installation of NVIDIA GPU Driver and CUDA Toolkit
- 数组循环左移的一种方法
- Android自学笔记之ImageView的特殊属性及同为背景属性的src、background区别
- 解决不同操作系统的路径分隔符问题
- 一个人的时候
- PHP性能优化
- HDU 2030 汉字统计(水~)