- Update to 4.1.2.
See WHATSNEW.txt from the main tar ball or the samba.changes file for more details. - Let gpg verify execution condition not fail on non SUSE systems. - Add systemd support for post-12.2 systems. OBS-URL: https://build.opensuse.org/package/show/network:samba:STABLE/samba?expand=0&rev=349
This commit is contained in:
committed by
Git OBS Bridge
parent
b67cc8116c
commit
27ee0f2ccd
62
samba.spec
62
samba.spec
@@ -105,10 +105,10 @@ BuildRequires: libxslt1
|
||||
%if 0%{?suse_version} > 1210
|
||||
BuildRequires: libxslt-tools
|
||||
%endif
|
||||
%if %suse_version > 1220
|
||||
%if 0%{?suse_version} > 1220
|
||||
BuildRequires: gpg-offline
|
||||
%endif
|
||||
%define samba_ver 4.1.1
|
||||
%define samba_ver 4.1.2
|
||||
%define samba_ver_suffix %nil
|
||||
%if "%{samba_ver_suffix}" == ""
|
||||
%define samba_source_location http://ftp.samba.org/pub/samba/stable/samba-%{version}.tar.gz
|
||||
@@ -119,7 +119,7 @@ BuildRequires: gpg-offline
|
||||
%endif
|
||||
%define samba_ver_full %{samba_ver}%{samba_ver_suffix}
|
||||
%if 0%{?suse_version} && 0%{?suse_version} < 1111
|
||||
%define guards_symbols pre_1111
|
||||
%define guards_symbols default_passdb_backend
|
||||
%endif
|
||||
%if 0%{?suse_version} && 0%{?suse_version} < 1031
|
||||
%define libsmbclient_name libsmbclient
|
||||
@@ -135,12 +135,12 @@ BuildRequires: gpg-offline
|
||||
%else
|
||||
%define build_make_smp_mflags %{?jobs:-j%jobs}
|
||||
%endif
|
||||
%define SOURCE_TIMESTAMP 3113
|
||||
%define SOURCE_TIMESTAMP 3121
|
||||
%define BRANCH %{version}
|
||||
%global with_mitkrb5 1
|
||||
%global with_dc 0
|
||||
%global with_get_printing_ticket 0
|
||||
Version: 4.1.1
|
||||
Version: 4.1.2
|
||||
Release: 0
|
||||
License: GPL-3.0+
|
||||
Url: http://www.samba.org/
|
||||
@@ -256,6 +256,7 @@ PreReq: %{?insserv_prereq}
|
||||
PreReq: /sbin/chkconfig
|
||||
PreReq: /sbin/ldconfig
|
||||
PreReq: coreutils
|
||||
%{?systemd_requires}
|
||||
Requires: cifs-utils
|
||||
|
||||
%description client
|
||||
@@ -1126,7 +1127,7 @@ Branch: %{BRANCH}
|
||||
|
||||
|
||||
%prep
|
||||
%if %suse_version > 1220
|
||||
%if 0%{?suse_version} > 1220
|
||||
gzip -dc %{SOURCE0} >${RPM_SOURCE_DIR}/%{name}-%{samba_ver_full}.tar
|
||||
%{?gpg_verify: %gpg_verify --keyring %{SOURCE6} %{SOURCE5}}
|
||||
rm ${RPM_SOURCE_DIR}/%{name}-%{samba_ver_full}.tar
|
||||
@@ -1263,7 +1264,11 @@ install -d -m 0755 -p \
|
||||
%{buildroot}/%{_sysconfdir}/security \
|
||||
%{buildroot}/%{_sysconfdir}/slp.reg.d \
|
||||
%{buildroot}/%{CONFIGDIR} \
|
||||
%if 0%{?suse_version} > 1220
|
||||
%{buildroot}/%{_unitdir} \
|
||||
%else
|
||||
%{buildroot}/%{INITDIR} \
|
||||
%endif
|
||||
%{buildroot}/%{_lib}/security \
|
||||
%{buildroot}/sbin \
|
||||
%{buildroot}/%{_includedir} \
|
||||
@@ -1349,11 +1354,21 @@ startScripts="smb nmb winbind"
|
||||
%if 0%{?suse_version} && 0%{?suse_version} < 1221
|
||||
startScripts="${startScripts} %{cifs_init_script}"
|
||||
%endif
|
||||
%if 0%{?suse_version} > 1220
|
||||
for srv_name in nmb smb winbind; do
|
||||
sed -e "s@PIDFile=/run/${srv_name}d.pid@PIDFile=/run/samba/${srv_name}d.pid@g" \
|
||||
-e 's@Type=forking@Type=forking\nEnvironment=KRB5CCNAME=/run/samba/krb5cc_samba@g' \
|
||||
../packaging/systemd/${srv_name}.service \
|
||||
>%{buildroot}/%{_unitdir}/${srv_name}.service
|
||||
ln -s %{_unitdir}/${srv_name}.service %{buildroot}/usr/sbin/rc${srv_name}
|
||||
done
|
||||
%else
|
||||
for script in ${startScripts}; do
|
||||
install -m 0755 "init/${script}${scriptSuffix}" \
|
||||
"%{buildroot}/%{INITDIR}/${script}"
|
||||
ln -s "%{INITDIR}/${script}" "%{buildroot}/%{_sbindir}/rc${script}"
|
||||
done
|
||||
%endif
|
||||
for script in ${startScripts}; do
|
||||
SERVICE_NAME=$( echo "${script}" | tr [:lower:] [:upper:])
|
||||
sed \
|
||||
@@ -1487,13 +1502,27 @@ popd
|
||||
|
||||
%pre
|
||||
getent group ntadmin >/dev/null || groupadd -g 71 -o -r ntadmin || :
|
||||
%if 0%{?suse_version} > 1220
|
||||
%service_add_pre nmb.service smb.service
|
||||
%endif
|
||||
|
||||
%preun
|
||||
%{?stop_on_removal:%{stop_on_removal smb nmb}}
|
||||
%if 0%{?suse_version} > 1220
|
||||
%service_del_preun nmb.service smb.service
|
||||
%endif
|
||||
|
||||
%post
|
||||
%if 0%{?suse_version} > 1220
|
||||
%service_add_post nmb.service smb.service
|
||||
%endif
|
||||
|
||||
%postun
|
||||
%{?restart_on_update:%{restart_on_update nmb smb}}
|
||||
%{?insserv_cleanup:%{insserv_cleanup}}
|
||||
%if 0%{?suse_version} > 1220
|
||||
%service_del_postun nmb.service smb.service
|
||||
%endif
|
||||
|
||||
%pre client
|
||||
%if 0%{?suse_version} && 0%{?suse_version} < 1221
|
||||
@@ -1646,6 +1675,9 @@ fi
|
||||
# we need this group for squid (ntlmauth)
|
||||
# read access to /var/lib/samba/winbindd_privileged
|
||||
getent group winbind >/dev/null || groupadd -r winbind || :
|
||||
%if 0%{?suse_version} > 1220
|
||||
%service_add_pre winbind.service
|
||||
%endif
|
||||
|
||||
%post winbind
|
||||
/sbin/ldconfig
|
||||
@@ -1660,9 +1692,15 @@ else
|
||||
ln -fs %{_sysconfdir}/sysconfig/%{NET_CFGDIR}/scripts/samba-winbindd %{_sysconfdir}/sysconfig/%{NET_CFGDIR}/${if_case}/55-samba-winbindd
|
||||
done
|
||||
fi
|
||||
%if 0%{?suse_version} > 1220
|
||||
%service_add_post winbind.service
|
||||
%endif
|
||||
|
||||
%preun winbind
|
||||
%{?stop_on_removal:%{stop_on_removal winbind}}
|
||||
%if 0%{?suse_version} > 1220
|
||||
%service_del_preun winbind.service
|
||||
%endif
|
||||
|
||||
%postun winbind
|
||||
/sbin/ldconfig
|
||||
@@ -1677,6 +1715,9 @@ fi
|
||||
%endif
|
||||
%{?restart_on_update:%{restart_on_update winbind}}
|
||||
%{?insserv_cleanup:%{insserv_cleanup}}
|
||||
%if 0%{?suse_version} > 1220
|
||||
%service_del_postun winbind.service
|
||||
%endif
|
||||
|
||||
%post -n %{libsmbclient_name} -p /sbin/ldconfig
|
||||
|
||||
@@ -1694,8 +1735,13 @@ fi
|
||||
|
||||
%files -f filelist-samba
|
||||
%defattr(-,root,root)
|
||||
%if 0%{?suse_version} < 1221
|
||||
%attr(0754,root,root) %config %{INITDIR}/nmb
|
||||
%attr(0754,root,root) %config %{INITDIR}/smb
|
||||
%else
|
||||
%{_unitdir}/nmb.service
|
||||
%{_unitdir}/smb.service
|
||||
%endif
|
||||
%if 0%{?suse_version} && 0%{?suse_version} < 1111
|
||||
%attr(0600,root,root) %config(noreplace) %{CONFIGDIR}/smbpasswd
|
||||
%else
|
||||
@@ -2084,7 +2130,11 @@ fi
|
||||
%files winbind -f filelist-samba-winbind
|
||||
%defattr(-,root,root)
|
||||
%config(noreplace) %{_sysconfdir}/security/pam_winbind.conf
|
||||
%if 0%{?suse_version} < 1221
|
||||
%attr(0754,root,root) %config %{INITDIR}/winbind
|
||||
%else
|
||||
%{_unitdir}/winbind.service
|
||||
%endif
|
||||
%ghost %{_sysconfdir}/sysconfig/%{NET_CFGDIR}/if-down.d/55-samba-winbindd
|
||||
%ghost %{_sysconfdir}/sysconfig/%{NET_CFGDIR}/if-up.d/55-samba-winbindd
|
||||
%{_sysconfdir}/sysconfig/%{NET_CFGDIR}/scripts/samba-winbindd
|
||||
|
Reference in New Issue
Block a user