]>
Commit | Line | Data |
---|---|---|
4813e2b2 | 1 | # TODO: package bash-completion in proper way |
6727d68f | 2 | Summary: A framework for defining policy for system-wide components |
ec26c0e8 | 3 | Summary(pl.UTF-8): Szkielet do definiowania polityki dla komponentów systemowych |
6727d68f | 4 | Name: PolicyKit |
4813e2b2 | 5 | Version: 0.7 |
06942ab7 | 6 | Release: 3 |
204749d0 | 7 | License: MIT |
6727d68f | 8 | Group: Libraries |
5623b4a4 | 9 | Source0: http://hal.freedesktop.org/releases/%{name}-%{version}.tar.gz |
4813e2b2 | 10 | # Source0-md5: 99e0cc588310656fa25f8f66a411c71f |
bfd83e1e | 11 | Patch0: %{name}-xfs.patch |
06942ab7 | 12 | Patch1: %{name}-CVE.patch |
27dd9833 | 13 | URL: http://people.freedesktop.org/~david/polkit-spec.html |
183aac36 | 14 | BuildRequires: autoconf >= 2.60 |
23049034 | 15 | BuildRequires: automake >= 1:1.7 |
183aac36 | 16 | BuildRequires: dbus-devel >= 1.0 |
4813e2b2 | 17 | BuildRequires: dbus-glib-devel >= 0.73 |
b9051385 | 18 | BuildRequires: expat-devel >= 1:1.95.8 |
7a09d427 JB |
19 | BuildRequires: glib2-devel >= 1:2.6.0 |
20 | BuildRequires: gtk-doc >= 1.3 | |
23049034 | 21 | BuildRequires: libselinux-devel >= 1.30 |
6727d68f AM |
22 | BuildRequires: libtool |
23 | BuildRequires: pam-devel >= 0.80 | |
7a09d427 JB |
24 | BuildRequires: pkgconfig |
25 | BuildRequires: rpmbuild(macros) >= 1.268 | |
6727d68f | 26 | BuildRequires: xmlto |
c0001c5d PZ |
27 | Requires(postun): /usr/sbin/groupdel |
28 | Requires(postun): /usr/sbin/userdel | |
29 | Requires(pre): /bin/id | |
30 | Requires(pre): /usr/bin/getgid | |
31 | Requires(pre): /usr/lib/rpm/user_group.sh | |
32 | Requires(pre): /usr/sbin/groupadd | |
33 | Requires(pre): /usr/sbin/useradd | |
34 | Requires(pre): /usr/sbin/usermod | |
b9051385 | 35 | Requires(triggerpostun): /sbin/chkconfig |
4342a6d9 | 36 | Requires: %{name}-libs = %{version}-%{release} |
616120d3 | 37 | Requires: ConsoleKit >= 0.2.1 |
ea89b22a | 38 | Requires: dbus >= 1.1.2-5 |
c0001c5d PZ |
39 | Provides: group(polkituser) |
40 | Provides: user(polkituser) | |
6727d68f AM |
41 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
42 | ||
1df708eb AM |
43 | %define _libexecdir %{_libdir}/%{name} |
44 | ||
6727d68f AM |
45 | %description |
46 | PolicyKit is a framework for defining policy for system-wide | |
47 | components and for desktop pieces to configure it. It is used by HAL. | |
48 | ||
6678f48b JR |
49 | %description -l pl.UTF-8 |
50 | PolicyKit to szkielet do definiowania polityki dla komponentów | |
51 | systemowych oraz składników pulpitu do konfigurowania ich. Jest | |
52 | używany przez HAL-a. | |
df978f17 | 53 | |
27dd9833 PZ |
54 | %package apidocs |
55 | Summary: PolicyKit API documentation | |
56 | Summary(pl.UTF-8): Dokumentacja API PolicyKit | |
57 | Group: Documentation | |
58 | Requires: gtk-doc-common | |
59 | ||
60 | %description apidocs | |
61 | PolicyKit API documentation. | |
62 | ||
63 | %description apidocs -l pl.UTF-8 | |
64 | Dokumentacja API PolicyKit. | |
65 | ||
4342a6d9 JB |
66 | %package libs |
67 | Summary: PolicyKit libraries | |
ec26c0e8 | 68 | Summary(pl.UTF-8): Biblioteki PolicyKit |
4342a6d9 | 69 | Group: Libraries |
b9051385 JB |
70 | Requires: dbus-libs >= 1.0 |
71 | Requires: glib2 >= 1:2.6.0 | |
4342a6d9 JB |
72 | Conflicts: PolicyKit < 0.1-0.20061203.6 |
73 | ||
74 | %description libs | |
75 | PolicyKit libraries. | |
76 | ||
6678f48b | 77 | %description libs -l pl.UTF-8 |
4342a6d9 JB |
78 | Biblioteki PolicyKit. |
79 | ||
6727d68f | 80 | %package devel |
df978f17 | 81 | Summary: Header files for PolicyKit |
ec26c0e8 | 82 | Summary(pl.UTF-8): Pliki nagłówkowe PolicyKit |
6727d68f | 83 | Group: Development/Libraries |
4342a6d9 | 84 | Requires: %{name}-libs = %{version}-%{release} |
b9051385 | 85 | Requires: expat-devel >= 1:1.95.8 |
4813e2b2 JB |
86 | # polkit-grant |
87 | #Requires: glib2-devel >= 1:2.6.0 | |
23049034 | 88 | # polkit-dbus and polkit-grant |
b9051385 | 89 | #Requires: dbus-devel >= 1.0 |
23049034 JB |
90 | # polkit-dbus |
91 | #Requires: libselinux-devel >= 1.30 | |
6727d68f AM |
92 | |
93 | %description devel | |
df978f17 | 94 | Header files for PolicyKit. |
6727d68f | 95 | |
6678f48b JR |
96 | %description devel -l pl.UTF-8 |
97 | Pliki nagłówkowe PolicyKit. | |
6727d68f AM |
98 | |
99 | %package static | |
df978f17 | 100 | Summary: Static PolicyKit libraries |
ec26c0e8 | 101 | Summary(pl.UTF-8): Statyczne biblioteki PolicyKit |
6727d68f AM |
102 | Group: Development/Libraries |
103 | Requires: %{name}-devel = %{version}-%{release} | |
104 | ||
105 | %description static | |
df978f17 | 106 | Static PolicyKit libraries. |
6727d68f | 107 | |
6678f48b | 108 | %description static -l pl.UTF-8 |
df978f17 | 109 | Statyczne biblioteki PolicyKit. |
6727d68f AM |
110 | |
111 | %prep | |
27dd9833 | 112 | %setup -q |
bfd83e1e | 113 | %patch0 -p0 |
06942ab7 | 114 | %patch1 -p1 |
6727d68f AM |
115 | |
116 | %build | |
4342a6d9 JB |
117 | %{__libtoolize} |
118 | %{__aclocal} | |
119 | %{__autoconf} | |
120 | %{__autoheader} | |
121 | %{__automake} | |
6727d68f | 122 | %configure \ |
7a09d427 | 123 | --with-html-dir=%{_gtkdocdir} \ |
23049034 | 124 | --with-pam-include=system-auth \ |
6727d68f | 125 | --with-pam-module-dir=/%{_lib}/security |
e7d78954 | 126 | %{__make} -j1 |
6727d68f AM |
127 | |
128 | %install | |
129 | rm -rf $RPM_BUILD_ROOT | |
130 | ||
e7d78954 | 131 | %{__make} -j1 install \ |
6727d68f AM |
132 | DESTDIR=$RPM_BUILD_ROOT |
133 | ||
183aac36 | 134 | rm -f $RPM_BUILD_ROOT%{_libdir}/PolicyKit/modules/*.{la,a} |
7a09d427 | 135 | |
6727d68f AM |
136 | %clean |
137 | rm -rf $RPM_BUILD_ROOT | |
138 | ||
4813e2b2 | 139 | %triggerun -- PolicyKit < 0.3 |
183aac36 JB |
140 | %service -q PolicyKit stop |
141 | /sbin/chkconfig --del PolicyKit | |
142 | ||
c0001c5d PZ |
143 | %pre |
144 | %groupadd -g 220 polkituser | |
145 | %useradd -u 220 -d %{_datadir}/empty -c "PolicyKit User" -g polkituser polkituser | |
146 | ||
4813e2b2 JB |
147 | %post |
148 | umask 022 | |
149 | touch /var/lib/misc/PolicyKit.reload | |
150 | chown root:polkituser /var/lib/misc/PolicyKit.reload | |
151 | chmod 664 /var/lib/misc/PolicyKit.reload | |
152 | ||
c0001c5d PZ |
153 | %postun |
154 | if [ "$1" = "0" ]; then | |
155 | %userremove polkituser | |
156 | %groupremove polkituser | |
157 | fi | |
158 | ||
4342a6d9 JB |
159 | %post libs -p /sbin/ldconfig |
160 | %postun libs -p /sbin/ldconfig | |
6727d68f AM |
161 | |
162 | %files | |
163 | %defattr(644,root,root,755) | |
27dd9833 | 164 | %doc AUTHORS README doc/TODO |
4813e2b2 JB |
165 | %attr(755,root,root) %{_bindir}/polkit-action |
166 | %attr(755,root,root) %{_bindir}/polkit-auth | |
167 | %attr(755,root,root) %{_bindir}/polkit-config-file-validate | |
168 | %attr(755,root,root) %{_bindir}/polkit-policy-file-validate | |
1df708eb | 169 | %dir %{_libexecdir} |
4813e2b2 | 170 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-explicit-grant-helper |
1df708eb | 171 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-grant-helper |
4813e2b2 JB |
172 | %attr(4754,root,polkituser) %{_libexecdir}/polkit-grant-helper-pam |
173 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-read-auth-helper | |
174 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-revoke-helper | |
175 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-set-default-helper | |
176 | %attr(755,root,root) %{_libexecdir}/polkitd | |
5623b4a4 | 177 | %dir %{_sysconfdir}/PolicyKit |
178 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/PolicyKit/PolicyKit.conf | |
4813e2b2 | 179 | /etc/dbus-1/system.d/org.freedesktop.PolicyKit.conf |
183aac36 | 180 | /etc/pam.d/polkit |
4813e2b2 JB |
181 | %{_datadir}/PolicyKit |
182 | %{_datadir}/dbus-1/interfaces/org.freedesktop.PolicyKit.AuthenticationAgent.xml | |
183 | %{_datadir}/dbus-1/system-services/org.freedesktop.PolicyKit.service | |
184 | %attr(664,root,polkituser) %ghost /var/lib/misc/PolicyKit.reload | |
185 | %attr(770,root,polkituser) /var/lib/PolicyKit | |
186 | %attr(775,root,polkituser) /var/lib/PolicyKit-public | |
187 | %attr(770,root,polkituser) /var/run/PolicyKit | |
188 | %{_mandir}/man1/polkit-action.1* | |
189 | %{_mandir}/man1/polkit-auth.1* | |
5623b4a4 | 190 | %{_mandir}/man1/polkit-config-file-validate.1* |
5623b4a4 | 191 | %{_mandir}/man1/polkit-policy-file-validate.1* |
192 | %{_mandir}/man5/PolicyKit.conf.5* | |
193 | %{_mandir}/man8/PolicyKit.8* | |
194 | ||
27dd9833 PZ |
195 | %files apidocs |
196 | %defattr(644,root,root,755) | |
197 | %{_gtkdocdir}/polkit | |
6727d68f | 198 | |
4342a6d9 JB |
199 | %files libs |
200 | %defattr(644,root,root,755) | |
183aac36 JB |
201 | # notes which license applies to which package part, AFL text (and GPL text copy) |
202 | %doc COPYING | |
4342a6d9 | 203 | %attr(755,root,root) %{_libdir}/libpolkit.so.*.*.* |
4813e2b2 | 204 | %attr(755,root,root) %ghost %{_libdir}/libpolkit.so.2 |
27dd9833 | 205 | %attr(755,root,root) %{_libdir}/libpolkit-dbus.so.*.*.* |
4813e2b2 | 206 | %attr(755,root,root) %ghost %{_libdir}/libpolkit-dbus.so.2 |
183aac36 | 207 | %attr(755,root,root) %{_libdir}/libpolkit-grant.so.*.*.* |
4813e2b2 | 208 | %attr(755,root,root) %ghost %{_libdir}/libpolkit-grant.so.2 |
4342a6d9 | 209 | |
6727d68f AM |
210 | %files devel |
211 | %defattr(644,root,root,755) | |
183aac36 JB |
212 | %attr(755,root,root) %{_libdir}/libpolkit.so |
213 | %attr(755,root,root) %{_libdir}/libpolkit-dbus.so | |
214 | %attr(755,root,root) %{_libdir}/libpolkit-grant.so | |
215 | %{_libdir}/libpolkit.la | |
216 | %{_libdir}/libpolkit-dbus.la | |
217 | %{_libdir}/libpolkit-grant.la | |
27dd9833 | 218 | %{_includedir}/PolicyKit |
4342a6d9 | 219 | %{_pkgconfigdir}/polkit.pc |
27dd9833 PZ |
220 | %{_pkgconfigdir}/polkit-dbus.pc |
221 | %{_pkgconfigdir}/polkit-grant.pc | |
6727d68f AM |
222 | |
223 | %files static | |
224 | %defattr(644,root,root,755) | |
183aac36 JB |
225 | %{_libdir}/libpolkit.a |
226 | %{_libdir}/libpolkit-dbus.a | |
227 | %{_libdir}/libpolkit-grant.a |