[f175d6f6] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE chapter 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 | <!ENTITY kf5-download-http "&kf5-download-http;">
|
---|
| 8 | <!ENTITY kf5-download-ftp "&kf5e-download-ftp;">
|
---|
| 9 | <!ENTITY kf5-md5sum "See Below">
|
---|
| 10 | <!ENTITY kf5-size "30 MB">
|
---|
| 11 | <!ENTITY kf5-buildsize "11.7 MB">
|
---|
| 12 | <!ENTITY kf5-time "0.4 SBU">
|
---|
| 13 | ]>
|
---|
| 14 |
|
---|
| 15 | <sect1 id="kf5-intro" xreflabel="Introduction to KF5">
|
---|
| 16 | <?dbhtml filename="kf5-intro.html"?>
|
---|
| 17 |
|
---|
| 18 | <sect1info>
|
---|
[d027410] | 19 | <date>$Date$</date>
|
---|
[f175d6f6] | 20 | </sect1info>
|
---|
| 21 |
|
---|
| 22 | <title>KDE Frameworks 5 Pre-installation Configuration</title>
|
---|
| 23 |
|
---|
[2630345] | 24 | <indexterm zone="kf5-intro">
|
---|
| 25 | <primary sortas="g-kf5">KDE Frameworks Introduction</primary>
|
---|
[f175d6f6] | 26 | </indexterm>
|
---|
| 27 |
|
---|
[1c8c15c] | 28 | <para>
|
---|
| 29 | KF5 can be installed in <filename class="directory">/usr</filename> or
|
---|
| 30 | <filename class="directory">/opt/kf5</filename>. The BLFS editors
|
---|
| 31 | recommend the latter in the BLFS environment.
|
---|
[f175d6f6] | 32 | </para>
|
---|
| 33 |
|
---|
| 34 | <sect2>
|
---|
| 35 | <title>Installing in /usr</title>
|
---|
| 36 |
|
---|
| 37 | <para>
|
---|
| 38 | One option is to install <application>KDE Frameworks 5</application>
|
---|
| 39 | into the <filename class="directory">/usr</filename> hierarchy.
|
---|
| 40 | This creates a simpler setup but makes it more difficult to try
|
---|
| 41 | multiple versions of <application>KDE Frameworks</application>.
|
---|
| 42 | </para>
|
---|
| 43 |
|
---|
| 44 | <screen><userinput>export KF5_PREFIX=/usr</userinput></screen>
|
---|
| 45 |
|
---|
| 46 | <para>
|
---|
| 47 | It is a good idea to add the following variables to your
|
---|
[5652a81] | 48 | system or personal profiles:
|
---|
[f175d6f6] | 49 | </para>
|
---|
| 50 |
|
---|
[5652a81] | 51 | <screen role="root"><userinput>cat >> /etc/profile.d/qt5.sh << "EOF"
|
---|
[77a6d25] | 52 | <literal># Begin kf5 extension for /etc/profile.d/qt5.sh
|
---|
[f175d6f6] | 53 |
|
---|
[c50cdeea] | 54 | pathappend /usr/lib/plugins QT_PLUGIN_PATH
|
---|
[5652a81] | 55 | pathappend $QT5DIR/lib/plugins QT_PLUGIN_PATH
|
---|
[f175d6f6] | 56 |
|
---|
| 57 | pathappend /usr/lib/qt5/qml QML2_IMPORT_PATH
|
---|
[5652a81] | 58 | pathappend $QT5DIR/lib/qml QML2_IMPORT_PATH
|
---|
| 59 |
|
---|
[77a6d25] | 60 | # End extension for /etc/profile.d/qt5.sh</literal>
|
---|
[5652a81] | 61 | EOF
|
---|
| 62 |
|
---|
| 63 | cat > /etc/profile.d/kf5.sh << "EOF"
|
---|
| 64 | <literal># Begin /etc/profile.d/kf5.sh
|
---|
| 65 |
|
---|
| 66 | export KF5_PREFIX=/usr
|
---|
[f175d6f6] | 67 |
|
---|
| 68 | # End /etc/profile.d/kf5.sh</literal>
|
---|
| 69 | EOF</userinput></screen>
|
---|
[5652a81] | 70 |
|
---|
[1c8c15c] | 71 | <note>
|
---|
| 72 | <para>
|
---|
| 73 | If <application>qt5</application> was installed in <filename
|
---|
| 74 | class="directory">/usr</filename>, the <filename
|
---|
| 75 | class="directory">$QT5DIR/lib/</filename> portions of the above paths
|
---|
| 76 | may need to be changed to <filename
|
---|
| 77 | class="directory">$QT5DIR/lib/qt5/</filename>.
|
---|
| 78 | </para>
|
---|
| 79 | </note>
|
---|
[5652a81] | 80 |
|
---|
[1c8c15c] | 81 | <para>
|
---|
| 82 | Additionally, if <xref linkend="sudo"/> is installed, these variables
|
---|
| 83 | should be available to the super user. Execute the following commands as
|
---|
| 84 | the <systemitem class="username">root</systemitem> user:
|
---|
| 85 | </para>
|
---|
[77b64bd] | 86 |
|
---|
[b32a1dc] | 87 | <screen role="root"><userinput>cat >> /etc/sudoers.d/qt << "EOF"
|
---|
[77b64bd] | 88 | <literal>Defaults env_keep += QT_PLUGIN_PATH
|
---|
| 89 | Defaults env_keep += QML2_IMPORT_PATH</literal>
|
---|
| 90 | EOF
|
---|
| 91 |
|
---|
[b32a1dc] | 92 | cat >> /etc/sudoers.d/kde << "EOF"
|
---|
[77b64bd] | 93 | <literal>Defaults env_keep += KF5_PREFIX</literal>
|
---|
| 94 | EOF</userinput></screen>
|
---|
| 95 |
|
---|
[f175d6f6] | 96 | </sect2>
|
---|
| 97 |
|
---|
| 98 | <sect2>
|
---|
| 99 | <title>Installing in /opt</title>
|
---|
| 100 |
|
---|
| 101 | <para>
|
---|
| 102 | A method of building multiple versions installs
|
---|
| 103 | <application>KDE Frameworks 5</application> in the
|
---|
| 104 | <filename class="directory">/opt</filename> hierarchy:
|
---|
| 105 | </para>
|
---|
| 106 |
|
---|
| 107 | <screen><userinput>export KF5_PREFIX=/opt/kf5</userinput></screen>
|
---|
| 108 |
|
---|
| 109 | <para>
|
---|
| 110 | If you are not installing <application>KDE Frameworks 5</application>
|
---|
| 111 | in <filename class="directory">/usr</filename>, you will need to
|
---|
| 112 | make some additional configuration changes. Best practice is to add
|
---|
| 113 | those to your system or personal profile:
|
---|
| 114 | </para>
|
---|
| 115 |
|
---|
| 116 | <screen role="root"><userinput>cat > /etc/profile.d/kf5.sh << "EOF"
|
---|
| 117 | <literal># Begin /etc/profile.d/kf5.sh
|
---|
| 118 |
|
---|
| 119 | export KF5_PREFIX=/opt/kf5
|
---|
| 120 |
|
---|
[4e0a40f] | 121 | pathappend $KF5_PREFIX/bin PATH
|
---|
| 122 | pathappend $KF5_PREFIX/lib/pkgconfig PKG_CONFIG_PATH
|
---|
[f175d6f6] | 123 |
|
---|
[4e0a40f] | 124 | pathappend $KF5_PREFIX/etc/xdg XDG_CONFIG_DIRS
|
---|
| 125 | pathappend $KF5_PREFIX/share XDG_DATA_DIRS
|
---|
[f175d6f6] | 126 |
|
---|
[4e0a40f] | 127 | pathappend $KF5_PREFIX/lib/plugins QT_PLUGIN_PATH
|
---|
| 128 | pathappend $KF5_PREFIX/lib/plugins/kcms QT_PLUGIN_PATH
|
---|
[f175d6f6] | 129 |
|
---|
[4e0a40f] | 130 | pathappend $KF5_PREFIX/lib/qml QML2_IMPORT_PATH
|
---|
[f175d6f6] | 131 |
|
---|
[33c8b427] | 132 | pathappend $KF5_PREFIX/lib/python&python3-majorver;/site-packages PYTHONPATH
|
---|
[2ead8c6f] | 133 |
|
---|
[4e0a40f] | 134 | pathappend $KF5_PREFIX/share/man MANPATH
|
---|
[f175d6f6] | 135 | # End /etc/profile.d/kf5.sh</literal>
|
---|
| 136 | EOF
|
---|
| 137 |
|
---|
[773b316] | 138 | cat >> /etc/profile.d/qt5.sh << "EOF"
|
---|
| 139 | <literal># Begin Qt5 changes for KF5
|
---|
[f175d6f6] | 140 |
|
---|
[c50cdeea] | 141 | pathappend /usr/lib/plugins QT_PLUGIN_PATH
|
---|
[f175d6f6] | 142 | pathappend $QT5DIR/plugins QT_PLUGIN_PATH
|
---|
| 143 | pathappend $QT5DIR/qml QML2_IMPORT_PATH
|
---|
| 144 |
|
---|
| 145 | # End Qt5 changes for KF5</literal>
|
---|
| 146 | EOF</userinput></screen>
|
---|
| 147 |
|
---|
| 148 | <para>
|
---|
| 149 | Expand your <filename>/etc/ld.so.conf</filename> file:
|
---|
| 150 | </para>
|
---|
| 151 |
|
---|
| 152 | <screen role="root"><userinput>cat >> /etc/ld.so.conf << "EOF"
|
---|
| 153 | <literal># Begin KF5 addition
|
---|
| 154 |
|
---|
| 155 | /opt/kf5/lib
|
---|
| 156 |
|
---|
| 157 | # End KF5 addition</literal>
|
---|
| 158 | EOF</userinput></screen>
|
---|
| 159 |
|
---|
| 160 | <indexterm zone="kf5-intro">
|
---|
| 161 | <primary sortas="e-etc-ld.so.conf">/etc/ld.so.conf</primary>
|
---|
| 162 | </indexterm>
|
---|
| 163 |
|
---|
[2e29bba] | 164 | <para revision="sysv">
|
---|
[f263bf7] | 165 | Several <application>KDE Frameworks 5</application> and
|
---|
| 166 | <application>Plasma 5</application> packages install
|
---|
| 167 | files into <application>D-Bus</application> and
|
---|
| 168 | <application>Polkit</application> directories. When installing
|
---|
[f175d6f6] | 169 | <application>KDE Frameworks 5</application> in a location other than
|
---|
| 170 | <filename class="directory">/usr</filename>,
|
---|
[f263bf7] | 171 | <application>D-Bus</application> and <application>Polkit</application>
|
---|
| 172 | need to be able to find these files.
|
---|
[f175d6f6] | 173 | The easiest way to achieve this is to create the following symlinks (as
|
---|
| 174 | the <systemitem class="username">root</systemitem> user):
|
---|
| 175 | </para>
|
---|
| 176 |
|
---|
[2e29bba] | 177 | <screen role="root"
|
---|
| 178 | revision="sysv"><userinput>install -v -dm755 $KF5_PREFIX/{etc,share} &&
|
---|
[f175d6f6] | 179 | ln -sfv /etc/dbus-1 $KF5_PREFIX/etc &&
|
---|
[f263bf7] | 180 | ln -sfv /usr/share/dbus-1 $KF5_PREFIX/share &&
|
---|
| 181 | ln -sfv /usr/share/polkit-1 $KF5_PREFIX/share</userinput></screen>
|
---|
[f175d6f6] | 182 |
|
---|
[2e29bba] | 183 | <para revision="systemd">
|
---|
| 184 | Several <application>KDE Frameworks 5</application> and
|
---|
| 185 | <application>KDE Plasma 5</application> packages install
|
---|
[f263bf7] | 186 | files into <application>D-Bus</application>,
|
---|
| 187 | <application>Polkit</application>, and
|
---|
[2e29bba] | 188 | <application>systemd</application> directories. When installing
|
---|
| 189 | <application>KDE 5</application> in a location other than
|
---|
| 190 | <filename class="directory">/usr</filename>,
|
---|
[f263bf7] | 191 | <application>D-Bus</application>, <application>Polkit</application>,
|
---|
| 192 | and <application>systemd</application>
|
---|
[2e29bba] | 193 | need to be able to find these files.
|
---|
| 194 | The easiest way to achieve this is to create the following symlinks (as
|
---|
| 195 | the <systemitem class="username">root</systemitem> user):
|
---|
| 196 | </para>
|
---|
| 197 |
|
---|
| 198 | <screen role="root"
|
---|
[f263bf7] | 199 | revision="systemd"><userinput>install -v -dm755 $KF5_PREFIX/{etc,share} &&
|
---|
| 200 | ln -sfv /etc/dbus-1 $KF5_PREFIX/etc &&
|
---|
| 201 | ln -sfv /usr/share/dbus-1 $KF5_PREFIX/share &&
|
---|
| 202 | ln -sfv /usr/share/polkit-1 $KF5_PREFIX/share &&
|
---|
| 203 | install -v -dm755 $KF5_PREFIX/lib &&
|
---|
| 204 | ln -sfv /usr/lib/systemd $KF5_PREFIX/lib</userinput></screen>
|
---|
[2e29bba] | 205 |
|
---|
[f175d6f6] | 206 | <para>
|
---|
| 207 | Some packages may also install icons from the "hicolor" icon set. Since that
|
---|
| 208 | icon set is used by many packages, it is a good idea to create a
|
---|
| 209 | symlink to the one in <filename class="directory">/usr/share</filename>
|
---|
| 210 | to avoid having multiple installations of <xref linkend="hicolor-icon-theme"/>.
|
---|
| 211 | Run the following commands as the <systemitem class="username">root</systemitem>
|
---|
| 212 | user:
|
---|
| 213 | </para>
|
---|
| 214 |
|
---|
| 215 | <screen role="root"><userinput>install -v -dm755 $KF5_PREFIX/share/icons &&
|
---|
| 216 | ln -sfv /usr/share/icons/hicolor $KF5_PREFIX/share/icons</userinput></screen>
|
---|
| 217 |
|
---|
| 218 | <tip>
|
---|
| 219 | <para>
|
---|
| 220 | Sometimes, the installation paths are hardcoded into installed files.
|
---|
| 221 | This is the reason why <filename class="directory">/opt/kf5</filename>
|
---|
| 222 | is used as installation prefix instead of <filename
|
---|
| 223 | class="directory">/opt/kf5-&kf5-version;</filename>. After installing
|
---|
| 224 | <application>KDE Frameworks</application>, you may rename the directory
|
---|
| 225 | and create a symlink:
|
---|
| 226 | </para>
|
---|
| 227 |
|
---|
| 228 | <screen role="root"><userinput>mv /opt/kf5{,-&kf5-version;}
|
---|
| 229 | ln -sfv kf5-&kf5-version; /opt/kf5</userinput></screen>
|
---|
| 230 |
|
---|
| 231 | <para>
|
---|
| 232 | Later on, you may want to install other versions of
|
---|
| 233 | <application>KDE Frameworks 5</application>. To do that, just remove
|
---|
| 234 | the symlink and use <filename class="directory">/opt/kf5</filename>
|
---|
| 235 | as the prefix again. Which version of
|
---|
| 236 | <application>KDE Frameworks 5</application> you use depends only on
|
---|
| 237 | where the symlink points. No other reconfiguration will be needed.
|
---|
| 238 | </para>
|
---|
| 239 | </tip>
|
---|
| 240 |
|
---|
| 241 | </sect2>
|
---|
| 242 |
|
---|
| 243 | </sect1>
|
---|