Redhat下配置qt4.4.3

一开始首先需要获得安装包,这里已经下载好了(版本qt-x11-opensource-src-4.4.3.tar),链接地址

http://download.youkuaiyun.com/detail/fzxy002763/4201181

http://download.youkuaiyun.com/detail/fzxy002763/4201235

然后传到linux上,然后在Linux下进行配置

登录root,解压缩包

[root@bogon qqq]# tar zvxf qt-x11-opensource-src-4.4.3.tar.gz
然后进入压缩文件夹

[root@bogon qqq]# cd qt-x11-opensource-src-4.4.3
[root@bogon qt-x11-opensource-src-4.4.3]# ./configure
就可以进行配置了,然后
[root@bogon qt-x11-opensource-src-4.4.3]# ./configure

This is the Qt/X11 Open Source Edition.

You are licensed to use this software under the terms of
the GNU General Public License (GPL) versions 2 or 3.

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

Do you accept the terms of either license? yes

这样就可以了(PS:如果要编译嵌入式的交叉编译环境需要加上一些的配置,这里不进行具体配置

PS:这个时间比较长,大致10分钟左右,慢慢等吧,后面更长时间

接着

[root@bogon qt-x11-opensource-src-4.4.3]# gmake
[root@bogon qt-x11-opensource-src-4.4.3]# gmake install

长久等待之后终于装好了,找好的文件在目录

/usr/local/Trolltech/Qt-4.4.3

然后需要配置bash

在结尾处加上,然后配置就好了

#QT-4.4.3 config
#QTDIR=/usr/local/Trolltech/Qt-4.4.3
#PATH=$QTDIR/bin:$PATH
#QMAKESPEC=$QTDIR/mkspecs/linux-g++
#LD_LIBRARRY_PATH=$QTDIR/lib:$LD_LIBRARRY_PATH
#export QTDIR PATH QMAKESPEC LD_LIBRARRY_PATH

使用的方法是,在windows把整个工程传过去,或者直接在Linux下建立

然后qmake,最后make,就行了,然后就能编译运行程序了

[root@bogon helloworld]# qmake
[root@bogon helloworld]# make
[root@bogon helloworld]# ./helloworld -qws

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值