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