Changeset 1b0d0188 for x/lib/qt4.xml


Ignore:
Timestamp:
06/24/2015 09:55:25 PM (9 years ago)
Author:
Bruce Dubbs <bdubbs@…>
Branches:
10.0, 10.1, 11.0, 11.1, 11.2, 11.3, 12.0, 12.1, 7.10, 7.8, 7.9, 8.0, 8.1, 8.2, 8.3, 8.4, 9.0, 9.1, basic, bdubbs/svn, elogind, kea, ken/TL2024, ken/inkscape-core-mods, ken/tuningfonts, lazarus, lxqt, nosym, perl-modules, plabs/newcss, plabs/python-mods, python3.11, qt5new, rahul/power-profiles-daemon, renodr/vulkan-addition, trunk, upgradedb, xry111/intltool, xry111/llvm18, xry111/soup3, xry111/test-20220226, xry111/xf86-video-removal
Children:
8e6f4f8
Parents:
233a4949
Message:

Update qt4 and qt5 instructions
Prep for KF5
Temove some tab characters

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@16163 af4574ff-66df-0310-9fd7-8a98e5e911e0

File:
1 edited

Legend:

Unmodified
Added
Removed
  • x/lib/qt4.xml

    r233a4949 r1b0d0188  
    55  %general-entities;
    66
     7  <!ENTITY qt4-major "4.8">
     8  <!ENTITY qt4-url   "http://download.qt-project.org/official_releases/qt/&qt4-major;">
     9
    710  <!ENTITY qt4-download-http
    8            "http://download.qt-project.org/official_releases/qt/4.8/&qt4-version;/qt-everywhere-opensource-src-&qt4-version;.tar.gz">
     11           "&qt4-url;;/&qt4-version;/qt-everywhere-opensource-src-&qt4-version;.tar.gz">
    912  <!ENTITY qt4-download-ftp  " ">
    1013  <!ENTITY qt4-md5sum        "d990ee66bf7ab0c785589776f35ba6ad">
     
    2932
    3033  <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>.
     34    <title>Introduction to Qt4</title>
     35
     36    <para>
     37      <application>Qt4</application> is a cross-platform application framework
     38      that is widely used for developing application software with a graphical
     39      user interface (GUI) (in which cases Qt4 is classified as a widget
     40      toolkit), and also used for developing non-GUI programs such as
     41      command-line tools and consoles for servers. One of the major users of
     42      <application>Qt</application> is <application>KDE4</application>.
    4043    </para>
    4144
     
    115118  </sect2>
    116119
    117   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="../../xincludes/qt-alternatives.xml"/>
     120  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
     121              href="../../xincludes/qt-alternatives.xml"/>
    118122
    119123  <sect2 role="qt4-prefix">
    120124    <title>Setting the installation prefix</title>
    121125
    122     <bridgehead renderas="sect3">Installing in /usr</bridgehead>
    123 
    124     <para>
    125       If you want to install <application>Qt4</application>
    126       in <filename class="directory">/usr</filename>, set the
     126    <bridgehead renderas="sect3">Installing in /opt/qt4</bridgehead>
     127
     128    <para>
     129      The BLFS editors recommend installing <application>Qt4</application> in a
     130      directory other than <filename class="directory">/usr</filename>, ie
     131      <filename class="directory">/opt/qt4</filename>.  To do this, set the
    127132      following environment variable:
    128     </para>
    129 
    130 <screen><userinput>export QT4PREFIX=/usr</userinput></screen>
    131 
    132     <bridgehead renderas="sect3">Installing in /opt/qt4</bridgehead>
    133 
    134     <para>
    135       If you want to install <application>Qt4</application>
    136       in a directory other than <filename
    137       class="directory">/usr</filename>, ie
    138       <filename class="directory">/opt/qt4</filename>, set
    139       the following environment variable:
    140133    </para>
    141134
     
    167160
    168161  <sect2 role="installation">
    169     <title>Installation of Qt</title>
    170 
    171     <caution>
    172       <para>
    173         If you did not install some of the recommended dependencies, examine
    174         <command>./configure --help</command> output to check how to disable
    175         them or use internal versions bundled in the source tarball.
    176       </para>
    177     </caution>
     162    <title>Installation of Qt4</title>
    178163
    179164    <warning>
     
    188173    </warning>
    189174
     175    <caution>
     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>
     181    </caution>
     182
    190183    <note>
    191184      <para>
    192185        The build time and space required for the full
    193         <application>Qt</application> is quite long. The instructions below
    194         do not build the tutorials and examples. Removing the
     186        <application>Qt3</application> is quite long. The instructions below do
     187        not build the tutorials and examples. Removing the
    195188        <parameter>-nomake</parameter> lines will create a complete build.
    196189      </para>
    197190    </note>
    198191
    199     <para>
    200       Install <application>Qt4</application> into the <filename
    201       class='directory'>/usr</filename> hierarchy by running the following
    202       commands:
    203     </para>
    204 
    205 <screen><userinput>./configure -prefix         $QT4PREFIX                        \
    206             -sysconfdir     /etc/xdg                          \
    207             -bindir         $QT4BINDIR                        \
    208             -plugindir      $QT4PREFIX/lib/qt4/plugins        \
    209             -importdir      $QT4PREFIX/lib/qt4/imports        \
    210             -headerdir      $QT4PREFIX/include/qt4            \
    211             -datadir        $QT4PREFIX/share/qt4              \
    212             -docdir         $QT4PREFIX/share/doc/qt4          \
    213             -translationdir $QT4PREFIX/share/qt4/translations \
    214             -demosdir       $QT4PREFIX/share/doc/qt4/demos    \
    215             -examplesdir    $QT4PREFIX/share/doc/qt4/examples \
    216             -confirm-license   \
    217             -opensource        \
    218             -release           \
    219             -dbus-linked       \
    220             -openssl-linked    \
    221             -system-sqlite     \
    222             -no-phonon         \
    223             -no-phonon-backend \
    224             -no-openvg         \
    225             -nomake demos      \
    226             -nomake examples   \
    227             -optimized-qmake   &amp;&amp;
    228 
     192    <note>
     193      <para>
     194        The BLFS editors do not recommend installing <application>Qt4</application>
     195        into the /usr hierarchy because it becomes difficult to find
     196        components and to update to a new version.  If you do want to install
     197        <application>Qt4</application> in /usr, the directories need to
     198        be specified explicitly.  In this case, set QT4PREFIX=/usr and add
     199        the following to the configure arguments below:</para>
     200
     201        <screen><userinput>-bindir         /usr/bin/qt4                \
     202-plugindir      /usr/lib/qt4/plugins        \
     203-importdir      /usr/lib/qt4/imports        \
     204-headerdir      /usr/include/qt4            \
     205-datadir        /usr/share/qt4              \
     206-docdir         /usr/share/doc/qt4          \
     207-translationdir /usr/share/qt4/translations \
     208-demosdir       /usr/share/doc/qt4/demos    \
     209-examplesdir    /usr/share/doc/qt4/examples </userinput></screen>
     210    </note>
     211
     212    <para>
     213      Install <application>Qt4</application> by running the following commands:
     214    </para>
     215
     216<screen><userinput>./configure -prefix           $QT4PREFIX \
     217            -sysconfdir       /etc/xdg   \
     218            -confirm-license             \
     219            -opensource                  \
     220            -release                     \
     221            -dbus-linked                 \
     222            -openssl-linked              \
     223            -system-sqlite               \
     224            -no-phonon                   \
     225            -no-phonon-backend           \
     226            -no-openvg                   \
     227            -nomake demos                \
     228            -nomake examples             \
     229            -optimized-qmake             &amp;&amp;
    229230make</userinput></screen>
    230231
     
    234235
    235236    <para>
    236       Remove references to the build directory from the
     237      Now as the <systemitem class="username">root</systemitem> user:
     238    </para>
     239
     240<screen role="root"><userinput>make install &amp;&amp;
     241rm -rf $QT4PREFIX/tests</userinput></screen>
     242
     243    <para>
     244      Remove references to the build directory from the installed
    237245      <filename class="extension">.pc</filename> files by running
    238246      the following command:
    239247    </para>
    240248
    241 <screen><userinput>find . -name "*.pc" -exec perl -pi -e "s, -L$PWD/?\S+,,g" {} \;</userinput></screen>
    242 
    243     <para>Now as the <systemitem class="username">root</systemitem> user:</para>
    244 
    245 <screen role="root"><userinput>make install &amp;&amp;
    246 rm -rf /usr/tests</userinput></screen>
    247 
    248     <para>
    249       Remove references to the build directory from installed files by
    250       running the following command as the
     249<screen><userinput>find $QT4PREFIX/lib/pkgconfig -name "*.pc" -exec perl -pi -e "s, -L$PWD/?\S+,,g" {} \;</userinput></screen>
     250
     251    <para>
     252      Remove references to the build directory in the installed library dependency
     253      (prl) files by running the following command as the
    251254      <systemitem class="username">root</systemitem> user:
    252255    </para>
    253256
    254 <screen role="root"><userinput>for file in 3Support CLucene Core DBus Declarative DesignerComponents \
    255             Designer Gui Help Multimedia Network OpenGL Script \
    256             ScriptTools Sql Svg Test UiTools WebKit XmlPatterns Xml phonon; do
    257 
    258      [ -e /usr/lib/libQt${file}.prl ] &amp;&amp;
    259      sed -r '/^QMAKE_PRL_BUILD_DIR/d;s/(QMAKE_PRL_LIBS =).*/\1/' \
    260          -i /usr/lib/libQt${file}.prl
    261 done
    262 unset file</userinput></screen>
    263 
    264     <para>
    265       Install images and create the menu entries
    266       for installed applications.  Be sure that the <envar>QT4PREFIX</envar>
    267       variable is defined in root's environment and
    268       as the <systemitem class="username">root</systemitem> user:
    269     </para>
    270 
    271 <screen role="root"><userinput>install -v -Dm644 src/gui/dialogs/images/qtlogo-64.png \
     257<screen role="root"><userinput>for file in $QT4PREFIX/lib/libQt*.prl; do
     258     sed -r -e '/^QMAKE_PRL_BUILD_DIR/d'    \
     259            -e 's/(QMAKE_PRL_LIBS =).*/\1/' \
     260            -i $file
     261done</userinput></screen>
     262
     263    <para>
     264      Install images and create the menu entries for installed applications.
     265      The <envar>QT4BINDIR</envar> variable is used here to point to the
     266      directory for the executable programs.  If you have changed the bindir
     267      above, <envar>QT4BINDIR</envar> will need to be adjusted below.  Be sure
     268      that the <envar>QT4BINDIR</envar> variable is defined in root's
     269      environment and as the <systemitem class="username">root</systemitem>
     270      user:
     271    </para>
     272
     273<screen role="root"><userinput>QT4BINDIR=$QT4PREFIX/bin
     274
     275install -v -Dm644 src/gui/dialogs/images/qtlogo-64.png \
    272276                  /usr/share/pixmaps/qt4logo.png       &amp;&amp;
    273277
     
    290294Name=Qt4 Assistant
    291295Comment=Shows Qt4 documentation and examples
    292 Exec=$QT4PREFIX/bin/assistant
     296Exec=$QT4BINDIR/assistant
    293297Icon=assistant-qt4.png
    294298Terminal=false
     
    302306Name=Qt4 Designer
    303307Comment=Design GUIs for Qt4 applications
    304 Exec=$QT4PREFIX/bin/designer
     308Exec=$QT4BINDIR/designer
    305309Icon=designer-qt4.png
    306310MimeType=application/x-designer;
     
    315319Name=Qt4 Linguist
    316320Comment=Add translations to Qt4 applications
    317 Exec=$QT4PREFIX/bin/linguist
     321Exec=$QT4BINDIR/linguist
    318322Icon=linguist-qt4.png
    319323MimeType=text/vnd.trolltech.linguist;application/x-linguist;
     
    329333GenericName=D-Bus Debugger
    330334Comment=Debug D-Bus applications
    331 Exec=$QT4PREFIX/bin/qdbusviewer
     335Exec=$QT4BINDIR/qdbusviewer
    332336Icon=qdbusviewer-qt4.png
    333337Terminal=false
     
    341345Name=Qt4 Config
    342346Comment=Configure Qt4 behavior, styles, fonts
    343 Exec=$QT4PREFIX/bin/qtconfig
     347Exec=$QT4BINDIR/qtconfig
    344348Icon=qt4logo.png
    345349Terminal=false
     
    349353EOF</userinput></screen>
    350354
     355    <para>Some packages such as <xref linkend='vlc'/> look for certain
     356    executables with a -qt4 suffix.  Run the following command as the root user
     357    to create the necessary symlinks:</para>
     358
     359<screen role="root"><userinput>for file in moc uic rcc qmake lconvert lrelease lupdate; do
     360  ln -sfrvn $QT4BINDIR/$file /usr/bin/$file-qt4
     361done</userinput></screen>
     362
    351363  </sect2>
    352364
     
    436448
    437449QT4DIR=/usr
    438 export QT4DIR
     450QTDIR=$QT4DIR
     451export QT4DIR QTDIR
    439452
    440453# End /etc/profile.d/qt4.sh</literal>
     
    442455
    443456   <para>
    444       If you installed <application>Qt</application> in a location other
     457      If you installed <application>Qt4</application> in a location other
    445458      than /usr, you need to update the following configuration files so
    446459      that <application>Qt</application> is correctly found by other packages
     
    475488   
    476489QT4DIR=/opt/qt4
    477    
    478 pathappend /opt/qt4/bin           PATH
    479 pathappend /opt/qt4/lib/pkgconfig PKG_CONFIG_PATH
    480    
    481 export QT4DIR
     490QTDIR=$QT4DIR
     491   
     492pathappend $QT4DIR/bin           PATH
     493pathappend $QT4DIR/lib/pkgconfig PKG_CONFIG_PATH
     494   
     495export QT4DIR QTDIR
    482496   
    483497# End /etc/profile.d/qt4.sh</literal>
Note: See TracChangeset for help on using the changeset viewer.