[7af92fe5] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
| 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[1de3dce9] | 7 | <!ENTITY qt4-download-http
|
---|
[a6c6923] | 8 | "http://download.qt-project.org/official_releases/qt/4.8/&qt4-version;/qt-everywhere-opensource-src-&qt4-version;.tar.gz">
|
---|
[7af92fe5] | 9 | <!ENTITY qt4-download-ftp " ">
|
---|
[1de3dce9] | 10 | <!ENTITY qt4-md5sum "1864987bdbb2f58f8ae8b350dfdbe133">
|
---|
| 11 | <!ENTITY qt4-size "231 MB">
|
---|
[7af92fe5] | 12 | <!ENTITY qt4-buildsize "1.9 GB">
|
---|
[1de3dce9] | 13 | <!ENTITY qt4-time "41 SBU">
|
---|
[7af92fe5] | 14 | ]>
|
---|
| 15 |
|
---|
| 16 | <sect1 id="qt4" xreflabel="Qt-&qt4-version;">
|
---|
| 17 | <?dbhtml filename="qt4.html" ?>
|
---|
| 18 |
|
---|
| 19 | <sect1info>
|
---|
| 20 | <othername>$LastChangedBy$</othername>
|
---|
| 21 | <date>$Date$</date>
|
---|
| 22 | </sect1info>
|
---|
| 23 |
|
---|
| 24 | <title>Qt-&qt4-version;</title>
|
---|
| 25 |
|
---|
| 26 | <indexterm zone="qt4">
|
---|
| 27 | <primary sortas="a-Qt">Qt</primary>
|
---|
| 28 | </indexterm>
|
---|
| 29 |
|
---|
| 30 | <sect2 role="package">
|
---|
| 31 | <title>Introduction to Qt</title>
|
---|
| 32 |
|
---|
| 33 | <para>
|
---|
| 34 | <application>Qt</application> is a cross-platform application
|
---|
| 35 | framework that is widely used for developing application software
|
---|
| 36 | with a graphical user interface (GUI) (in which cases Qt is classified
|
---|
| 37 | as a widget toolkit), and also used for developing non-GUI programs such
|
---|
| 38 | as command-line tools and consoles for servers. One of the major users
|
---|
| 39 | of <application>Qt</application> is <application>KDE</application>.
|
---|
| 40 | </para>
|
---|
| 41 |
|
---|
[54e9eea] | 42 | &lfs74_checked;
|
---|
[7af92fe5] | 43 |
|
---|
| 44 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 45 | <itemizedlist spacing="compact">
|
---|
| 46 | <listitem>
|
---|
| 47 | <para>
|
---|
| 48 | Download (HTTP): <ulink url="&qt4-download-http;"/>
|
---|
| 49 | </para>
|
---|
| 50 | </listitem>
|
---|
| 51 | <listitem>
|
---|
| 52 | <para>
|
---|
| 53 | Download (FTP): <ulink url="&qt4-download-ftp;"/>
|
---|
| 54 | </para>
|
---|
| 55 | </listitem>
|
---|
| 56 | <listitem>
|
---|
| 57 | <para>
|
---|
| 58 | Download MD5 sum: &qt4-md5sum;
|
---|
| 59 | </para>
|
---|
| 60 | </listitem>
|
---|
| 61 | <listitem>
|
---|
| 62 | <para>
|
---|
| 63 | Download size: &qt4-size;
|
---|
| 64 | </para>
|
---|
| 65 | </listitem>
|
---|
| 66 | <listitem>
|
---|
| 67 | <para>
|
---|
| 68 | Estimated disk space required: &qt4-buildsize;
|
---|
| 69 | </para>
|
---|
| 70 | </listitem>
|
---|
| 71 | <listitem>
|
---|
| 72 | <para>
|
---|
| 73 | Estimated build time: &qt4-time;
|
---|
| 74 | </para>
|
---|
| 75 | </listitem>
|
---|
| 76 | </itemizedlist>
|
---|
| 77 |
|
---|
| 78 | <bridgehead renderas="sect3">Qt Dependencies</bridgehead>
|
---|
| 79 |
|
---|
| 80 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
| 81 | <para role="required">
|
---|
[a8ece039] | 82 | <xref linkend="alsa-lib"/> and
|
---|
| 83 | <xref linkend="mesalib"/>
|
---|
[7af92fe5] | 84 | </para>
|
---|
| 85 |
|
---|
| 86 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
| 87 | <para role="recommended">
|
---|
| 88 | <xref linkend="cacerts"/>,
|
---|
| 89 | <xref linkend="dbus"/>,
|
---|
| 90 | <xref linkend="glib2"/>,
|
---|
| 91 | <xref linkend="icu"/> (unicode support),
|
---|
| 92 | <xref linkend="libjpeg"/>,
|
---|
| 93 | <xref linkend="libmng"/>,
|
---|
| 94 | <xref linkend="libpng"/>,
|
---|
| 95 | <xref linkend="libtiff"/>,
|
---|
[a8ece039] | 96 | <xref linkend="openssl"/>, and
|
---|
[7af92fe5] | 97 | <xref linkend="sqlite"/>
|
---|
| 98 | </para>
|
---|
| 99 |
|
---|
| 100 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
| 101 | <para role="optional">
|
---|
| 102 | <xref linkend="cups"/>,
|
---|
| 103 | <xref linkend="gtk2"/> (GTK+ 2 theme support),
|
---|
| 104 | <xref linkend="gst-plugins-base"/> (For QtWebKit HTML5 Video),
|
---|
[419a60e] | 105 | <xref linkend="mariadb"/> or <xref linkend="mysql"/>,
|
---|
[7af92fe5] | 106 | <xref linkend="postgresql"/>,
|
---|
[a8ece039] | 107 | <xref linkend="pulseaudio"/>,
|
---|
[fb28b3b] | 108 | <xref linkend="unixodbc"/>, and
|
---|
| 109 | <xref linkend="qtchooser"/> (runtime, if also installing Qt5 and
|
---|
| 110 | installing in /usr)
|
---|
[7af92fe5] | 111 | </para>
|
---|
| 112 |
|
---|
| 113 | <para condition="html" role="usernotes">User Notes:
|
---|
| 114 | <ulink url="&blfs-wiki;/qt4"/>
|
---|
| 115 | </para>
|
---|
| 116 | </sect2>
|
---|
| 117 |
|
---|
| 118 | <sect2 role="installation">
|
---|
| 119 | <title>Installation of Qt</title>
|
---|
| 120 |
|
---|
[54e9eea] | 121 | <para>
|
---|
| 122 | There are several ways to install a complicated package such as
|
---|
| 123 | <application>Qt</application>. The files are not completely position
|
---|
| 124 | independent. Installation procedures execute the program
|
---|
| 125 | <command>pkg-config</command> to determine the location of package
|
---|
| 126 | executables, libraries, headers, and other files. For
|
---|
| 127 | <application>Qt</application>, <command>pkg-config</command> will look
|
---|
| 128 | for the appropriate <filename>lib/pkgconfig/Qt*.pc</filename> files
|
---|
| 129 | which must be modified if relocating the package. These files are set up
|
---|
| 130 | correctly by the build process.
|
---|
| 131 | </para>
|
---|
[a8ece039] | 132 |
|
---|
[54e9eea] | 133 | <para>
|
---|
| 134 | The default installation places the files in <filename
|
---|
[a8ece039] | 135 | class='directory'>/usr/local/qt/</filename>. Many commercial
|
---|
[54e9eea] | 136 | distributions place the files in the system's <filename
|
---|
[a8ece039] | 137 | class='directory'>/usr</filename> hierarchy. The package can also be
|
---|
[54e9eea] | 138 | installed in an arbitrary directory.
|
---|
| 139 | </para>
|
---|
| 140 |
|
---|
| 141 | <para>
|
---|
| 142 | The advantage of installing in <filename
|
---|
[a8ece039] | 143 | class='directory'>/usr</filename> is that no updates to the
|
---|
[54e9eea] | 144 | <filename>/etc/ld.so.conf</filename> or
|
---|
| 145 | <filename>/etc/man_db.conf</filename> files are required. The package
|
---|
| 146 | files are distributed within several subdirectories of the <filename
|
---|
[a8ece039] | 147 | class='directory'>/usr</filename> hierarchy. This is the method that
|
---|
| 148 | most commercial distributions use. It is also supported by the
|
---|
| 149 | optional <application>qtchooser</application> application.
|
---|
[54e9eea] | 150 | </para>
|
---|
| 151 |
|
---|
[fb28b3b] | 152 | <para>
|
---|
| 153 | The disadvantage of installing in <filename
|
---|
| 154 | class='directory'>/usr</filename> is that the executable filenames
|
---|
| 155 | for <application>Qt4</application> and <application>Qt5</application>
|
---|
| 156 | conflict if both packages are installed in the
|
---|
| 157 | same directory. The instructions below give a workaround for
|
---|
| 158 | this problem using the helper program <xref linkend='qtchooser'/>.
|
---|
| 159 | This requires renaming the Qt executables with a version suffix.
|
---|
| 160 | </para>
|
---|
| 161 |
|
---|
[54e9eea] | 162 | <para>
|
---|
[a8ece039] | 163 | The advantage of installing <application>Qt4</application> in a custom
|
---|
[54e9eea] | 164 | directory such as <filename
|
---|
[a8ece039] | 165 | class='directory'>/opt/qt-&qt4-version;</filename> is that it keeps all
|
---|
[54e9eea] | 166 | the package files consolidated in a dedicated directory hierarchy. By
|
---|
| 167 | using this method, an update can be made without overwriting a previous
|
---|
| 168 | installation and users can easily revert to a previous version by
|
---|
[a8ece039] | 169 | changing one symbolic link or merely changing the PATH variable. It
|
---|
| 170 | also allows a developer to maintain multiple versions of
|
---|
[fb28b3b] | 171 | <application>Qt4</application> or <application>Qt5</application>
|
---|
| 172 | for testing.
|
---|
[54e9eea] | 173 | </para>
|
---|
| 174 |
|
---|
[fb28b3b] | 175 | <caution>
|
---|
[8d4b121] | 176 | <para>
|
---|
| 177 | If you did not install some of the recommended dependencies, examine
|
---|
| 178 | <command>./configure --help</command> output to check how to disable
|
---|
| 179 | them or use internal versions bundled in the source tarball.
|
---|
| 180 | </para>
|
---|
[fb28b3b] | 181 | </caution>
|
---|
[8d4b121] | 182 |
|
---|
[fb28b3b] | 183 | <warning>
|
---|
[7af92fe5] | 184 | <para>
|
---|
[fb28b3b] | 185 | If <application>Qt4</application> is being reinstalled into the
|
---|
[54e9eea] | 186 | same directory as an existing instance, run the
|
---|
[fb28b3b] | 187 | following commands from a console or non-Qt4 based window manager.
|
---|
| 188 | It overwrites <application>Qt4</application> libraries that should
|
---|
[7af92fe5] | 189 | not be in use during the install process.
|
---|
| 190 | </para>
|
---|
[fb28b3b] | 191 | </warning>
|
---|
[7af92fe5] | 192 |
|
---|
| 193 | <note>
|
---|
| 194 | <para>
|
---|
| 195 | The build time and space required for the full
|
---|
| 196 | <application>Qt</application> is quite long. The instructions below
|
---|
| 197 | do not build the tutorials and examples. Removing the
|
---|
| 198 | <parameter>-nomake</parameter> lines will create a complete build.
|
---|
| 199 | </para>
|
---|
| 200 | </note>
|
---|
| 201 |
|
---|
[54e9eea] | 202 | <bridgehead renderas="sect3">Method 1: Installing in /usr</bridgehead>
|
---|
| 203 |
|
---|
[7af92fe5] | 204 | <para>
|
---|
[fb28b3b] | 205 | Install <application>Qt4</application> by running the
|
---|
[7af92fe5] | 206 | following commands:
|
---|
| 207 | </para>
|
---|
| 208 |
|
---|
[fb28b3b] | 209 | <note><para>
|
---|
| 210 | If <emphasis>not</emphasis> also installing <application>Qt5</application>
|
---|
| 211 | into the /usr directory, change the entry for -bindir below to /usr/bin.
|
---|
| 212 | </para></note>
|
---|
| 213 |
|
---|
| 214 |
|
---|
[a6c6923] | 215 | <screen><userinput>sed -i -e "/#if/d" -e "/#error/d" -e "/#endif/d" \
|
---|
| 216 | config.tests/unix/libmng/libmng.cpp &&
|
---|
[57242ab] | 217 | sed -i '/CONFIG -/ a\isEmpty(OUTPUT_DIR): OUTPUT_DIR = ../..' \
|
---|
| 218 | src/3rdparty/webkit/Source/WebKit2/DerivedSources.pro &&
|
---|
[a6c6923] | 219 |
|
---|
[a8ece039] | 220 | ./configure -prefix /usr \
|
---|
| 221 | -bindir /usr/lib/qt4/bin \
|
---|
| 222 | -plugindir /usr/lib/qt4/plugins \
|
---|
| 223 | -importdir /usr/lib/qt4/imports \
|
---|
| 224 | -headerdir /usr/include/qt4 \
|
---|
| 225 | -datadir /usr/share/qt4 \
|
---|
| 226 | -sysconfdir /etc/xdg \
|
---|
| 227 | -docdir /usr/share/doc/qt4 \
|
---|
| 228 | -demosdir /usr/share/doc/qt4/demos \
|
---|
| 229 | -examplesdir /usr/share/doc/qt4/examples \
|
---|
[7af92fe5] | 230 | -translationdir /usr/share/qt4/translations \
|
---|
[a8ece039] | 231 | -confirm-license \
|
---|
| 232 | -opensource \
|
---|
| 233 | -release \
|
---|
| 234 | -dbus-linked \
|
---|
| 235 | -openssl-linked \
|
---|
| 236 | -system-sqlite \
|
---|
| 237 | -no-phonon \
|
---|
[7af92fe5] | 238 | -no-phonon-backend \
|
---|
[a8ece039] | 239 | -no-nis \
|
---|
| 240 | -no-openvg \
|
---|
| 241 | -nomake demos \
|
---|
| 242 | -nomake examples \
|
---|
| 243 | -optimized-qmake &&
|
---|
| 244 |
|
---|
[7af92fe5] | 245 | make</userinput></screen>
|
---|
| 246 |
|
---|
| 247 | <para>
|
---|
| 248 | This package does not come with a test suite.
|
---|
| 249 | </para>
|
---|
| 250 |
|
---|
[acacfb64] | 251 | <para>
|
---|
| 252 | Remove references to the build directory from the
|
---|
| 253 | <filename class="extension">.pc</filename> files by running
|
---|
| 254 | the following command:
|
---|
| 255 | </para>
|
---|
| 256 |
|
---|
| 257 | <screen><userinput>find . -name "*.pc" -exec perl -pi -e "s, -L$PWD/?\S+,,g" {} \;</userinput></screen>
|
---|
| 258 |
|
---|
[7af92fe5] | 259 | <para>
|
---|
| 260 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 261 | </para>
|
---|
| 262 |
|
---|
| 263 | <screen role="root"><userinput>make install &&
|
---|
| 264 | rm -rf /usr/tests &&
|
---|
| 265 | install -v -Dm644 src/gui/dialogs/images/qtlogo-64.png \
|
---|
[a8ece039] | 266 | /usr/share/pixmaps/qt4logo.png &&
|
---|
[7af92fe5] | 267 | install -v -Dm644 tools/assistant/tools/assistant/images/assistant-128.png \
|
---|
| 268 | /usr/share/pixmaps/assistant-qt4.png &&
|
---|
| 269 | install -v -Dm644 tools/designer/src/designer/images/designer.png \
|
---|
[a8ece039] | 270 | /usr/share/pixmaps/designer-qt4.png &&
|
---|
[7af92fe5] | 271 | install -v -Dm644 tools/linguist/linguist/images/icons/linguist-128-32.png \
|
---|
[a8ece039] | 272 | /usr/share/pixmaps/linguist-qt4.png &&
|
---|
[7af92fe5] | 273 | install -v -Dm644 tools/qdbus/qdbusviewer/images/qdbusviewer-128.png \
|
---|
| 274 | /usr/share/pixmaps/qdbusviewer-qt4.png</userinput></screen>
|
---|
| 275 |
|
---|
| 276 | <para>
|
---|
| 277 | Remove references to the build directory from installed files by
|
---|
| 278 | running the following command as the
|
---|
| 279 | <systemitem class="username">root</systemitem> user:
|
---|
| 280 | </para>
|
---|
| 281 |
|
---|
[acacfb64] | 282 | <screen role="root"><userinput>for file in 3Support CLucene Core DBus Declarative DesignerComponents \
|
---|
| 283 | Designer Gui Help Multimedia Network OpenGL Script \
|
---|
| 284 | ScriptTools Sql Svg Test UiTools WebKit XmlPatterns Xml phonon
|
---|
[a6c6923] | 285 | do
|
---|
[acacfb64] | 286 | [ -e /usr/lib/libQt${file}.prl ] && sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' \
|
---|
| 287 | /usr/lib/libQt${file}.prl
|
---|
[a6c6923] | 288 | done
|
---|
| 289 | unset file</userinput></screen>
|
---|
[7af92fe5] | 290 |
|
---|
| 291 | <para>
|
---|
[fb28b3b] | 292 | If also installing Qt5 into /usr,
|
---|
| 293 | symlink the <application>Qt4</application> executables into
|
---|
[7af92fe5] | 294 | <filename class="directory">/usr/bin</filename> by running the
|
---|
| 295 | following commands as the
|
---|
| 296 | <systemitem class="username">root</systemitem> user:
|
---|
| 297 | </para>
|
---|
| 298 |
|
---|
| 299 | <screen role="root"><userinput>for file in /usr/lib/qt4/bin/*
|
---|
| 300 | do
|
---|
| 301 | ln -sfv ../lib/qt4/bin/$(basename $file) /usr/bin/$(basename $file)-qt4
|
---|
| 302 | done</userinput></screen>
|
---|
| 303 |
|
---|
[54e9eea] | 304 | <bridgehead renderas="sect3">Method 2: Installing in /opt/qt-&qt4-version;</bridgehead>
|
---|
| 305 |
|
---|
[fb28b3b] | 306 | <para>
|
---|
| 307 | This section provides an alternate way to install Qt4 by installing
|
---|
| 308 | almost all of the files in the <filename class="directory">/opt</filename>
|
---|
| 309 | directory. This allows management of all Qt4 related files in one unit.
|
---|
| 310 | For instance, a new version of Qt4 can be installed without over-writing
|
---|
| 311 | the existing installation and entire Qt4 instances can be easily removed.
|
---|
| 312 | However, it has the disadvantage of needing some extra configuration.
|
---|
| 313 | </para>
|
---|
| 314 |
|
---|
| 315 |
|
---|
[54e9eea] | 316 | <para>
|
---|
[a8ece039] | 317 | Install <application>Qt</application> in /opt/qt-&qt4-version;
|
---|
[54e9eea] | 318 | by running the following commands:
|
---|
| 319 | </para>
|
---|
| 320 |
|
---|
| 321 | <screen><userinput>sed -i -e "/#if/d" -e "/#error/d" -e "/#endif/d" \
|
---|
| 322 | config.tests/unix/libmng/libmng.cpp &&
|
---|
[57242ab] | 323 | sed -i '/CONFIG -/ a\isEmpty(OUTPUT_DIR): OUTPUT_DIR = ../..' \
|
---|
| 324 | src/3rdparty/webkit/Source/WebKit2/DerivedSources.pro &&
|
---|
[54e9eea] | 325 |
|
---|
| 326 | export QTDIR=/opt/qt-&qt4-version;
|
---|
| 327 |
|
---|
| 328 | ./configure -prefix $QTDIR \
|
---|
| 329 | -sysconfdir /etc/xdg \
|
---|
| 330 | -confirm-license \
|
---|
| 331 | -opensource \
|
---|
| 332 | -release \
|
---|
| 333 | -dbus-linked \
|
---|
| 334 | -openssl-linked \
|
---|
| 335 | -system-sqlite \
|
---|
| 336 | -plugin-sql-sqlite \
|
---|
| 337 | -no-phonon \
|
---|
| 338 | -no-phonon-backend \
|
---|
| 339 | -no-nis \
|
---|
| 340 | -no-openvg \
|
---|
| 341 | -nomake demos \
|
---|
| 342 | -nomake examples \
|
---|
| 343 | -optimized-qmake &&
|
---|
| 344 |
|
---|
| 345 | make</userinput></screen>
|
---|
| 346 |
|
---|
| 347 | <para>
|
---|
| 348 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 349 | </para>
|
---|
| 350 |
|
---|
[7ff6db2] | 351 | <screen role="root"><userinput>make install &&
|
---|
| 352 | ln -svfn qt-&qt4-version; /opt/qt &&
|
---|
[54e9eea] | 353 |
|
---|
| 354 | install -v -Dm644 src/gui/dialogs/images/qtlogo-64.png \
|
---|
| 355 | /usr/share/pixmaps/qt4logo.png &&
|
---|
| 356 | install -v -Dm644 tools/assistant/tools/assistant/images/assistant-128.png \
|
---|
| 357 | /usr/share/pixmaps/assistant-qt4.png &&
|
---|
| 358 | install -v -Dm644 tools/designer/src/designer/images/designer.png \
|
---|
| 359 | /usr/share/pixmaps/designer-qt4.png &&
|
---|
| 360 | install -v -Dm644 tools/linguist/linguist/images/icons/linguist-128-32.png \
|
---|
| 361 | /usr/share/pixmaps/linguist-qt4.png &&
|
---|
| 362 | install -v -Dm644 tools/qdbus/qdbusviewer/images/qdbusviewer-128.png \
|
---|
| 363 | /usr/share/pixmaps/qdbusviewer-qt4.png</userinput></screen>
|
---|
| 364 |
|
---|
| 365 | <para>
|
---|
| 366 | Remove references to the build directory from installed files by
|
---|
| 367 | running the following command as the
|
---|
| 368 | <systemitem class="username">root</systemitem> user:
|
---|
| 369 | </para>
|
---|
| 370 |
|
---|
[4ef0f11] | 371 | <screen role="root"><userinput>for file in `basename -a -s .prl $QTDIR/lib/lib*.prl`; do
|
---|
| 372 | sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' \
|
---|
| 373 | $QTDIR/lib/${file}.prl
|
---|
| 374 | perl -pi -e "s, -L$PWD/?\S+,,g" $QTDIR/lib/pkgconfig/${file##lib}.pc
|
---|
[54e9eea] | 375 | done
|
---|
| 376 |
|
---|
| 377 | unset file</userinput></screen>
|
---|
| 378 |
|
---|
[7af92fe5] | 379 | </sect2>
|
---|
| 380 |
|
---|
| 381 | <sect2 role="commands">
|
---|
| 382 | <title>Command Explanations</title>
|
---|
| 383 |
|
---|
[a6c6923] | 384 | <para>
|
---|
[57242ab] | 385 | <command>sed -i ...</command>: First command fixes detection of
|
---|
| 386 | <application>libmng</application> 2.0 and second one prevents configure
|
---|
| 387 | script to write in root directory if building as privileged user.
|
---|
[a6c6923] | 388 | </para>
|
---|
| 389 |
|
---|
[7af92fe5] | 390 | <para>
|
---|
| 391 | <parameter>-confirm-license</parameter>: Accept license
|
---|
| 392 | without prompting user during configuration.
|
---|
| 393 | </para>
|
---|
| 394 |
|
---|
| 395 | <para>
|
---|
| 396 | <parameter>-opensource</parameter>: Install the opensource
|
---|
| 397 | version of <application>Qt</application>.
|
---|
| 398 | </para>
|
---|
| 399 |
|
---|
[8d4b121] | 400 | <para>
|
---|
| 401 | <parameter>-release</parameter>: This switch disables
|
---|
| 402 | building with debugging symbols.
|
---|
| 403 | </para>
|
---|
[7af92fe5] | 404 |
|
---|
| 405 | <para>
|
---|
| 406 | <parameter>-nomake examples -nomake demos</parameter>:
|
---|
| 407 | These switches disable building programs that are only of
|
---|
| 408 | interest to a <application>Qt</application> developer.
|
---|
| 409 | </para>
|
---|
| 410 |
|
---|
| 411 | <para>
|
---|
| 412 | <parameter>-system-sqlite</parameter>: This switch enables use
|
---|
| 413 | the system version of <application>SQLite</application>.
|
---|
| 414 | </para>
|
---|
| 415 |
|
---|
| 416 | <para>
|
---|
| 417 | <parameter>-no-nis</parameter>: This switch disables support
|
---|
| 418 | for Network Information Service (NIS) which has been
|
---|
| 419 | deprecated in recent versions of <application>Glibc</application>.
|
---|
| 420 | </para>
|
---|
| 421 |
|
---|
| 422 | <para>
|
---|
| 423 | <parameter>-no-phonon -no-phonon-backend</parameter>: These
|
---|
| 424 | switches disable building of the bundled
|
---|
| 425 | <application>Phonon</application> library. Better version
|
---|
| 426 | is provided by <xref linkend="phonon"/> package.
|
---|
| 427 | </para>
|
---|
| 428 |
|
---|
| 429 | <para>
|
---|
| 430 | <parameter>-dbus-linkend -openssl-linkend</parameter>: These
|
---|
| 431 | switches enable explicit linking of the
|
---|
| 432 | <application>D-Bus</application> and
|
---|
| 433 | <application>OpenSSL</application> libraries into
|
---|
| 434 | <application>Qt</application> libraries instead of
|
---|
| 435 | <command>dlopen()</command>-ing them.
|
---|
| 436 | </para>
|
---|
| 437 |
|
---|
| 438 | <para>
|
---|
| 439 | <parameter>-no-openvg</parameter>: This switch disables
|
---|
| 440 | <application>OpenVG</application> support in
|
---|
| 441 | <application>Qt</application>.
|
---|
| 442 | </para>
|
---|
| 443 |
|
---|
[8d4b121] | 444 | <para>
|
---|
| 445 | <parameter>-optimized-qmake</parameter>: This switch enables
|
---|
| 446 | building of the optimized <command>qmake</command> program.
|
---|
| 447 | </para>
|
---|
| 448 |
|
---|
[df5884e] | 449 | <para>
|
---|
| 450 | <option>-no-dbus</option>: Use this switch if you don't have
|
---|
| 451 | <application>D-Bus</application> installed.
|
---|
| 452 | </para>
|
---|
| 453 |
|
---|
[7af92fe5] | 454 | </sect2>
|
---|
| 455 |
|
---|
| 456 | <sect2 role="configuration">
|
---|
| 457 | <title>Configuring Qt</title>
|
---|
| 458 |
|
---|
| 459 | <sect3 id="qt4-config">
|
---|
| 460 | <title>Configuration Information</title>
|
---|
| 461 |
|
---|
| 462 | <para>
|
---|
[a8ece039] | 463 | If you installed <application>Qt</application> in /usr,
|
---|
| 464 | create an environment variable needed by certain packages.
|
---|
[7af92fe5] | 465 | As the <systemitem class="username">root</systemitem> user:
|
---|
| 466 | </para>
|
---|
| 467 |
|
---|
| 468 | <screen role="root"><userinput>cat > /etc/profile.d/qt.sh << EOF
|
---|
| 469 | <literal># Begin /etc/profile.d/qt.sh
|
---|
| 470 |
|
---|
| 471 | QTDIR=/usr
|
---|
| 472 |
|
---|
| 473 | export QTDIR
|
---|
| 474 |
|
---|
| 475 | # End /etc/profile.d/qt.sh</literal>
|
---|
| 476 | EOF</userinput></screen>
|
---|
| 477 |
|
---|
[54e9eea] | 478 | <para>
|
---|
| 479 | If you installed <application>Qt</application> in a location other
|
---|
[a8ece039] | 480 | than /usr, you need to update the following configuration files so
|
---|
| 481 | that <application>Qt</application> is correctly found by other packages
|
---|
| 482 | and system processes.</para>
|
---|
| 483 |
|
---|
| 484 | <para>As the <systemitem class="username">root</systemitem> user, update
|
---|
[54e9eea] | 485 | the <filename>/etc/ld.so.conf</filename> file and the dynamic linker's
|
---|
| 486 | run-time cache file:
|
---|
| 487 | </para>
|
---|
[a8ece039] | 488 |
|
---|
[54e9eea] | 489 | <screen role="root"><userinput>cat >> /etc/ld.so.conf << EOF
|
---|
[fb28b3b] | 490 | <literal># Begin Qt addition
|
---|
[54e9eea] | 491 |
|
---|
| 492 | /opt/qt/lib
|
---|
| 493 |
|
---|
| 494 | # End Qt addition</literal>
|
---|
| 495 | EOF
|
---|
| 496 |
|
---|
| 497 | ldconfig</userinput></screen>
|
---|
[a8ece039] | 498 |
|
---|
[fb28b3b] | 499 | <indexterm zone="qt4 qt4-config">
|
---|
[a8ece039] | 500 | <primary sortas="e-etc-ld.so.conf">/etc/ld.so.conf</primary>
|
---|
| 501 | </indexterm>
|
---|
| 502 |
|
---|
[54e9eea] | 503 | <para>
|
---|
| 504 | As the <systemitem class="username">root</systemitem> user, create
|
---|
| 505 | the <filename>/etc/profile.d/qt.sh</filename> file:
|
---|
| 506 | </para>
|
---|
[a8ece039] | 507 |
|
---|
[54e9eea] | 508 | <screen role="root"><userinput>cat > /etc/profile.d/qt.sh << EOF
|
---|
[fb28b3b] | 509 | <literal># Begin /etc/profile.d/qt.sh
|
---|
[a8ece039] | 510 |
|
---|
[54e9eea] | 511 | QTDIR=/opt/qt
|
---|
[a8ece039] | 512 |
|
---|
[54e9eea] | 513 | pathappend /opt/qt/bin PATH
|
---|
| 514 | pathappend /opt/qt/lib/pkgconfig PKG_CONFIG_PATH
|
---|
[a8ece039] | 515 |
|
---|
[54e9eea] | 516 | export QTDIR
|
---|
[a8ece039] | 517 |
|
---|
[54e9eea] | 518 | # End /etc/profile.d/qt.sh</literal>
|
---|
| 519 | EOF</userinput></screen>
|
---|
| 520 |
|
---|
[7af92fe5] | 521 | <para>
|
---|
[fb28b3b] | 522 | For all methods, create the menu entries for installed applications.
|
---|
[7af92fe5] | 523 | As the <systemitem class="username">root</systemitem> user:
|
---|
| 524 | </para>
|
---|
| 525 |
|
---|
[8d4b121] | 526 | <screen role="root"><userinput>install -dm755 /usr/share/applications
|
---|
[54e9eea] | 527 |
|
---|
[8d4b121] | 528 | cat > /usr/share/applications/qtconfig-qt4.desktop << "EOF"
|
---|
[7af92fe5] | 529 | <literal>[Desktop Entry]
|
---|
| 530 | Name=Qt4 Config
|
---|
| 531 | Comment=Configure Qt4 behavior, styles, fonts
|
---|
| 532 | Exec=qtconfig-qt4
|
---|
| 533 | Icon=qt4logo
|
---|
| 534 | Terminal=false
|
---|
| 535 | Encoding=UTF-8
|
---|
| 536 | Type=Application
|
---|
| 537 | Categories=Qt;Settings;</literal>
|
---|
| 538 | EOF
|
---|
[54e9eea] | 539 |
|
---|
[7af92fe5] | 540 | cat > /usr/share/applications/assistant-qt4.desktop << "EOF"
|
---|
| 541 | <literal>[Desktop Entry]
|
---|
| 542 | Name=Qt4 Assistant
|
---|
| 543 | Comment=Shows Qt4 documentation and examples
|
---|
| 544 | Exec=assistant-qt4
|
---|
| 545 | Icon=assistant-qt4
|
---|
| 546 | Terminal=false
|
---|
| 547 | Encoding=UTF-8
|
---|
| 548 | Type=Application
|
---|
| 549 | Categories=Qt;Development;Documentation;</literal>
|
---|
| 550 | EOF
|
---|
[54e9eea] | 551 |
|
---|
[7af92fe5] | 552 | cat > /usr/share/applications/designer-qt4.desktop << "EOF"
|
---|
| 553 | <literal>[Desktop Entry]
|
---|
| 554 | Name=Qt4 Designer
|
---|
| 555 | Comment=Design GUIs for Qt4 applications
|
---|
| 556 | Exec=designer-qt4
|
---|
| 557 | Icon=designer-qt4
|
---|
| 558 | MimeType=application/x-designer;
|
---|
| 559 | Terminal=false
|
---|
| 560 | Encoding=UTF-8
|
---|
| 561 | Type=Application
|
---|
| 562 | Categories=Qt;Development;</literal>
|
---|
| 563 | EOF
|
---|
[54e9eea] | 564 |
|
---|
[7af92fe5] | 565 | cat > /usr/share/applications/linguist-qt4.desktop << "EOF"
|
---|
| 566 | <literal>[Desktop Entry]
|
---|
| 567 | Name=Qt4 Linguist
|
---|
| 568 | Comment=Add translations to Qt4 applications
|
---|
| 569 | Exec=linguist-qt4
|
---|
| 570 | Icon=linguist-qt4
|
---|
| 571 | MimeType=text/vnd.trolltech.linguist;application/x-linguist;
|
---|
| 572 | Terminal=false
|
---|
| 573 | Encoding=UTF-8
|
---|
| 574 | Type=Application
|
---|
| 575 | Categories=Qt;Development;</literal>
|
---|
[8d4b121] | 576 | EOF
|
---|
[54e9eea] | 577 |
|
---|
[8d4b121] | 578 | cat > /usr/share/applications/qdbusviewer-qt4.desktop << "EOF"
|
---|
[7af92fe5] | 579 | <literal>[Desktop Entry]
|
---|
| 580 | Name=Qt4 QDbusViewer
|
---|
| 581 | GenericName=D-Bus Debugger
|
---|
| 582 | Comment=Debug D-Bus applications
|
---|
| 583 | Exec=qdbusviewer-qt4
|
---|
| 584 | Icon=qdbusviewer-qt4
|
---|
| 585 | Terminal=false
|
---|
| 586 | Encoding=UTF-8
|
---|
| 587 | Type=Application
|
---|
| 588 | Categories=Qt;Development;Debugger;</literal>
|
---|
| 589 | EOF</userinput></screen>
|
---|
| 590 |
|
---|
| 591 | </sect3>
|
---|
| 592 |
|
---|
| 593 | </sect2>
|
---|
| 594 |
|
---|
| 595 | <sect2 role="content">
|
---|
| 596 | <title>Contents</title>
|
---|
| 597 |
|
---|
| 598 | <segmentedlist>
|
---|
| 599 | <segtitle>Installed Programs</segtitle>
|
---|
| 600 | <segtitle>Installed Libraries</segtitle>
|
---|
| 601 | <segtitle>Installed Directories</segtitle>
|
---|
| 602 |
|
---|
| 603 | <seglistitem>
|
---|
| 604 | <seg>
|
---|
[8d4b121] | 605 | assistant-qt4, designer-qt4, lconvert-qt4, linguist-qt4,
|
---|
| 606 | lrelease-qt4, lupdate-qt4, moc-qt4, pixeltool-qt4,
|
---|
| 607 | qcollectiongenerator-qt4, qdbuscpp2xml-qt4, qdbus-qt4,
|
---|
| 608 | qdbusviewer-qt4, qdbusxml2cpp-qt4, qdoc3-qt4, qhelpconverter-qt4,
|
---|
| 609 | qhelpgenerator-qt4, qmake-qt4, qmlplugindump-qt4, qmlviewer-qt4,
|
---|
| 610 | qt3to4-qt4, qtconfig-qt4, qttracereplay-qt4, rcc-qt4, uic3-qt4,
|
---|
| 611 | uic-qt4, xmlpatterns-qt4 and xmlpatternsvalidator-qt4
|
---|
[7af92fe5] | 612 | </seg>
|
---|
| 613 | <seg>
|
---|
| 614 | libQt3Support.so, libQtCLucene.so, libQtCore.so, libQtDBus.so,
|
---|
[8d4b121] | 615 | libQtDeclarative.so, libQtDesignerComponents.so,
|
---|
| 616 | libQtDesigner.so, libQtGui.so, libQtHelp.so, libQtMultimedia.so,
|
---|
| 617 | libQtNetwork.so, libQtOpenGL.so, libQtScript.so, libQtScriptTools.so,
|
---|
| 618 | libQtSql.so, libQtSvg.so, libQtTest.so, libQtWebKit.so,
|
---|
| 619 | libQtXmlPatterns.so and libQtXml.so
|
---|
[7af92fe5] | 620 | </seg>
|
---|
| 621 | <seg>
|
---|
| 622 | /usr/include/qt4,
|
---|
| 623 | /usr/lib/qt4,
|
---|
[54e9eea] | 624 | /usr/share/doc/qt4, and
|
---|
[a8ece039] | 625 | /usr/share/qt4 (OR $QTDIR)
|
---|
[54e9eea] | 626 | (OR $QTDIR)
|
---|
[7af92fe5] | 627 | </seg>
|
---|
| 628 | </seglistitem>
|
---|
| 629 | </segmentedlist>
|
---|
| 630 |
|
---|
| 631 | <variablelist>
|
---|
| 632 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 633 | <?dbfo list-presentation="list"?>
|
---|
| 634 | <?dbhtml list-presentation="table"?>
|
---|
| 635 |
|
---|
[8d4b121] | 636 | <varlistentry id="assistant-qt4">
|
---|
| 637 | <term><command>assistant-qt4</command></term>
|
---|
[7af92fe5] | 638 | <listitem>
|
---|
| 639 | <para>
|
---|
| 640 | is a tool for presenting on-line documentation.
|
---|
| 641 | </para>
|
---|
[8d4b121] | 642 | <indexterm zone="qt4 assistant-qt4">
|
---|
| 643 | <primary sortas="b-assistant-qt4">assistant-qt4</primary>
|
---|
[7af92fe5] | 644 | </indexterm>
|
---|
| 645 | </listitem>
|
---|
| 646 | </varlistentry>
|
---|
| 647 |
|
---|
[8d4b121] | 648 | <varlistentry id="designer-qt4">
|
---|
| 649 | <term><command>designer-qt4</command></term>
|
---|
[7af92fe5] | 650 | <listitem>
|
---|
| 651 | <para>
|
---|
| 652 | is a full-fledged GUI builder. It includes
|
---|
| 653 | powerful features such as preview mode, automatic widget
|
---|
| 654 | layout, support for custom widgets, and an advanced
|
---|
| 655 | property editor.
|
---|
| 656 | </para>
|
---|
[8d4b121] | 657 | <indexterm zone="qt4 designer-qt4">
|
---|
| 658 | <primary sortas="b-designer-qt4">designer-qt4</primary>
|
---|
[7af92fe5] | 659 | </indexterm>
|
---|
| 660 | </listitem>
|
---|
| 661 | </varlistentry>
|
---|
| 662 |
|
---|
[8d4b121] | 663 | <varlistentry id="linguist-qt4">
|
---|
| 664 | <term><command>linguist-qt4</command></term>
|
---|
[7af92fe5] | 665 | <listitem>
|
---|
| 666 | <para>
|
---|
| 667 | provides support for translating applications into
|
---|
| 668 | local languages.
|
---|
| 669 | </para>
|
---|
[8d4b121] | 670 | <indexterm zone="qt4 linguist-qt4">
|
---|
| 671 | <primary sortas="b-linguist-qt4">linguist-qt4</primary>
|
---|
[7af92fe5] | 672 | </indexterm>
|
---|
| 673 | </listitem>
|
---|
| 674 | </varlistentry>
|
---|
| 675 |
|
---|
[8d4b121] | 676 | <varlistentry id="lrelease-qt4">
|
---|
| 677 | <term><command>lrelease-qt4</command></term>
|
---|
[7af92fe5] | 678 | <listitem>
|
---|
| 679 | <para>
|
---|
| 680 | is a simple command line tool. It reads a Qt project
|
---|
| 681 | file and produces message files used by the application.
|
---|
| 682 | </para>
|
---|
[8d4b121] | 683 | <indexterm zone="qt4 lrelease-qt4">
|
---|
| 684 | <primary sortas="b-lrelease-qt4">lrelease-qt4</primary>
|
---|
[7af92fe5] | 685 | </indexterm>
|
---|
| 686 | </listitem>
|
---|
| 687 | </varlistentry>
|
---|
| 688 |
|
---|
[8d4b121] | 689 | <varlistentry id="lupdate-qt4">
|
---|
| 690 | <term><command>lupdate-qt4</command></term>
|
---|
[7af92fe5] | 691 | <listitem>
|
---|
| 692 | <para>
|
---|
| 693 | reads a Qt project file, finds the translatable
|
---|
| 694 | strings in the specified source, header and Qt Designer
|
---|
| 695 | interface files, and produces or updates the translation
|
---|
| 696 | files listed in the project file.
|
---|
| 697 | </para>
|
---|
[8d4b121] | 698 | <indexterm zone="qt4 lupdate-qt4">
|
---|
| 699 | <primary sortas="b-lupdate-qt4">lupdate-qt4</primary>
|
---|
[7af92fe5] | 700 | </indexterm>
|
---|
| 701 | </listitem>
|
---|
| 702 | </varlistentry>
|
---|
| 703 |
|
---|
[8d4b121] | 704 | <varlistentry id="moc-qt4">
|
---|
| 705 | <term><command>moc-qt4</command></term>
|
---|
[7af92fe5] | 706 | <listitem>
|
---|
| 707 | <para>
|
---|
| 708 | generates Qt meta object support code.
|
---|
| 709 | </para>
|
---|
[8d4b121] | 710 | <indexterm zone="qt4 moc-qt4">
|
---|
| 711 | <primary sortas="b-moc-qt4">moc-qt4</primary>
|
---|
[7af92fe5] | 712 | </indexterm>
|
---|
| 713 | </listitem>
|
---|
| 714 | </varlistentry>
|
---|
| 715 |
|
---|
[8d4b121] | 716 | <varlistentry id="pixeltool-qt4">
|
---|
| 717 | <term><command>pixeltool-qt4</command></term>
|
---|
[7af92fe5] | 718 | <listitem>
|
---|
| 719 | <para>
|
---|
| 720 | is a desktop magnifier and as you move your mouse around
|
---|
| 721 | the screen it will show the magnified contents in its window.
|
---|
| 722 | </para>
|
---|
[8d4b121] | 723 | <indexterm zone="qt4 pixeltool-qt4">
|
---|
| 724 | <primary sortas="b-pixeltool-qt4">pixeltool-qt4</primary>
|
---|
[7af92fe5] | 725 | </indexterm>
|
---|
| 726 | </listitem>
|
---|
| 727 | </varlistentry>
|
---|
| 728 |
|
---|
[8d4b121] | 729 | <varlistentry id="qmake-qt4">
|
---|
| 730 | <term><command>qmake-qt4</command></term>
|
---|
[7af92fe5] | 731 | <listitem>
|
---|
| 732 | <para>
|
---|
| 733 | uses information stored in project files to
|
---|
| 734 | determine what should go in the makefiles it
|
---|
| 735 | generates.
|
---|
| 736 | </para>
|
---|
[8d4b121] | 737 | <indexterm zone="qt4 qmake-qt4">
|
---|
| 738 | <primary sortas="b-qmake-qt4">qmake-qt4</primary>
|
---|
[7af92fe5] | 739 | </indexterm>
|
---|
| 740 | </listitem>
|
---|
| 741 | </varlistentry>
|
---|
| 742 |
|
---|
[8d4b121] | 743 | <varlistentry id="qt3to4-qt4">
|
---|
| 744 | <term><command>qt3to4-qt4</command></term>
|
---|
[7af92fe5] | 745 | <listitem>
|
---|
| 746 | <para>
|
---|
| 747 | qt3to4 is a tool to help update Qt3 code to Qt4.
|
---|
| 748 | </para>
|
---|
[8d4b121] | 749 | <indexterm zone="qt4 qt3to4-qt4">
|
---|
| 750 | <primary sortas="b-qt3to4-qt4">qt3to4-qt4</primary>
|
---|
[7af92fe5] | 751 | </indexterm>
|
---|
| 752 | </listitem>
|
---|
| 753 | </varlistentry>
|
---|
| 754 |
|
---|
[8d4b121] | 755 | <varlistentry id="qtconfig-qt4">
|
---|
| 756 | <term><command>qtconfig-qt4</command></term>
|
---|
[7af92fe5] | 757 | <listitem>
|
---|
| 758 | <para>
|
---|
| 759 | is used to customize the appearance of Qt applications.
|
---|
| 760 | </para>
|
---|
[8d4b121] | 761 | <indexterm zone="qt4 qtconfig-qt4">
|
---|
| 762 | <primary sortas="b-qtconfig-qt4">qtconfig-qt4</primary>
|
---|
[7af92fe5] | 763 | </indexterm>
|
---|
| 764 | </listitem>
|
---|
| 765 | </varlistentry>
|
---|
| 766 |
|
---|
[8d4b121] | 767 | <varlistentry id="rcc-qt4">
|
---|
| 768 | <term><command>rcc-qt4</command></term>
|
---|
[7af92fe5] | 769 | <listitem>
|
---|
| 770 | <para>
|
---|
| 771 | is a resource compiler used in conjunction with designer.
|
---|
| 772 | </para>
|
---|
[8d4b121] | 773 | <indexterm zone="qt4 rcc-qt4">
|
---|
| 774 | <primary sortas="b-rcc-qt4">rcc-qt4</primary>
|
---|
[7af92fe5] | 775 | </indexterm>
|
---|
| 776 | </listitem>
|
---|
| 777 | </varlistentry>
|
---|
| 778 |
|
---|
[8d4b121] | 779 | <varlistentry id="uic-qt4">
|
---|
| 780 | <term><command>uic-qt4</command></term>
|
---|
[7af92fe5] | 781 | <listitem>
|
---|
| 782 | <para>
|
---|
| 783 | is a Qt user interface compiler.
|
---|
| 784 | </para>
|
---|
[8d4b121] | 785 | <indexterm zone="qt4 uic-qt4">
|
---|
| 786 | <primary sortas="b-uic-qt4">uic-qt4</primary>
|
---|
[7af92fe5] | 787 | </indexterm>
|
---|
| 788 | </listitem>
|
---|
| 789 | </varlistentry>
|
---|
| 790 |
|
---|
[8d4b121] | 791 | <varlistentry id="uic3-qt4">
|
---|
| 792 | <term><command>uic3-qt4</command></term>
|
---|
[7af92fe5] | 793 | <listitem>
|
---|
| 794 | <para>
|
---|
| 795 | is a tool to generate Qt4 code out of
|
---|
| 796 | user interface files generated by the Qt3
|
---|
| 797 | version of designer.
|
---|
| 798 | </para>
|
---|
[8d4b121] | 799 | <indexterm zone="qt4 uic3-qt4">
|
---|
| 800 | <primary sortas="b-uic3-qt4">uic3-qt4</primary>
|
---|
[7af92fe5] | 801 | </indexterm>
|
---|
| 802 | </listitem>
|
---|
| 803 | </varlistentry>
|
---|
| 804 |
|
---|
| 805 | </variablelist>
|
---|
| 806 |
|
---|
| 807 | </sect2>
|
---|
| 808 |
|
---|
| 809 | </sect1>
|
---|