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