- rel 5; build fixed
[packages/sssd.git] / sssd.spec
CommitLineData
dacaa562
ER
1# TODO
2# - fix stripping before rpm:
3# *** WARNING: no sources found for /usr/lib64/libipa_hbac.so.0.0.0 (stripped without sourcefile information?)
3ae68d1d 4# - add info how sssd-heimdal.patch is updated, where is it's origin?
e1f3ee2a
ER
5#
6# Conditional build:
66c0dc33 7%bcond_with tests # check target
e1f3ee2a 8%bcond_without python2 # CPython 2.x module
66c0dc33
JB
9%bcond_without python3 # CPython 3.x module
10%bcond_with krb5 # MIT Kerberos V instead of Heimdal (enables locator plugin, profile support and pac-responder)
e1f3ee2a 11
599b73f3
ER
12%define ldb_version 1.1.0
13Summary: System Security Services Daemon
dd3b701a 14Summary(pl.UTF-8): System Security Services Daemon - demon usług bezpieczeństwa systemu
599b73f3 15Name: sssd
e1f3ee2a 16Version: 1.13.4
1dbfdfbe 17Release: 5
599b73f3
ER
18License: GPL v3+
19Group: Applications/System
599b73f3 20Source0: https://fedorahosted.org/released/sssd/%{name}-%{version}.tar.gz
e1f3ee2a 21# Source0-md5: d147e0a4f4719d993693c6a99370b350
dacaa562 22Source1: %{name}.init
66c0dc33 23Patch0: %{name}-python.patch
2713c68f 24Patch1: %{name}-heimdal.patch
38af2cc5 25Patch2: %{name}-systemd.patch
7168e7f9 26Patch3: %{name}-link.patch
1dbfdfbe 27Patch4: format.patch
dd3b701a 28URL: https://fedorahosted.org/sssd/
3278078b 29BuildRequires: augeas-devel >= 1.0.0
dd3b701a 30BuildRequires: autoconf >= 2.59
599b73f3 31BuildRequires: automake
dd3b701a 32# nsupdate utility
599b73f3
ER
33BuildRequires: bind-utils
34BuildRequires: c-ares-devel
dd3b701a 35BuildRequires: check-devel >= 0.9.5
3278078b 36BuildRequires: cifs-utils-devel
66c0dc33 37%{?with_tests:BuildRequires: cmocka-devel >= 1.0.0}
dd3b701a
JB
38BuildRequires: cyrus-sasl-devel >= 2
39BuildRequires: dbus-devel >= 1.0.0
2713c68f 40BuildRequires: docbook-dtd44-xml
599b73f3
ER
41BuildRequires: docbook-style-xsl
42BuildRequires: doxygen
66c0dc33 43%{?with_tests:BuildRequires: fakeroot}
e1f3ee2a 44BuildRequires: gettext-tools >= 0.14.4
dd3b701a 45BuildRequires: glib2-devel >= 2.0
66c0dc33 46%{!?with_krb5:BuildRequires: heimdal-devel}
2713c68f 47BuildRequires: keyutils-devel
66c0dc33
JB
48%{?with_krb5:BuildRequires: krb5-devel >= 1.9}
49BuildRequires: ldb-devel >= %{ldb_version}
dd3b701a 50BuildRequires: libcollection-devel >= 0.5.1
4d07ac90 51BuildRequires: libdhash-devel >= 0.4.2
66c0dc33 52BuildRequires: libini_config-devel >= 1.1.0
6c14d591 53BuildRequires: libltdl-devel
7168e7f9 54BuildRequires: libnfsidmap-devel
dd3b701a 55BuildRequires: libnl-devel >= 3.2
599b73f3
ER
56BuildRequires: libselinux-devel
57BuildRequires: libsemanage-devel
66c0dc33 58BuildRequires: libsmbclient-devel
7168e7f9 59BuildRequires: libtool >= 2:2
dd3b701a
JB
60BuildRequires: libxml2-progs
61BuildRequires: libxslt-progs
599b73f3 62BuildRequires: m4
599b73f3
ER
63BuildRequires: nspr-devel
64BuildRequires: nss-devel
66c0dc33 65%{?with_tests:BuildRequires: nss_wrapper}
599b73f3
ER
66BuildRequires: openldap-devel
67BuildRequires: pam-devel
dd3b701a 68BuildRequires: pcre-devel >= 7
6c14d591 69BuildRequires: pkgconfig
dd3b701a 70BuildRequires: po4a
599b73f3 71BuildRequires: popt-devel
66c0dc33
JB
72%{?with_python2:BuildRequires: python-devel >= 1:2.6}
73%{?with_tests:BuildRequires: python-pytest}
74%{?with_python3:BuildRequires: python3-devel >= 1:3.3}
6c14d591 75BuildRequires: rpm-pythonprov
66c0dc33
JB
76BuildRequires: rpmbuild(macros) >= 1.612
77# pkgconfig(ndr_nbt), pkgconfig(ndr_krb5pac) if with krb5
dd3b701a 78BuildRequires: samba-devel >= 4
66c0dc33 79BuildRequires: systemd-devel >= 1:209
dd3b701a
JB
80BuildRequires: systemd-units
81BuildRequires: talloc-devel
82BuildRequires: tdb-devel >= 1.1.3
59928269 83BuildRequires: tevent-devel
66c0dc33 84%{?with_tests:BuildRequires: uid_wrapper}
a256e3fe 85Requires(post): /sbin/ldconfig
2713c68f 86Requires(post,preun): /sbin/chkconfig
59928269 87Requires: %{name}-client = %{version}-%{release}
599b73f3 88Requires: cyrus-sasl-gssapi
dd3b701a 89Requires: ldb >= %{ldb_version}
66c0dc33
JB
90Requires: libcollection >= 0.5.1
91Requires: libdhash >= 0.4.2
92Requires: libini_config >= 1.1.0
dd3b701a 93Requires: libsss_idmap = %{version}-%{release}
66c0dc33 94Requires: pcre >= 7
70b8a086 95Requires: rc-scripts >= 0.4.0.10
4d07ac90 96Requires: tdb >= 1.1.3
599b73f3
ER
97BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
98
dd3b701a 99%define sssdstatedir %{_localstatedir}/lib/sss
599b73f3
ER
100%define dbpath %{sssdstatedir}/db
101%define pipepath %{sssdstatedir}/pipes
102%define pubconfpath %{sssdstatedir}/pubconf
103
104# Determine the location of the LDB modules directory
105%define ldb_modulesdir %(pkg-config --variable=modulesdir ldb)
106
107%description
108Provides a set of daemons to manage access to remote directories and
109authentication mechanisms. It provides an NSS and PAM interface toward
110the system and a pluggable backend system to connect to multiple
111different account sources. It is also the basis to provide client
112auditing and policy services for projects like FreeIPA.
113
dd3b701a
JB
114%description -l pl.UTF-8
115Ten pakiet dostarcza zbiór demonów do zarządzania dostępem do zdalnych
116katalogów i mechanizmów uwierzytelniania. Udostępnia interfejsy NSS i
117PAM dla systemu oraz system backendu z wtyczkami w celu łączenia się z
118wieloma różnymi źródłami kont. Jest także podstawą zapewniającą audyt
119klientów oraz usługi polityk dla projektów takich jak FreeIPA.
120
599b73f3
ER
121%package client
122Summary: SSSD Client libraries for NSS and PAM
dd3b701a
JB
123Summary(pl.UTF-8): Biblioteki klienckie SSSD dla NSS i PAM
124License: LGPL v3+
599b73f3 125Group: Applications/System
66c0dc33
JB
126Requires: libsss_idmap = %{version}-%{release}
127Requires: libsss_nss_idmap = %{version}-%{release}
599b73f3
ER
128
129%description client
130Provides the libraries needed by the PAM and NSS stacks to connect to
131the SSSD service.
132
dd3b701a
JB
133%description client -l pl.UTF-8
134Ten pakiet dostarcza biblioteki wymagane przez stosy PAM i NSS w celu
135łączenia się z usługą SSSD.
136
599b73f3
ER
137%package tools
138Summary: Userspace tools for use with the SSSD
dd3b701a 139Summary(pl.UTF-8): Narzędzia przestrzeni użytkownika do używania z SSSD
599b73f3
ER
140License: GPL v3+
141Group: Applications/System
142Requires: %{name} = %{version}-%{release}
143
144%description tools
145Provides userspace tools for manipulating users, groups, and nested
146groups in SSSD when using id_provider = local in /etc/sssd/sssd.conf.
147
dd3b701a
JB
148Also provides several other administrative tools:
149 - sss_debuglevel to change the debug level on the fly,
150 - sss_seed which pre-creates a user entry for use in kickstarts,
151 - sss_obfuscate for generating an obfuscated LDAP password.
152
153%description tools -l pl.UTF-8
154Ten pakiet dostarcza narzędzia przestrzeni poleceń do operowania na
155użytkownikach, grupach oraz zagnieżdżonych grupach w SSSD w przypadku
156używania id_provider = local w /etc/sssd/sssd.conf.
157
158Pakiet zawiera także kilka innych narzędzi administracyjnych:
159 - sss_debuglevel do zmiany poziomu diagnostyki w locie,
160 - sss_seed tworzący wpis użytkownika do szybkiego rozruchu,
161 - sss_obfuscate do generowania utajnionego hasła LDAP.
599b73f3 162
66c0dc33
JB
163%package -n python-sss
164Summary: Python 2 bindings for sssd
165Summary(pl.UTF-8): Wiązania Pythona 2 do sssd
166License: LGPL v3+
167Group: Libraries/Python
168Requires: %{name} = %{version}-%{release}
169
170%description -n python-sss
171Python 2 module for manipulating users, groups, and nested groups in
172SSSD when using id_provider = local in /etc/sssd/sssd.conf.
173
174This module also provides several other useful Python 2 bindings:
175 - function for retrieving list of groups user belongs to.
176 - class for obfuscation of passwords
177
178%description -n python-sss -l pl.UTF-8
179Moduł Pythona 2 do operowania na użytkownikach, grupach i
180zagnieżdżonych grupach w SSSD w przypadku używania id_provider = local
181w /etc/sssd/sssd.conf.
182
183Ten moduł dostarcza także kilka innych przydatnych wiązań Pythona 2:
184 - funkcję do użyskiwania list grup, do których należy użytkownik,
185 - klasę do ukrywania haseł.
186
187%package -n python-sss-murmur
188Summary: Python 2 bindings for murmur hash function
189Summary(pl.UTF-8): Wiązania Pythona 2 do funkcji mieszającej murmur
190License: LGPL v3+
191Group: Libraries/Python
192
193%description -n python-sss-murmur
194Python 2 module for calculating the murmur hash version 3.
195
196%description -n python-sss-murmur -l pl.UTF-8
197Moduł Pythona 2 do obliczania skrótu murmur w wersji 3.
198
199%package -n python-sssdconfig
200Summary: SSSD and IPA configuration file manipulation classes and functions for Python 2
201Summary(pl.UTF-8): Klasy i funkcje Pythona 2 do operowania na plikach konfiguracyjnych SSSD oraz IPA
202License: GPL v3+
203Group: Libraries/Python
204BuildArch: noarch
205
206%description -n python-sssdconfig
207SSSD and IPA configuration file manipulation classes and functions for
208Python 2.
209
210%description -n python-sssdconfig -l pl.UTF-8
211Klasy i funkcje Pythona 2 do operowania na plikach konfiguracyjnych
212SSSD oraz IPA.
213
214%package -n python3-sss
215Summary: Python 3 bindings for sssd
216Summary(pl.UTF-8): Wiązania Pythona 3 do sssd
217License: LGPL v3+
218Group: Libraries/Python
219Requires: %{name} = %{version}-%{release}
220
221%description -n python3-sss
222Python 3 module for manipulating users, groups, and nested groups in
223SSSD when using id_provider = local in /etc/sssd/sssd.conf.
224
225This module also provides several other useful Python 3 bindings:
226 - function for retrieving list of groups user belongs to.
227 - class for obfuscation of passwords
228
229%description -n python3-sss -l pl.UTF-8
230Moduł Pythona 3 do operowania na użytkownikach, grupach i
231zagnieżdżonych grupach w SSSD w przypadku używania id_provider = local
232w /etc/sssd/sssd.conf.
233
234Ten moduł dostarcza także kilka innych przydatnych wiązań Pythona 3:
235 - funkcję do użyskiwania list grup, do których należy użytkownik,
236 - klasę do ukrywania haseł.
237
238%package -n python3-sss-murmur
239Summary: Python 3 bindings for murmur hash function
240Summary(pl.UTF-8): Wiązania Pythona 3 do funkcji mieszającej murmur
241License: LGPL v3+
242Group: Libraries/Python
243
244%description -n python3-sss-murmur
245Python 3 module for calculating the murmur hash version 3.
246
247%description -n python3-sss-murmur -l pl.UTF-8
248Moduł Pythona 3 do obliczania skrótu murmur w wersji 3.
249
250%package -n python3-sssdconfig
251Summary: SSSD and IPA configuration file manipulation classes and functions for Python 3
252Summary(pl.UTF-8): Klasy i funkcje Pythona 3 do operowania na plikach konfiguracyjnych SSSD oraz IPA
253License: GPL v3+
254Group: Libraries/Python
255BuildArch: noarch
256
257%description -n python3-sssdconfig
258SSSD and IPA configuration file manipulation classes and functions for
259Python 3.
260
261%description -n python3-sssdconfig -l pl.UTF-8
262Klasy i funkcje Pythona 3 do operowania na plikach konfiguracyjnych
263SSSD oraz IPA.
264
7168e7f9
JB
265%package libwbclient
266Summary: The SSSD libwbclient implementation
267Summary(pl.UTF-8): Implementacja libwbclient oparta na SSSD
268Group: Libraries
269License: LGPL v3+
270Requires: libsss_nss_idmap = %{version}-%{release}
271
272%description libwbclient
273The SSSD implementation of Samba wbclient library.
274
275%description libwbclient -l pl.UTF-8
276Implementacja biblioteki Samba wbclient oparta na SSSD.
277
278%package libwbclient-devel
279Summary: Development files of the SSSD libwbclient implementation
280Summary(pl.UTF-8): Pliki programistyczne implementacja libwbclient oparta na SSSD
281Group: Development/Libraries
282License: LGPL v3+
283Requires: %{name}-libwbclient = %{version}-%{release}
284
285%description libwbclient-devel
286Development files for the SSSD implementation of Samba wbclient
287library.
288
289%description libwbclient-devel -l pl.UTF-8
290Pliki programistyczne implementacji biblioteki Samba wbclient opartej
291na SSSD.
292
599b73f3
ER
293%package -n libipa_hbac
294Summary: FreeIPA HBAC Evaluator library
dd3b701a
JB
295Summary(pl.UTF-8): Biblioteka oceniająca FreeIPA HBAC
296License: LGPL v3+
297Group: Libraries
599b73f3
ER
298
299%description -n libipa_hbac
300Utility library to validate FreeIPA HBAC rules for authorization
dd3b701a
JB
301requests.
302
303%description -n libipa_hbac
304Biblioteka narzędziowa do sprawdzania poprawności reguł FreeIPA HBAC
305dla żądań autoryzacji.
599b73f3
ER
306
307%package -n libipa_hbac-devel
dd3b701a
JB
308Summary: Development files for FreeIPA HBAC Evaluator library
309Summary(pl.UTF-8): Pliki programistyczne biblioteki oceniająca FreeIPA HBAC
310License: LGPL v3+
599b73f3
ER
311Group: Development/Libraries
312Requires: libipa_hbac = %{version}-%{release}
313
314%description -n libipa_hbac-devel
dd3b701a
JB
315Development files for FreeIPA HBAC Evaluator library.
316
317%description -n libipa_hbac-devel -l pl.UTF-8
318Pliki programistyczne biblioteki oceniająca FreeIPA HBAC.
599b73f3
ER
319
320%package -n python-libipa_hbac
66c0dc33
JB
321Summary: Python 2 bindings for the FreeIPA HBAC Evaluator library
322Summary(pl.UTF-8): Wiązania Pythona 2 do biblioteki oceniającej FreeIPA HBAC
dd3b701a
JB
323License: LGPL v3+
324Group: Libraries/Python
599b73f3
ER
325Requires: libipa_hbac = %{version}-%{release}
326Obsoletes: libipa_hbac-python
327
328%description -n python-libipa_hbac
329This package contains the bindings so that libipa_hbac can be used by
66c0dc33 330Python 2 applications.
599b73f3 331
dd3b701a
JB
332%description -n python-libipa_hbac -l pl.UTF-8
333Ten pakiet zawiera wiązania pozwalające na używanie libipa_hbac w
66c0dc33
JB
334aplikacjach Pythona 2.
335
336%package -n python3-libipa_hbac
337Summary: Python 3 bindings for the FreeIPA HBAC Evaluator library
338Summary(pl.UTF-8): Wiązania Pythona 3 do biblioteki oceniającej FreeIPA HBAC
339License: LGPL v3+
340Group: Libraries/Python
341Requires: libipa_hbac = %{version}-%{release}
342
343%description -n python3-libipa_hbac
344This package contains the bindings so that libipa_hbac can be used by
345Python 3 applications.
346
347%description -n python3-libipa_hbac -l pl.UTF-8
348Ten pakiet zawiera wiązania pozwalające na używanie libipa_hbac w
349aplikacjach Pythona 3.
dd3b701a
JB
350
351%package -n libsss_idmap
352Summary: FreeIPA Idmap library
353Summary(pl.UTF-8): Biblioteka FreeIPA Idmap
354Group: Libraries
355License: LGPL v3+
356
357%description -n libsss_idmap
358Utility library to convert SIDs to Unix uids and gids.
359
360%description -n libsss_idmap -l pl.UTF-8
361Biblioteka narzędziowa konwertująca SID-y na uniksowe uidy i gidy.
362
363%package -n libsss_idmap-devel
364Summary: Development files for FreeIPA Idmap library
365Summary(pl.UTF-8): Pliki programistyczne biblioteki FreeIPA Idmap
366Group: Development/Libraries
367License: LGPL v3+
368Requires: libsss_idmap = %{version}-%{release}
369
370%description -n libsss_idmap-devel
371Development files for FreeIPA Idmap library.
372
373%description -n libsss_idmap-devel -l pl.UTF-8
374Pliki programistyczne biblioteki FreeIPA Idmap.
375
376%package -n libsss_nss_idmap
377Summary: Library for SID based lookups
378Summary(pl.UTF-8): Biblioteka do wyszukiwań w oparciu o SID
379Group: Libraries
380License: LGPL v3+
381
382%description -n libsss_nss_idmap
383Utility library for SID based lookups.
384
385%description -n libsss_nss_idmap -l pl.UTF-8
386Biblioteka do wyszukiwań w oparciu o SID.
387
388%package -n libsss_nss_idmap-devel
389Summary: Development files for sss_nss_idmap library
390Summary(pl.UTF-8): Pliki programistyczne biblioteki sss_nss_idmap
391Group: Development/Libraries
392License: LGPL v3+
393Requires: libsss_nss_idmap = %{version}-%{release}
394
395%description -n libsss_nss_idmap-devel
396Development files for sss_nss_idmap library.
397
398%description -n libsss_nss_idmap-devel -l pl.UTF-8
399Pliki programistyczne biblioteki sss_nss_idmap.
400
401%package -n python-libsss_nss_idmap
66c0dc33
JB
402Summary: Python 2 bindings for libsss_nss_idmap
403Summary(pl.UTF-8): Wiązania Pythona 2 do biblioteki libsss_nss_idmap
dd3b701a
JB
404Group: Libraries/Python
405License: LGPL v3+
406Requires: libsss_nss_idmap = %{version}-%{release}
407
408%description -n python-libsss_nss_idmap
409This package contains the bindings so that libsss_nss_idmap can be
66c0dc33 410used by Python 2 applications.
dd3b701a
JB
411
412%description -n python-libsss_nss_idmap -l pl.UTF-8
413Ten pakiet zawiera wiązania umożliwiające korzystanie z biblioteki
66c0dc33
JB
414libsss_nss_idmap w aplikacjach Pythona 2.
415
416%package -n python3-libsss_nss_idmap
417Summary: Python 3 bindings for libsss_nss_idmap
418Summary(pl.UTF-8): Wiązania Pythona 3 do biblioteki libsss_nss_idmap
419Group: Libraries/Python
420License: LGPL v3+
421Requires: libsss_nss_idmap = %{version}-%{release}
422
423%description -n python3-libsss_nss_idmap
424This package contains the bindings so that libsss_nss_idmap can be
425used by Python 3 applications.
426
427%description -n python3-libsss_nss_idmap -l pl.UTF-8
428Ten pakiet zawiera wiązania umożliwiające korzystanie z biblioteki
429libsss_nss_idmap w aplikacjach Pythona 3.
dd3b701a 430
3278078b
JB
431%package -n libsss_simpleifp
432Summary: A library that simplifies work with the InfoPipe responder
433Summary(pl.UTF-8): Biblioteka upraszczająca pracę z responderem InfoPipe
434Group: Libraries
435Requires: dbus-libs >= 1.0.0
436Requires: libdhash >= 0.4.2
437
438%description -n libsss_simpleifp
439A library that simplifies work with the InfoPipe responder.
440
441%description -n libsss_simpleifp -l pl.UTF-8
442Biblioteka upraszczająca pracę z responderem InfoPipe.
443
444%package -n libsss_simpleifp-devel
445Summary: Header files for libsss_simpleifp library
446Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libsss_simpleifp
447Group: Development/Libraries
448Requires: dbus-devel >= 1.0.0
449Requires: libdhash-devel >= 0.4.2
450Requires: libsss_simpleifp = %{version}-%{release}
451
452%description -n libsss_simpleifp-devel
453Header files for libsss_simpleifp library.
454
455%description -n libsss_simpleifp-devel -l pl.UTF-8
456Pliki nagłówkowe biblioteki libsss_simpleifp.
457
599b73f3
ER
458%prep
459%setup -q
66c0dc33 460%patch0 -p1
7168e7f9 461%patch1 -p1
38af2cc5 462%patch2 -p1
7168e7f9 463%patch3 -p1
1dbfdfbe 464%patch4 -p1
599b73f3
ER
465
466%build
dacaa562 467%{__libtoolize}
2713c68f 468%{__gettextize}
66c0dc33 469%{__aclocal} -I m4
2713c68f 470%{__autoconf}
66c0dc33 471%{__automake}
599b73f3 472%configure \
dd3b701a 473 NSCD=/usr/sbin/nscd \
66c0dc33 474 %{!?with_krb5:--disable-krb5-locator-plugin} \
7168e7f9
JB
475 --enable-nfsidmaplibdir=/%{_lib}/libnfsidmap \
476 --enable-nsslibdir=/%{_lib} \
66c0dc33 477 %{!?with_krb5:--disable-pac-responder} \
7168e7f9
JB
478 --enable-pammoddir=/%{_lib}/security \
479 --disable-rpath \
599b73f3 480 --with-db-path=%{dbpath} \
7168e7f9 481 --with-init-dir=/etc/rc.d/init.d \
38af2cc5 482 --with-initscript=sysv,systemd \
599b73f3
ER
483 --with-pipe-path=%{pipepath} \
484 --with-pubconf-path=%{pubconfpath} \
66c0dc33
JB
485 --with-python2-bindings%{!?with_python2:=no} \
486 --with-python3-bindings%{!?with_python3:=no} \
38af2cc5 487 --with-systemdunitdir=%{systemdunitdir} \
599b73f3
ER
488 --with-test-dir=/dev/shm
489
490%{__make}
491
492%if %{with tests}
493export CK_TIMEOUT_MULTIPLIER=10
494%{__make} check
495unset CK_TIMEOUT_MULTIPLIER
496%endif
497
498%install
499rm -rf $RPM_BUILD_ROOT
66c0dc33
JB
500
501%{__make} -j1 install \
502 DESTDIR=$RPM_BUILD_ROOT \
503 python3dir=%{py3_sitescriptdir}
599b73f3
ER
504
505# Prepare language files
506%find_lang %{name}
507
508# Copy default sssd.conf file
dd3b701a
JB
509install -d $RPM_BUILD_ROOT%{_sysconfdir}/sssd/sssd.api.d
510cp -p src/examples/sssd-example.conf $RPM_BUILD_ROOT%{_sysconfdir}/sssd/sssd.conf
599b73f3
ER
511
512# Copy default logrotate file
513install -d $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d
514cp -p src/examples/logrotate $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/sssd
515
516# Make sure SSSD is able to run on read-only root
dacaa562 517install -d $RPM_BUILD_ROOT%{_sysconfdir}/rwtab.d
37fed748 518#cp -p src/examples/rwtab $RPM_BUILD_ROOT%{_sysconfdir}/rwtab.d/sssd
599b73f3 519
4d07ac90 520# Remove .la files created by libtool
521%{__rm} \
dd3b701a 522 $RPM_BUILD_ROOT/%{_lib}/libnss_sss.la \
7168e7f9 523 $RPM_BUILD_ROOT/%{_lib}/libnfsidmap/sss.la \
dd3b701a
JB
524 $RPM_BUILD_ROOT/%{_lib}/security/pam_sss.la \
525 $RPM_BUILD_ROOT%{ldb_modulesdir}/memberof.la \
3278078b 526 $RPM_BUILD_ROOT%{_libdir}/cifs-utils/*.la \
66c0dc33 527 %{?with_krb5:$RPM_BUILD_ROOT%{_libdir}/krb5/plugins/libkrb5/sss*.la} \
dd3b701a 528 $RPM_BUILD_ROOT%{_libdir}/sssd/libsss_*.la \
7168e7f9 529 $RPM_BUILD_ROOT%{_libdir}/sssd/modules/lib*.la \
66c0dc33
JB
530 $RPM_BUILD_ROOT%{_libdir}/lib*.la
531%if %{with python2}
532%{__rm} $RPM_BUILD_ROOT%{py_sitedir}/*.la
533%py_postclean
534%endif
535%if %{with python3}
536%{__rm} $RPM_BUILD_ROOT%{py3_sitedir}/*.la
537%endif
599b73f3 538
2713c68f
ER
539install -p %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
540
dd3b701a
JB
541echo '%%defattr(644,root,root,755)' > sssd_client.lang
542echo '%%defattr(644,root,root,755)' > sssd_tools.lang
dacaa562
ER
543for man in $(find $RPM_BUILD_ROOT%{_mandir}/??/man? -type f | sed -e "s#$RPM_BUILD_ROOT%{_mandir}/##"); do
544 lang=$(echo $man | cut -c 1-2)
545 case $(basename $man) in
dd3b701a
JB
546 pam_sss.8|sssd_krb5_locator_plugin.8)
547 echo "%lang(${lang}) %{_mandir}/${man}*" >> sssd_client.lang
548 ;;
549 sss_debuglevel.8|sss_group*.8|sss_obfuscate.8|sss_seed.8|sss_user*.8)
dacaa562
ER
550 echo "%lang(${lang}) %{_mandir}/${man}*" >> sssd_tools.lang
551 ;;
552 *)
553 echo "%lang(${lang}) %{_mandir}/${man}*" >> sssd.lang
599b73f3 554 ;;
599b73f3
ER
555 esac
556done
557
558%clean
559rm -rf $RPM_BUILD_ROOT
560
561%post
562/sbin/ldconfig
563/sbin/chkconfig --add %{name}
564%service %{name} restart
565
566%preun
567if [ "$1" = "0" ]; then
568 %service -q %{name} stop
569 /sbin/chkconfig --del %{name}
570fi
571
dd3b701a
JB
572%postun -p /sbin/ldconfig
573
599b73f3
ER
574%post client -p /sbin/ldconfig
575%postun client -p /sbin/ldconfig
576
577%post -n libipa_hbac -p /sbin/ldconfig
578%postun -n libipa_hbac -p /sbin/ldconfig
579
dd3b701a
JB
580%post -n libsss_idmap -p /sbin/ldconfig
581%postun -n libsss_idmap -p /sbin/ldconfig
582
583%post -n libsss_nss_idmap -p /sbin/ldconfig
584%postun -n libsss_nss_idmap -p /sbin/ldconfig
585
3278078b
JB
586%post -n libsss_simpleifp -p /sbin/ldconfig
587%postun -n libsss_simpleifp -p /sbin/ldconfig
588
599b73f3
ER
589%files -f sssd.lang
590%defattr(644,root,root,755)
dd3b701a
JB
591%attr(755,root,root) %{_bindir}/sss_ssh_authorizedkeys
592%attr(755,root,root) %{_bindir}/sss_ssh_knownhostsproxy
593%attr(755,root,root) %{_sbindir}/sss_cache
599b73f3 594%attr(755,root,root) %{_sbindir}/sssd
66c0dc33 595# sudo plugin
dd3b701a
JB
596%attr(755,root,root) %{_libdir}/libsss_sudo.so
597%dir %{_libdir}/sssd
598# internal shared libraries
66c0dc33 599%attr(755,root,root) %{_libdir}/sssd/libsss_cert.so
dd3b701a 600%attr(755,root,root) %{_libdir}/sssd/libsss_child.so
3278078b 601%attr(755,root,root) %{_libdir}/sssd/libsss_config.so
dd3b701a
JB
602%attr(755,root,root) %{_libdir}/sssd/libsss_crypt.so
603%attr(755,root,root) %{_libdir}/sssd/libsss_debug.so
66c0dc33 604%attr(755,root,root) %{_libdir}/sssd/libsss_krb5_common.so
dd3b701a 605%attr(755,root,root) %{_libdir}/sssd/libsss_ldap_common.so
7168e7f9 606%attr(755,root,root) %{_libdir}/sssd/libsss_semanage.so
dd3b701a
JB
607%attr(755,root,root) %{_libdir}/sssd/libsss_util.so
608# modules
609%attr(755,root,root) %{_libdir}/sssd/libsss_simple.so
610%attr(755,root,root) %{_libdir}/sssd/libsss_ad.so
611%attr(755,root,root) %{_libdir}/sssd/libsss_ipa.so
612%attr(755,root,root) %{_libdir}/sssd/libsss_krb5.so
dd3b701a
JB
613%attr(755,root,root) %{_libdir}/sssd/libsss_ldap.so
614%attr(755,root,root) %{_libdir}/sssd/libsss_proxy.so
615%dir %{_libdir}/sssd/modules
616%attr(755,root,root) %{_libdir}/sssd/modules/libsss_autofs.so
617%if "%{_libdir}" != "%{_libexecdir}"
618%dir %{_libexecdir}/sssd
619%endif
3278078b 620%attr(755,root,root) %{_libexecdir}/sssd/gpo_child
dd3b701a
JB
621%attr(755,root,root) %{_libexecdir}/sssd/krb5_child
622%attr(755,root,root) %{_libexecdir}/sssd/ldap_child
66c0dc33 623%attr(755,root,root) %{_libexecdir}/sssd/p11_child
dd3b701a 624%attr(755,root,root) %{_libexecdir}/sssd/proxy_child
7168e7f9 625%attr(755,root,root) %{_libexecdir}/sssd/selinux_child
3278078b 626%attr(755,root,root) %{_libexecdir}/sssd/sss_signal
dd3b701a
JB
627%attr(755,root,root) %{_libexecdir}/sssd/sssd_autofs
628%attr(755,root,root) %{_libexecdir}/sssd/sssd_be
38af2cc5 629%attr(755,root,root) %{_libexecdir}/sssd/sssd_ifp
dd3b701a 630%attr(755,root,root) %{_libexecdir}/sssd/sssd_nss
66c0dc33
JB
631%if %{with krb5}
632%attr(755,root,root) %{_libexecdir}/sssd/sssd_pac
633%endif
dd3b701a
JB
634%attr(755,root,root) %{_libexecdir}/sssd/sssd_pam
635%attr(755,root,root) %{_libexecdir}/sssd/sssd_ssh
636%attr(755,root,root) %{_libexecdir}/sssd/sssd_sudo
637%dir %{_datadir}/sssd
638%{_datadir}/sssd/sssd.api.conf
639%dir %{_datadir}/sssd/sssd.api.d
640%{_datadir}/sssd/sssd.api.d/sssd-ad.conf
641%{_datadir}/sssd/sssd.api.d/sssd-ipa.conf
642%{_datadir}/sssd/sssd.api.d/sssd-krb5.conf
643%{_datadir}/sssd/sssd.api.d/sssd-ldap.conf
644%{_datadir}/sssd/sssd.api.d/sssd-local.conf
645%{_datadir}/sssd/sssd.api.d/sssd-proxy.conf
646%{_datadir}/sssd/sssd.api.d/sssd-simple.conf
7168e7f9 647%attr(755,root,root) /%{_lib}/libnfsidmap/sss.so
599b73f3
ER
648%attr(755,root,root) %{ldb_modulesdir}/memberof.so
649%dir %{sssdstatedir}
650%attr(700,root,root) %dir %{dbpath}
651%dir %{pipepath}
652%dir %{pubconfpath}
653%attr(700,root,root) %dir %{pipepath}/private
654%attr(750,root,root) %dir %{_var}/log/%{name}
655%attr(700,root,root) %dir %{_sysconfdir}/sssd
dd3b701a
JB
656%attr(600,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/sssd/sssd.conf
657%config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/sssd
37fed748 658#%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rwtab.d/sssd
38af2cc5
JB
659%attr(754,root,root) /etc/rc.d/init.d/sssd
660%{systemdunitdir}/sssd.service
661/etc/dbus-1/system.d/org.freedesktop.sssd.infopipe.conf
3278078b 662%{_datadir}/dbus-1/system-services/org.freedesktop.sssd.infopipe.service
dd3b701a
JB
663%{_mandir}/man1/sss_ssh_authorizedkeys.1*
664%{_mandir}/man1/sss_ssh_knownhostsproxy.1*
7168e7f9 665%{_mandir}/man5/sss_rpcidmapd.5*
599b73f3 666%{_mandir}/man5/sssd.conf.5*
dd3b701a 667%{_mandir}/man5/sssd-ad.5*
38af2cc5 668%{_mandir}/man5/sssd-ifp.5*
599b73f3
ER
669%{_mandir}/man5/sssd-ipa.5*
670%{_mandir}/man5/sssd-krb5.5*
671%{_mandir}/man5/sssd-ldap.5*
672%{_mandir}/man5/sssd-simple.5*
dd3b701a
JB
673%{_mandir}/man5/sssd-sudo.5*
674%{_mandir}/man8/sss_cache.8*
599b73f3 675%{_mandir}/man8/sssd.8*
599b73f3 676
dd3b701a 677%files client -f sssd_client.lang
599b73f3
ER
678%defattr(644,root,root,755)
679%attr(755,root,root) /%{_lib}/libnss_sss.so.2
680%attr(755,root,root) /%{_lib}/security/pam_sss.so
3278078b 681%attr(755,root,root) %{_libdir}/cifs-utils/cifs_idmap_sss.so
66c0dc33
JB
682%if %{with krb5}
683# XXX: verify locations
684%attr(755,root,root) %{_libdir}/krb5/plugins/libkrb5/sssd_krb5_localauth_plugin.so
685%attr(755,root,root) %{_libdir}/krb5/plugins/libkrb5/sssd_krb5_locator_plugin.so
686%attr(755,root,root) %{_libdir}/krb5/plugins/libkrb5/sssd_pac_plugin.so
687%endif
599b73f3
ER
688%{_mandir}/man8/pam_sss.8*
689%{_mandir}/man8/sssd_krb5_locator_plugin.8*
690
dd3b701a 691%files tools -f sssd_tools.lang
599b73f3 692%defattr(644,root,root,755)
dd3b701a 693%attr(755,root,root) %{_sbindir}/sss_debuglevel
599b73f3
ER
694%attr(755,root,root) %{_sbindir}/sss_groupadd
695%attr(755,root,root) %{_sbindir}/sss_groupdel
696%attr(755,root,root) %{_sbindir}/sss_groupmod
697%attr(755,root,root) %{_sbindir}/sss_groupshow
698%attr(755,root,root) %{_sbindir}/sss_obfuscate
66c0dc33 699%attr(755,root,root) %{_sbindir}/sss_override
dd3b701a
JB
700%attr(755,root,root) %{_sbindir}/sss_seed
701%attr(755,root,root) %{_sbindir}/sss_useradd
702%attr(755,root,root) %{_sbindir}/sss_userdel
703%attr(755,root,root) %{_sbindir}/sss_usermod
704%{_mandir}/man8/sss_debuglevel.8*
599b73f3
ER
705%{_mandir}/man8/sss_groupadd.8*
706%{_mandir}/man8/sss_groupdel.8*
707%{_mandir}/man8/sss_groupmod.8*
708%{_mandir}/man8/sss_groupshow.8*
dd3b701a 709%{_mandir}/man8/sss_obfuscate.8*
66c0dc33 710%{_mandir}/man8/sss_override.8*
dd3b701a 711%{_mandir}/man8/sss_seed.8*
599b73f3
ER
712%{_mandir}/man8/sss_useradd.8*
713%{_mandir}/man8/sss_userdel.8*
714%{_mandir}/man8/sss_usermod.8*
599b73f3 715
66c0dc33
JB
716%if %{with python2}
717%files -n python-sss
718%defattr(644,root,root,755)
719%attr(755,root,root) %{py_sitedir}/pysss.so
720
721%files -n python-sss-murmur
722%defattr(644,root,root,755)
723%attr(755,root,root) %{py_sitedir}/pysss_murmur.so
724
725%files -n python-sssdconfig
726%defattr(644,root,root,755)
727%dir %{py_sitescriptdir}/SSSDConfig
728%{py_sitescriptdir}/SSSDConfig/*.py[co]
729%{py_sitescriptdir}/SSSDConfig-%{version}-py*.egg-info
730%endif
731
732%if %{with python3}
733%files -n python3-sss
734%defattr(644,root,root,755)
735%attr(755,root,root) %{py3_sitedir}/pysss.so
736
737%files -n python3-sss-murmur
738%defattr(644,root,root,755)
739%attr(755,root,root) %{py3_sitedir}/pysss_murmur.so
740
741%files -n python3-sssdconfig
742%defattr(644,root,root,755)
743%dir %{py3_sitescriptdir}/SSSDConfig
744%{py3_sitescriptdir}/SSSDConfig/*.py
745%{py3_sitescriptdir}/SSSDConfig/__pycache__
746%{py3_sitescriptdir}/SSSDConfig-%{version}-py*.egg-info
747%endif
748
749%files libwbclient
750%defattr(644,root,root,755)
751%attr(755,root,root) %{_libdir}/sssd/modules/libwbclient.so.*
752
753%files libwbclient-devel
754%defattr(644,root,root,755)
755%attr(755,root,root) %{_libdir}/sssd/modules/libwbclient.so
756%{_includedir}/wbclient_sssd.h
757%{_pkgconfigdir}/wbclient_sssd.pc
758
599b73f3
ER
759%files -n libipa_hbac
760%defattr(644,root,root,755)
dd3b701a
JB
761%attr(755,root,root) %{_libdir}/libipa_hbac.so.*.*.*
762%attr(755,root,root) %ghost %{_libdir}/libipa_hbac.so.0
599b73f3
ER
763
764%files -n libipa_hbac-devel
765%defattr(644,root,root,755)
dd3b701a 766%attr(755,root,root) %{_libdir}/libipa_hbac.so
599b73f3 767%{_includedir}/ipa_hbac.h
599b73f3
ER
768%{_pkgconfigdir}/ipa_hbac.pc
769
66c0dc33 770%if %{with python2}
599b73f3
ER
771%files -n python-libipa_hbac
772%defattr(644,root,root,755)
dd3b701a 773%attr(755,root,root) %{py_sitedir}/pyhbac.so
66c0dc33
JB
774%endif
775
776%if %{with python3}
777%files -n python3-libipa_hbac
778%defattr(644,root,root,755)
779%attr(755,root,root) %{py3_sitedir}/pyhbac.so
780%endif
dd3b701a
JB
781
782%files -n libsss_idmap
783%defattr(644,root,root,755)
784%attr(755,root,root) %{_libdir}/libsss_idmap.so.*.*.*
785%attr(755,root,root) %ghost %{_libdir}/libsss_idmap.so.0
786
787%files -n libsss_idmap-devel
788%defattr(644,root,root,755)
789%attr(755,root,root) %{_libdir}/libsss_idmap.so
790%{_includedir}/sss_idmap.h
791%{_pkgconfigdir}/sss_idmap.pc
792
793%files -n libsss_nss_idmap
794%defattr(644,root,root,755)
795%attr(755,root,root) %{_libdir}/libsss_nss_idmap.so.*.*.*
796%attr(755,root,root) %ghost %{_libdir}/libsss_nss_idmap.so.0
797
798%files -n libsss_nss_idmap-devel
799%defattr(644,root,root,755)
800%attr(755,root,root) %{_libdir}/libsss_nss_idmap.so
801%{_includedir}/sss_nss_idmap.h
802%{_pkgconfigdir}/sss_nss_idmap.pc
803
66c0dc33 804%if %{with python2}
dd3b701a
JB
805%files -n python-libsss_nss_idmap
806%defattr(644,root,root,755)
38af2cc5 807%attr(755,root,root) %{py_sitedir}/pysss_nss_idmap.so
66c0dc33
JB
808%endif
809
810%if %{with python3}
811%files -n python3-libsss_nss_idmap
812%defattr(644,root,root,755)
813%attr(755,root,root) %{py3_sitedir}/pysss_nss_idmap.so
814%endif
3278078b
JB
815
816%files -n libsss_simpleifp
817%defattr(644,root,root,755)
818%attr(755,root,root) %{_libdir}/libsss_simpleifp.so.*.*.*
819%attr(755,root,root) %ghost %{_libdir}/libsss_simpleifp.so.0
820
821%files -n libsss_simpleifp-devel
822%defattr(644,root,root,755)
823%attr(755,root,root) %{_libdir}/libsss_simpleifp.so
824%{_includedir}/sss_sifp.h
825%{_includedir}/sss_sifp_dbus.h
826%{_pkgconfigdir}/sss_simpleifp.pc
This page took 0.268982 seconds and 4 git commands to generate.