[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),
|
---|
| 105 | <xref linkend="mysql"/>,
|
---|
| 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 |
|
---|
| 251 | <para>
|
---|
| 252 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 253 | </para>
|
---|
| 254 |
|
---|
| 255 | <screen role="root"><userinput>make install &&
|
---|
| 256 | rm -rf /usr/tests &&
|
---|
| 257 | install -v -Dm644 src/gui/dialogs/images/qtlogo-64.png \
|
---|
[a8ece039] | 258 | /usr/share/pixmaps/qt4logo.png &&
|
---|
[7af92fe5] | 259 | install -v -Dm644 tools/assistant/tools/assistant/images/assistant-128.png \
|
---|
| 260 | /usr/share/pixmaps/assistant-qt4.png &&
|
---|
| 261 | install -v -Dm644 tools/designer/src/designer/images/designer.png \
|
---|
[a8ece039] | 262 | /usr/share/pixmaps/designer-qt4.png &&
|
---|
[7af92fe5] | 263 | install -v -Dm644 tools/linguist/linguist/images/icons/linguist-128-32.png \
|
---|
[a8ece039] | 264 | /usr/share/pixmaps/linguist-qt4.png &&
|
---|
[7af92fe5] | 265 | install -v -Dm644 tools/qdbus/qdbusviewer/images/qdbusviewer-128.png \
|
---|
| 266 | /usr/share/pixmaps/qdbusviewer-qt4.png</userinput></screen>
|
---|
| 267 |
|
---|
| 268 | <para>
|
---|
| 269 | Remove references to the build directory from installed files by
|
---|
| 270 | running the following command as the
|
---|
| 271 | <systemitem class="username">root</systemitem> user:
|
---|
| 272 | </para>
|
---|
| 273 |
|
---|
[a6c6923] | 274 | <screen role="root"><userinput>for file in 3Support CLucene Core DBus Declarative DesignerComponents \
|
---|
| 275 | Designer Gui Help Multimedia Network OpenGL Script \
|
---|
| 276 | ScriptTools Sql Svg Test UiTools WebKit XmlPatterns Xml
|
---|
| 277 | do
|
---|
| 278 | sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' \
|
---|
| 279 | /usr/lib/libQt${file}.prl
|
---|
| 280 | perl -pi -e "s, -L$PWD/?\S+,,g" /usr/lib/pkgconfig/Qt${file}.pc
|
---|
| 281 | done
|
---|
| 282 | unset file</userinput></screen>
|
---|
[7af92fe5] | 283 |
|
---|
| 284 | <para>
|
---|
[fb28b3b] | 285 | If also installing Qt5 into /usr,
|
---|
| 286 | symlink the <application>Qt4</application> executables into
|
---|
[7af92fe5] | 287 | <filename class="directory">/usr/bin</filename> by running the
|
---|
| 288 | following commands as the
|
---|
| 289 | <systemitem class="username">root</systemitem> user:
|
---|
| 290 | </para>
|
---|
| 291 |
|
---|
| 292 | <screen role="root"><userinput>for file in /usr/lib/qt4/bin/*
|
---|
| 293 | do
|
---|
| 294 | ln -sfv ../lib/qt4/bin/$(basename $file) /usr/bin/$(basename $file)-qt4
|
---|
| 295 | done</userinput></screen>
|
---|
| 296 |
|
---|
[54e9eea] | 297 | <bridgehead renderas="sect3">Method 2: Installing in /opt/qt-&qt4-version;</bridgehead>
|
---|
| 298 |
|
---|
[fb28b3b] | 299 | <para>
|
---|
| 300 | This section provides an alternate way to install Qt4 by installing
|
---|
| 301 | almost all of the files in the <filename class="directory">/opt</filename>
|
---|
| 302 | directory. This allows management of all Qt4 related files in one unit.
|
---|
| 303 | For instance, a new version of Qt4 can be installed without over-writing
|
---|
| 304 | the existing installation and entire Qt4 instances can be easily removed.
|
---|
| 305 | However, it has the disadvantage of needing some extra configuration.
|
---|
| 306 | </para>
|
---|
| 307 |
|
---|
| 308 |
|
---|
[54e9eea] | 309 | <para>
|
---|
[a8ece039] | 310 | Install <application>Qt</application> in /opt/qt-&qt4-version;
|
---|
[54e9eea] | 311 | by running the following commands:
|
---|
| 312 | </para>
|
---|
| 313 |
|
---|
| 314 | <screen><userinput>sed -i -e "/#if/d" -e "/#error/d" -e "/#endif/d" \
|
---|
| 315 | config.tests/unix/libmng/libmng.cpp &&
|
---|
[57242ab] | 316 | sed -i '/CONFIG -/ a\isEmpty(OUTPUT_DIR): OUTPUT_DIR = ../..' \
|
---|
| 317 | src/3rdparty/webkit/Source/WebKit2/DerivedSources.pro &&
|
---|
[54e9eea] | 318 |
|
---|
| 319 | export QTDIR=/opt/qt-&qt4-version;
|
---|
| 320 |
|
---|
| 321 | ./configure -prefix $QTDIR \
|
---|
| 322 | -sysconfdir /etc/xdg \
|
---|
| 323 | -confirm-license \
|
---|
| 324 | -opensource \
|
---|
| 325 | -release \
|
---|
| 326 | -dbus-linked \
|
---|
| 327 | -openssl-linked \
|
---|
| 328 | -system-sqlite \
|
---|
| 329 | -plugin-sql-sqlite \
|
---|
| 330 | -no-phonon \
|
---|
| 331 | -no-phonon-backend \
|
---|
| 332 | -no-nis \
|
---|
| 333 | -no-openvg \
|
---|
| 334 | -nomake demos \
|
---|
| 335 | -nomake examples \
|
---|
| 336 | -optimized-qmake &&
|
---|
| 337 |
|
---|
| 338 | make</userinput></screen>
|
---|
| 339 |
|
---|
| 340 | <para>
|
---|
| 341 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 342 | </para>
|
---|
| 343 |
|
---|
[7ff6db2] | 344 | <screen role="root"><userinput>make install &&
|
---|
| 345 | ln -svfn qt-&qt4-version; /opt/qt &&
|
---|
[54e9eea] | 346 |
|
---|
| 347 | install -v -Dm644 src/gui/dialogs/images/qtlogo-64.png \
|
---|
| 348 | /usr/share/pixmaps/qt4logo.png &&
|
---|
| 349 | install -v -Dm644 tools/assistant/tools/assistant/images/assistant-128.png \
|
---|
| 350 | /usr/share/pixmaps/assistant-qt4.png &&
|
---|
| 351 | install -v -Dm644 tools/designer/src/designer/images/designer.png \
|
---|
| 352 | /usr/share/pixmaps/designer-qt4.png &&
|
---|
| 353 | install -v -Dm644 tools/linguist/linguist/images/icons/linguist-128-32.png \
|
---|
| 354 | /usr/share/pixmaps/linguist-qt4.png &&
|
---|
| 355 | install -v -Dm644 tools/qdbus/qdbusviewer/images/qdbusviewer-128.png \
|
---|
| 356 | /usr/share/pixmaps/qdbusviewer-qt4.png</userinput></screen>
|
---|
| 357 |
|
---|
| 358 | <para>
|
---|
| 359 | Remove references to the build directory from installed files by
|
---|
| 360 | running the following command as the
|
---|
| 361 | <systemitem class="username">root</systemitem> user:
|
---|
| 362 | </para>
|
---|
| 363 |
|
---|
| 364 | <screen role="root"><userinput>for file in 3Support CLucene Core DBus Declarative DesignerComponents \
|
---|
| 365 | Designer Gui Help Multimedia Network OpenGL Script \
|
---|
| 366 | ScriptTools Sql Svg Test UiTools WebKit XmlPatterns Xml; do
|
---|
| 367 | sed -i -e '/^QMAKE_PRL_BUILD_DIR/d;s/\(QMAKE_PRL_LIBS =\).*/\1/' \
|
---|
| 368 | $QTDIR/lib/libQt${file}.prl
|
---|
| 369 | perl -pi -e "s, -L$PWD/?\S+,,g" $QTDIR/lib/pkgconfig/Qt${file}.pc
|
---|
| 370 | done
|
---|
| 371 |
|
---|
| 372 | unset file</userinput></screen>
|
---|
| 373 |
|
---|
[7af92fe5] | 374 | </sect2>
|
---|
| 375 |
|
---|
| 376 | <sect2 role="commands">
|
---|
| 377 | <title>Command Explanations</title>
|
---|
| 378 |
|
---|
[a6c6923] | 379 | <para>
|
---|
[57242ab] | 380 | <command>sed -i ...</command>: First command fixes detection of
|
---|
| 381 | <application>libmng</application> 2.0 and second one prevents configure
|
---|
| 382 | script to write in root directory if building as privileged user.
|
---|
[a6c6923] | 383 | </para>
|
---|
| 384 |
|
---|
[7af92fe5] | 385 | <para>
|
---|
| 386 | <parameter>-confirm-license</parameter>: Accept license
|
---|
| 387 | without prompting user during configuration.
|
---|
| 388 | </para>
|
---|
| 389 |
|
---|
| 390 | <para>
|
---|
| 391 | <parameter>-opensource</parameter>: Install the opensource
|
---|
| 392 | version of <application>Qt</application>.
|
---|
| 393 | </para>
|
---|
| 394 |
|
---|
[8d4b121] | 395 | <para>
|
---|
| 396 | <parameter>-release</parameter>: This switch disables
|
---|
| 397 | building with debugging symbols.
|
---|
| 398 | </para>
|
---|
[7af92fe5] | 399 |
|
---|
| 400 | <para>
|
---|
| 401 | <parameter>-nomake examples -nomake demos</parameter>:
|
---|
| 402 | These switches disable building programs that are only of
|
---|
| 403 | interest to a <application>Qt</application> developer.
|
---|
| 404 | </para>
|
---|
| 405 |
|
---|
| 406 | <para>
|
---|
| 407 | <parameter>-system-sqlite</parameter>: This switch enables use
|
---|
| 408 | the system version of <application>SQLite</application>.
|
---|
| 409 | </para>
|
---|
| 410 |
|
---|
| 411 | <para>
|
---|
| 412 | <parameter>-no-nis</parameter>: This switch disables support
|
---|
| 413 | for Network Information Service (NIS) which has been
|
---|
| 414 | deprecated in recent versions of <application>Glibc</application>.
|
---|
| 415 | </para>
|
---|
| 416 |
|
---|
| 417 | <para>
|
---|
| 418 | <parameter>-no-phonon -no-phonon-backend</parameter>: These
|
---|
| 419 | switches disable building of the bundled
|
---|
| 420 | <application>Phonon</application> library. Better version
|
---|
| 421 | is provided by <xref linkend="phonon"/> package.
|
---|
| 422 | </para>
|
---|
| 423 |
|
---|
| 424 | <para>
|
---|
| 425 | <parameter>-dbus-linkend -openssl-linkend</parameter>: These
|
---|
| 426 | switches enable explicit linking of the
|
---|
| 427 | <application>D-Bus</application> and
|
---|
| 428 | <application>OpenSSL</application> libraries into
|
---|
| 429 | <application>Qt</application> libraries instead of
|
---|
| 430 | <command>dlopen()</command>-ing them.
|
---|
| 431 | </para>
|
---|
| 432 |
|
---|
| 433 | <para>
|
---|
| 434 | <parameter>-no-openvg</parameter>: This switch disables
|
---|
| 435 | <application>OpenVG</application> support in
|
---|
| 436 | <application>Qt</application>.
|
---|
| 437 | </para>
|
---|
| 438 |
|
---|
[8d4b121] | 439 | <para>
|
---|
| 440 | <parameter>-optimized-qmake</parameter>: This switch enables
|
---|
| 441 | building of the optimized <command>qmake</command> program.
|
---|
| 442 | </para>
|
---|
| 443 |
|
---|
[7af92fe5] | 444 | </sect2>
|
---|
| 445 |
|
---|
| 446 | <sect2 role="configuration">
|
---|
| 447 | <title>Configuring Qt</title>
|
---|
| 448 |
|
---|
| 449 | <sect3 id="qt4-config">
|
---|
| 450 | <title>Configuration Information</title>
|
---|
| 451 |
|
---|
| 452 | <para>
|
---|
[a8ece039] | 453 | If you installed <application>Qt</application> in /usr,
|
---|
| 454 | create an environment variable needed by certain packages.
|
---|
[7af92fe5] | 455 | As the <systemitem class="username">root</systemitem> user:
|
---|
| 456 | </para>
|
---|
| 457 |
|
---|
| 458 | <screen role="root"><userinput>cat > /etc/profile.d/qt.sh << EOF
|
---|
| 459 | <literal># Begin /etc/profile.d/qt.sh
|
---|
| 460 |
|
---|
| 461 | QTDIR=/usr
|
---|
| 462 |
|
---|
| 463 | export QTDIR
|
---|
| 464 |
|
---|
| 465 | # End /etc/profile.d/qt.sh</literal>
|
---|
| 466 | EOF</userinput></screen>
|
---|
| 467 |
|
---|
[54e9eea] | 468 | <para>
|
---|
| 469 | If you installed <application>Qt</application> in a location other
|
---|
[a8ece039] | 470 | than /usr, you need to update the following configuration files so
|
---|
| 471 | that <application>Qt</application> is correctly found by other packages
|
---|
| 472 | and system processes.</para>
|
---|
| 473 |
|
---|
| 474 | <para>As the <systemitem class="username">root</systemitem> user, update
|
---|
[54e9eea] | 475 | the <filename>/etc/ld.so.conf</filename> file and the dynamic linker's
|
---|
| 476 | run-time cache file:
|
---|
| 477 | </para>
|
---|
[a8ece039] | 478 |
|
---|
[54e9eea] | 479 | <screen role="root"><userinput>cat >> /etc/ld.so.conf << EOF
|
---|
[fb28b3b] | 480 | <literal># Begin Qt addition
|
---|
[54e9eea] | 481 |
|
---|
| 482 | /opt/qt/lib
|
---|
| 483 |
|
---|
| 484 | # End Qt addition</literal>
|
---|
| 485 | EOF
|
---|
| 486 |
|
---|
| 487 | ldconfig</userinput></screen>
|
---|
[a8ece039] | 488 |
|
---|
[fb28b3b] | 489 | <indexterm zone="qt4 qt4-config">
|
---|
[a8ece039] | 490 | <primary sortas="e-etc-ld.so.conf">/etc/ld.so.conf</primary>
|
---|
| 491 | </indexterm>
|
---|
| 492 |
|
---|
[54e9eea] | 493 | <para>
|
---|
| 494 | As the <systemitem class="username">root</systemitem> user, create
|
---|
| 495 | the <filename>/etc/profile.d/qt.sh</filename> file:
|
---|
| 496 | </para>
|
---|
[a8ece039] | 497 |
|
---|
[54e9eea] | 498 | <screen role="root"><userinput>cat > /etc/profile.d/qt.sh << EOF
|
---|
[fb28b3b] | 499 | <literal># Begin /etc/profile.d/qt.sh
|
---|
[a8ece039] | 500 |
|
---|
[54e9eea] | 501 | QTDIR=/opt/qt
|
---|
[a8ece039] | 502 |
|
---|
[54e9eea] | 503 | pathappend /opt/qt/bin PATH
|
---|
| 504 | pathappend /opt/qt/lib/pkgconfig PKG_CONFIG_PATH
|
---|
[a8ece039] | 505 |
|
---|
[54e9eea] | 506 | export QTDIR
|
---|
[a8ece039] | 507 |
|
---|
[54e9eea] | 508 | # End /etc/profile.d/qt.sh</literal>
|
---|
| 509 | EOF</userinput></screen>
|
---|
| 510 |
|
---|
[7af92fe5] | 511 | <para>
|
---|
[fb28b3b] | 512 | For all methods, create the menu entries for installed applications.
|
---|
[7af92fe5] | 513 | As the <systemitem class="username">root</systemitem> user:
|
---|
| 514 | </para>
|
---|
| 515 |
|
---|
[8d4b121] | 516 | <screen role="root"><userinput>install -dm755 /usr/share/applications
|
---|
[54e9eea] | 517 |
|
---|
[8d4b121] | 518 | cat > /usr/share/applications/qtconfig-qt4.desktop << "EOF"
|
---|
[7af92fe5] | 519 | <literal>[Desktop Entry]
|
---|
| 520 | Name=Qt4 Config
|
---|
| 521 | Comment=Configure Qt4 behavior, styles, fonts
|
---|
| 522 | Exec=qtconfig-qt4
|
---|
| 523 | Icon=qt4logo
|
---|
| 524 | Terminal=false
|
---|
| 525 | Encoding=UTF-8
|
---|
| 526 | Type=Application
|
---|
| 527 | Categories=Qt;Settings;</literal>
|
---|
| 528 | EOF
|
---|
[54e9eea] | 529 |
|
---|
[7af92fe5] | 530 | cat > /usr/share/applications/assistant-qt4.desktop << "EOF"
|
---|
| 531 | <literal>[Desktop Entry]
|
---|
| 532 | Name=Qt4 Assistant
|
---|
| 533 | Comment=Shows Qt4 documentation and examples
|
---|
| 534 | Exec=assistant-qt4
|
---|
| 535 | Icon=assistant-qt4
|
---|
| 536 | Terminal=false
|
---|
| 537 | Encoding=UTF-8
|
---|
| 538 | Type=Application
|
---|
| 539 | Categories=Qt;Development;Documentation;</literal>
|
---|
| 540 | EOF
|
---|
[54e9eea] | 541 |
|
---|
[7af92fe5] | 542 | cat > /usr/share/applications/designer-qt4.desktop << "EOF"
|
---|
| 543 | <literal>[Desktop Entry]
|
---|
| 544 | Name=Qt4 Designer
|
---|
| 545 | Comment=Design GUIs for Qt4 applications
|
---|
| 546 | Exec=designer-qt4
|
---|
| 547 | Icon=designer-qt4
|
---|
| 548 | MimeType=application/x-designer;
|
---|
| 549 | Terminal=false
|
---|
| 550 | Encoding=UTF-8
|
---|
| 551 | Type=Application
|
---|
| 552 | Categories=Qt;Development;</literal>
|
---|
| 553 | EOF
|
---|
[54e9eea] | 554 |
|
---|
[7af92fe5] | 555 | cat > /usr/share/applications/linguist-qt4.desktop << "EOF"
|
---|
| 556 | <literal>[Desktop Entry]
|
---|
| 557 | Name=Qt4 Linguist
|
---|
| 558 | Comment=Add translations to Qt4 applications
|
---|
| 559 | Exec=linguist-qt4
|
---|
| 560 | Icon=linguist-qt4
|
---|
| 561 | MimeType=text/vnd.trolltech.linguist;application/x-linguist;
|
---|
| 562 | Terminal=false
|
---|
| 563 | Encoding=UTF-8
|
---|
| 564 | Type=Application
|
---|
| 565 | Categories=Qt;Development;</literal>
|
---|
[8d4b121] | 566 | EOF
|
---|
[54e9eea] | 567 |
|
---|
[8d4b121] | 568 | cat > /usr/share/applications/qdbusviewer-qt4.desktop << "EOF"
|
---|
[7af92fe5] | 569 | <literal>[Desktop Entry]
|
---|
| 570 | Name=Qt4 QDbusViewer
|
---|
| 571 | GenericName=D-Bus Debugger
|
---|
| 572 | Comment=Debug D-Bus applications
|
---|
| 573 | Exec=qdbusviewer-qt4
|
---|
| 574 | Icon=qdbusviewer-qt4
|
---|
| 575 | Terminal=false
|
---|
| 576 | Encoding=UTF-8
|
---|
| 577 | Type=Application
|
---|
| 578 | Categories=Qt;Development;Debugger;</literal>
|
---|
| 579 | EOF</userinput></screen>
|
---|
| 580 |
|
---|
| 581 | </sect3>
|
---|
| 582 |
|
---|
| 583 | </sect2>
|
---|
| 584 |
|
---|
| 585 | <sect2 role="content">
|
---|
| 586 | <title>Contents</title>
|
---|
| 587 |
|
---|
| 588 | <segmentedlist>
|
---|
| 589 | <segtitle>Installed Programs</segtitle>
|
---|
| 590 | <segtitle>Installed Libraries</segtitle>
|
---|
| 591 | <segtitle>Installed Directories</segtitle>
|
---|
| 592 |
|
---|
| 593 | <seglistitem>
|
---|
| 594 | <seg>
|
---|
[8d4b121] | 595 | assistant-qt4, designer-qt4, lconvert-qt4, linguist-qt4,
|
---|
| 596 | lrelease-qt4, lupdate-qt4, moc-qt4, pixeltool-qt4,
|
---|
| 597 | qcollectiongenerator-qt4, qdbuscpp2xml-qt4, qdbus-qt4,
|
---|
| 598 | qdbusviewer-qt4, qdbusxml2cpp-qt4, qdoc3-qt4, qhelpconverter-qt4,
|
---|
| 599 | qhelpgenerator-qt4, qmake-qt4, qmlplugindump-qt4, qmlviewer-qt4,
|
---|
| 600 | qt3to4-qt4, qtconfig-qt4, qttracereplay-qt4, rcc-qt4, uic3-qt4,
|
---|
| 601 | uic-qt4, xmlpatterns-qt4 and xmlpatternsvalidator-qt4
|
---|
[7af92fe5] | 602 | </seg>
|
---|
| 603 | <seg>
|
---|
| 604 | libQt3Support.so, libQtCLucene.so, libQtCore.so, libQtDBus.so,
|
---|
[8d4b121] | 605 | libQtDeclarative.so, libQtDesignerComponents.so,
|
---|
| 606 | libQtDesigner.so, libQtGui.so, libQtHelp.so, libQtMultimedia.so,
|
---|
| 607 | libQtNetwork.so, libQtOpenGL.so, libQtScript.so, libQtScriptTools.so,
|
---|
| 608 | libQtSql.so, libQtSvg.so, libQtTest.so, libQtWebKit.so,
|
---|
| 609 | libQtXmlPatterns.so and libQtXml.so
|
---|
[7af92fe5] | 610 | </seg>
|
---|
| 611 | <seg>
|
---|
| 612 | /usr/include/qt4,
|
---|
| 613 | /usr/lib/qt4,
|
---|
[54e9eea] | 614 | /usr/share/doc/qt4, and
|
---|
[a8ece039] | 615 | /usr/share/qt4 (OR $QTDIR)
|
---|
[54e9eea] | 616 | (OR $QTDIR)
|
---|
[7af92fe5] | 617 | </seg>
|
---|
| 618 | </seglistitem>
|
---|
| 619 | </segmentedlist>
|
---|
| 620 |
|
---|
| 621 | <variablelist>
|
---|
| 622 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 623 | <?dbfo list-presentation="list"?>
|
---|
| 624 | <?dbhtml list-presentation="table"?>
|
---|
| 625 |
|
---|
[8d4b121] | 626 | <varlistentry id="assistant-qt4">
|
---|
| 627 | <term><command>assistant-qt4</command></term>
|
---|
[7af92fe5] | 628 | <listitem>
|
---|
| 629 | <para>
|
---|
| 630 | is a tool for presenting on-line documentation.
|
---|
| 631 | </para>
|
---|
[8d4b121] | 632 | <indexterm zone="qt4 assistant-qt4">
|
---|
| 633 | <primary sortas="b-assistant-qt4">assistant-qt4</primary>
|
---|
[7af92fe5] | 634 | </indexterm>
|
---|
| 635 | </listitem>
|
---|
| 636 | </varlistentry>
|
---|
| 637 |
|
---|
[8d4b121] | 638 | <varlistentry id="designer-qt4">
|
---|
| 639 | <term><command>designer-qt4</command></term>
|
---|
[7af92fe5] | 640 | <listitem>
|
---|
| 641 | <para>
|
---|
| 642 | is a full-fledged GUI builder. It includes
|
---|
| 643 | powerful features such as preview mode, automatic widget
|
---|
| 644 | layout, support for custom widgets, and an advanced
|
---|
| 645 | property editor.
|
---|
| 646 | </para>
|
---|
[8d4b121] | 647 | <indexterm zone="qt4 designer-qt4">
|
---|
| 648 | <primary sortas="b-designer-qt4">designer-qt4</primary>
|
---|
[7af92fe5] | 649 | </indexterm>
|
---|
| 650 | </listitem>
|
---|
| 651 | </varlistentry>
|
---|
| 652 |
|
---|
[8d4b121] | 653 | <varlistentry id="linguist-qt4">
|
---|
| 654 | <term><command>linguist-qt4</command></term>
|
---|
[7af92fe5] | 655 | <listitem>
|
---|
| 656 | <para>
|
---|
| 657 | provides support for translating applications into
|
---|
| 658 | local languages.
|
---|
| 659 | </para>
|
---|
[8d4b121] | 660 | <indexterm zone="qt4 linguist-qt4">
|
---|
| 661 | <primary sortas="b-linguist-qt4">linguist-qt4</primary>
|
---|
[7af92fe5] | 662 | </indexterm>
|
---|
| 663 | </listitem>
|
---|
| 664 | </varlistentry>
|
---|
| 665 |
|
---|
[8d4b121] | 666 | <varlistentry id="lrelease-qt4">
|
---|
| 667 | <term><command>lrelease-qt4</command></term>
|
---|
[7af92fe5] | 668 | <listitem>
|
---|
| 669 | <para>
|
---|
| 670 | is a simple command line tool. It reads a Qt project
|
---|
| 671 | file and produces message files used by the application.
|
---|
| 672 | </para>
|
---|
[8d4b121] | 673 | <indexterm zone="qt4 lrelease-qt4">
|
---|
| 674 | <primary sortas="b-lrelease-qt4">lrelease-qt4</primary>
|
---|
[7af92fe5] | 675 | </indexterm>
|
---|
| 676 | </listitem>
|
---|
| 677 | </varlistentry>
|
---|
| 678 |
|
---|
[8d4b121] | 679 | <varlistentry id="lupdate-qt4">
|
---|
| 680 | <term><command>lupdate-qt4</command></term>
|
---|
[7af92fe5] | 681 | <listitem>
|
---|
| 682 | <para>
|
---|
| 683 | reads a Qt project file, finds the translatable
|
---|
| 684 | strings in the specified source, header and Qt Designer
|
---|
| 685 | interface files, and produces or updates the translation
|
---|
| 686 | files listed in the project file.
|
---|
| 687 | </para>
|
---|
[8d4b121] | 688 | <indexterm zone="qt4 lupdate-qt4">
|
---|
| 689 | <primary sortas="b-lupdate-qt4">lupdate-qt4</primary>
|
---|
[7af92fe5] | 690 | </indexterm>
|
---|
| 691 | </listitem>
|
---|
| 692 | </varlistentry>
|
---|
| 693 |
|
---|
[8d4b121] | 694 | <varlistentry id="moc-qt4">
|
---|
| 695 | <term><command>moc-qt4</command></term>
|
---|
[7af92fe5] | 696 | <listitem>
|
---|
| 697 | <para>
|
---|
| 698 | generates Qt meta object support code.
|
---|
| 699 | </para>
|
---|
[8d4b121] | 700 | <indexterm zone="qt4 moc-qt4">
|
---|
| 701 | <primary sortas="b-moc-qt4">moc-qt4</primary>
|
---|
[7af92fe5] | 702 | </indexterm>
|
---|
| 703 | </listitem>
|
---|
| 704 | </varlistentry>
|
---|
| 705 |
|
---|
[8d4b121] | 706 | <varlistentry id="pixeltool-qt4">
|
---|
| 707 | <term><command>pixeltool-qt4</command></term>
|
---|
[7af92fe5] | 708 | <listitem>
|
---|
| 709 | <para>
|
---|
| 710 | is a desktop magnifier and as you move your mouse around
|
---|
| 711 | the screen it will show the magnified contents in its window.
|
---|
| 712 | </para>
|
---|
[8d4b121] | 713 | <indexterm zone="qt4 pixeltool-qt4">
|
---|
| 714 | <primary sortas="b-pixeltool-qt4">pixeltool-qt4</primary>
|
---|
[7af92fe5] | 715 | </indexterm>
|
---|
| 716 | </listitem>
|
---|
| 717 | </varlistentry>
|
---|
| 718 |
|
---|
[8d4b121] | 719 | <varlistentry id="qmake-qt4">
|
---|
| 720 | <term><command>qmake-qt4</command></term>
|
---|
[7af92fe5] | 721 | <listitem>
|
---|
| 722 | <para>
|
---|
| 723 | uses information stored in project files to
|
---|
| 724 | determine what should go in the makefiles it
|
---|
| 725 | generates.
|
---|
| 726 | </para>
|
---|
[8d4b121] | 727 | <indexterm zone="qt4 qmake-qt4">
|
---|
| 728 | <primary sortas="b-qmake-qt4">qmake-qt4</primary>
|
---|
[7af92fe5] | 729 | </indexterm>
|
---|
| 730 | </listitem>
|
---|
| 731 | </varlistentry>
|
---|
| 732 |
|
---|
[8d4b121] | 733 | <varlistentry id="qt3to4-qt4">
|
---|
| 734 | <term><command>qt3to4-qt4</command></term>
|
---|
[7af92fe5] | 735 | <listitem>
|
---|
| 736 | <para>
|
---|
| 737 | qt3to4 is a tool to help update Qt3 code to Qt4.
|
---|
| 738 | </para>
|
---|
[8d4b121] | 739 | <indexterm zone="qt4 qt3to4-qt4">
|
---|
| 740 | <primary sortas="b-qt3to4-qt4">qt3to4-qt4</primary>
|
---|
[7af92fe5] | 741 | </indexterm>
|
---|
| 742 | </listitem>
|
---|
| 743 | </varlistentry>
|
---|
| 744 |
|
---|
[8d4b121] | 745 | <varlistentry id="qtconfig-qt4">
|
---|
| 746 | <term><command>qtconfig-qt4</command></term>
|
---|
[7af92fe5] | 747 | <listitem>
|
---|
| 748 | <para>
|
---|
| 749 | is used to customize the appearance of Qt applications.
|
---|
| 750 | </para>
|
---|
[8d4b121] | 751 | <indexterm zone="qt4 qtconfig-qt4">
|
---|
| 752 | <primary sortas="b-qtconfig-qt4">qtconfig-qt4</primary>
|
---|
[7af92fe5] | 753 | </indexterm>
|
---|
| 754 | </listitem>
|
---|
| 755 | </varlistentry>
|
---|
| 756 |
|
---|
[8d4b121] | 757 | <varlistentry id="rcc-qt4">
|
---|
| 758 | <term><command>rcc-qt4</command></term>
|
---|
[7af92fe5] | 759 | <listitem>
|
---|
| 760 | <para>
|
---|
| 761 | is a resource compiler used in conjunction with designer.
|
---|
| 762 | </para>
|
---|
[8d4b121] | 763 | <indexterm zone="qt4 rcc-qt4">
|
---|
| 764 | <primary sortas="b-rcc-qt4">rcc-qt4</primary>
|
---|
[7af92fe5] | 765 | </indexterm>
|
---|
| 766 | </listitem>
|
---|
| 767 | </varlistentry>
|
---|
| 768 |
|
---|
[8d4b121] | 769 | <varlistentry id="uic-qt4">
|
---|
| 770 | <term><command>uic-qt4</command></term>
|
---|
[7af92fe5] | 771 | <listitem>
|
---|
| 772 | <para>
|
---|
| 773 | is a Qt user interface compiler.
|
---|
| 774 | </para>
|
---|
[8d4b121] | 775 | <indexterm zone="qt4 uic-qt4">
|
---|
| 776 | <primary sortas="b-uic-qt4">uic-qt4</primary>
|
---|
[7af92fe5] | 777 | </indexterm>
|
---|
| 778 | </listitem>
|
---|
| 779 | </varlistentry>
|
---|
| 780 |
|
---|
[8d4b121] | 781 | <varlistentry id="uic3-qt4">
|
---|
| 782 | <term><command>uic3-qt4</command></term>
|
---|
[7af92fe5] | 783 | <listitem>
|
---|
| 784 | <para>
|
---|
| 785 | is a tool to generate Qt4 code out of
|
---|
| 786 | user interface files generated by the Qt3
|
---|
| 787 | version of designer.
|
---|
| 788 | </para>
|
---|
[8d4b121] | 789 | <indexterm zone="qt4 uic3-qt4">
|
---|
| 790 | <primary sortas="b-uic3-qt4">uic3-qt4</primary>
|
---|
[7af92fe5] | 791 | </indexterm>
|
---|
| 792 | </listitem>
|
---|
| 793 | </varlistentry>
|
---|
| 794 |
|
---|
| 795 | </variablelist>
|
---|
| 796 |
|
---|
| 797 | </sect2>
|
---|
| 798 |
|
---|
| 799 | </sect1>
|
---|