mirror of
https://github.com/Zeckmathederg/glfs.git
synced 2025-01-27 09:42:12 +08:00
3ddb430311
git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@10668 af4574ff-66df-0310-9fd7-8a98e5e911e0
481 lines
17 KiB
XML
481 lines
17 KiB
XML
<?xml version="1.0" encoding="ISO-8859-1"?>
|
|
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
|
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
|
<!ENTITY % general-entities SYSTEM "../../general.ent">
|
|
%general-entities;
|
|
|
|
<!ENTITY qt-download-http "http://releases.qt-project.org/qt4/source/qt-everywhere-opensource-src-&qt-version;.tar.gz">
|
|
<!ENTITY qt-download-ftp " ">
|
|
<!ENTITY qt-md5sum "a663b6c875f8d7caa8ac9c30e4a4ec3b">
|
|
<!ENTITY qt-size "234 MB">
|
|
<!ENTITY qt-buildsize "1.8 GB (full), 619 (essential)">
|
|
<!ENTITY qt-time "69 SBU (full), 54 SBU (essential)">
|
|
]>
|
|
|
|
<sect1 id="qt" xreflabel="Qt-&qt-version;">
|
|
<?dbhtml filename="qt.html" ?>
|
|
|
|
<sect1info>
|
|
<othername>$LastChangedBy$</othername>
|
|
<date>$Date$</date>
|
|
</sect1info>
|
|
|
|
<title>Qt-&qt-version;</title>
|
|
|
|
<indexterm zone="qt">
|
|
<primary sortas="a-qt">Qt</primary>
|
|
</indexterm>
|
|
|
|
<sect2 role="package">
|
|
<title>Introduction to Qt</title>
|
|
|
|
<para><application>Qt</application> is a cross-platform application
|
|
framework that is widely used for developing application software
|
|
with a graphical user interface (GUI) (in which cases Qt is classified
|
|
as a widget toolkit), and also used for developing non-GUI programs such
|
|
as command-line tools and consoles for servers. One of the major users
|
|
of <application>Qt</application> is <application>KDE</application>.</para>
|
|
|
|
&lfs72_checked;
|
|
|
|
<bridgehead renderas="sect3">Package Information</bridgehead>
|
|
<itemizedlist spacing="compact">
|
|
<listitem>
|
|
<para>Download (HTTP): <ulink url="&qt-download-http;"/></para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>Download (FTP): <ulink url="&qt-download-ftp;"/></para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>Download MD5 sum: &qt-md5sum;</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>Download size: &qt-size;</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>Estimated disk space required: &qt-buildsize;</para>
|
|
</listitem>
|
|
<listitem>
|
|
<para>Estimated build time: &qt-time;</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
|
|
<!--
|
|
<bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
|
<itemizedlist spacing="compact">
|
|
<listitem>
|
|
<para>GLib 2.32 patch: <ulink
|
|
url="&patch-root;/qt-everywhere-opensource-src-&qt-version;-glib_fix-1.patch"/>
|
|
</para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
-->
|
|
|
|
<bridgehead renderas="sect3">Qt Dependencies</bridgehead>
|
|
|
|
<bridgehead renderas="sect4">Required</bridgehead>
|
|
<para role="required"><xref linkend="x-window-system"/></para>
|
|
|
|
<bridgehead renderas="sect4">Recommended</bridgehead>
|
|
<para role="recommended">
|
|
<xref linkend="dbus"/>,
|
|
<xref linkend="libjpeg"/>,
|
|
<xref linkend="libmng"/>,
|
|
<xref linkend="libtiff"/>,
|
|
<xref linkend="libpng"/> and
|
|
<xref linkend="pkgconfig"/> (needed to use D-Bus, GLib, GTK and PulseAudio)
|
|
</para>
|
|
|
|
<bridgehead renderas="sect4">Optional</bridgehead>
|
|
<para role="optional">
|
|
<!--<xref linkend="nas"/>,-->
|
|
<xref linkend="gst-plugins-base"/>,
|
|
<xref linkend='pulseaudio'/>,
|
|
<xref linkend='glib2'/>,
|
|
<xref linkend="gtk2"/>,
|
|
<xref linkend="openssl"/>,
|
|
<xref linkend="cups"/>,
|
|
<xref linkend="mysql"/>,
|
|
<xref linkend="postgresql"/>,
|
|
<xref linkend="unixodbc"/> and
|
|
<xref linkend="sqlite"/>
|
|
</para>
|
|
|
|
<para condition="html" role="usernotes">User Notes:
|
|
<ulink url="&blfs-wiki;/qt"/></para>
|
|
|
|
</sect2>
|
|
|
|
<sect2 role="installation">
|
|
<title>Installation of Qt</title>
|
|
|
|
<para>There are several ways to install a complicated package such as
|
|
<application>Qt</application>. The files are not completely position
|
|
independent. Installation procedures execute the program
|
|
<command>pkg-config</command> to determine the location of package
|
|
executables, libraries, headers, and other files. For
|
|
<application>Qt</application>, <command>pkg-config</command> will look
|
|
for the appropriate <filename>lib/pkgconfig/Qt*.pc</filename> files which
|
|
must be modified if relocating the package. These files are set up correctly
|
|
by the build process.</para>
|
|
|
|
<para>The default installation places the files in
|
|
<filename class='directory'>/usr/local/qt/</filename>. Many commercial
|
|
distributions place the files in the system's
|
|
<filename class='directory'>/usr</filename> hierarchy. The package can
|
|
also be installed in an arbitrary directory.</para>
|
|
|
|
<para>The advantage of installing in
|
|
<filename class='directory'>/usr</filename> is that no updates to the
|
|
<filename>/etc/ld.so.conf</filename> or
|
|
<filename>/etc/man_db.conf</filename> files are required. The package
|
|
files are distributed within several subdirectories of the
|
|
<filename class='directory'>/usr</filename> hierarchy.
|
|
This is the method that most commercial distributions use.</para>
|
|
|
|
<caution>
|
|
<para>If <application>Qt</application> is being reinstalled and the
|
|
<filename class='directory'>/usr</filename>
|
|
directory is used as the prefix, run the following commands from a
|
|
console or non-Qt based window manager. It overwrites
|
|
<application>Qt</application> libraries that should not be in use during
|
|
the install process.</para>
|
|
</caution>
|
|
|
|
<note>
|
|
<para>The build time and space required for the full
|
|
<application>Qt</application> is quite long. The instructions below do
|
|
not build the tutorials and examples. Removing the
|
|
<parameter>-nomake</parameter> lines will create a complete build.</para>
|
|
</note>
|
|
|
|
<para>The method recommended by the <application>Qt</application>
|
|
developers does not use the /usr directory prefix. It has the advantage of
|
|
keeping all the package files consolidated in a dedicated directory
|
|
hierarchy. By using this method, an update can be made without overwriting
|
|
a previous installation and users can easily revert to a previous version
|
|
by changing one symbolic link.</para>
|
|
|
|
<para>The <application>Qt</application> developers use a default location
|
|
of <filename class='directory'>/usr/local/qt/</filename>, however the
|
|
procedure below puts the files in <filename
|
|
class='directory'>/opt/qt-&qt-version;/</filename>
|
|
and then creates a symbolic link to <filename>/opt/qt/</filename>.</para>
|
|
|
|
<para>Configure <application>Qt</application> by running the
|
|
following commands:</para>
|
|
|
|
<screen><userinput>./configure -prefix /opt/qt-&qt-version; \
|
|
-release \
|
|
-nomake examples \
|
|
-nomake demos \
|
|
-system-sqlite \
|
|
-no-nis \
|
|
-opensource \
|
|
-confirm-license &&
|
|
make</userinput></screen>
|
|
|
|
<note><title>Phonon</title>
|
|
<para>If <application>KDE</application> is intended to be installed, add
|
|
<option>-no-phonon</option> to the <command>./configure</command> command
|
|
above. While installing <application>KDE</application>, a separate version of the
|
|
<application>Phonon</application> libraries will be installed which better
|
|
matches the needs of the <application>KDE</application> desktop.</para></note>
|
|
|
|
<para>This package does not come with a test suite.</para>
|
|
|
|
<para>Now, as the <systemitem class="username">root</systemitem>
|
|
user:</para>
|
|
|
|
<screen role="root"><userinput>make install</userinput></screen>
|
|
|
|
<para>If you installed <application>Qt</application> in the /opt directory,
|
|
again as the <systemitem class="username">root</systemitem> user issue:</para>
|
|
|
|
<screen role="root"><userinput>ln -svfn qt-&qt-version; /opt/qt</userinput></screen>
|
|
|
|
</sect2>
|
|
|
|
<sect2 role="commands">
|
|
<title>Command Explanations</title>
|
|
|
|
<para><parameter>-release</parameter>:
|
|
This switch disables building with debugging symbols.</para>
|
|
|
|
<para><parameter>-nomake examples, -nomake demos</parameter>:
|
|
These switches disable building programs that are only of interest
|
|
to a <application>Qt</application> developer.</para>
|
|
|
|
<para><parameter>-system-sqlite</parameter>:
|
|
Use the system version of <application>SQLite</application>.</para>
|
|
|
|
<para><parameter>-no-nis</parameter>:
|
|
Disable support for Network Information Service (NIS).</para>
|
|
|
|
<para><parameter>-opensource</parameter>:
|
|
Install the opensource version of <application>Qt</application>.</para>
|
|
|
|
<para><parameter>-confirm-license</parameter>:
|
|
Accept license without prompting user during configuration.</para>
|
|
|
|
<para><parameter>-plugin-sql-<replaceable><driver></replaceable></parameter>
|
|
or <parameter>-qt-sql-<replaceable><driver></replaceable></parameter>:
|
|
These switches build SQL support into the <application>Qt</application>
|
|
libraries.</para>
|
|
|
|
<note>
|
|
<para>To check if <application>mysql</application> is autodetected
|
|
properly, examine the output of <command>./configure -qt-sql-mysql
|
|
-help</command>. Other database support will require similar
|
|
<command>configure</command> parameters.</para>
|
|
</note>
|
|
|
|
<para>There are several optional directories that can be specified in the
|
|
<command>./configure</command> line. These include
|
|
<option>-bindir</option>, <option>-libdir</option>,
|
|
<option>-docdir</option>, and <option>-headerdir</option>. For a complete
|
|
list, run <command>./configure -help</command>.</para>
|
|
|
|
</sect2>
|
|
|
|
<sect2 role="configuration">
|
|
<title>Configuring Qt</title>
|
|
|
|
<sect3 id='qt-config'>
|
|
<title>Configuration Information</title>
|
|
|
|
<para>If you installed <application>Qt</application> in /usr, create an
|
|
environment variable needed by certain packages. As the
|
|
<systemitem class="username">root</systemitem> user:</para>
|
|
|
|
<screen role="root"><userinput>cat > /etc/profile.d/qt.sh << EOF
|
|
<literal># Begin /etc/profile.d/qt.sh
|
|
|
|
QTDIR=/usr
|
|
|
|
export QTDIR
|
|
|
|
# End /etc/profile.d/qt.sh</literal>
|
|
EOF</userinput></screen>
|
|
|
|
<para>If you installed <application>Qt</application> in a location other
|
|
than /usr, you need to update the following configuration files so
|
|
that <application>Qt</application> is correctly found by other packages
|
|
and system processes.</para>
|
|
|
|
<para>As the <systemitem class="username">root</systemitem> user, update
|
|
the <filename>/etc/ld.so.conf</filename> file and the dynamic linker's
|
|
run-time cache file:</para>
|
|
|
|
<screen role="root"><userinput>cat >> /etc/ld.so.conf << EOF
|
|
<literal># Begin Qt addition
|
|
|
|
/opt/qt/lib
|
|
|
|
# End Qt addition</literal>
|
|
EOF
|
|
ldconfig</userinput></screen>
|
|
|
|
<indexterm zone="qt qt-config">
|
|
<primary sortas="e-etc-ld.so.conf">/etc/ld.so.conf</primary>
|
|
</indexterm>
|
|
|
|
<para>As the <systemitem class="username">root</systemitem> user, create
|
|
the <filename>/etc/profile.d/qt.sh</filename> file:</para>
|
|
|
|
<screen role="root"><userinput>cat > /etc/profile.d/qt.sh << EOF
|
|
<literal># Begin /etc/profile.d/qt.sh
|
|
|
|
QTDIR=/opt/qt
|
|
|
|
pathappend /opt/qt/bin PATH
|
|
pathappend /opt/qt/lib/pkgconfig PKG_CONFIG_PATH
|
|
|
|
export QTDIR
|
|
|
|
# End /etc/profile.d/qt.sh</literal>
|
|
EOF</userinput></screen>
|
|
|
|
</sect3>
|
|
</sect2>
|
|
|
|
<sect2 role="content">
|
|
<title>Contents</title>
|
|
|
|
<segmentedlist>
|
|
<segtitle>Installed Programs</segtitle>
|
|
<segtitle>Installed Libraries</segtitle>
|
|
<segtitle>Installed Directories</segtitle>
|
|
|
|
<seglistitem>
|
|
<seg>assistant, designer, lconvert, linguist, lrelease, lupdate, moc,
|
|
pixeltool, qcollectiongenerator, qdbus, qdbuscpp2xml, qdbusviewer,
|
|
qdbusxml2cpp, qdoc3, qhelpconverter, qhelpgenerator, qmake,
|
|
qmlplugindump, qmlviewer, qt3to4, qtconfig, qttracereplay, rcc, uic,
|
|
uic3, xmlpatterns and xmlpatternsvalidator</seg>
|
|
|
|
<seg>libphonon.so, libQt3Support.so, libQtCLucene.so, libQtCore.so,
|
|
libQtDBus.so, libQtDeclarative.so, libQtDesigner.so,
|
|
libQtDesignerComponents.so, libQtGui.so, libQtHelp.so, libQtMultimedia,
|
|
libQtNetwork.so, libQtOpenGL.so, libQtScript.so, libQtScriptTools.so,
|
|
libQtSql.so, libQtSvg.so, libQtTest.so, libQtUiTools.a, libQtWebKit.so,
|
|
libQtXml.so, libQtXmlPatterns.so and numerous plugin modules installed
|
|
in <filename class='directory'>/opt/qt/plugins</filename></seg>
|
|
|
|
<seg>/opt/qt-&qt-version;</seg>
|
|
</seglistitem>
|
|
</segmentedlist>
|
|
|
|
<variablelist>
|
|
<bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
|
<?dbfo list-presentation="list"?>
|
|
<?dbhtml list-presentation="table"?>
|
|
|
|
<varlistentry id="qt-assistant">
|
|
<term><command>assistant</command></term>
|
|
<listitem>
|
|
<para>is a tool for presenting on-line documentation.</para>
|
|
<indexterm zone="qt qt-assistant">
|
|
<primary sortas="b-assistant">assistant</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-designer">
|
|
<term><command>designer</command></term>
|
|
<listitem>
|
|
<para>is a full-fledged GUI builder. It includes
|
|
powerful features such as preview mode, automatic widget
|
|
layout, support for custom widgets, and an advanced
|
|
property editor.</para>
|
|
<indexterm zone="qt qt-designer">
|
|
<primary sortas="b-designer">designer</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-linguist">
|
|
<term><command>linguist</command></term>
|
|
<listitem>
|
|
<para>provides support for translating applications into
|
|
local languages.</para>
|
|
<indexterm zone="qt qt-linguist">
|
|
<primary sortas="b-linguist">linguist</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-lrelease">
|
|
<term><command>lrelease</command></term>
|
|
<listitem>
|
|
<para>is a simple command line tool. It reads a Qt project
|
|
file and produces message files used by the application.</para>
|
|
<indexterm zone="qt qt-lrelease">
|
|
<primary sortas="b-lrelease">lrelease</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-lupdate">
|
|
<term><command>lupdate</command></term>
|
|
<listitem>
|
|
<para>reads a Qt project file, finds the translatable
|
|
strings in the specified source, header and Qt Designer
|
|
interface files, and produces or updates the translation
|
|
files listed in the project file.</para>
|
|
<indexterm zone="qt qt-lupdate">
|
|
<primary sortas="b-lupdate">lupdate</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-moc">
|
|
<term><command>moc</command></term>
|
|
<listitem>
|
|
<para>generates Qt meta object support code.</para>
|
|
<indexterm zone="qt qt-moc">
|
|
<primary sortas="b-moc">moc</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-pixeltool">
|
|
<term><command>pixeltool</command></term>
|
|
<listitem>
|
|
<para>is a desktop magnifier and as you move your mouse around
|
|
the screen it will show the magnified contents in its window.</para>
|
|
<indexterm zone="qt qt-pixeltool">
|
|
<primary sortas="b-pixeltool">pixeltool</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-qmake">
|
|
<term><command>qmake</command></term>
|
|
<listitem>
|
|
<para>qmake uses information stored in project files to
|
|
determine what should go in the makefiles it generates.</para>
|
|
<indexterm zone="qt qt-qmake">
|
|
<primary sortas="b-qmake">qmake</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-qt3to4">
|
|
<term><command>qt3to4</command></term>
|
|
<listitem>
|
|
<para>qt3to4 is a tool to help update Qt3 code to Qt4.</para>
|
|
<indexterm zone="qt qt-qt3to4">
|
|
<primary sortas="b-qt3to4">qt3to4</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-qtconfig">
|
|
<term><command>qtconfig</command></term>
|
|
<listitem>
|
|
<para>is used to customize the appearance of Qt applications.</para>
|
|
<indexterm zone="qt qt-qtconfig">
|
|
<primary sortas="b-qtconfig">qtconfig</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-rcc">
|
|
<term><command>rcc</command></term>
|
|
<listitem>
|
|
<para>is a resource compiler used in conjunction with designer.</para>
|
|
<indexterm zone="qt qt-rcc">
|
|
<primary sortas="b-rcc">rcc</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-uic">
|
|
<term><command>uic</command></term>
|
|
<listitem>
|
|
<para>is a Qt user interface compiler.</para>
|
|
<indexterm zone="qt qt-uic">
|
|
<primary sortas="b-uic">uic</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
<varlistentry id="qt-uic3">
|
|
<term><command>uic3</command></term>
|
|
<listitem>
|
|
<para>is a tool to generate Qt4 code out of
|
|
user interface files generated by the Qt3
|
|
version of designer.</para>
|
|
<indexterm zone="qt qt-uic3">
|
|
<primary sortas="b-uic3">uic3</primary>
|
|
</indexterm>
|
|
</listitem>
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
|
|
|
</sect2>
|
|
|
|
</sect1>
|