[技术问题解答] 关于QT5.3.2在ARM编绎的问题,这事很绝!

[复制链接]
3218|6
 楼主| bendanzhu2018 发表于 2015-8-26 12:02 | 显示全部楼层 |阅读模式
本帖最后由 bendanzhu2018 于 2015-8-26 12:25 编辑

arm-gcc: /opt/arm/arm-linux-gcc-4.9/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-g++
使用QT为:qt-everywhere-opensource-src-5.3.2.tar.gz
修改的文件为:qtbase\mkspecs\linux-arm-gnueabi-g++\qmake.conf
#
# qmake configuration for building with arm-linux-gnueabi-g++
#

MAKEFILE_GENERATOR      = UNIX
CONFIG                 += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib

QT_QPA_DEFAULT_PLATFORM = linuxfb
QMAKE_CFLAGS_RELEASE   += -O2 -march=armv7-a -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a9
QMAKE_CXXFLAGS_RELEASE += -O2 -march=armv7-a -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a9

include(../common/linux.conf)
include(../common/gcc-base-unix.conf)
include(../common/g++-unix.conf)

# modifications to g++.conf
QMAKE_CC                = arm-poky-linux-gnueabi-gcc
QMAKE_CXX               = arm-poky-linux-gnueabi-g++
QMAKE_LINK              = arm-poky-linux-gnueabi-g++
QMAKE_LINK_SHLIB        = arm-poky-linux-gnueabi-g++

# modifications to linux.conf
QMAKE_AR                = arm-poky-linux-gnueabi-ar cqs
QMAKE_OBJCOPY           = arm-poky-linux-gnueabi-objcopy
QMAKE_NM                = arm-poky-linux-gnueabi-nm -P
QMAKE_STRIP             = arm-poky-linux-gnueabi-strip
load(qt_config)

配制选项为:./configure -prefix $PWD/qtbase -xplatform linux-arm-gnueabi-g++ -opensource -no-c++11 -qreal float -nomake examples

交叉编绎之后就是没有libQt5WebKit.so.5.3.2和libQt5WebKitWidgets.so.5.3.2两个库:

用./configure -prefix $PWD/qtbase -opensource -no-c++11 -qreal float -nomake examples 命令,不指定交叉编绎会生成上面两个库
 楼主| bendanzhu2018 发表于 2015-8-26 12:03 | 显示全部楼层
本帖最后由 bendanzhu2018 于 2015-8-26 12:10 编辑

这个天下就没有和一样遇到同样的问题吗?

据网上资料说,要编绎qtwebkit,必须打开icu!
 楼主| bendanzhu2018 发表于 2015-8-26 12:07 | 显示全部楼层
我用./configure -prefix $PWD/qtbase -xplatform linux-arm-gnueabi-g++ -opensource -no-c++11 -qreal float -nomake examples -icu  打开ICU这个模块
提示如下:

harry@mh:~/QT_ARM_5.3.2/qt-opensource-arm-5.3.2$
harry@mh:~/QT_ARM_5.3.2/qt-opensource-arm-5.3.2$ ./configure -prefix $PWD/qtbase -xplatform linux-arm-gnueabi-g++ -opensource -no-c++11 -qreal float -nomake examples -icu
+ cd qtbase
+ /home/harry/QT_ARM_5.3.2/qt-opensource-arm-5.3.2/qtbase/configure -top-level -prefix /home/harry/QT_ARM_5.3.2/qt-opensource-arm-5.3.2/qtbase -xplatform linux-arm-gnueabi-g++ -opensource -no-c++11 -qreal float -nomake examples -icu

This is the Qt Open Source Edition.

You are licensed to use this software under the terms of
the Lesser GNU General Public License (LGPL) versions 2.1.
You are also licensed to use this software under the terms of
the GNU General Public License (GPL) versions 3.

Type '3' to view the GNU General Public License version 3.
Type 'L' to view the Lesser GNU General Public License version 2.1.
Type 'yes' to accept this license offer.
Type 'no' to decline this license offer.

Do you accept the terms of either license? yes

Creating qmake...
make: Nothing to be done for `first'.
Running configuration tests...
Warning: Disabling pkg-config since PKG_CONFIG_LIBDIR is not set.
Warning: Disabling pkg-config since PKG_CONFIG_SYSROOT_DIR is not set.
The ICU library support cannot be enabled.
Turn on verbose messaging (-v) to /home/harry/QT_ARM_5.3.2/qt-opensource-arm-5.3.2/qtbase/configure to see the final report.
If you believe this message is in error you may use the continue
switch (-continue) to /home/harry/QT_ARM_5.3.2/qt-opensource-arm-5.3.2/qtbase/configure to continue.
harry@mh:~/QT_ARM_5.3.2/qt-opensource-arm-5.3.2$
 楼主| bendanzhu2018 发表于 2015-8-26 12:08 | 显示全部楼层
有哪位大神大牛,能解决这个问题呢?感谢了!
 楼主| bendanzhu2018 发表于 2015-8-26 14:18 | 显示全部楼层
有大神帮忙看看吗?
lovecat2015 发表于 2015-8-26 15:08 | 显示全部楼层
帮楼主顶一下吧,我解决不了呢
奥德赛 发表于 2015-8-26 17:05 | 显示全部楼层
这是makefile的问题,具体的可以一句句的分析
您需要登录后才可以回帖 登录 | 注册

本版积分规则

11

主题

56

帖子

2

粉丝
快速回复 在线客服 返回列表 返回顶部