[samba4] Fix installation on systems without systemd.

asn asn at fedoraproject.org
Fri Jul 20 16:04:15 UTC 2012


commit f929f85c36a5e1884867f7591208714959e8b628
Author: Andreas Schneider <asn at cryptomilk.org>
Date:   Fri Jul 20 18:03:49 2012 +0200

    Fix installation on systems without systemd.

 samba.conf.tmp |    1 +
 samba4.spec    |   17 ++++++++++++++---
 2 files changed, 15 insertions(+), 3 deletions(-)
---
diff --git a/samba.conf.tmp b/samba.conf.tmp
index 8a29577..2d6d626 100644
--- a/samba.conf.tmp
+++ b/samba.conf.tmp
@@ -1 +1,2 @@
 d /var/run/samba  755 root root
+d /var/run/winbindd  755 root root
diff --git a/samba4.spec b/samba4.spec
index 7ae5aa6..aa1697b 100644
--- a/samba4.spec
+++ b/samba4.spec
@@ -1,4 +1,4 @@
-%define main_release 129
+%define main_release 130
 
 %define samba_version 4.0.0
 %define talloc_version 2.0.7
@@ -228,7 +228,9 @@ and Wireshark to parse IDL and similar protocols
 Summary: Files used by both Samba servers and clients
 Group: Applications/System
 Requires: %{name}-libs = %{samba_depver}
+%if 0%{?fedora} > 15 || 0%{?rhel} > 6
 Requires(post): systemd
+%endif
 
 Conflicts: samba-common < 2:3.9.9
 Provides: samba-common = %{samba_depver}
@@ -249,6 +251,7 @@ packages of Samba.
 Summary: Samba winbind
 Group: Applications/System
 Requires: %{name} = %{samba_depver}
+Requires: samba4-common = %{samba_depver}
 
 Conflicts: samba-winbind < 2:3.9.9
 Provides: samba-winbind = %{samba_depver}
@@ -466,6 +469,7 @@ install -d -m 0755 %{buildroot}/var/lib/samba/sysvol
 install -d -m 0755 %{buildroot}/var/log/samba/old
 install -d -m 0755 %{buildroot}/var/spool/samba
 install -d -m 0755 %{buildroot}/%{_datadir}/swat/using_samba
+install -d -m 0755 %{buildroot}/var/run/samba
 install -d -m 0755 %{buildroot}/var/run/winbindd
 install -d -m 0755 %{buildroot}/%{_libdir}/samba
 install -d -m 0755 %{buildroot}/%{_libdir}/pkgconfig
@@ -656,7 +660,9 @@ exit 0
 
 %post common
 /sbin/ldconfig
+%if 0%{?fedora} > 15 || 0%{?rhel} > 6
 /usr/bin/systemd-tmpfiles --create %{_sysconfdir}/tmpfiles.d/samba.conf
+%endif
 
 %postun common -p /sbin/ldconfig
 
@@ -864,6 +870,8 @@ rm -rf %{buildroot}
 %{_libdir}/libnetapi.so.*
 %{_libdir}/samba/libprinting_migrate.so
 %{_datadir}/samba/codepages
+%ghost %dir /var/run/samba
+%ghost %dir /var/run/winbindd
 %attr(700,root,root) %dir /var/lib/samba/private
 %attr(755,root,root) %dir %{_sysconfdir}/samba
 %config(noreplace) %{_sysconfdir}/samba/smb.conf
@@ -933,7 +941,6 @@ rm -rf %{buildroot}
 %{_libdir}/samba/libnss_info.so
 %{_libdir}/samba/libidmap.so
 %{_sbindir}/winbindd
-%ghost %dir /var/run/winbindd
 %attr(750,root,wbpriv) %dir /var/lib/samba/winbindd_privileged
 %config(noreplace) %{_sysconfdir}/security/pam_winbind.conf
 %if 0%{?fedora} > 15 || 0%{?rhel} > 6
@@ -1285,7 +1292,11 @@ rm -rf %{buildroot}
 %endif # with_libwbclient
 
 %changelog
-* Thu Jul 19 2012 Andreas Schneider <asn at redhat.com> -2:4.0.0-129.beta4
+* Fri Jul 20 2012 - Andreas Schneider <asn at redhat.com> - 2:4.0.0-130.beta4
+- Fix installation on systems without systemd.
+- Make sure we have /var/run/winbindd with systemd.
+
+* Thu Jul 19 2012 Andreas Schneider <asn at redhat.com> - 2:4.0.0-129.beta4
 - Use %%global instead of %%define.
 - Fix building with internal libaries.
 


More information about the scm-commits mailing list