[feeb99a] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[6732c094] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[feeb99a] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[751e96f] | 7 | <!ENTITY qt-download-http "http://ftp.silug.org/mirrors/ftp.trolltech.com/qt/source/qt-x11-free-&qt-version;.tar.bz2">
|
---|
[feeb99a] | 8 | <!ENTITY qt-download-ftp "ftp://ftp.trolltech.com/qt/source/qt-x11-free-&qt-version;.tar.bz2">
|
---|
[d8e2f89b] | 9 | <!ENTITY qt-md5sum "cf3c43a7dfde5bfb76f8001102fe6e85">
|
---|
| 10 | <!ENTITY qt-size "14.3 MB">
|
---|
| 11 | <!ENTITY qt-buildsize "261 MB">
|
---|
| 12 | <!ENTITY qt-time "11 SBU (full), 7.5 SBU (sub-tools)">
|
---|
[feeb99a] | 13 | ]>
|
---|
| 14 |
|
---|
[46bca118] | 15 | <sect1 id="qt" xreflabel="Qt-&qt-version;">
|
---|
[f82c9c69] | 16 | <?dbhtml filename="qt.html" ?>
|
---|
| 17 |
|
---|
| 18 | <sect1info>
|
---|
| 19 | <othername>$LastChangedBy$</othername>
|
---|
| 20 | <date>$Date$</date>
|
---|
| 21 | </sect1info>
|
---|
| 22 |
|
---|
| 23 | <title>Qt-&qt-version;</title>
|
---|
| 24 |
|
---|
| 25 | <indexterm zone="qt">
|
---|
| 26 | <primary sortas="a-qt">Qt</primary>
|
---|
| 27 | </indexterm>
|
---|
| 28 |
|
---|
[4e82a189] | 29 | <sect2 role="package">
|
---|
[f82c9c69] | 30 | <title>Introduction to Qt</title>
|
---|
| 31 |
|
---|
| 32 | <para>The <application>Qt</application> package contains a
|
---|
| 33 | <application>C++</application> GUI library. This is useful for creating
|
---|
| 34 | graphical applications or executing graphical applications that are
|
---|
| 35 | dynamically linked to the <application>Qt</application> library. One of
|
---|
| 36 | the major users of <application>Qt</application> is
|
---|
| 37 | <application>KDE</application>.</para>
|
---|
| 38 |
|
---|
| 39 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 40 | <itemizedlist spacing="compact">
|
---|
| 41 | <listitem>
|
---|
| 42 | <para>Download (HTTP): <ulink url="&qt-download-http;"/></para>
|
---|
| 43 | </listitem>
|
---|
| 44 | <listitem>
|
---|
| 45 | <para>Download (FTP): <ulink url="&qt-download-ftp;"/></para>
|
---|
| 46 | </listitem>
|
---|
| 47 | <listitem>
|
---|
| 48 | <para>Download MD5 sum: &qt-md5sum;</para>
|
---|
| 49 | </listitem>
|
---|
| 50 | <listitem>
|
---|
| 51 | <para>Download size: &qt-size;</para>
|
---|
| 52 | </listitem>
|
---|
| 53 | <listitem>
|
---|
| 54 | <para>Estimated disk space required: &qt-buildsize;</para>
|
---|
| 55 | </listitem>
|
---|
| 56 | <listitem>
|
---|
| 57 | <para>Estimated build time: &qt-time;</para>
|
---|
| 58 | </listitem>
|
---|
| 59 | </itemizedlist>
|
---|
| 60 |
|
---|
[bf4f431] | 61 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
[b276c41] | 62 | <itemizedlist spacing="compact">
|
---|
| 63 | <listitem>
|
---|
| 64 | <para>Required patch: <ulink
|
---|
| 65 | url="http://www.trolltech.com/developer/download/Qt-3.3.8-UTF-8-fix.diff"/></para>
|
---|
| 66 | </listitem>
|
---|
| 67 | </itemizedlist>
|
---|
[751e96f] | 68 |
|
---|
[f82c9c69] | 69 | <bridgehead renderas="sect3">Qt Dependencies</bridgehead>
|
---|
| 70 |
|
---|
| 71 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
[e77976f] | 72 | <para role="required"><xref linkend="x-window-system"/></para>
|
---|
[f82c9c69] | 73 |
|
---|
| 74 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
[76a39aa] | 75 | <para role="recommended"><xref linkend="libjpeg"/> and
|
---|
| 76 | <xref linkend="libmng"/></para>
|
---|
[f82c9c69] | 77 |
|
---|
[751e96f] | 78 | <para>Note: if for whatever reason you do not have the recommended
|
---|
| 79 | libraries installed on your system, you must remove the corresponding
|
---|
[c5c2654] | 80 | <parameter>-system-<replaceable><library></replaceable></parameter> and
|
---|
| 81 | <parameter>-plugin-imgfmt-<replaceable><library></replaceable></parameter>
|
---|
[751e96f] | 82 | parameters from the <command>configure</command> commands shown in the
|
---|
| 83 | instructions below.</para>
|
---|
[d9c80e1] | 84 |
|
---|
[f82c9c69] | 85 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[76a39aa] | 86 | <para role="optional"><xref linkend="nas"/>,
|
---|
[76b19ad] | 87 | <xref linkend="cups"/>,
|
---|
| 88 | <xref linkend="mysql"/>,
|
---|
| 89 | <xref linkend="postgresql"/>,
|
---|
| 90 | <xref linkend="unixodbc"/>,
|
---|
| 91 | <ulink url="http://sqlite.org/">SQLite</ulink> and
|
---|
| 92 | <ulink url="http://firebird.sourceforge.net/">Firebird</ulink></para>
|
---|
[f82c9c69] | 93 |
|
---|
[58c6057] | 94 | <para condition="html" role="usernotes">User Notes:
|
---|
| 95 | <ulink url="&blfs-wiki;/qt"/></para>
|
---|
| 96 |
|
---|
[f82c9c69] | 97 | </sect2>
|
---|
| 98 |
|
---|
| 99 | <sect2 role="installation">
|
---|
| 100 | <title>Installation of Qt</title>
|
---|
| 101 |
|
---|
[ed87c5a] | 102 | <para>The <application>Qt</application> source hard codes the location
|
---|
[864b24de] | 103 | of the <application>X Window System</application> installtion to
|
---|
| 104 | <filename class="directory">/usr/X11R6</filename>. If you've installed
|
---|
[ed87c5a] | 105 | the <application>X Window System</application> in any prefix other than
|
---|
| 106 | <filename class="directory">/usr/X11R6</filename>, then you should correct
|
---|
| 107 | the <application>qmake</application> configuration files with the following
|
---|
[dc19fbff] | 108 | commands, replacing <replaceable><PREFIX></replaceable> with the
|
---|
| 109 | installation prefix of the
|
---|
| 110 | <application>X Window System</application>:</para>
|
---|
[ed87c5a] | 111 |
|
---|
| 112 | <screen><userinput>for file in $(grep -lr "X11R6" *)
|
---|
| 113 | do
|
---|
| 114 | sed -i "s@/usr/X11R6@<replaceable><PREFIX></replaceable>@g" $file
|
---|
| 115 | done</userinput></screen>
|
---|
| 116 |
|
---|
[f82c9c69] | 117 | <para>There are several ways to install a complicated package such as
|
---|
| 118 | <application>Qt</application>. The files are not completely position
|
---|
| 119 | independent. Installation procedures execute the program
|
---|
| 120 | <command>pkg-config</command> to determine the location of package
|
---|
| 121 | executables, libraries, headers, and other files. For
|
---|
| 122 | <application>Qt</application>, <command>pkg-config</command> will look
|
---|
| 123 | for the file <filename>lib/pkgconfig/qt-mt.pc</filename> which must be
|
---|
| 124 | modified if relocating the package. This file is set up correctly by
|
---|
| 125 | the build process.</para>
|
---|
| 126 |
|
---|
| 127 | <para>The default installation places the files in
|
---|
| 128 | <filename class='directory'>/usr/local/qt/</filename>. Many commercial
|
---|
| 129 | distributions place the files in the system's
|
---|
| 130 | <filename class='directory'>/usr</filename> hierarchy. The package can
|
---|
| 131 | also be installed in an arbitrary directory.</para>
|
---|
| 132 |
|
---|
| 133 | <para>This section will demonstrate two different methods.</para>
|
---|
| 134 |
|
---|
[4b48ee50] | 135 | <warning>
|
---|
| 136 | <para>Building <application>Qt</application> in a
|
---|
| 137 | <command>chroot</command> environment may fail.</para>
|
---|
| 138 | </warning>
|
---|
| 139 |
|
---|
[f82c9c69] | 140 | <note>
|
---|
| 141 | <para>The build time for <application>Qt</application> is quite long. If
|
---|
| 142 | you want to save some time and don't want the tutorials and examples,
|
---|
[751e96f] | 143 | change the first <command>make</command> command to:</para>
|
---|
[f82c9c69] | 144 |
|
---|
| 145 | <screen><userinput>make sub-tools</userinput></screen>
|
---|
| 146 |
|
---|
| 147 | </note>
|
---|
| 148 |
|
---|
| 149 | <sect3>
|
---|
| 150 | <title>Method 1 - Installing in the '/usr' Hierarchy</title>
|
---|
| 151 |
|
---|
| 152 | <para>The advantage of this method is that no updates to the
|
---|
| 153 | <filename>/etc/ld.so.conf</filename> or
|
---|
[58c6057] | 154 | <filename>/etc/man_db.conf</filename> files are required. The package
|
---|
[f82c9c69] | 155 | files are distributed within several subdirectories of the
|
---|
| 156 | <filename class='directory'>/usr</filename> hierarchy.
|
---|
| 157 | This is the method that most commercial distributions use.</para>
|
---|
| 158 |
|
---|
[033c86d] | 159 | <!--
|
---|
[f82c9c69] | 160 | <note>
|
---|
[884db0e3] | 161 | <para>The installation incorrectly uses <command>cp</command> to
|
---|
| 162 | install the files. This causes problems if the
|
---|
| 163 | <application>Qt</application> libraries are already in use (e.g.,
|
---|
| 164 | you are logged into your <application>KDE</application> desktop
|
---|
| 165 | environment). To avoid problems, <command>cp -f</command> is
|
---|
| 166 | replaced by <command>install</command> in
|
---|
| 167 | <filename>qmake.conf</filename>.</para>
|
---|
[f82c9c69] | 168 | </note>
|
---|
[033c86d] | 169 | -->
|
---|
[751e96f] | 170 |
|
---|
[033c86d] | 171 | <note>
|
---|
| 172 | <para>If <application>Qt</application> is being reinstalled, run the
|
---|
| 173 | following commands from a console or non-Qt based window manager.
|
---|
| 174 | It overwrites <application>Qt</application> libraries that should not
|
---|
| 175 | be in use during the install process.</para>
|
---|
| 176 | </note>
|
---|
[f82c9c69] | 177 |
|
---|
[b276c41] | 178 | <para>A <ulink
|
---|
| 179 | url='http://www.trolltech.com/company/newsroom/announcements/press.2007-03-30.9172215350'>security
|
---|
| 180 | vulnerability</ulink> has been identified in the
|
---|
| 181 | <application>Qt</application> package. Apply the patch to fix this
|
---|
| 182 | vulnerability with the following command:</para>
|
---|
| 183 |
|
---|
| 184 | <screen><userinput>patch -Np0 -i ../Qt-3.3.8-UTF-8-fix.diff</userinput></screen>
|
---|
| 185 |
|
---|
| 186 | <para>Continue with:</para>
|
---|
| 187 |
|
---|
[1afe6c26] | 188 | <screen><userinput>sed -i '/QMAKE_RPATH/d' mkspecs/linux*/qmake.conf &&
|
---|
[751e96f] | 189 |
|
---|
[972150e7] | 190 | bash
|
---|
| 191 | export PATH=$PWD/bin:$PATH &&
|
---|
[2dae8b3d] | 192 | export LD_LIBRARY_PATH=$PWD/lib:$LD_LIBRARY_PATH &&
|
---|
[751e96f] | 193 |
|
---|
| 194 | ./configure -prefix /usr \
|
---|
| 195 | -docdir /usr/share/doc/qt \
|
---|
| 196 | -headerdir /usr/include/qt \
|
---|
| 197 | -plugindir /usr/lib/qt/plugins \
|
---|
| 198 | -datadir /usr/share/qt \
|
---|
| 199 | -translationdir /usr/share/qt/translations \
|
---|
| 200 | -sysconfdir /etc/qt \
|
---|
| 201 | -qt-gif \
|
---|
| 202 | -system-zlib \
|
---|
| 203 | -system-libpng \
|
---|
| 204 | -system-libjpeg \
|
---|
| 205 | -system-libmng \
|
---|
| 206 | -plugin-imgfmt-png \
|
---|
| 207 | -plugin-imgfmt-jpeg \
|
---|
| 208 | -plugin-imgfmt-mng \
|
---|
| 209 | -no-exceptions \
|
---|
| 210 | -thread \
|
---|
| 211 | -tablet &&
|
---|
| 212 |
|
---|
[c52af0c] | 213 | make &&
|
---|
| 214 | exit</userinput></screen>
|
---|
[14db7cc] | 215 |
|
---|
[751e96f] | 216 | <para>This package does not come with a test suite.</para>
|
---|
| 217 |
|
---|
[f82c9c69] | 218 | <para>Now, as the <systemitem class="username">root</systemitem>
|
---|
| 219 | user:</para>
|
---|
[14db7cc] | 220 |
|
---|
[f82c9c69] | 221 | <screen role="root"><userinput>make install &&
|
---|
| 222 | ln -v -sf libqt-mt.so /usr/lib/libqt.so &&
|
---|
[1afe6c26] | 223 | ln -v -snf ../../bin /usr/share/qt/bin &&
|
---|
| 224 | ln -v -snf ../../include/qt /usr/share/qt/include &&
|
---|
| 225 | ln -v -snf ../../lib /usr/share/qt/lib &&
|
---|
[f82c9c69] | 226 | cp -v -r doc/man /usr/share &&
|
---|
| 227 | cp -v -r examples /usr/share/doc/qt</userinput></screen>
|
---|
[14db7cc] | 228 |
|
---|
[f82c9c69] | 229 | </sect3>
|
---|
[972150e7] | 230 |
|
---|
[f82c9c69] | 231 | <sect3>
|
---|
| 232 | <title>Method 2 - Installing in '/opt'</title>
|
---|
[972150e7] | 233 |
|
---|
[f82c9c69] | 234 | <para>This is the method recommended by the <application>Qt</application>
|
---|
| 235 | developers. It has the advantage of keeping all the package files
|
---|
| 236 | consolidated in a dedicated directory hierarchy. By using this method,
|
---|
| 237 | an update can be made without overwriting a previous installation and
|
---|
[884db0e3] | 238 | users can easily revert to a previous version by changing one symbolic
|
---|
| 239 | link.</para>
|
---|
[972150e7] | 240 |
|
---|
[f82c9c69] | 241 | <para>The <application>Qt</application> developers use a default location
|
---|
| 242 | of <filename class='directory'>/usr/local/qt/</filename>, however this
|
---|
| 243 | procedure puts the files in <filename
|
---|
| 244 | class='directory'>/opt/qt-&qt-version;/</filename>
|
---|
| 245 | and then creates a symbolic link to <filename>/opt/qt/</filename>.</para>
|
---|
| 246 |
|
---|
[b276c41] | 247 | <para>A <ulink
|
---|
| 248 | url='http://www.trolltech.com/company/newsroom/announcements/press.2007-03-30.9172215350'>security
|
---|
| 249 | vulnerability</ulink> has been identified in the
|
---|
| 250 | <application>Qt</application> package. Apply the patch to fix this
|
---|
| 251 | vulnerability with the following command:</para>
|
---|
| 252 |
|
---|
| 253 | <screen><userinput>patch -Np0 -i ../Qt-3.3.8-UTF-8-fix.diff</userinput></screen>
|
---|
| 254 |
|
---|
| 255 | <para>Continue with:</para>
|
---|
| 256 |
|
---|
[f82c9c69] | 257 | <screen><userinput>bash
|
---|
[972150e7] | 258 | export QTDIR=$PWD &&
|
---|
[2dae8b3d] | 259 | export LD_LIBRARY_PATH=$PWD/lib:$LD_LIBRARY_PATH &&
|
---|
[972150e7] | 260 | export PATH=$PWD/bin:$PATH &&
|
---|
[751e96f] | 261 |
|
---|
| 262 | ./configure -prefix /opt/qt-&qt-version; \
|
---|
| 263 | -sysconfdir /etc/qt \
|
---|
| 264 | -qt-gif \
|
---|
| 265 | -system-zlib \
|
---|
| 266 | -system-libpng \
|
---|
| 267 | -system-libjpeg \
|
---|
| 268 | -system-libmng \
|
---|
| 269 | -plugin-imgfmt-png \
|
---|
| 270 | -plugin-imgfmt-jpeg \
|
---|
| 271 | -plugin-imgfmt-mng \
|
---|
| 272 | -no-exceptions \
|
---|
| 273 | -thread \
|
---|
| 274 | -tablet &&
|
---|
| 275 |
|
---|
[033c86d] | 276 | make &&
|
---|
| 277 | exit</userinput></screen>
|
---|
[f82c9c69] | 278 |
|
---|
[751e96f] | 279 | <para>This package does not come with a test suite.</para>
|
---|
| 280 |
|
---|
[f82c9c69] | 281 | <para>Now, as the <systemitem class="username">root</systemitem>
|
---|
| 282 | user:</para>
|
---|
| 283 |
|
---|
| 284 | <screen role="root"><userinput>make install &&
|
---|
| 285 | ln -v -sfn qt-&qt-version; /opt/qt &&
|
---|
| 286 | ln -v -s libqt-mt.so /opt/qt/lib/libqt.so &&
|
---|
[d8e2f89b] | 287 | cp -v -r doc/man examples /opt/qt/doc</userinput></screen>
|
---|
[f82c9c69] | 288 |
|
---|
| 289 | </sect3>
|
---|
[972150e7] | 290 |
|
---|
[f82c9c69] | 291 | </sect2>
|
---|
[78d0e3c] | 292 |
|
---|
[f82c9c69] | 293 | <sect2 role="commands">
|
---|
| 294 | <title>Command Explanations</title>
|
---|
[972150e7] | 295 |
|
---|
[1afe6c26] | 296 | <para><command>sed -i '/QMAKE_RPATH/d' mkspecs/linux*/qmake.conf</command>:
|
---|
| 297 | In Method 1, <application>Qt</application> is being installed into
|
---|
| 298 | the standard system directories. The runtime library search path does not
|
---|
| 299 | need to be set in this case.</para>
|
---|
[972150e7] | 300 |
|
---|
[f82c9c69] | 301 | <para><command>bash</command>: This command enters a sub-shell to isolate
|
---|
| 302 | environment changes.</para>
|
---|
[972150e7] | 303 |
|
---|
[f82c9c69] | 304 | <para><command>export QTDIR=$PWD</command>: This command defines where
|
---|
| 305 | the root of the <application>Qt</application> directory is located.</para>
|
---|
[972150e7] | 306 |
|
---|
[f82c9c69] | 307 | <para><command>export LD_LIBRARY_PATH=$PWD/lib:$LD_LIBRARY_PATH</command>:
|
---|
| 308 | This command allows the not yet installed <application>Qt</application>
|
---|
| 309 | libraries to be used by the not yet installed <application>Qt</application>
|
---|
| 310 | programs.</para>
|
---|
[972150e7] | 311 |
|
---|
[f82c9c69] | 312 | <para><command>export PATH=$PWD/bin:$PATH</command>: This command
|
---|
| 313 | allows the build process to find supporting executables.</para>
|
---|
[972150e7] | 314 |
|
---|
[f82c9c69] | 315 | <para><parameter>-qt-gif</parameter>: This switch adds support for
|
---|
| 316 | <filename>gif</filename> files to the libraries.</para>
|
---|
[972150e7] | 317 |
|
---|
[751e96f] | 318 | <para><parameter>-system-zlib -system-libpng -system-libjpeg
|
---|
| 319 | -system-mng</parameter>: These switches force the build instructions to use
|
---|
| 320 | the shared libraries that are on your system instead of creating a custom
|
---|
| 321 | set of support libraries for these functions.</para>
|
---|
[972150e7] | 322 |
|
---|
[751e96f] | 323 | <para><parameter>-plugin-imgfmt-png -plugin-imgfmt-jpeg
|
---|
| 324 | -plugin-imgfmt-mng</parameter>: These switches enable run-time linking of
|
---|
| 325 | the referenced libraries.</para>
|
---|
[972150e7] | 326 |
|
---|
[b276c41] | 327 | <para>If you pass the
|
---|
| 328 | <option>-plugin-sql-<replaceable><driver></replaceable></option> or
|
---|
| 329 | <option>-qt-sql-<replaceable><driver></replaceable></option> switch
|
---|
| 330 | to the <command>configure</command> command, you must also pass
|
---|
| 331 | <option>-I<replaceable></path/to/sql/headers></replaceable></option>
|
---|
| 332 | so <command>make</command> can find the appropriate header files. For
|
---|
| 333 | instance, building in <application>MySQL</application> support (as opposed
|
---|
| 334 | to building the plugin) will need to use <option>-I/usr/include/mysql
|
---|
| 335 | -qt-sql-mysql</option>.</para>
|
---|
[cc25f73] | 336 |
|
---|
[b276c41] | 337 | <note>
|
---|
[cc25f73] | 338 | <para>To check if <application>mysql</application> is autotetected
|
---|
| 339 | properly, examine the output of <command>./configure -I/usr/include/mysql
|
---|
| 340 | -help</command>. Other database support will require similar
|
---|
| 341 | <command>configure</command> parameters.</para>
|
---|
| 342 | </note>
|
---|
| 343 |
|
---|
[f82c9c69] | 344 | <para><parameter>-no-exceptions</parameter>: This switch disables
|
---|
| 345 | the exceptions coding generated by the <application>C++</application>
|
---|
| 346 | compiler.</para>
|
---|
[fac11e8] | 347 |
|
---|
[f82c9c69] | 348 | <para><parameter>-thread</parameter>: This switch adds
|
---|
| 349 | support for multi-threading.</para>
|
---|
[972150e7] | 350 |
|
---|
[1afe6c26] | 351 | <para><command>ln -v -sf libqt-mt.so /usr/lib/libqt.so</command>: This
|
---|
[f82c9c69] | 352 | command allows <command>configure</command> scripts to find a working
|
---|
| 353 | <application>Qt</application> installation.</para>
|
---|
[972150e7] | 354 |
|
---|
[1afe6c26] | 355 | <para><command>ln -v -snf ../../bin /usr/share/qt/bin</command>: This
|
---|
| 356 | command and the following two allow the
|
---|
| 357 | <filename class="directory">/usr</filename> style installation to mimic
|
---|
| 358 | the <filename class="directory">/opt</filename> style installation by
|
---|
| 359 | making all binaries, headers and libraries available from a single
|
---|
| 360 | directory, <filename class="directory">/usr/share/qt</filename>.</para>
|
---|
| 361 |
|
---|
[d8e2f89b] | 362 | <para><command>cp -v -r doc/man examples /usr/share (or
|
---|
| 363 | /opt/qt/doc)</command>:
|
---|
| 364 | This command installs the man pages and examples which are missed by
|
---|
[f82c9c69] | 365 | <command>make install</command>.</para>
|
---|
[972150e7] | 366 |
|
---|
[f82c9c69] | 367 | <para><command>exit</command>: This command returns to the parent shell
|
---|
[d8e2f89b] | 368 | and eliminates the environment variables set earlier.</para>
|
---|
[972150e7] | 369 |
|
---|
[f82c9c69] | 370 | </sect2>
|
---|
[972150e7] | 371 |
|
---|
[f82c9c69] | 372 | <sect2 role="configuration">
|
---|
| 373 | <title>Configuring Qt</title>
|
---|
[78d0e3c] | 374 |
|
---|
[f82c9c69] | 375 | <sect3 id='qt-config'>
|
---|
| 376 | <title>Configuration Information</title>
|
---|
[972150e7] | 377 |
|
---|
[f82c9c69] | 378 | <para>The <envar>QTDIR</envar> environment variable needs to be set when
|
---|
| 379 | building packages that depend on <application>Qt</application>. Add the
|
---|
| 380 | following to the <filename>.bash_profile</filename> initialization script
|
---|
| 381 | for each user that builds packages using the <application>Qt</application>
|
---|
| 382 | libraries. Alternatively, the variable can be set in the system wide
|
---|
| 383 | <filename>/etc/profile</filename> file.</para>
|
---|
[14db7cc] | 384 |
|
---|
[c52af0c] | 385 | <para>For Method 1 (This is optional, only set this if an application is
|
---|
[1afe6c26] | 386 | unable to find the installed libraries or headers):</para>
|
---|
[14db7cc] | 387 |
|
---|
[1afe6c26] | 388 | <screen><literal>export QTDIR=/usr/share/qt</literal></screen>
|
---|
[14db7cc] | 389 |
|
---|
[f82c9c69] | 390 | <para>or for Method 2:</para>
|
---|
[14db7cc] | 391 |
|
---|
[f82c9c69] | 392 | <screen><literal>export QTDIR=/opt/qt</literal></screen>
|
---|
[78d0e3c] | 393 |
|
---|
[f82c9c69] | 394 | <para>If you installed <application>Qt</application> using Method 2,
|
---|
| 395 | you also need to update the following configuration files so that
|
---|
| 396 | <application>Qt</application> is correctly found by other packages
|
---|
| 397 | and system processes.</para>
|
---|
[78d0e3c] | 398 |
|
---|
[f82c9c69] | 399 | <para>Update the <filename>/etc/ld.so.conf</filename> and
|
---|
[58c6057] | 400 | <filename>/etc/man_db.conf</filename> files:</para>
|
---|
[f82c9c69] | 401 |
|
---|
| 402 | <screen role="root"><userinput>cat >> /etc/ld.so.conf << "EOF" &&
|
---|
| 403 | <literal># Begin qt addition to /etc/ld.so.conf
|
---|
[78d0e3c] | 404 |
|
---|
| 405 | /opt/qt/lib
|
---|
| 406 |
|
---|
[f82c9c69] | 407 | # End qt addition</literal>
|
---|
[78d0e3c] | 408 | EOF
|
---|
[f82c9c69] | 409 | ldconfig &&
|
---|
[58c6057] | 410 | cat >> /etc/man_db.conf << "EOF"
|
---|
| 411 | <literal># Begin qt addition to man_db.conf
|
---|
[78d0e3c] | 412 |
|
---|
[c5c2654] | 413 | MANDATORY_MANPATH /opt/qt/doc/man
|
---|
[78d0e3c] | 414 |
|
---|
[58c6057] | 415 | # End qt addition to man_db.conf</literal>
|
---|
[f82c9c69] | 416 | EOF</userinput></screen>
|
---|
| 417 |
|
---|
| 418 | <indexterm zone="qt qt-config">
|
---|
| 419 | <primary sortas="e-etc-ld.so.conf">/etc/ld.so.conf</primary>
|
---|
| 420 | </indexterm>
|
---|
| 421 |
|
---|
| 422 | <indexterm zone="qt qt-config">
|
---|
[58c6057] | 423 | <primary sortas="e-etc-man_db.conf">/etc/man_db.conf</primary>
|
---|
[f82c9c69] | 424 | </indexterm>
|
---|
| 425 |
|
---|
| 426 | <indexterm zone="qt qt-config">
|
---|
| 427 | <primary sortas="e-etc-profile">/etc/profile</primary>
|
---|
| 428 | </indexterm>
|
---|
| 429 |
|
---|
| 430 | <indexterm zone="qt qt-config">
|
---|
| 431 | <primary sortas="e-AA.bash_profile">~/.bash_profile</primary>
|
---|
| 432 | </indexterm>
|
---|
| 433 |
|
---|
| 434 | <para>Update the <envar>PKG_CONFIG_PATH</envar> environment variable
|
---|
| 435 | in your <filename>~/.bash_profile</filename> or
|
---|
| 436 | <filename>/etc/profile</filename> with the following:</para>
|
---|
| 437 |
|
---|
| 438 | <screen><literal>PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/opt/qt/lib/pkgconfig</literal></screen>
|
---|
| 439 |
|
---|
| 440 | <para>If you want the <application>Qt</application> executables in your
|
---|
| 441 | shell search path, update the <envar>PATH</envar> environment variable
|
---|
| 442 | in your <filename>~/.bash_profile</filename> or
|
---|
| 443 | <filename>/etc/profile</filename> to include
|
---|
| 444 | <filename class='directory'>/opt/qt/bin</filename>.</para>
|
---|
| 445 |
|
---|
| 446 | <para>As with most libraries, there is no explicit configuration to do.
|
---|
| 447 | After updating <filename>/etc/ld.so.conf</filename> as explained above,
|
---|
| 448 | run <command>/sbin/ldconfig</command> so that <command>ldd</command>
|
---|
| 449 | can find the shared libraries.</para>
|
---|
| 450 |
|
---|
| 451 | </sect3>
|
---|
| 452 |
|
---|
| 453 | </sect2>
|
---|
| 454 |
|
---|
| 455 | <sect2 role="content">
|
---|
| 456 | <title>Contents</title>
|
---|
| 457 |
|
---|
| 458 | <segmentedlist>
|
---|
| 459 | <segtitle>Installed Programs</segtitle>
|
---|
| 460 | <segtitle>Installed Libraries</segtitle>
|
---|
| 461 | <segtitle>Installed Directories</segtitle>
|
---|
| 462 |
|
---|
| 463 | <seglistitem>
|
---|
| 464 | <seg>assistant, designer, linguist, lrelease, lupdate, moc,
|
---|
| 465 | qm2ts, qmake, qtconfig, and uic</seg>
|
---|
| 466 | <seg>libqt-mt.so, libqt.so libqui.so, libdesignercore.a,
|
---|
| 467 | libeditor.a, and libqassistantclient.a</seg>
|
---|
| 468 | <seg>/opt/qt-&qt-version; or /usr/lib/qt, /usr/share/qt,
|
---|
| 469 | /usr/share/doc/qt, /usr/include/qt, and /etc/qt</seg>
|
---|
| 470 | </seglistitem>
|
---|
| 471 | </segmentedlist>
|
---|
| 472 |
|
---|
| 473 | <variablelist>
|
---|
| 474 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 475 | <?dbfo list-presentation="list"?>
|
---|
| 476 | <?dbhtml list-presentation="table"?>
|
---|
| 477 |
|
---|
| 478 | <varlistentry id="assistant">
|
---|
| 479 | <term><command>assistant</command></term>
|
---|
| 480 | <listitem>
|
---|
| 481 | <para>is a tool for presenting on-line documentation.</para>
|
---|
| 482 | <indexterm zone="qt assistant">
|
---|
| 483 | <primary sortas="b-assistant">assistant</primary>
|
---|
| 484 | </indexterm>
|
---|
| 485 | </listitem>
|
---|
| 486 | </varlistentry>
|
---|
| 487 |
|
---|
| 488 | <varlistentry id="designer">
|
---|
| 489 | <term><command>designer</command></term>
|
---|
| 490 | <listitem>
|
---|
| 491 | <para>is a full-fledged GUI builder. It includes
|
---|
| 492 | powerful features such as preview mode, automatic widget
|
---|
| 493 | layout, support for custom widgets, and an advanced
|
---|
| 494 | property editor.</para>
|
---|
| 495 | <indexterm zone="qt designer">
|
---|
| 496 | <primary sortas="b-designer">designer</primary>
|
---|
| 497 | </indexterm>
|
---|
| 498 | </listitem>
|
---|
| 499 | </varlistentry>
|
---|
| 500 |
|
---|
| 501 | <varlistentry id="linguist">
|
---|
| 502 | <term><command>linguist</command></term>
|
---|
| 503 | <listitem>
|
---|
| 504 | <para>provides support for translating applications into
|
---|
| 505 | local languages. </para>
|
---|
| 506 | <indexterm zone="qt linguist">
|
---|
| 507 | <primary sortas="b-linguist">linguist</primary>
|
---|
| 508 | </indexterm>
|
---|
| 509 | </listitem>
|
---|
| 510 | </varlistentry>
|
---|
| 511 |
|
---|
| 512 | <varlistentry id="lrelease">
|
---|
| 513 | <term><command>lrelease</command></term>
|
---|
| 514 | <listitem>
|
---|
| 515 | <para>is a simple command line tool. It reads a Qt project
|
---|
| 516 | file and produces message files used by the application.</para>
|
---|
| 517 | <indexterm zone="qt lrelease">
|
---|
| 518 | <primary sortas="b-lrelease">lrelease</primary>
|
---|
| 519 | </indexterm>
|
---|
| 520 | </listitem>
|
---|
| 521 | </varlistentry>
|
---|
| 522 |
|
---|
| 523 | <varlistentry id="lupdate">
|
---|
| 524 | <term><command>lupdate</command></term>
|
---|
| 525 | <listitem>
|
---|
| 526 | <para>reads a Qt project file, finds the translatable
|
---|
| 527 | strings in the specified source, header and Qt Designer
|
---|
| 528 | interface files, and produces or updates the translation
|
---|
| 529 | files listed in the project file.</para>
|
---|
| 530 | <indexterm zone="qt lupdate">
|
---|
| 531 | <primary sortas="b-lupdate">lupdate</primary>
|
---|
| 532 | </indexterm>
|
---|
| 533 | </listitem>
|
---|
| 534 | </varlistentry>
|
---|
| 535 |
|
---|
| 536 | <varlistentry id="moc">
|
---|
| 537 | <term><command>moc</command></term>
|
---|
| 538 | <listitem>
|
---|
| 539 | <para>generates Qt meta object support code.</para>
|
---|
| 540 | <indexterm zone="qt moc">
|
---|
| 541 | <primary sortas="b-moc">moc</primary>
|
---|
| 542 | </indexterm>
|
---|
| 543 | </listitem>
|
---|
| 544 | </varlistentry>
|
---|
| 545 |
|
---|
| 546 | <varlistentry id="qm2ts">
|
---|
| 547 | <term><command>qm2ts</command></term>
|
---|
| 548 | <listitem>
|
---|
| 549 | <para>is a tool for converting Qt message file formats.</para>
|
---|
| 550 | <indexterm zone="qt qm2ts">
|
---|
| 551 | <primary sortas="b-qm2ts">qm2ts</primary>
|
---|
| 552 | </indexterm>
|
---|
| 553 | </listitem>
|
---|
| 554 | </varlistentry>
|
---|
| 555 |
|
---|
| 556 | <varlistentry id="qmake">
|
---|
| 557 | <term><command>qmake</command></term>
|
---|
| 558 | <listitem>
|
---|
| 559 | <para>qmake uses information stored in project files to
|
---|
| 560 | determine what should go in the makefiles it generates.</para>
|
---|
| 561 | <indexterm zone="qt qmake">
|
---|
| 562 | <primary sortas="b-qmake">qmake</primary>
|
---|
| 563 | </indexterm>
|
---|
| 564 | </listitem>
|
---|
| 565 | </varlistentry>
|
---|
| 566 |
|
---|
| 567 | <varlistentry id="qtconfig">
|
---|
| 568 | <term><command>qtconfig</command></term>
|
---|
| 569 | <listitem>
|
---|
| 570 | <para>is used to customize the appearance of Qt applications.</para>
|
---|
| 571 | <indexterm zone="qt qtconfig">
|
---|
| 572 | <primary sortas="b-qtconfig">qtconfig</primary>
|
---|
| 573 | </indexterm>
|
---|
| 574 | </listitem>
|
---|
| 575 | </varlistentry>
|
---|
| 576 |
|
---|
| 577 | <varlistentry id="uic">
|
---|
| 578 | <term><command>uic</command></term>
|
---|
| 579 | <listitem>
|
---|
| 580 | <para>is a Qt user interface compiler.</para>
|
---|
| 581 | <indexterm zone="qt uic">
|
---|
| 582 | <primary sortas="b-uic">uic</primary>
|
---|
| 583 | </indexterm>
|
---|
| 584 | </listitem>
|
---|
| 585 | </varlistentry>
|
---|
| 586 |
|
---|
| 587 | </variablelist>
|
---|
| 588 |
|
---|
| 589 | </sect2>
|
---|
| 590 |
|
---|
[972150e7] | 591 | </sect1>
|
---|