1) apt-get install build-essential
2) apt-get install libxrender-dev libxrandr-dev libxcursor-dev libxinerama-dev libxi-dev libxt-dev libglib2.0-dev libxtst-dev
可能遇到的问题
could not open lock file /var/lib/dpkg.lock -open(13:Permission denied)
原因是没有使用root用户
3)解压Qt源码
#tar xzvf qt-opensource.4.8.2.tar.bz2
4)进入qt源码目录进行配置
#./configure -qt-kbd-tty -qt-kbd-linuxinput -qt-gfx-linuxfb -qt-gfx-transformed -qt-gfx-multiscreen -qt-mouse-pc -qt-gfx-qvfb -qt-gfx-vnc -prefix /usr/local/Trolltech/QtEmbedded-4.8.2-arm -opensource -confirm-license -release -shared -embedded arm -xplatform qws/linux-arm-g++ -depths 16,18,24 -fast -optimized-qmake -pch -qt-sql-sqlite -qt-libjpeg -qt-zlib -qt-libpng -qt-freetype -little-endian -host-little-endian -no-qt3support -no-libtiff -no-libmng -no-opengl -no-mmx -no-sse -no-sse2 -no-3dnow -no-openssl -no-webkit -no-phonon -no-nis -no-opengl -no-cups -no-glib -no-xcursor -no-xfixes -no-xrandr -no-xrender -no-separate-debug-info -nomake examples -nomake tools -nomake docs
5)进入qt源码目录进行配置
#./configure -qt-kbd-tty -qt-kbd-linuxinput -qt-gfx-linuxfb -qt-gfx-transformed -qt-gfx-multiscreen -qt-mouse-pc -qt-gfx-qvfb -qt-gfx-vnc -prefix /usr/local/Trolltech/QtEmbedded-4.8.2-arm -opensource -confirm-license -release -shared -embedded arm -xplatform qws/linux-arm-g++ -depths 16,18,24 -fast -optimized-qmake -pch -qt-sql-sqlite -qt-libjpeg -qt-zlib -qt-libpng -qt-freetype -little-endian -host-little-endian -no-qt3support -no-libtiff -no-libmng -no-opengl -no-mmx -no-sse -no-sse2 -no-3dnow -no-openssl -no-webkit -no-phonon -no-nis -no-opengl -no-cups -no-glib -no-xcursor -no-xfixes -no-xrandr -no-xrender -no-separate-debug-info -nomake examples -nomake tools -nomake docs