|
|
| Line 1: |
Line 1: |
| {| style="text-align: left; background-color: AliceBlue;"
| | == Making a Selection == |
| |-
| |
| !Download Source:
| |
| | ftp://ftp.trolltech.com/qt/source/qt-all-opensource-src-{{Qt4-Version}}.tar.bz2
| |
| |}
| |
|
| |
|
| ----
| | From here you have two paths you can take. You can either install [[Qt4]] to /usr, Not recommended because of conflicts with [[Qt3]] or you can install into /opt, recommended. |
|
| |
|
| {{Package-Introduction|Qt is a comprehensive development framework that includes an extensive array of features, capabilities and tools that enable development of high-performance, cross-platform rich-client and server-side applications. Qt is the GUI framework on which [[KDE]] is built and Qt4 is the version of Qt that the upcoming [[KDE]]4 will use. You can of course use Qt for non-[[KDE]] applications as well, but if you wish to use [[KDE]] or any [[KDE]]-based applications, you must have Qt installed on your system.|http://trolltech.com/products/appdev}}
| | * [[Qt4/opt]] (Recommended) |
| | | * [[Qt4/usr]] |
| == Dependencies ==
| |
| | |
| === Required ===
| |
| * [[X Window System]]
| |
| | |
| === Optional ===
| |
| * Xinerama provided by and [[X Window System]]
| |
| * Xfixes provided by and [[X Window System]] | |
| * [[Glib2]]
| |
| * [[FreeType]]
| |
| * [[FontConfig]]
| |
| * [[D-BUS]]
| |
| * [[OpenSSL]]
| |
| * [[LibTIFF]]
| |
| * [[libjpeg]]
| |
| * [[libmng]]
| |
| * [[NAS]]
| |
| * [[CUPS]]
| |
| * [[MySQL]]
| |
| * [[PostgreSQL]]
| |
| * [[unixODBC]]
| |
| * [[SQLite]]
| |
| * [[SQLite3]]
| |
| * [[Firebird]]
| |
| | |
| == Configuration Information ==
| |
| | |
| If you would like to compile with [[MySQL]] support add the following to the configure command:
| |
| | |
| -plugin-sql-mysql -I/usr/include/mysql
| |
| | |
| If you would like to compile with [[PostgreSQL]] support add the following to the configure command:
| |
| | |
| -plugin-sql-psql -I/usr/include/postgresql/server
| |
| | |
| If you would like to compile with [[SQLite]] support add the following to the configure command:
| |
| | |
| -plugin-sql-sqlite2 -system-sqlite
| |
| | |
| If you would like to compile with [[SQLite3]] support add the following to the configure command:
| |
| | |
| -plugin-sql-sqlite -system-sqlite
| |
| | |
| If you would like to compile with [[unixODBC]] support add the following to the configure command:
| |
| | |
| -plugin-sql-odbc
| |
| | |
| If you would like to compile with [[NAS]] support add the following to the configure command:
| |
| | |
| -system-nas-sound
| |
| | |
| If you would like to disable Qt 3 support functionality add the following to the configure command:
| |
| | |
| -no-qt3support
| |
| | |
| If your [[X Window System]] is <font color="red">'''NOT'''</font> Xorg, then add to configure:
| |
| | |
| -no-xfixes
| |
| | |
| If you want optimized qmake tool add the following to the configure command:
| |
| | |
| -optimized-qmake
| |
| | |
| If you would like to disable GLib event loop (which is known to be buggy) add the following to the configure command:
| |
| | |
| -no-glib
| |
| | |
| {{Note|Also you can disable GLib event loop at runtime by setting NO_GLIB environment variable to 1.}}
| |
| | |
| == Non-Multilib ==
| |
| | |
| If you're [[X Window System]] prefix is something other then '''/usr/X11R6''' then run the following command to change the hard coded paths in the sources:
| |
| | |
| for file in $(grep -lr "X11R6" *)
| |
| do
| |
| sed -i "s@/usr/X11R6@${XORG_PREFIX}@g" $file
| |
| sed -i "s@{XORG_PREFIX}/lib64@${XORG_PREFIX}/lib@g" $file
| |
| done
| |
| | |
| Compile the package:
| |
| | |
| mkdir -v /opt/qt-{{Qt4-Version}} &&
| |
| ln -v -sfn qt-{{Qt4-Version}} /opt/qt4 &&
| |
| ./configure -prefix /opt/qt4 \
| |
| -libdir /opt/qt4/lib \
| |
| -plugindir /opt/qt4/lib/plugins \
| |
| -headerdir /opt/qt4/include \
| |
| -datadir /opt/qt4/share \
| |
| -translationdir /opt/qt4/share/translations \
| |
| -docdir /opt/qt4/share/doc/qt \
| |
| -demosdir /opt/qt4/share/demos \
| |
| -examplesdir /opt/qt4/share/examples \
| |
| -sysconfdir /etc/qt4 \
| |
| -L/usr/lib \
| |
| -qt-gif \
| |
| -system-zlib \
| |
| -system-libtiff \
| |
| -system-libpng \
| |
| -system-libmng \
| |
| -system-libjpeg \
| |
| -no-exceptions \
| |
| -openssl \
| |
| -opengl \
| |
| -glib \
| |
| -release &&
| |
| make
| |
| | |
| Install the package
| |
| | |
| make install
| |
| | |
| == Multilib ==
| |
| | |
| === 32Bit ===
| |
| | |
| If you're [[X Window System]] prefix is something other then '''/usr/X11R6''' then run the following command to change the hard coded paths in the sources:
| |
| | |
| for file in $(grep -lr "X11R6" *)
| |
| do
| |
| sed -i "s@/usr/X11R6@${XORG_PREFIX}@g" $file
| |
| done
| |
| | |
| Compile the package
| |
| | |
| mkdir -v /opt/qt-{{Qt4-Version}} &&
| |
| ln -v -sfn qt-{{Qt4-Version}} /opt/qt4 &&
| |
| export QMAKESPEC=linux-g++-32 &&
| |
| PKG_CONFIG_PATH="${PKG_CONFIG_PATH32}" \
| |
| ./configure -prefix /opt/qt4 \
| |
| -libdir /opt/qt4/lib \
| |
| -plugindir /opt/qt4/lib/plugins \
| |
| -headerdir /opt/qt4/include \
| |
| -datadir /opt/qt4/share \
| |
| -translationdir /opt/qt4/share/translations \
| |
| -docdir /opt/qt4/share/doc/qt \
| |
| -demosdir /opt/qt4/share/demos \
| |
| -examplesdir /opt/qt4/share/examples \
| |
| -sysconfdir /etc/qt4 \
| |
| -L/usr/lib \
| |
| -qt-gif \
| |
| -system-zlib \
| |
| -system-libtiff \
| |
| -system-libpng \
| |
| -system-libmng \
| |
| -system-libjpeg \
| |
| -no-exceptions \
| |
| -openssl \
| |
| -opengl \
| |
| -glib \
| |
| -release &&
| |
| make
| |
| | |
| Install the package
| |
| | |
| make install &&
| |
| mv -v /opt/qt4/bin/qmake{,-32} &&
| |
| mv -v /opt/qt4/bin/uic{,-32} &&
| |
| mv -v /opt/qt4/bin/uic3{,-32} &&
| |
| mv -v /opt/qt4/bin/moc{,-32} &&
| |
| mv -v /opt/qt4/include/Qt/qconfig{,-32}.h &&
| |
| mv -v /opt/qt4/include/QtCore/qconfig{,-32}.h
| |
| | |
| === N32 ===
| |
| | |
| TO BE DONE
| |
| | |
| === 64Bit ===
| |
| | |
| If you're [[X Window System]] prefix is something other then '''/usr/X11R6''' then run the following command to change the hard coded paths in the sources:
| |
| | |
| for file in $(grep -lr "X11R6" *)
| |
| do
| |
| sed -i "s@/usr/X11R6@${XORG_PREFIX}@g" $file
| |
| done
| |
| | |
| Compile the package
| |
| | |
| mkdir -v /opt/qt-{{Qt4-Version}} &&
| |
| ln -v -sfn qt-{{Qt4-Version}} /opt/qt4 &&
| |
| export QMAKESPEC=linux-g++-64 &&
| |
| PKG_CONFIG_PATH="${PKG_CONFIG_PATH64}" \
| |
| ./configure -prefix /opt/qt4 \
| |
| -libdir /opt/qt4/lib64 \
| |
| -plugindir /opt/qt4/lib64/plugins \
| |
| -headerdir /opt/qt4/include \
| |
| -datadir /opt/qt4/share \
| |
| -translationdir /opt/qt4/share/translations \
| |
| -docdir /opt/qt4/share/doc/qt \
| |
| -demosdir /opt/qt4/share/demos \
| |
| -examplesdir /opt/qt4/share/examples \
| |
| -sysconfdir /etc/qt4 \
| |
| -L/usr/lib64 \
| |
| -qt-gif \
| |
| -system-zlib \
| |
| -system-libtiff \
| |
| -system-libpng \
| |
| -system-libmng \
| |
| -system-libjpeg \
| |
| -no-exceptions \
| |
| -openssl \
| |
| -opengl \
| |
| -glib \
| |
| -release &&
| |
| make
| |
| | |
| Install the package
| |
| | |
| make install &&
| |
| mv -v /opt/qt4/bin/qmake{,-64} &&
| |
| mv -v /opt/qt4/bin/uic{,-64} &&
| |
| mv -v /opt/qt4/bin/uic3{,-64} &&
| |
| mv -v /opt/qt4/bin/moc{,-64} &&
| |
| mv -v /opt/qt4/include/Qt/qconfig{,-64}.h &&
| |
| mv -v /opt/qt4/include/QtCore/qconfig{,-64}.h
| |
| ln -sfv /usr/bin/multiarch_wrapper /opt/qt4/bin/qmake &&
| |
| ln -sfv /usr/bin/multiarch_wrapper /opt/qt4/bin/uic &&
| |
| ln -sfv /usr/bin/multiarch_wrapper /opt/qt4/bin/uic3 &&
| |
| ln -sfv /usr/bin/multiarch_wrapper /opt/qt4/bin/moc
| |
| | |
| Create two qconfig.h header files which select the actual architecture-dependent qconfig-{32,64}.h header files:
| |
| | |
| {{Stub-Header|qconfig|/opt/qt4/include/Qt}}
| |
| {{Stub-Header|qconfig|/opt/qt4/include/QtCore}}
| |
| | |
| == Configuring ==
| |
| | |
| === Non-Multilib ===
| |
| | |
| ==== /etc/profile.d/20-qt4.sh ====
| |
| | |
| Create an addition to the [[Bash Startup Files]]:
| |
| | |
| cat > /etc/profile.d/20-qt4.sh << "EOF"
| |
| # Begin /etc/profile.d/20-qt4.sh
| |
|
| |
| export QT4DIR="/opt/qt4"
| |
| export PATH="${PATH}:${QT4DIR}/bin"
| |
|
| |
| export PKG_CONFIG_PATH="${PKG_CONFIG_PATH}${PKG_CONFIG_PATH+:}${QT4DIR}/lib/pkgconfig"
| |
|
| |
| # End /etc/profile.d/20-qt4.sh
| |
| EOF
| |
| | |
| ==== ld.so.conf ====
| |
| | |
| cat >> /etc/ld.so.conf << "EOF"
| |
| # Begin qt4 addition to /etc/ld.so.conf
| |
|
| |
| /opt/qt4/lib
| |
|
| |
| # End qt4 addition
| |
| EOF
| |
| ldconfig
| |
| | |
| === Multilib ===
| |
| | |
| ==== /etc/profile.d/20-qt4.sh ====
| |
| | |
| Create an addition to the [[Bash Startup Files]]:
| |
| | |
| cat > /etc/profile.d/20-qt4.sh << "EOF"
| |
| # Begin /etc/profile.d/20-qt4.sh
| |
|
| |
| export QT4DIR="/opt/qt4"
| |
| export PATH="${PATH}:${QT4DIR}/bin"
| |
|
| |
| export PKG_CONFIG_PATH32="${PKG_CONFIG_PATH32}${PKG_CONFIG_PATH32+:}${QT4DIR}/lib/pkgconfig"
| |
| export PKG_CONFIG_PATHN32="${PKG_CONFIG_PATHN32}${PKG_CONFIG_PATHN32+:}${QT4DIR}/lib32/pkgconfig"
| |
| export PKG_CONFIG_PATH64="${PKG_CONFIG_PATH64}${PKG_CONFIG_PATH64+:}${QT4DIR}/lib64/pkgconfig"
| |
|
| |
| # End /etc/profile.d/20-qt4.sh
| |
| EOF
| |
| | |
| ==== ld.so.conf ====
| |
| | |
| cat >> /etc/ld.so.conf << "EOF"
| |
| # Begin qt4 addition to /etc/ld.so.conf
| |
|
| |
| /opt/qt4/lib
| |
| /opt/qt4/lib32
| |
| /opt/qt4/lib64
| |
|
| |
| # End qt4 addition
| |
| EOF
| |
| ldconfig
| |