To install Qt on X11, you may need to be root, depending on the permissions of the directory where you choose to install Qt.
cd /usr/local
cp /cdrom/x11/qt-x11-free3.2.1.tar.gz. gunzip qt-x11-free-3.2.1.tar.gz tar xf qt-x11-free-3.2.1.tar
This will create the directory qt-x11-free-3.2.1, assuming that your CD-ROM is mounted at /cdrom.
The variables are set differently depending on which shell you are using. For example, if your user name is gregory, you can find out which shell you are using with the finger command:
finger gregory
If your shell is bash, ksh, zsh, or sh, add the following lines to the .profile file in your home directory:
QTDIR=/usr/local/qt-x11-free-3.2.1 PATH=$QTDIR/bin:$PATH MANPATH=$QTDIR/doc/man:$MANPATH LD_LIBRARY_PATH=$QTDIR/lib:$LD_LIBRARY_PATH export QTDIR PATH MANPATH LD_LIBRARY_PATH
If your shell is csh or tcsh, add the following lines to your .login file:
setenv QTDIR /usr/local/qt-x11-free-3.2.1 setenv PATH $QTDIR/bin:$PATH setenv MANPATH $QTDIR/doc/man:$MANPATH setenv LD_LIBRARY_PATH $QTDIR/lib:$LD_LIBRARY_PATH
If you encounter "undefined variable" problems, change the last two lines above to these:
setenv MANPATH $QTDIR/doc/man setenv LD_LIBRARY_PATH $QTDIR/lib
Irrespective of which shell you use, if you install Qt on AIX, replace all occurrences of LD_LIBRARY_PATH with LIBPATH. And if you install Qt on HP-UX, replace LD_LIBRARY_PATH with SHLIB_PATH.
After you have done this, you must either login again or re-source the .profile or .login file before continuing.
cd $QTDIR ./configure
You can run ./configure -help to get a list of configuration options. For example, you can use the -thread option to create a threaded version of the library.
If you want to customize how you install Qt or if you encounter problems with installing Qt, refer to the INSTALL file in $QTDIR for more information.
Part I: Basic Qt
Getting Started
Creating Dialogs
Creating Main Windows
Implementing Application Functionality
Creating Custom Widgets
Part II: Intermediate Qt
Layout Management
Event Processing
2D and 3D Graphics
Drag and Drop
Input/Output
Container Classes
Databases
Networking
XML
Internationalization
Providing Online Help
Multithreading
Platform-Specific Features