]>
Commit | Line | Data |
---|---|---|
3e1bced5 | 1 | # NOTE: this package is the last version of upower from 0.9.x series, compatible with pm-utils |
867116c0 AO |
2 | %define orig_name upower |
3 | ||
4 | Summary: Power management service with pm-utils backend | |
5 | Summary(pl.UTF-8): Usługa zarządzania energią z wykorzystaniem pm-utils | |
6 | Name: %{orig_name}-pm-utils | |
4c5b8e51 | 7 | Version: 0.9.23 |
c0e07778 | 8 | Release: 8 |
867116c0 AO |
9 | License: GPL v2+ |
10 | Group: Libraries | |
4c5b8e51 JP |
11 | Source0: http://upower.freedesktop.org/releases/%{orig_name}-%{version}.tar.xz |
12 | # Source0-md5: 39cfd97bfaf7d30908f20cf937a57634 | |
13 | Patch0: %{orig_name}-battery_range.patch | |
3e1bced5 | 14 | Patch1: %{orig_name}-glib-deprecated.patch |
867116c0 AO |
15 | URL: http://upower.freedesktop.org/ |
16 | BuildRequires: autoconf >= 2.65 | |
17 | BuildRequires: automake >= 1:1.11 | |
18 | BuildRequires: dbus-devel >= 1.0.0 | |
19 | BuildRequires: dbus-glib-devel >= 0.76 | |
20 | BuildRequires: docbook-dtd412-xml | |
21 | BuildRequires: gettext-devel >= 0.17 | |
22 | BuildRequires: glib2-devel >= 1:2.22.0 | |
23 | BuildRequires: gobject-introspection-devel >= 0.10.0 | |
24 | BuildRequires: gtk-doc >= 1.11 | |
25 | BuildRequires: intltool >= 0.40.0 | |
26 | BuildRequires: libimobiledevice-devel >= 0.9.7 | |
27 | BuildRequires: libplist-devel >= 0.12 | |
28 | BuildRequires: libtool >= 2:2 | |
29 | BuildRequires: libusb-devel >= 1.0.0 | |
30 | BuildRequires: pkgconfig | |
31 | BuildRequires: polkit-devel >= 0.97 | |
32 | BuildRequires: systemd-devel | |
33 | BuildRequires: tar >= 1:1.22 | |
34 | BuildRequires: udev-glib-devel >= 1:147 | |
35 | BuildRequires: xz | |
36 | Requires(post,preun,postun): systemd-units >= 38 | |
dfa320b9 | 37 | Requires: %{name}-libs = %{version}-%{release} |
867116c0 AO |
38 | Requires: libimobiledevice >= 0.9.7 |
39 | Requires: libplist >= 0.12 | |
40 | Requires: pm-utils | |
41 | Requires: polkit >= 0.97 | |
42 | Requires: systemd-units >= 38 | |
43 | Requires: udev-glib >= 1:147 | |
44 | Provides: %{orig_name} = %{version}-%{release} | |
dfa320b9 | 45 | Obsoletes: %{orig_name} |
867116c0 AO |
46 | Obsoletes: DeviceKit-power < 0.15 |
47 | Obsoletes: UPower < 0.9.8-2 | |
867116c0 AO |
48 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
49 | ||
50 | %description | |
51 | upower provides a daemon, API and command line tools for managing | |
dfa320b9 ER |
52 | power devices attached to the system. upower-pm-utils use pm-utils as |
53 | backend. | |
867116c0 AO |
54 | |
55 | %description -l pl.UTF-8 | |
56 | upower dostarcza demona, API i narzędzia linii poleceń do zarządzania | |
dfa320b9 ER |
57 | urządzeniami energii dołączonymi do systemu. upower-pm-utils |
58 | wykorzystuje do działania pm-utils. | |
867116c0 AO |
59 | |
60 | %package libs | |
61 | Summary: UPower shared library | |
62 | Summary(pl.UTF-8): Biblioteka współdzielona UPower | |
63 | Group: Libraries | |
64 | Requires: dbus-glib >= 0.76 | |
65 | Requires: dbus-libs >= 1.0.0 | |
66 | Requires: glib2 >= 1:2.22.0 | |
67 | Provides: %{orig_name}-libs = %{version}-%{release} | |
867116c0 AO |
68 | |
69 | %description libs | |
70 | UPower shared library. | |
71 | ||
72 | %description libs -l pl.UTF-8 | |
73 | Biblioteka współdzielona UPower. | |
74 | ||
75 | %package devel | |
76 | Summary: Header files for UPower library | |
77 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki UPower | |
78 | Group: Development/Libraries | |
79 | Requires: %{name}-libs = %{version}-%{release} | |
80 | Requires: dbus-devel >= 1.0.0 | |
81 | Requires: dbus-glib-devel >= 0.76 | |
82 | Requires: glib2-devel >= 1:2.22.0 | |
83 | Provides: %{orig_name}-devel = %{version}-%{release} | |
84 | Obsoletes: %{orig_name}-devel | |
85 | Obsoletes: DeviceKit-power-devel | |
86 | Obsoletes: UPower-devel | |
87 | ||
88 | %description devel | |
89 | Header files for UPower library. | |
90 | ||
91 | %description devel -l pl.UTF-8 | |
92 | Pliki nagłówkowe biblioteki UPower. | |
93 | ||
94 | %package static | |
95 | Summary: Static UPower library | |
96 | Summary(pl.UTF-8): Statyczna biblioteka UPower | |
97 | Group: Development/Libraries | |
98 | Requires: %{orig_name}-devel = %{version}-%{release} | |
99 | Provides: %{orig_name}-static = %{version}-%{release} | |
100 | Obsoletes: %{orig_name}-static | |
101 | ||
102 | %description static | |
103 | Static UPower library. | |
104 | ||
105 | %description static -l pl.UTF-8 | |
106 | Statyczna biblioteka UPower. | |
107 | ||
108 | %package apidocs | |
109 | Summary: UPower API documentation | |
110 | Summary(pl.UTF-8): Dokumentacja API UPower | |
111 | Group: Documentation | |
112 | Requires: gtk-doc-common | |
dfa320b9 | 113 | Obsoletes: %{orig_name}-apidocs |
867116c0 AO |
114 | Obsoletes: DeviceKit-power-apidocs |
115 | Obsoletes: UPower-apidocs | |
dfa320b9 ER |
116 | %if "%{_rpmversion}" >= "5" |
117 | BuildArch: noarch | |
118 | %endif | |
867116c0 AO |
119 | |
120 | %description apidocs | |
121 | UPower API documentation. | |
122 | ||
123 | %description apidocs -l pl.UTF-8 | |
124 | Dokumentacja API UPower. | |
125 | ||
126 | %prep | |
127 | %setup -q -n %{orig_name}-%{version} | |
4c5b8e51 | 128 | %patch0 -p1 |
3e1bced5 | 129 | %patch1 -p1 |
867116c0 AO |
130 | |
131 | %build | |
132 | %{__gtkdocize} | |
133 | %{__intltoolize} | |
134 | %{__libtoolize} | |
135 | %{__aclocal} | |
136 | %{__autoconf} | |
137 | %{__autoheader} | |
138 | %{__automake} | |
139 | %configure \ | |
140 | --disable-silent-rules \ | |
141 | --enable-deprecated \ | |
142 | --enable-gtk-doc \ | |
143 | --with-html-dir=%{_gtkdocdir} \ | |
144 | --with-systemdsystemunitdir=%{systemdunitdir} | |
145 | ||
146 | %{__make} | |
147 | ||
148 | %install | |
149 | rm -rf $RPM_BUILD_ROOT | |
150 | ||
151 | %{__make} install \ | |
152 | DESTDIR=$RPM_BUILD_ROOT | |
153 | ||
3e1bced5 JB |
154 | # obsoleted by pkg-config |
155 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libupower-glib.la | |
156 | ||
867116c0 AO |
157 | %find_lang upower |
158 | ||
159 | %clean | |
160 | rm -rf $RPM_BUILD_ROOT | |
161 | ||
162 | %post | |
163 | %systemd_post upower.service | |
164 | ||
165 | %preun | |
166 | %systemd_preun upower.service | |
167 | ||
168 | %postun | |
169 | %systemd_reload | |
170 | ||
171 | %post libs -p /sbin/ldconfig | |
172 | %postun libs -p /sbin/ldconfig | |
173 | ||
174 | %files -f upower.lang | |
175 | %defattr(644,root,root,755) | |
176 | %doc AUTHORS HACKING NEWS README | |
177 | %attr(755,root,root) %{_bindir}/upower | |
c0e07778 | 178 | %attr(755,root,root) %{_libexecdir}/upowerd |
867116c0 AO |
179 | %config(noreplace) %verify(not md5 mtime size) /etc/dbus-1/system.d/org.freedesktop.UPower.conf |
180 | %dir %{_sysconfdir}/UPower | |
181 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/UPower/UPower.conf | |
182 | %{_datadir}/dbus-1/system-services/org.freedesktop.UPower.service | |
4c5b8e51 JP |
183 | %{_datadir}/polkit-1/actions/org.freedesktop.upower.policy |
184 | %{_datadir}/polkit-1/actions/org.freedesktop.upower.qos.policy | |
867116c0 | 185 | %{systemdunitdir}/upower.service |
4c5b8e51 JP |
186 | %attr(755,root,root) /lib/systemd/system-sleep/notify-upower.sh |
187 | /lib/udev/rules.d/95-upower-battery-recall-dell.rules | |
188 | /lib/udev/rules.d/95-upower-battery-recall-fujitsu.rules | |
189 | /lib/udev/rules.d/95-upower-battery-recall-gateway.rules | |
190 | /lib/udev/rules.d/95-upower-battery-recall-ibm.rules | |
191 | /lib/udev/rules.d/95-upower-battery-recall-lenovo.rules | |
192 | /lib/udev/rules.d/95-upower-battery-recall-toshiba.rules | |
867116c0 AO |
193 | /lib/udev/rules.d/95-upower-csr.rules |
194 | /lib/udev/rules.d/95-upower-hid.rules | |
195 | /lib/udev/rules.d/95-upower-wup.rules | |
196 | %{_mandir}/man1/upower.1* | |
197 | %{_mandir}/man7/UPower.7* | |
198 | %{_mandir}/man8/upowerd.8* | |
199 | %dir /var/lib/upower | |
200 | ||
201 | %files libs | |
202 | %defattr(644,root,root,755) | |
203 | %attr(755,root,root) %{_libdir}/libupower-glib.so.*.*.* | |
4c5b8e51 | 204 | %attr(755,root,root) %ghost %{_libdir}/libupower-glib.so.1 |
867116c0 AO |
205 | %{_libdir}/girepository-1.0/UPowerGlib-1.0.typelib |
206 | ||
207 | %files devel | |
208 | %defattr(644,root,root,755) | |
209 | %attr(755,root,root) %{_libdir}/libupower-glib.so | |
867116c0 AO |
210 | %{_datadir}/dbus-1/interfaces/org.freedesktop.UPower.Device.xml |
211 | %{_datadir}/dbus-1/interfaces/org.freedesktop.UPower.KbdBacklight.xml | |
4c5b8e51 | 212 | %{_datadir}/dbus-1/interfaces/org.freedesktop.UPower.QoS.xml |
867116c0 AO |
213 | %{_datadir}/dbus-1/interfaces/org.freedesktop.UPower.Wakeups.xml |
214 | %{_datadir}/dbus-1/interfaces/org.freedesktop.UPower.xml | |
215 | %{_datadir}/gir-1.0/UPowerGlib-1.0.gir | |
216 | %{_includedir}/libupower-glib | |
217 | %{_pkgconfigdir}/upower-glib.pc | |
218 | ||
219 | %files static | |
220 | %defattr(644,root,root,755) | |
221 | %{_libdir}/libupower-glib.a | |
222 | ||
223 | %files apidocs | |
224 | %defattr(644,root,root,755) | |
225 | %{_gtkdocdir}/UPower |