]>
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 |
4342a6d9 | 67 | Group: Libraries |
b9051385 JB |
68 | Requires: dbus-libs >= 1.0 |
69 | Requires: glib2 >= 1:2.6.0 | |
4342a6d9 JB |
70 | Conflicts: PolicyKit < 0.1-0.20061203.6 |
71 | ||
72 | %description libs | |
73 | PolicyKit libraries. | |
74 | ||
6678f48b | 75 | %description libs -l pl.UTF-8 |
4342a6d9 JB |
76 | Biblioteki PolicyKit. |
77 | ||
6727d68f | 78 | %package devel |
df978f17 | 79 | Summary: Header files for PolicyKit |
ec26c0e8 | 80 | Summary(pl.UTF-8): Pliki nagłówkowe PolicyKit |
6727d68f | 81 | Group: Development/Libraries |
4342a6d9 | 82 | Requires: %{name}-libs = %{version}-%{release} |
b9051385 | 83 | Requires: expat-devel >= 1:1.95.8 |
4813e2b2 JB |
84 | # polkit-grant |
85 | #Requires: glib2-devel >= 1:2.6.0 | |
23049034 | 86 | # polkit-dbus and polkit-grant |
b9051385 | 87 | #Requires: dbus-devel >= 1.0 |
23049034 JB |
88 | # polkit-dbus |
89 | #Requires: libselinux-devel >= 1.30 | |
6727d68f AM |
90 | |
91 | %description devel | |
df978f17 | 92 | Header files for PolicyKit. |
6727d68f | 93 | |
6678f48b JR |
94 | %description devel -l pl.UTF-8 |
95 | Pliki nagłówkowe PolicyKit. | |
6727d68f AM |
96 | |
97 | %package static | |
df978f17 | 98 | Summary: Static PolicyKit libraries |
ec26c0e8 | 99 | Summary(pl.UTF-8): Statyczne biblioteki PolicyKit |
6727d68f AM |
100 | Group: Development/Libraries |
101 | Requires: %{name}-devel = %{version}-%{release} | |
102 | ||
103 | %description static | |
df978f17 | 104 | Static PolicyKit libraries. |
6727d68f | 105 | |
6678f48b | 106 | %description static -l pl.UTF-8 |
df978f17 | 107 | Statyczne biblioteki PolicyKit. |
6727d68f AM |
108 | |
109 | %prep | |
27dd9833 | 110 | %setup -q |
6727d68f AM |
111 | |
112 | %build | |
4342a6d9 JB |
113 | %{__libtoolize} |
114 | %{__aclocal} | |
115 | %{__autoconf} | |
116 | %{__autoheader} | |
117 | %{__automake} | |
6727d68f | 118 | %configure \ |
7a09d427 | 119 | --with-html-dir=%{_gtkdocdir} \ |
23049034 | 120 | --with-pam-include=system-auth \ |
6727d68f | 121 | --with-pam-module-dir=/%{_lib}/security |
e7d78954 | 122 | %{__make} -j1 |
6727d68f AM |
123 | |
124 | %install | |
125 | rm -rf $RPM_BUILD_ROOT | |
126 | ||
e7d78954 | 127 | %{__make} -j1 install \ |
6727d68f AM |
128 | DESTDIR=$RPM_BUILD_ROOT |
129 | ||
183aac36 | 130 | rm -f $RPM_BUILD_ROOT%{_libdir}/PolicyKit/modules/*.{la,a} |
7a09d427 | 131 | |
6727d68f AM |
132 | %clean |
133 | rm -rf $RPM_BUILD_ROOT | |
134 | ||
4813e2b2 | 135 | %triggerun -- PolicyKit < 0.3 |
183aac36 JB |
136 | %service -q PolicyKit stop |
137 | /sbin/chkconfig --del PolicyKit | |
138 | ||
c0001c5d PZ |
139 | %pre |
140 | %groupadd -g 220 polkituser | |
141 | %useradd -u 220 -d %{_datadir}/empty -c "PolicyKit User" -g polkituser polkituser | |
142 | ||
4813e2b2 JB |
143 | %post |
144 | umask 022 | |
145 | touch /var/lib/misc/PolicyKit.reload | |
146 | chown root:polkituser /var/lib/misc/PolicyKit.reload | |
147 | chmod 664 /var/lib/misc/PolicyKit.reload | |
148 | ||
c0001c5d PZ |
149 | %postun |
150 | if [ "$1" = "0" ]; then | |
151 | %userremove polkituser | |
152 | %groupremove polkituser | |
153 | fi | |
154 | ||
4342a6d9 JB |
155 | %post libs -p /sbin/ldconfig |
156 | %postun libs -p /sbin/ldconfig | |
6727d68f AM |
157 | |
158 | %files | |
159 | %defattr(644,root,root,755) | |
27dd9833 | 160 | %doc AUTHORS README doc/TODO |
4813e2b2 JB |
161 | %attr(755,root,root) %{_bindir}/polkit-action |
162 | %attr(755,root,root) %{_bindir}/polkit-auth | |
163 | %attr(755,root,root) %{_bindir}/polkit-config-file-validate | |
164 | %attr(755,root,root) %{_bindir}/polkit-policy-file-validate | |
1df708eb | 165 | %dir %{_libexecdir} |
4813e2b2 | 166 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-explicit-grant-helper |
1df708eb | 167 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-grant-helper |
4813e2b2 JB |
168 | %attr(4754,root,polkituser) %{_libexecdir}/polkit-grant-helper-pam |
169 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-read-auth-helper | |
170 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-revoke-helper | |
171 | %attr(2755,root,polkituser) %{_libexecdir}/polkit-set-default-helper | |
172 | %attr(755,root,root) %{_libexecdir}/polkitd | |
5623b4a4 | 173 | %dir %{_sysconfdir}/PolicyKit |
174 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/PolicyKit/PolicyKit.conf | |
4813e2b2 | 175 | /etc/dbus-1/system.d/org.freedesktop.PolicyKit.conf |
183aac36 | 176 | /etc/pam.d/polkit |
4813e2b2 JB |
177 | %{_datadir}/PolicyKit |
178 | %{_datadir}/dbus-1/interfaces/org.freedesktop.PolicyKit.AuthenticationAgent.xml | |
179 | %{_datadir}/dbus-1/system-services/org.freedesktop.PolicyKit.service | |
180 | %attr(664,root,polkituser) %ghost /var/lib/misc/PolicyKit.reload | |
181 | %attr(770,root,polkituser) /var/lib/PolicyKit | |
182 | %attr(775,root,polkituser) /var/lib/PolicyKit-public | |
183 | %attr(770,root,polkituser) /var/run/PolicyKit | |
184 | %{_mandir}/man1/polkit-action.1* | |
185 | %{_mandir}/man1/polkit-auth.1* | |
5623b4a4 | 186 | %{_mandir}/man1/polkit-config-file-validate.1* |
5623b4a4 | 187 | %{_mandir}/man1/polkit-policy-file-validate.1* |
188 | %{_mandir}/man5/PolicyKit.conf.5* | |
189 | %{_mandir}/man8/PolicyKit.8* | |
190 | ||
27dd9833 PZ |
191 | %files apidocs |
192 | %defattr(644,root,root,755) | |
193 | %{_gtkdocdir}/polkit | |
6727d68f | 194 | |
4342a6d9 JB |
195 | %files libs |
196 | %defattr(644,root,root,755) | |
183aac36 JB |
197 | # notes which license applies to which package part, AFL text (and GPL text copy) |
198 | %doc COPYING | |
4342a6d9 | 199 | %attr(755,root,root) %{_libdir}/libpolkit.so.*.*.* |
4813e2b2 | 200 | %attr(755,root,root) %ghost %{_libdir}/libpolkit.so.2 |
27dd9833 | 201 | %attr(755,root,root) %{_libdir}/libpolkit-dbus.so.*.*.* |
4813e2b2 | 202 | %attr(755,root,root) %ghost %{_libdir}/libpolkit-dbus.so.2 |
183aac36 | 203 | %attr(755,root,root) %{_libdir}/libpolkit-grant.so.*.*.* |
4813e2b2 | 204 | %attr(755,root,root) %ghost %{_libdir}/libpolkit-grant.so.2 |
4342a6d9 | 205 | |
6727d68f AM |
206 | %files devel |
207 | %defattr(644,root,root,755) | |
183aac36 JB |
208 | %attr(755,root,root) %{_libdir}/libpolkit.so |
209 | %attr(755,root,root) %{_libdir}/libpolkit-dbus.so | |
210 | %attr(755,root,root) %{_libdir}/libpolkit-grant.so | |
211 | %{_libdir}/libpolkit.la | |
212 | %{_libdir}/libpolkit-dbus.la | |
213 | %{_libdir}/libpolkit-grant.la | |
27dd9833 | 214 | %{_includedir}/PolicyKit |
4342a6d9 | 215 | %{_pkgconfigdir}/polkit.pc |
27dd9833 PZ |
216 | %{_pkgconfigdir}/polkit-dbus.pc |
217 | %{_pkgconfigdir}/polkit-grant.pc | |
6727d68f AM |
218 | |
219 | %files static | |
220 | %defattr(644,root,root,755) | |
183aac36 JB |
221 | %{_libdir}/libpolkit.a |
222 | %{_libdir}/libpolkit-dbus.a | |
223 | %{_libdir}/libpolkit-grant.a |