[1a55dac4] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE sect1 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 |
|
---|
[655f3e9] | 7 | <!ENTITY upower-download-http "http://upower.freedesktop.org/releases/upower-&upower1-version;.tar.xz">
|
---|
[1a55dac4] | 8 | <!ENTITY upower-download-ftp " ">
|
---|
[7356a067] | 9 | <!ENTITY upower-md5sum "14f43bc13353e23e7280863f33ac50d2">
|
---|
| 10 | <!ENTITY upower-size "420 KB">
|
---|
| 11 | <!ENTITY upower-buildsize "11 MB">
|
---|
[b5cd92fc] | 12 | <!ENTITY upower-time "0.2 SBU">
|
---|
[1a55dac4] | 13 | ]>
|
---|
| 14 |
|
---|
[655f3e9] | 15 | <sect1 id="upower" xreflabel="UPower-&upower1-version;">
|
---|
[1a55dac4] | 16 | <?dbhtml filename="upower.html"?>
|
---|
| 17 |
|
---|
| 18 | <sect1info>
|
---|
| 19 | <othername>$LastChangedBy$</othername>
|
---|
| 20 | <date>$Date$</date>
|
---|
| 21 | </sect1info>
|
---|
| 22 |
|
---|
[655f3e9] | 23 | <title>UPower-&upower1-version;</title>
|
---|
[1a55dac4] | 24 |
|
---|
| 25 | <indexterm zone="upower">
|
---|
| 26 | <primary sortas="a-UPower">UPower</primary>
|
---|
| 27 | </indexterm>
|
---|
| 28 |
|
---|
| 29 | <sect2 role="package">
|
---|
| 30 | <title>Introduction to UPower</title>
|
---|
| 31 |
|
---|
[b84342d6] | 32 | <para>
|
---|
| 33 | The <application>UPower</application> package provides an interface to
|
---|
| 34 | enumerating power devices, listening to device events and querying history
|
---|
| 35 | and statistics. Any application or service on the system can access the
|
---|
| 36 | org.freedesktop.UPower service via the system message bus.
|
---|
| 37 | </para>
|
---|
[1a55dac4] | 38 |
|
---|
[df9fb20] | 39 | &lfs75_checked;
|
---|
[1a55dac4] | 40 |
|
---|
| 41 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 42 | <itemizedlist spacing="compact">
|
---|
| 43 | <listitem>
|
---|
[b84342d6] | 44 | <para>
|
---|
| 45 | Download (HTTP): <ulink url="&upower-download-http;"/>
|
---|
| 46 | </para>
|
---|
[1a55dac4] | 47 | </listitem>
|
---|
| 48 | <listitem>
|
---|
[b84342d6] | 49 | <para>
|
---|
| 50 | Download (FTP): <ulink url="&upower-download-ftp;"/>
|
---|
| 51 | </para>
|
---|
[1a55dac4] | 52 | </listitem>
|
---|
| 53 | <listitem>
|
---|
[b84342d6] | 54 | <para>
|
---|
| 55 | Download MD5 sum: &upower-md5sum;
|
---|
| 56 | </para>
|
---|
[1a55dac4] | 57 | </listitem>
|
---|
| 58 | <listitem>
|
---|
[b84342d6] | 59 | <para>
|
---|
| 60 | Download size: &upower-size;
|
---|
| 61 | </para>
|
---|
[1a55dac4] | 62 | </listitem>
|
---|
| 63 | <listitem>
|
---|
[b84342d6] | 64 | <para>
|
---|
| 65 | Estimated disk space required: &upower-buildsize;
|
---|
| 66 | </para>
|
---|
[1a55dac4] | 67 | </listitem>
|
---|
| 68 | <listitem>
|
---|
[b84342d6] | 69 | <para>
|
---|
| 70 | Estimated build time: &upower-time;
|
---|
| 71 | </para>
|
---|
[1a55dac4] | 72 | </listitem>
|
---|
| 73 | </itemizedlist>
|
---|
| 74 |
|
---|
[7e548ae] | 75 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
| 76 | <itemizedlist spacing="compact">
|
---|
| 77 | <listitem>
|
---|
| 78 | <para>
|
---|
| 79 | Required patch:
|
---|
[cb378e16] | 80 | <ulink url="&patch-root;/upower-&upower1-version;-upstream_fixes-1.patch"/>
|
---|
[7e548ae] | 81 | </para>
|
---|
| 82 | </listitem>
|
---|
| 83 | </itemizedlist>
|
---|
| 84 |
|
---|
[1a55dac4] | 85 | <bridgehead renderas="sect3">UPower Dependencies</bridgehead>
|
---|
| 86 |
|
---|
| 87 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
[c341539] | 88 | <para role="required">
|
---|
| 89 | <xref linkend="dbus-glib"/>,
|
---|
[f57b5c7] | 90 | <xref linkend="libusb"/>,
|
---|
[e6ce81b6] | 91 | <xref linkend="polkit"/>, and
|
---|
[47e9f6b0] | 92 | <xref linkend="systemd"/> (for GUdev and Logind)
|
---|
[70727c9] | 93 | </para>
|
---|
| 94 |
|
---|
[4c2be438] | 95 | <bridgehead renderas="sect4">Optional (Required if building GNOME)</bridgehead>
|
---|
| 96 | <para role="optional">
|
---|
[c341539] | 97 | <xref linkend="gobject-introspection"/>
|
---|
| 98 | </para>
|
---|
[1a55dac4] | 99 |
|
---|
| 100 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[c341539] | 101 | <para role="optional">
|
---|
[7e548ae] | 102 | <xref linkend="gtk-doc"/>,
|
---|
| 103 | <xref linkend="python3"/> (used only in the testsuite) and
|
---|
| 104 | <ulink url="http://www.libimobiledevice.org/">libimobiledevice</ulink>
|
---|
[c341539] | 105 | </para>
|
---|
[1a55dac4] | 106 |
|
---|
| 107 | <para condition="html" role="usernotes">User Notes:
|
---|
[7ded7e3] | 108 | <ulink url="&blfs-wiki;/upower"/>
|
---|
| 109 | </para>
|
---|
[1a55dac4] | 110 | </sect2>
|
---|
| 111 |
|
---|
| 112 | <sect2 role="installation">
|
---|
| 113 | <title>Installation of UPower</title>
|
---|
| 114 |
|
---|
[b84342d6] | 115 | <para>
|
---|
| 116 | Install <application>UPower</application> by running the following
|
---|
| 117 | commands:
|
---|
| 118 | </para>
|
---|
[1a55dac4] | 119 |
|
---|
[3588b86] | 120 | <screen><userinput>patch -Np1 -i ../upower-&upower1-version;-upstream_fixes-1.patch &&
|
---|
[7e548ae] | 121 | ./configure --prefix=/usr \
|
---|
[dc6ba1c0] | 122 | --sysconfdir=/etc \
|
---|
[1a55dac4] | 123 | --localstatedir=/var \
|
---|
[7e548ae] | 124 | --disable-static &&
|
---|
[1a55dac4] | 125 | make</userinput></screen>
|
---|
| 126 |
|
---|
[b84342d6] | 127 | <para>
|
---|
[7e548ae] | 128 | To test the results, issue: <command>make check</command>. Test
|
---|
| 129 | suite should be run from a local GUI session started with
|
---|
| 130 | dbus-launch.
|
---|
[b84342d6] | 131 | </para>
|
---|
[1a55dac4] | 132 |
|
---|
[b84342d6] | 133 | <para>
|
---|
| 134 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 135 | </para>
|
---|
[1a55dac4] | 136 |
|
---|
| 137 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
| 138 |
|
---|
| 139 | </sect2>
|
---|
| 140 |
|
---|
| 141 | <sect2 role="commands">
|
---|
| 142 | <title>Command Explanations</title>
|
---|
| 143 |
|
---|
[c341539] | 144 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
[b84342d6] | 145 | href="../../xincludes/static-libraries.xml"/>
|
---|
[3990efec] | 146 |
|
---|
[1a55dac4] | 147 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
[b84342d6] | 148 | href="../../xincludes/gtk-doc-rebuild.xml"/>
|
---|
[1a55dac4] | 149 |
|
---|
| 150 | </sect2>
|
---|
| 151 |
|
---|
[00c4d39] | 152 | <sect2 role="configuration">
|
---|
| 153 | <title>Configuring your kernel for UPower</title>
|
---|
| 154 |
|
---|
[b84342d6] | 155 | <para>
|
---|
| 156 | To use the command <command>upower -w</command> for information about
|
---|
[47e9f6b0] | 157 | processor wakeups (this command is used by <ulink
|
---|
| 158 | url="http://ftp.gnome.org/pub/gnome/sources/gnome-power-manager/">gnome-power-manager</ulink>)
|
---|
[b84342d6] | 159 | you need to enable CONFIG_TIMER_STATS. This is achieved in
|
---|
| 160 | <command>make menuconfig</command> by going to the 'kernel-hacking'
|
---|
| 161 | menu and selecting 'Collect kernel timers statistics'.
|
---|
| 162 | </para>
|
---|
[00c4d39] | 163 |
|
---|
[47e9f6b0] | 164 | <sect3 id="upower-init">
|
---|
[96733af] | 165 | <title>Systemd Units</title>
|
---|
| 166 |
|
---|
| 167 | <para>
|
---|
| 168 | To start the <command>upowerd</command> daemon at boot,
|
---|
| 169 | enable the previously installed systemd unit by
|
---|
| 170 | running the following command as the
|
---|
| 171 | <systemitem class="username">root</systemitem> user:
|
---|
| 172 | </para>
|
---|
[47e9f6b0] | 173 |
|
---|
| 174 | <indexterm zone="upower upower-init">
|
---|
| 175 | <primary sortas="f-upower">upower</primary>
|
---|
| 176 | </indexterm>
|
---|
| 177 |
|
---|
| 178 | <screen role="root"><userinput>systemctl enable upower</userinput></screen>
|
---|
| 179 |
|
---|
| 180 | </sect3>
|
---|
| 181 |
|
---|
[00c4d39] | 182 | </sect2>
|
---|
[47e9f6b0] | 183 |
|
---|
[1a55dac4] | 184 | <sect2 role="content">
|
---|
| 185 | <title>Contents</title>
|
---|
| 186 |
|
---|
| 187 | <segmentedlist>
|
---|
| 188 | <segtitle>Installed Programs</segtitle>
|
---|
[b35ec46c] | 189 | <segtitle>Installed Libraries</segtitle>
|
---|
[1a55dac4] | 190 | <segtitle>Installed Directories</segtitle>
|
---|
| 191 |
|
---|
| 192 | <seglistitem>
|
---|
[c341539] | 193 | <seg>
|
---|
| 194 | upower and upowerd
|
---|
| 195 | </seg>
|
---|
| 196 | <seg>
|
---|
| 197 | libupower-glib.so
|
---|
| 198 | </seg>
|
---|
| 199 | <seg>
|
---|
[7ded7e3] | 200 | /etc/UPower,
|
---|
[df9fb20] | 201 | /usr/include/libupower-glib, and
|
---|
[7ded7e3] | 202 | /var/lib/upower
|
---|
[c341539] | 203 | </seg>
|
---|
[1a55dac4] | 204 | </seglistitem>
|
---|
| 205 | </segmentedlist>
|
---|
| 206 |
|
---|
| 207 | <variablelist>
|
---|
| 208 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 209 | <?dbfo list-presentation="list"?>
|
---|
| 210 | <?dbhtml list-presentation="table"?>
|
---|
| 211 |
|
---|
| 212 | <varlistentry id="upower-prog">
|
---|
| 213 | <term><command>upower</command></term>
|
---|
| 214 | <listitem>
|
---|
[b84342d6] | 215 | <para>
|
---|
| 216 | is the <application>UPower</application> command line tool.
|
---|
| 217 | </para>
|
---|
[1a55dac4] | 218 | <indexterm zone="upower upower-prog">
|
---|
| 219 | <primary sortas="b-upower">upower</primary>
|
---|
| 220 | </indexterm>
|
---|
| 221 | </listitem>
|
---|
| 222 | </varlistentry>
|
---|
| 223 |
|
---|
| 224 | <varlistentry id="upowerd">
|
---|
| 225 | <term><command>upowerd</command></term>
|
---|
| 226 | <listitem>
|
---|
[b84342d6] | 227 | <para>
|
---|
| 228 | is the <application>UPower</application> Daemon. It provides the
|
---|
| 229 | org.freedesktop.UPower service on the system message bus.
|
---|
| 230 | </para>
|
---|
[1a55dac4] | 231 | <indexterm zone="upower upowerd">
|
---|
| 232 | <primary sortas="b-upowerd">upowerd</primary>
|
---|
| 233 | </indexterm>
|
---|
| 234 | </listitem>
|
---|
| 235 | </varlistentry>
|
---|
| 236 |
|
---|
| 237 | <varlistentry id="libupower-glib">
|
---|
[caed4c52] | 238 | <term><filename class="libraryfile">libupower-glib.so</filename></term>
|
---|
[1a55dac4] | 239 | <listitem>
|
---|
[b84342d6] | 240 | <para>
|
---|
| 241 | contains the <application>UPower</application> API functions.
|
---|
| 242 | </para>
|
---|
[1a55dac4] | 243 | <indexterm zone="upower libupower-glib">
|
---|
[c341539] | 244 | <primary sortas="c-libupower-glib">libupower-glib.so</primary>
|
---|
[1a55dac4] | 245 | </indexterm>
|
---|
| 246 | </listitem>
|
---|
| 247 | </varlistentry>
|
---|
| 248 |
|
---|
| 249 | </variablelist>
|
---|
| 250 |
|
---|
| 251 | </sect2>
|
---|
| 252 |
|
---|
| 253 | </sect1>
|
---|