[8fe1ea6] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE partintro 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 | ]>
|
---|
| 7 |
|
---|
| 8 | <sect1 id="frameworks-intro">
|
---|
| 9 | <?dbhtml filename="frameworks-intro.html"?>
|
---|
| 10 |
|
---|
| 11 | <sect1info>
|
---|
| 12 | <othername>$LastChangedBy$</othername>
|
---|
| 13 | <date>$Date$</date>
|
---|
| 14 | </sect1info>
|
---|
| 15 |
|
---|
| 16 | <title>Introduction to KDE Frameworks 5</title>
|
---|
| 17 |
|
---|
| 18 | <para>
|
---|
| 19 | <application>KDE Frameworks 5</application> is a collection of
|
---|
| 20 | libraries based on top of <application>Qt5</application> and
|
---|
| 21 | QML that can be used independently of
|
---|
| 22 | <application>KDE</application>.
|
---|
| 23 | </para>
|
---|
| 24 |
|
---|
| 25 | <important>
|
---|
| 26 | <para>
|
---|
| 27 | The instructions for <application>KDE Frameworks 5</application>
|
---|
| 28 | packages assume that <xref linkend="qt5"/> was built with
|
---|
[71a44f0] | 29 | recommended dependencies installed.
|
---|
[8fe1ea6] | 30 | </para>
|
---|
| 31 | </important>
|
---|
| 32 |
|
---|
| 33 | <sect2>
|
---|
| 34 | <title>Build Order</title>
|
---|
| 35 |
|
---|
| 36 | <para>
|
---|
| 37 | <application>KDE Frameworks 5</application> packages are listed
|
---|
| 38 | in the recommended and tested build order based on dependencies.
|
---|
| 39 | </para>
|
---|
| 40 |
|
---|
| 41 | </sect2>
|
---|
| 42 |
|
---|
| 43 | <sect2>
|
---|
| 44 | <title>Installing in /usr</title>
|
---|
| 45 |
|
---|
| 46 | <para>
|
---|
| 47 | One option is to install <application>KDE Frameworks 5</application>
|
---|
| 48 | into the <filename class="directory">/usr</filename> hierarchy.
|
---|
| 49 | This creates a simpler setup but makes it more difficult to try
|
---|
| 50 | multiple versions of <application>KDE Frameworks</application>.
|
---|
| 51 | </para>
|
---|
| 52 |
|
---|
| 53 | <screen><userinput>export KF5_PREFIX=/usr
|
---|
| 54 | export KF5_SYSCONFDIR=/etc</userinput></screen>
|
---|
| 55 |
|
---|
| 56 | <para>
|
---|
| 57 | It is a good idea to add the following variables to your
|
---|
| 58 | system or personal profile:
|
---|
| 59 | </para>
|
---|
| 60 |
|
---|
| 61 | <screen role="root"><userinput>cat > /etc/profile.d/kf5.sh << "EOF"
|
---|
| 62 | <literal># Begin /etc/profile.d/kf5.sh
|
---|
| 63 |
|
---|
| 64 | export KF5_PREFIX=/usr
|
---|
| 65 | export KF5_SYSCONFDIR=/etc
|
---|
| 66 |
|
---|
| 67 | pathappend /usr/lib/qt5/plugins QT_PLUGIN_PATH
|
---|
| 68 | pathappend /opt/qt5/plugins QT_PLUGIN_PATH
|
---|
| 69 |
|
---|
| 70 | pathappend /usr/lib/qt5/qml QML_IMPORT_PATH
|
---|
| 71 | pathappend /opt/qt5/qml QML_IMPORT_PATH
|
---|
| 72 |
|
---|
| 73 | pathappend /usr/lib/qt5/qml QML2_IMPORT_PATH
|
---|
| 74 | pathappend /opt/qt5/qml QML2_IMPORT_PATH
|
---|
| 75 |
|
---|
| 76 | # End /etc/profile.d/kf5.sh</literal>
|
---|
| 77 | EOF</userinput></screen>
|
---|
| 78 |
|
---|
| 79 | <warning>
|
---|
| 80 | <para>
|
---|
| 81 | If <application>KDE4</application> is installed in
|
---|
| 82 | <filename class="directory">/usr</filename>, some packages
|
---|
| 83 | from this chapter might overwrite some programs installed
|
---|
| 84 | by <application>KDE4</application> packages.
|
---|
| 85 | </para>
|
---|
| 86 | </warning>
|
---|
| 87 |
|
---|
| 88 | </sect2>
|
---|
| 89 |
|
---|
| 90 | <sect2>
|
---|
| 91 | <title>Installing in /opt</title>
|
---|
| 92 |
|
---|
| 93 | <para>
|
---|
| 94 | A method of building multiple versions installs
|
---|
| 95 | <application>KDE Frameworks 5</application> in the
|
---|
| 96 | <filename class="directory">/opt</filename> hierarchy:
|
---|
| 97 | </para>
|
---|
| 98 |
|
---|
| 99 | <screen><userinput>export KF5_PREFIX=/opt/kf5
|
---|
| 100 | export KF5_SYSCONFDIR=$KF5_PREFIX/etc</userinput></screen>
|
---|
| 101 |
|
---|
| 102 | <para>
|
---|
| 103 | If you are not installing <application>KDE Frameworks 5</application>
|
---|
| 104 | in <filename class="directory">/usr</filename>, you will need to
|
---|
| 105 | make some additional configuration changes. Best practice is to add
|
---|
| 106 | those to your system or personal profile:
|
---|
| 107 | </para>
|
---|
| 108 |
|
---|
| 109 | <screen role="root"><userinput>cat > /etc/profile.d/kf5.sh << "EOF"
|
---|
| 110 | <literal># Begin /etc/profile.d/kf5.sh
|
---|
| 111 |
|
---|
| 112 | export KF5_PREFIX=/opt/kf5
|
---|
| 113 | export KF5_SYSCONFDIR=$KF5_PREFIX/etc
|
---|
| 114 |
|
---|
[cd9acb7] | 115 | pathappend $KF5_PREFIX CMAKE_PREFIX_PATH
|
---|
| 116 | pathappend $KF5_PREFIX/bin PATH
|
---|
| 117 | pathappend $KF5_PREFIX/lib/pkgconfig PKG_CONFIG_PATH
|
---|
| 118 | pathappend $KF5_PREFIX/lib/python&python2-majorver;/site-packages PYTHONPATH
|
---|
[8fe1ea6] | 119 |
|
---|
| 120 | pathappend /etc/xdg XDG_CONFIG_DIRS
|
---|
| 121 | pathappend $KF5_PREFIX/etc/xdg XDG_CONFIG_DIRS
|
---|
| 122 | pathappend /usr/share XDG_DATA_DIRS
|
---|
| 123 | pathappend $KF5_PREFIX/share XDG_DATA_DIRS
|
---|
| 124 |
|
---|
| 125 | pathappend /usr/lib/qt5/plugins QT_PLUGIN_PATH
|
---|
| 126 | pathappend /opt/qt5/plugins QT_PLUGIN_PATH
|
---|
| 127 | pathappend $KF5_PREFIX/lib/qt5/plugins QT_PLUGIN_PATH
|
---|
| 128 |
|
---|
| 129 | pathappend /usr/lib/qt5/qml QML_IMPORT_PATH
|
---|
| 130 | pathappend /opt/qt5/qml QML_IMPORT_PATH
|
---|
| 131 | pathappend $KF5_PREFIX/lib/qt5/qml QML_IMPORT_PATH
|
---|
| 132 |
|
---|
| 133 | pathappend /usr/lib/qt5/qml QML2_IMPORT_PATH
|
---|
| 134 | pathappend /opt/qt5/qml QML2_IMPORT_PATH
|
---|
| 135 | pathappend $KF5_PREFIX/lib/qt5/qml QML2_IMPORT_PATH
|
---|
| 136 |
|
---|
| 137 | # End /etc/profile.d/kf5.sh</literal>
|
---|
| 138 | EOF</userinput></screen>
|
---|
| 139 |
|
---|
| 140 | <para>
|
---|
| 141 | Expand your <filename>/etc/ld.so.conf</filename> file:
|
---|
| 142 | </para>
|
---|
| 143 |
|
---|
| 144 | <screen role="root"><userinput>cat >> /etc/ld.so.conf << "EOF"
|
---|
| 145 | <literal># Begin KF5 addition
|
---|
| 146 |
|
---|
| 147 | /opt/kf5/lib
|
---|
| 148 |
|
---|
| 149 | # End KF5 addition</literal>
|
---|
| 150 | EOF</userinput></screen>
|
---|
| 151 |
|
---|
| 152 | <indexterm zone="frameworks-intro">
|
---|
| 153 | <primary sortas="e-etc-ld.so.conf">/etc/ld.so.conf</primary>
|
---|
| 154 | </indexterm>
|
---|
| 155 |
|
---|
| 156 | <para>
|
---|
| 157 | Several <application>KDE Frameworks 5</application> packages install files into
|
---|
| 158 | <application>D-Bus</application> and <application>Polkit</application> directories.
|
---|
| 159 | When installing <application>KDE Frameworks 5</application> in a location other than
|
---|
| 160 | <filename class="directory">/usr</filename>, <application>D-Bus</application> and
|
---|
| 161 | <application>Polkit</application> need to be able to find these files. The easiest
|
---|
| 162 | way to achieve this is to create the following symlinks (as the
|
---|
| 163 | <systemitem class="username">root</systemitem> user):
|
---|
| 164 | </para>
|
---|
| 165 |
|
---|
| 166 | <screen role="root"><userinput>install -v -dm755 $KF5_PREFIX/{etc,share} &&
|
---|
| 167 | ln -sfv /etc/dbus-1 $KF5_PREFIX/etc &&
|
---|
| 168 | ln -sfv /usr/share/dbus-1 $KF5_PREFIX/share &&
|
---|
| 169 | ln -sfv /usr/share/polkit-1 $KF5_PREFIX/share</userinput></screen>
|
---|
| 170 |
|
---|
| 171 | <para>
|
---|
| 172 | Some packages may also install icons from the "hicolor" icon set. Since that
|
---|
| 173 | icon set is used by many packages, it is a good idea to create a
|
---|
| 174 | symlink to the one in <filename class="directory">/usr/share</filename>
|
---|
| 175 | to avoid having multiple installations of <xref linkend="hicolor-icon-theme"/>.
|
---|
| 176 | Run the following commands as the <systemitem class="username">root</systemitem>
|
---|
| 177 | user:
|
---|
| 178 | </para>
|
---|
| 179 |
|
---|
| 180 | <screen role="root"><userinput>install -v -dm755 $KF5_PREFIX/share/icons &&
|
---|
| 181 | ln -sfv /usr/share/icons/hicolor $KF5_PREFIX/share/icons</userinput></screen>
|
---|
| 182 |
|
---|
| 183 | <tip>
|
---|
| 184 | <para>
|
---|
| 185 | Sometimes, the installation paths are hardcoded into installed files.
|
---|
| 186 | This is the reason why <filename class="directory">/opt/kf5</filename>
|
---|
| 187 | is used as installation prefix instead of <filename
|
---|
| 188 | class="directory">/opt/kf5-&kf5-version;</filename>. After installing
|
---|
| 189 | <application>KDE Frameworks</application>, you may rename the directory
|
---|
| 190 | and create a symlink:
|
---|
| 191 | </para>
|
---|
| 192 |
|
---|
| 193 | <screen role="root"><userinput>mv /opt/kf5{,-&kf5-version;}
|
---|
| 194 | ln -sfv kf5-&kf5-version; /opt/kf5</userinput></screen>
|
---|
| 195 |
|
---|
| 196 | <para>
|
---|
| 197 | Later on, you may want to install other versions of
|
---|
| 198 | <application>KDE Frameworks 5</application>. To do that, just remove
|
---|
| 199 | the symlink and use <filename class="directory">/opt/kf5</filename>
|
---|
| 200 | as the prefix again. Which version of
|
---|
| 201 | <application>KDE Frameworks 5</application> you use depends only on
|
---|
| 202 | where the symlink points to. No other reconfiguration will be needed.
|
---|
| 203 | </para>
|
---|
| 204 | </tip>
|
---|
| 205 |
|
---|
| 206 | </sect2>
|
---|
| 207 |
|
---|
| 208 | </sect1>
|
---|