[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 |
|
---|
[e33406a] | 7 | <!ENTITY upower-download-http "http://upower.freedesktop.org/releases/upower-&upower1-version;.tar.xz">
|
---|
[1a55dac4] | 8 | <!ENTITY upower-download-ftp " ">
|
---|
[3cd3dd7] | 9 | <!ENTITY upower-md5sum "e21ea7875e46142e37695850754a296a">
|
---|
[30f5f9e] | 10 | <!ENTITY upower-size "420 KB">
|
---|
[3cd3dd7] | 11 | <!ENTITY upower-buildsize "10.6 MB">
|
---|
[b5cd92fc] | 12 | <!ENTITY upower-time "0.2 SBU">
|
---|
[1a55dac4] | 13 | ]>
|
---|
| 14 |
|
---|
[e33406a] | 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 |
|
---|
[e33406a] | 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 |
|
---|
[80b8a40] | 39 | &lfs76_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 |
|
---|
[85e324e] | 75 |
|
---|
[1a55dac4] | 76 | <bridgehead renderas="sect3">UPower Dependencies</bridgehead>
|
---|
| 77 |
|
---|
| 78 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
[c341539] | 79 | <para role="required">
|
---|
| 80 | <xref linkend="dbus-glib"/>,
|
---|
[f57b5c7] | 81 | <xref linkend="libusb"/>,
|
---|
[e6ce81b6] | 82 | <xref linkend="polkit"/>, and
|
---|
[7de9746] | 83 | <xref linkend="systemd"/> (for GUdev and Logind)
|
---|
[70727c9] | 84 | </para>
|
---|
| 85 |
|
---|
[4c2be438] | 86 | <bridgehead renderas="sect4">Optional (Required if building GNOME)</bridgehead>
|
---|
| 87 | <para role="optional">
|
---|
[c341539] | 88 | <xref linkend="gobject-introspection"/>
|
---|
| 89 | </para>
|
---|
[1a55dac4] | 90 |
|
---|
| 91 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[c341539] | 92 | <para role="optional">
|
---|
[85e324e] | 93 | <xref linkend="gtk-doc"/>,
|
---|
| 94 | <xref linkend="python3"/> (used only in the testsuite) and
|
---|
| 95 | <ulink url="http://www.libimobiledevice.org/">libimobiledevice</ulink>
|
---|
[c341539] | 96 | </para>
|
---|
[1a55dac4] | 97 |
|
---|
| 98 | <para condition="html" role="usernotes">User Notes:
|
---|
[7ded7e3] | 99 | <ulink url="&blfs-wiki;/upower"/>
|
---|
| 100 | </para>
|
---|
[1a55dac4] | 101 | </sect2>
|
---|
| 102 |
|
---|
| 103 | <sect2 role="installation">
|
---|
| 104 | <title>Installation of UPower</title>
|
---|
| 105 |
|
---|
[b84342d6] | 106 | <para>
|
---|
| 107 | Install <application>UPower</application> by running the following
|
---|
| 108 | commands:
|
---|
| 109 | </para>
|
---|
[1a55dac4] | 110 |
|
---|
[3cd3dd7] | 111 | <screen><userinput>./configure --prefix=/usr \
|
---|
[dc6ba1c0] | 112 | --sysconfdir=/etc \
|
---|
[1a55dac4] | 113 | --localstatedir=/var \
|
---|
[85e324e] | 114 | --disable-static &&
|
---|
[1a55dac4] | 115 | make</userinput></screen>
|
---|
| 116 |
|
---|
[b84342d6] | 117 | <para>
|
---|
[85e324e] | 118 | To test the results, issue: <command>make check</command>. Test
|
---|
| 119 | suite should be run from a local GUI session started with
|
---|
| 120 | dbus-launch.
|
---|
[b84342d6] | 121 | </para>
|
---|
[1a55dac4] | 122 |
|
---|
[b84342d6] | 123 | <para>
|
---|
| 124 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 125 | </para>
|
---|
[1a55dac4] | 126 |
|
---|
| 127 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
| 128 |
|
---|
| 129 | </sect2>
|
---|
| 130 |
|
---|
| 131 | <sect2 role="commands">
|
---|
| 132 | <title>Command Explanations</title>
|
---|
| 133 |
|
---|
[c341539] | 134 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
[b84342d6] | 135 | href="../../xincludes/static-libraries.xml"/>
|
---|
[3990efec] | 136 |
|
---|
[1a55dac4] | 137 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
[b84342d6] | 138 | href="../../xincludes/gtk-doc-rebuild.xml"/>
|
---|
[1a55dac4] | 139 |
|
---|
| 140 | </sect2>
|
---|
| 141 |
|
---|
[00c4d39] | 142 | <sect2 role="configuration">
|
---|
| 143 | <title>Configuring your kernel for UPower</title>
|
---|
| 144 |
|
---|
[b84342d6] | 145 | <para>
|
---|
| 146 | To use the command <command>upower -w</command> for information about
|
---|
[7de9746] | 147 | processor wakeups (this command is used by <ulink
|
---|
| 148 | url="http://ftp.gnome.org/pub/gnome/sources/gnome-power-manager/">gnome-power-manager</ulink>)
|
---|
[b84342d6] | 149 | you need to enable CONFIG_TIMER_STATS. This is achieved in
|
---|
| 150 | <command>make menuconfig</command> by going to the 'kernel-hacking'
|
---|
| 151 | menu and selecting 'Collect kernel timers statistics'.
|
---|
| 152 | </para>
|
---|
[00c4d39] | 153 |
|
---|
[7de9746] | 154 | <sect3 id="upower-init">
|
---|
[e39afa06] | 155 | <title>Systemd Units</title>
|
---|
| 156 |
|
---|
| 157 | <para>
|
---|
| 158 | To start the <command>upowerd</command> daemon at boot,
|
---|
| 159 | enable the previously installed systemd unit by
|
---|
| 160 | running the following command as the
|
---|
| 161 | <systemitem class="username">root</systemitem> user:
|
---|
| 162 | </para>
|
---|
[7de9746] | 163 |
|
---|
| 164 | <indexterm zone="upower upower-init">
|
---|
| 165 | <primary sortas="f-upower">upower</primary>
|
---|
| 166 | </indexterm>
|
---|
| 167 |
|
---|
| 168 | <screen role="root"><userinput>systemctl enable upower</userinput></screen>
|
---|
| 169 |
|
---|
| 170 | </sect3>
|
---|
| 171 |
|
---|
[00c4d39] | 172 | </sect2>
|
---|
[7de9746] | 173 |
|
---|
[1a55dac4] | 174 | <sect2 role="content">
|
---|
| 175 | <title>Contents</title>
|
---|
| 176 |
|
---|
| 177 | <segmentedlist>
|
---|
| 178 | <segtitle>Installed Programs</segtitle>
|
---|
[b35ec46c] | 179 | <segtitle>Installed Libraries</segtitle>
|
---|
[1a55dac4] | 180 | <segtitle>Installed Directories</segtitle>
|
---|
| 181 |
|
---|
| 182 | <seglistitem>
|
---|
[c341539] | 183 | <seg>
|
---|
| 184 | upower and upowerd
|
---|
| 185 | </seg>
|
---|
| 186 | <seg>
|
---|
| 187 | libupower-glib.so
|
---|
| 188 | </seg>
|
---|
| 189 | <seg>
|
---|
[7ded7e3] | 190 | /etc/UPower,
|
---|
[df9fb20] | 191 | /usr/include/libupower-glib, and
|
---|
[7ded7e3] | 192 | /var/lib/upower
|
---|
[c341539] | 193 | </seg>
|
---|
[1a55dac4] | 194 | </seglistitem>
|
---|
| 195 | </segmentedlist>
|
---|
| 196 |
|
---|
| 197 | <variablelist>
|
---|
| 198 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 199 | <?dbfo list-presentation="list"?>
|
---|
| 200 | <?dbhtml list-presentation="table"?>
|
---|
| 201 |
|
---|
| 202 | <varlistentry id="upower-prog">
|
---|
| 203 | <term><command>upower</command></term>
|
---|
| 204 | <listitem>
|
---|
[b84342d6] | 205 | <para>
|
---|
| 206 | is the <application>UPower</application> command line tool.
|
---|
| 207 | </para>
|
---|
[1a55dac4] | 208 | <indexterm zone="upower upower-prog">
|
---|
| 209 | <primary sortas="b-upower">upower</primary>
|
---|
| 210 | </indexterm>
|
---|
| 211 | </listitem>
|
---|
| 212 | </varlistentry>
|
---|
| 213 |
|
---|
| 214 | <varlistentry id="upowerd">
|
---|
| 215 | <term><command>upowerd</command></term>
|
---|
| 216 | <listitem>
|
---|
[b84342d6] | 217 | <para>
|
---|
| 218 | is the <application>UPower</application> Daemon. It provides the
|
---|
| 219 | org.freedesktop.UPower service on the system message bus.
|
---|
| 220 | </para>
|
---|
[1a55dac4] | 221 | <indexterm zone="upower upowerd">
|
---|
| 222 | <primary sortas="b-upowerd">upowerd</primary>
|
---|
| 223 | </indexterm>
|
---|
| 224 | </listitem>
|
---|
| 225 | </varlistentry>
|
---|
| 226 |
|
---|
| 227 | <varlistentry id="libupower-glib">
|
---|
[caed4c52] | 228 | <term><filename class="libraryfile">libupower-glib.so</filename></term>
|
---|
[1a55dac4] | 229 | <listitem>
|
---|
[b84342d6] | 230 | <para>
|
---|
| 231 | contains the <application>UPower</application> API functions.
|
---|
| 232 | </para>
|
---|
[1a55dac4] | 233 | <indexterm zone="upower libupower-glib">
|
---|
[c341539] | 234 | <primary sortas="c-libupower-glib">libupower-glib.so</primary>
|
---|
[1a55dac4] | 235 | </indexterm>
|
---|
| 236 | </listitem>
|
---|
| 237 | </varlistentry>
|
---|
| 238 |
|
---|
| 239 | </variablelist>
|
---|
| 240 |
|
---|
| 241 | </sect2>
|
---|
| 242 |
|
---|
| 243 | </sect1>
|
---|