Merged update from upstream sources

This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/sendmail.git#39fb928d58db7a4171f825a5367d8325e41bb7e5
This commit is contained in:
DistroBaker 2021-03-29 18:35:41 +00:00
parent 885fdb7262
commit 7e2ceaeb02

View File

@ -3,6 +3,11 @@
%global with_sasl2 yes
%global with_milter yes
%global with_ldap yes
%if 0%{?rhel} < 9
%global with_nis yes
%else
%global with_nis no
%endif
%global enable_pie yes
%global sendmailcf %{_datadir}/sendmail-cf
@ -16,10 +21,15 @@
# hardened build if not overridden
%{!?_hardened_build:%global _hardened_build 1}
%if "%{with_nis}" == "yes"
%global nis_cflags -DNIS
%global nis_ldadd -lnsl
%endif
Summary: A widely used Mail Transport Agent (MTA)
Name: sendmail
Version: 8.16.1
Release: 4%{?dist}
Release: 6%{?dist}
License: Sendmail
URL: http://www.sendmail.org/
@ -87,7 +97,9 @@ Patch26: sendmail-8.16.1-libmilter-socket-activation.patch
BuildRequires: make
BuildRequires: libdb-devel
%if "%{with_nis}" == "yes"
BuildRequires: libnsl2-devel
%endif
BuildRequires: tinycdb-devel
BuildRequires: groff
BuildRequires: ghostscript
@ -203,11 +215,11 @@ sed -i 's|/usr/local/bin/perl|%{_bindir}/perl|' contrib/*.pl
%build
# generate redhat config file
cat > redhat.config.m4 << EOF
define(\`confMAPDEF', \`-DNEWDB -DCDB -DNIS -DMAP_REGEX -DSOCKETMAP -DNAMED_BIND=1')
define(\`confMAPDEF', \`-DNEWDB -DCDB %{?nis_cflags} -DMAP_REGEX -DSOCKETMAP -DNAMED_BIND=1')
define(\`confOPTIMIZE', \`\`\`\`${RPM_OPT_FLAGS}'''')
define(\`confENVDEF', \`-I%{_includedir}/libdb -I%{_prefix}/kerberos/include -Wall -DXDEBUG=0 -DNETINET6 -DHES_GETMAILHOST -DUSE_VENDOR_CF_PATH=1 -D_FFR_LINUX_MHNL -D_FFR_QOS -D_FILE_OFFSET_BITS=64 -DHAS_GETHOSTBYNAME2')
define(\`confLIBDIRS', \`-L%{_prefix}/kerberos/%{_lib}')
define(\`confLIBS', \`-lnsl -lcrypt -ldb -lcdb -lresolv')
define(\`confLIBS', \`%{?nis_ldadd} -lcrypt -ldb -lcdb -lresolv')
%{?_hardened_build:define(\`confLDOPTS', \`-Xlinker -z -Xlinker relro -Xlinker -z -Xlinker now')}
define(\`confMANOWN', \`root')
define(\`confMANGRP', \`root')
@ -695,6 +707,13 @@ exit 0
%changelog
* Thu Mar 25 2021 Jaroslav Škarvada <jskarvad@redhat.com> - 8.16.1-6
- Disable NIS support for RHEL9+
* Tue Mar 02 2021 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 8.16.1-5
- Rebuilt for updated systemd-rpm-macros
See https://pagure.io/fesco/issue/2583.
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 8.16.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild