Fedora 9 Install QT

1,Download qt-everywhere-opensource-src-4.7.1.tar.bz2 to ~./Downloads 
2,Unzip it to /usr/local
$ tar -jxvf qt-everywhere-opensource-src-4.7.1.tar.gz -C /usr/local
3,Add QT PATH to your .bash_profile
$ vi .bash_profile
Place below text after "export PATH"
#Add
QTDIR=/usr/local/qt-everywhere-opensource-src-4.7.1
PATH=$QTDIR/bin:$PATH
MANPATH=$QTDIR/doc/man:$MANPATH
LD_LIBRARY_PATH=$QTDIR/lib:$LD_LIBRARY_PATH
QMAKESPEC=/usr/local/qt-x11-opensource-src-4.7.1/mkspecs/linux-g++
export QTDIR PATH MANPATH LD_LIBRARY_PATH QMAKESPEC
#End
 
4,Refresh environment
$ source .bash_profile


5,Start Build QT
$ cd $QTDIR
$ ./configure
Which edition of Qt do you want to use ?
Type 'c' if you want to use the Commercial Edition.
Type 'o' if you want to use the Open Source Edition.


o


Qt is now configured for building. Just run 'gmake'.
Once everything is built, you must run 'gmake install'.
Qt will be installed into /usr/local/Trolltech/Qt-4.7.1


To reconfigure, run 'gmake confclean' and 'configure'.


6,So we run gmake, gmake install. to finish the installation.
And this will take a long time.


7,You can "make clean" to remove all .o files.


Error Case:
1,Basic XLib functionality test failed!
Goto $QTDIR/config.tests/x11/xlib
Run make
This will show detail error, if report is like 
"error:x11/xlib.h: No such file or directory"
You should install libX11-dev, so,just run "yum install libX*" can fix this error.


2,The specified system/compiler is not supported
reset QMAKESPEC
$ export QMAKESPEC=
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值