SHA256
1
0
forked from pool/postfix

Accepting request 585926 from home:13ilya:branches:server:mail

- Refresh spec-file via spec-cleaner and manual optinizations.
  * Add %license macro.
  * Set license to IPL-1.0 OR EPL-2.0.
- Update to 3.3.0
  * http://cdn.postfix.johnriley.me/mirrors/postfix-release/official/postfix-3.3.0.RELEASE_NOTES
  * Dual license: in addition to the historical IBM Public License
    1.0, Postfix is now also distributed with the more recent Eclipse
    Public License 2.0. Recipients can choose to take the software
    under the license of their choice. Those who are more comfortable
    with the IPL can continue with that license.
  * The postconf command now warns about unknown parameter names
    in a Postfix database configuration file. As with other unknown
    parameter names, these warnings can help to find typos early.
  * Container support: Postfix 3.3 will run in the foreground with
    "postfix start-fg". This requires that Postfix multi-instance
    support is disabled (the default). To collect Postfix syslog
    information on the container's host, mount the host's /dev/log
    socket into the container, for example with "docker run -v
    /dev/log:/dev/log ...other options...", and specify a distinct
    Postfix syslog_name setting in the container (for example with
    "postconf syslog_name=the-name-here").
  * Milter support: applications can now send RET and ENVID parameters
    in SMFIR_CHGFROM (change envelope sender) requests.
  * Postfix-generated From: headers with 'full name' information
    are now formatted as "From: name <address>" by default. Specify
    "header_from_format = obsolete" to get the earlier form "From:
    address (name)".
  * Interoperability: when Postfix IPv6 and IPv4 support are both
    enabled, the Postfix SMTP client will now relax MX preferences
    and attempt to schedule similar numbers of IPv4 and IPv6
    addresses. This works around mail delivery problems when a
    destination announces lots of primary MX addresses on IPv6, but
    is reachable only over IPv4 (or vice versa). The new behavior
    is controlled with the smtp_balance_mx_inet_protocols parameter.
  * Compatibility safety net: with compatibility_level < 1, the
    Postfix SMTP server now warns for mail that would be blocked
    by the Postfix 2.10 smtpd_relay_restrictions feature, without
    blocking that mail. There still is a steady trickle of sites
    that upgrade from an earlier Postfix version.

OBS-URL: https://build.opensuse.org/request/show/585926
OBS-URL: https://build.opensuse.org/package/show/server:mail/postfix?expand=0&rev=294
This commit is contained in:
Peter Varkoly 2018-03-13 07:02:46 +00:00 committed by Git OBS Bridge
parent c2cddd1e53
commit 96f02db6a7
4 changed files with 154 additions and 178 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ec55ebaa2aa464792af8d5ee103eb68b27a42dc2b36a02fee42dafbf9740c7f6
size 4390376

3
postfix-3.3.0.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:7942e89721e30118d7050675b0d976955e3160e21f7898b85a79cac4f4baef39
size 4419450

View File

@ -1,3 +1,46 @@
-------------------------------------------------------------------
Mon Mar 12 13:43:43 UTC 2018 - ilya@ilya.pp.ua
- Refresh spec-file via spec-cleaner and manual optinizations.
* Add %license macro.
* Set license to IPL-1.0 OR EPL-2.0.
- Update to 3.3.0
* http://cdn.postfix.johnriley.me/mirrors/postfix-release/official/postfix-3.3.0.RELEASE_NOTES
* Dual license: in addition to the historical IBM Public License
1.0, Postfix is now also distributed with the more recent Eclipse
Public License 2.0. Recipients can choose to take the software
under the license of their choice. Those who are more comfortable
with the IPL can continue with that license.
* The postconf command now warns about unknown parameter names
in a Postfix database configuration file. As with other unknown
parameter names, these warnings can help to find typos early.
* Container support: Postfix 3.3 will run in the foreground with
"postfix start-fg". This requires that Postfix multi-instance
support is disabled (the default). To collect Postfix syslog
information on the container's host, mount the host's /dev/log
socket into the container, for example with "docker run -v
/dev/log:/dev/log ...other options...", and specify a distinct
Postfix syslog_name setting in the container (for example with
"postconf syslog_name=the-name-here").
* Milter support: applications can now send RET and ENVID parameters
in SMFIR_CHGFROM (change envelope sender) requests.
* Postfix-generated From: headers with 'full name' information
are now formatted as "From: name <address>" by default. Specify
"header_from_format = obsolete" to get the earlier form "From:
address (name)".
* Interoperability: when Postfix IPv6 and IPv4 support are both
enabled, the Postfix SMTP client will now relax MX preferences
and attempt to schedule similar numbers of IPv4 and IPv6
addresses. This works around mail delivery problems when a
destination announces lots of primary MX addresses on IPv6, but
is reachable only over IPv4 (or vice versa). The new behavior
is controlled with the smtp_balance_mx_inet_protocols parameter.
* Compatibility safety net: with compatibility_level < 1, the
Postfix SMTP server now warns for mail that would be blocked
by the Postfix 2.10 smtpd_relay_restrictions feature, without
blocking that mail. There still is a steady trickle of sites
that upgrade from an earlier Postfix version.
-------------------------------------------------------------------
Tue Feb 13 10:39:37 UTC 2018 - varkoly@suse.com

View File

@ -12,32 +12,15 @@
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
# Please submit bugfixes or comments via https://bugs.opensuse.org
#
#Compat macro for new _fillupdir macro introduced in Nov 2017
%if ! %{defined _fillupdir}
%define _fillupdir /var/adm/fillup-templates
%endif
%if 0%{?suse_version} >= 1320 || ( 0%{?suse_version} == 1315 && 0%{?is_opensuse} )
%bcond_without lmdb
%bcond_without libnsl
%else
%bcond_with lmdb
%bcond_with libnsl
%endif
#
# Some defines
#
%define pf_docdir %{_docdir}/%{name}-doc
%define pf_config_directory %{_sysconfdir}/%{name}
%define pf_daemon_directory /usr/lib/%{name}/bin/
%define _libexecdir /usr/lib
%define pf_shlib_directory /usr/lib/%{name}
%define pf_command_directory %{_prefix}/sbin
%define pf_daemon_directory %{_prefix}/lib/%{name}/bin/
%define _libexecdir %{_prefix}/lib
%define pf_shlib_directory %{_prefix}/lib/%{name}
%define pf_command_directory %{_sbindir}
%define pf_queue_directory var/spool/%{name}
%define pf_sendmail_path %{_sbindir}/sendmail
%define pf_newaliases_path %{_bindir}/newaliases
@ -50,31 +33,34 @@
%define pf_uid 51
%define pf_gid 51
%define maildrop_gid 59
%define mail_group mail
%define mail_group mail
%define conf_backup_dir %{_localstatedir}/adm/backup/%{name}
%define omc_pdir %{_datadir}/omc/
%define omc_dir %{_datadir}/omc/svcinfo.d/
#
%define vmusr vmail
%define vmgid 303
%define vmid 303
%define vmdir /srv/maildirs
#
# ---------------------------------------------------------------------------
%if 0%{?suse_version} > 1220
%define _unitdir %{_libexecdir}/systemd
%define unitdir %{_libexecdir}/systemd
#Compat macro for new _fillupdir macro introduced in Nov 2017
%if ! %{defined _fillupdir}
%define _fillupdir %{_localstatedir}/adm/fillup-templates
%endif
%if 0%{?suse_version} >= 1320 || ( 0%{?suse_version} == 1315 && 0%{?is_opensuse} )
%bcond_without lmdb
%bcond_without libnsl
%else
%define _unitdir /lib/systemd
%bcond_with lmdb
%bcond_with libnsl
%endif
Name: postfix
Version: 3.2.4
Version: 3.3.0
Release: 0
Summary: A fast, secure, and flexible mailer
License: IPL-1.0
License: IPL-1.0 OR EPL-2.0
Group: Productivity/Networking/Email/Servers
Url: http://www.postfix.org/
#Source: http://www.artfiles.org/postfix.org/postfix-release/official/postfix-%{version}.tar.gz
Source: postfix-%{version}.tar.gz
URL: http://www.postfix.org
Source0: http://cdn.postfix.johnriley.me/mirrors/postfix-release/official/postfix-%{version}.tar.gz
Source2: %{name}-SuSE.tar.gz
Source3: %{name}-mysql.tar.bz2
Source10: %{name}-rpmlintrc
@ -87,80 +73,59 @@ Patch5: %{name}-master.cf.patch
Patch6: %{name}-linux45.patch
Patch7: %{name}-ssl-release-buffers.patch
Patch8: %{name}-vda-v14-3.0.3.patch
Patch9: fix-postfix-script.patch
Patch9: fix-postfix-script.patch
BuildRequires: ca-certificates
BuildRequires: cyrus-sasl-devel
BuildRequires: db-devel
BuildRequires: diffutils
BuildRequires: libopenssl-devel
%if %{with lmdb}
BuildRequires: lmdb-devel
%endif
BuildRequires: fdupes
BuildRequires: libicu-devel
%if %{with libnsl}
BuildRequires: libnsl-devel
%endif
BuildRequires: libopenssl-devel
BuildRequires: mysql-devel
BuildRequires: openldap2-devel
BuildRequires: pcre-devel
BuildRequires: pkgconfig
BuildRequires: postgresql-devel
BuildRequires: shadow
BuildRequires: systemd
Requires: iproute2
Requires(pre): permissions
Requires(post): permissions
Requires(pre): %fillup_prereq
Requires(pre): permissions
Requires(pre): shadow
Provides: smtp_daemon
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Conflicts: sendmail exim
%if 0%{?suse_version} > 1130
Requires(pre): sysvinit(network)
Requires(pre): sysvinit(syslog)
Conflicts: exim
Conflicts: sendmail
Provides: smtp_daemon
%{?systemd_requires}
%if %{with lmdb}
BuildRequires: lmdb-devel
%endif
%if 0%{?suse_version} >= 1100
BuildRequires: fdupes
%if %{with libnsl}
BuildRequires: libnsl-devel
%endif
%if 0%{?suse_version} >= 1330
Requires(pre): group(%{mail_group})
Requires: system-user-nobody
Requires: group(%{mail_group})
%endif
%if 0%{?suse_version} > 1210
BuildRequires: systemd
%{?systemd_requires}
%else
Requires(pre): %insserv_prereq
Requires(pre): %{_bindir}/getent
Requires(pre): pwdutils
Requires(pre): /bin/awk
Requires(pre): /bin/grep
Requires(pre): /bin/sed
Requires(pre): fileutils
Requires(pre): netcfg
Requires(pre): pcre
Requires(pre): sh-utils
Requires(pre): textutils
Requires: system-user-nobody
Requires(pre): group(%{mail_group})
%endif
%description
Postfix aims to be an alternative to the widely-used sendmail program.
%package devel
Summary: Development headers for the postfix package
Summary: Development headers for the %{name} package
Group: Development/Libraries/C and C++
Requires(pre): %{name} = %{version}
Requires(pre): %{name} = %{version}
%description devel
Postfix aims to be an alternative to the widely-used sendmail program.
%package doc
Summary: Documentations for the postfix package
Summary: Documentations for the %{name} package
Group: Productivity/Networking/Email/Servers
%if 0%{?suse_version} >= 1120
BuildArch: noarch
%endif
%description doc
Postfix aims to be an alternative to the widely-used sendmail program.
@ -169,8 +134,8 @@ This package contains the documentation for %{name}
%package mysql
Summary: Postfix plugin to support MySQL maps
Group: Productivity/Networking/Email/Servers
Requires(pre): %{name} = %{version}
Requires(pre): shadow
Requires(pre): %{name} = %{version}
Requires(pre): shadow
%description mysql
Postfix plugin to support MySQL maps. This library will be loaded by
@ -179,7 +144,7 @@ starting %{name} if you'll access a postmap which is stored in mysql.
%package postgresql
Summary: Postfix plugin to support PostgreSQL maps
Group: Productivity/Networking/Email/Servers
Requires(pre): %{name} = %{version}
Requires(pre): %{name} = %{version}
%description postgresql
Postfix plugin to support PostgreSQL maps. This library will be loaded
@ -190,7 +155,7 @@ PostgreSQL.
%package lmdb
Summary: Postfix plugin to support LMDB maps
Group: Productivity/Networking/Email/Servers
Requires(pre): %{name} = %{version}
Requires(pre): %{name} = %{version}
%description lmdb
Postfix plugin to support LMDB maps. This library will be loaded
@ -259,10 +224,10 @@ export AUXLIBS_LMDB="-llmdb"
export PIE=-pie
make makefiles pie=yes shared=yes dynamicmaps=yes \
shlib_directory=/usr/lib/postfix \
meta_directory=/usr/lib/postfix \
config_directory=/etc/postfix
make
shlib_directory=%{_prefix}/lib/%{name} \
meta_directory=%{_prefix}/lib/%{name} \
config_directory=%{_sysconfdir}/%{name}
make %{?_smp_mflags}
# ---------------------------------------------------------------------------
%install
@ -271,13 +236,13 @@ groupadd -g %{maildrop_gid} -o -r maildrop 2> /dev/null || :
useradd -r -o -g %{name} -u %{pf_uid} -s /bin/false -c "Postfix Daemon" -d /%{pf_queue_directory} %{name} 2> /dev/null || :
usermod -G %{maildrop_gid},%{mail_group} %{name} 2> /dev/null || :
mkdir -p %{buildroot}/%{_libdir}
mkdir -p %{buildroot}/etc/postfix
cp conf/* %{buildroot}/etc/postfix/
mkdir -p %{buildroot}%{_sysconfdir}/%{name}
cp conf/* %{buildroot}%{_sysconfdir}/%{name}
# create our default postfix ssl DIR (/etc/postfix/ssl)
mkdir -p %{buildroot}/etc/postfix/ssl/certs
mkdir -p %{buildroot}%{_sysconfdir}/%{name}/ssl/certs
# link cacerts to /etc/ssl/certs
ln -sf ../../ssl/certs %{buildroot}/etc/postfix/ssl/cacerts
cp lib/libpostfix-* %{buildroot}/%{_libdir}
ln -sf ../../ssl/certs %{buildroot}%{_sysconfdir}/%{name}/ssl/cacerts
cp lib/lib%{name}-* %{buildroot}/%{_libdir}
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}/%{_libdir}
sh postfix-install -non-interactive \
install_root=%{buildroot} \
@ -296,22 +261,17 @@ ln -sf ../sbin/sendmail %{buildroot}%{_libexecdir}/sendmail
for i in qmqp-source smtp-sink smtp-source; do
install -m 755 bin/$i %{buildroot}%{_sbindir}/$i
done
%if 0%{?suse_version} < 1210
mkdir -p %{buildroot}%{_sysconfdir}/init.d
%endif
mkdir -p %{buildroot}/sbin/conf.d
mkdir -p %{buildroot}%{_sysconfdir}/permissions.d
mkdir -p %{buildroot}/%{_libdir}/sasl2
mkdir -p %{buildroot}%{_prefix}/sbin
mkdir -p %{buildroot}%{_sbindir}
mkdir -p %{buildroot}/%{conf_backup_dir}
mkdir -p %{buildroot}/%{pf_sample_directory}
mkdir -p %{buildroot}/%{pf_html_directory}
mkdir -p %{buildroot}%{_includedir}/%{name}
mkdir -p %{buildroot}%{_sysconfdir}/pam.d
install -m 644 %{name}-SuSE/smtp %{buildroot}%{_sysconfdir}/pam.d/smtp
#mkdir samples
mkdir -p %{buildroot}%{_fillupdir}
rm -f %{buildroot}%{_fillupdir}/sysconfig.%{name}
sed -e 's;@lib@;%{_lib};g' %{name}-SuSE/sysconfig.%{name} > %{buildroot}%{_fillupdir}/sysconfig.%{name}
install -m 644 %{name}-SuSE/sysconfig.mail-%{name} %{buildroot}%{_fillupdir}/sysconfig.mail-%{name}
sed -e 's;@lib@;%{_lib};g' \
@ -328,10 +288,10 @@ sed -e 's;@lib@;%{_lib};g' \
chmod 755 %{buildroot}%{_sbindir}/config.%{name}
install -m 644 %{name}-SuSE/dynamicmaps.cf %{buildroot}%{_sysconfdir}/%{name}/dynamicmaps.cf
install -m 644 %{name}-SuSE/ldap_aliases.cf %{buildroot}%{_sysconfdir}/%{name}/ldap_aliases.cf
install -m 644 %{name}-SuSE/helo_access %{buildroot}%{_sysconfdir}/postfix/helo_access
install -m 644 %{name}-SuSE/helo_access %{buildroot}%{_sysconfdir}/%{name}/helo_access
install -m 644 %{name}-SuSE/permissions %{buildroot}%{_sysconfdir}/permissions.d/%{name}
install -m 644 %{name}-SuSE/sender_canonical %{buildroot}%{_sysconfdir}/%{name}/sender_canonical
install -m 644 %{name}-SuSE/relay %{buildroot}%{_sysconfdir}/postfix/relay
install -m 644 %{name}-SuSE/relay %{buildroot}%{_sysconfdir}/%{name}/relay
install -m 644 %{name}-SuSE/relay_ccerts %{buildroot}%{_sysconfdir}/%{name}/relay_ccerts
install -m 600 %{name}-SuSE/sasl_passwd %{buildroot}%{_sysconfdir}/%{name}/sasl_passwd
mkdir -p %{buildroot}%{_sysconfdir}/sasl2
@ -370,7 +330,7 @@ cat conf/main.cf
"disable_vrfy_command = yes" \
'smtpd_banner = $myhostname ESMTP'
#Set Permissions
install -m 644 %{name}-SuSE/%{name}-files %{buildroot}%{pf_shlib_directory}/postfix-files
install -m 644 %{name}-SuSE/%{name}-files %{buildroot}%{pf_shlib_directory}/%{name}-files
# postfix-mysql
install -m 644 %{name}-mysql/main.cf-mysql %{buildroot}%{_sysconfdir}/%{name}/main.cf-mysql
install -m 640 %{name}-mysql/*_maps.cf %{buildroot}%{_sysconfdir}/%{name}/
@ -385,26 +345,22 @@ for example in AIX42 BSDI* F* HPUX* IRIX* NETBSD1 NEXTSTEP3 OPENSTEP4 OSF1 Solar
done
cp -a examples/* %{buildroot}%{pf_sample_directory}
cp -a html/* %{buildroot}%{pf_html_directory}
cp -a auxiliary/ %{buildroot}%{pf_docdir}/
%if 0%{?suse_version} >= 1210
mkdir -p %{buildroot}%{_unitdir}/system
mkdir -p %{buildroot}%{_sysconfdir}/postfix/system
install -m 0644 %{name}-SuSE/postfix.service %{buildroot}%{_unitdir}/system/postfix.service
install -m 0755 %{name}-SuSE/config_postfix.systemd %{buildroot}%{_sysconfdir}/postfix/system/config_postfix
install -m 0755 %{name}-SuSE/update_chroot.systemd %{buildroot}%{_sysconfdir}/postfix/system/update_chroot
install -m 0755 %{name}-SuSE/update_postmaps.systemd %{buildroot}%{_sysconfdir}/postfix/system/update_postmaps
install -m 0755 %{name}-SuSE/wait_qmgr.systemd %{buildroot}%{_sysconfdir}/postfix/system/wait_qmgr
install -m 0755 %{name}-SuSE/cond_slp.systemd %{buildroot}%{_sysconfdir}/postfix/system/cond_slp
cp -a auxiliary %{buildroot}%{pf_docdir}
rm %{buildroot}%{pf_docdir}/README_FILES/INSTALL
# Fix build for Leap 42.3.
rm -f %{buildroot}%{_sysconfdir}/%{name}/*.orig
mkdir -p %{buildroot}%{_unitdir}
mkdir -p %{buildroot}%{_sysconfdir}/%{name}/system
install -m 0644 %{name}-SuSE/%{name}.service %{buildroot}%{_unitdir}/%{name}.service
install -m 0755 %{name}-SuSE/config_%{name}.systemd %{buildroot}%{_sysconfdir}/%{name}/system/config_%{name}
install -m 0755 %{name}-SuSE/update_chroot.systemd %{buildroot}%{_sysconfdir}/%{name}/system/update_chroot
install -m 0755 %{name}-SuSE/update_postmaps.systemd %{buildroot}%{_sysconfdir}/%{name}/system/update_postmaps
install -m 0755 %{name}-SuSE/wait_qmgr.systemd %{buildroot}%{_sysconfdir}/%{name}/system/wait_qmgr
install -m 0755 %{name}-SuSE/cond_slp.systemd %{buildroot}%{_sysconfdir}/%{name}/system/cond_slp
ln -sv %{_sbindir}/service %{buildroot}%{_sbindir}/rc%{name}
%else
install -m 755 %{name}-SuSE/rc.%{name} %{buildroot}%{_initddir}/%{name}
ln -s -f %{_initddir}/%{name} %{buildroot}%{_sbindir}/rc%{name}
%endif
%if 0%{?suse_version} >= 1100
%fdupes %{buildroot}%{pf_docdir}
%fdupes %{buildroot}%{_mandir}
%endif
for path in %{buildroot}%{pf_shlib_directory}/libpostfix-*.so
for path in %{buildroot}%{pf_shlib_directory}/lib%{name}-*.so
do
test -e "$path" || continue
name=${path##*/}
@ -416,9 +372,7 @@ done
install -m 755 %{SOURCE11} %{buildroot}%{_sbindir}/
%pre
%if 0%{?suse_version} > 1210
%service_add_pre %{name}.service
%endif
VERSIONTEST=$(test -x usr/sbin/postconf && usr/sbin/postconf proxy_read_maps 2>/dev/null || :)
if [ -z "$VERSIONTEST" -a -f %{pf_queue_directory}/pid/master.pid ]; then
@ -451,9 +405,7 @@ fi
%preun
%stop_on_removal %{name}
%if 0%{?suse_version} > 1210
%service_del_preun %{name}.service
%endif
# ---------------------------------------------------------------------------
%preun mysql
@ -494,37 +446,37 @@ fi
# We never have to run suseconfig for postfix after installation
# We only start postfix own upgrade-configuration by update
if [ ${1:-0} -gt 1 ]; then
touch %{_localstatedir}/adm/postfix.configured
touch %{_localstatedir}/adm/%{name}.configured
# Check if main.cf and master.cf was changed manualy
MAINCH=0
if [ -e %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/main.cf ]; then
MD5SUM1=$( cat %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/main.cf )
MD5SUM2=$( grep -v "^#" %{_sysconfdir}/postfix/main.cf | md5sum )
if [ -e %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/%{name}/main.cf ]; then
MD5SUM1=$( cat %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/%{name}/main.cf )
MD5SUM2=$( grep -v "^#" %{_sysconfdir}/%{name}/main.cf | md5sum )
if [ "$MD5SUM1" != "$MD5SUM2" ]; then
MAINCH=1
fi
fi
MASTERCH=0
if [ -e %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/master.cf ]; then
MD5SUM1=$( cat %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/master.cf )
MD5SUM2=$( grep -v "^#" %{_sysconfdir}/postfix/master.cf | md5sum )
if [ -e %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/%{name}/master.cf ]; then
MD5SUM1=$( cat %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/%{name}/master.cf )
MD5SUM2=$( grep -v "^#" %{_sysconfdir}/%{name}/master.cf | md5sum )
if [ "$MD5SUM1" != "$MD5SUM2" ]; then
MASTERCH=1
fi
fi
echo "Executing upgrade-configuration."
%{_sbindir}/postfix set-permissions upgrade-configuration setgid_group=%{pf_setgid_group} || :
if [ "$(/usr/sbin/postconf -h daemon_directory)" != "%{pf_daemon_directory}" ]; then
/usr/sbin/postconf daemon_directory=%{pf_daemon_directory}
%{_sbindir}/%{name} set-permissions upgrade-configuration setgid_group=%{pf_setgid_group} || :
if [ "$(%{_sbindir}/postconf -h daemon_directory)" != "%{pf_daemon_directory}" ]; then
%{_sbindir}/postconf daemon_directory=%{pf_daemon_directory}
fi
if [ $MASTERCH -eq 0 ]; then
test -e %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/master.cf && grep -v "^#" %{_sysconfdir}/postfix/master.cf | md5sum > %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/master.cf
test -e %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/%{name}/master.cf && grep -v "^#" %{_sysconfdir}/%{name}/master.cf | md5sum > %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/master.cf
fi
if [ $MAINCH -eq 0 ]; then
test -e %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/main.cf && grep -v "^#" %{_sysconfdir}/postfix/main.cf | md5sum > %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/main.cf
test -e %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/%{name}/main.cf && grep -v "^#" %{_sysconfdir}/%{name}/main.cf | md5sum > %{_localstatedir}/adm/SuSEconfig/md5%{_sysconfdir}/postfix/main.cf
fi
fi
%if 0%{?suse_version} > 1210
%service_add_post %{name}.service
%set_permissions %{_sbindir}/postqueue
@ -533,31 +485,18 @@ fi
%set_permissions %{_sbindir}/sendmail
%{fillup_only postfix}
%else
%{fillup_and_insserv -y postfix}
%endif
%{fillup_only -an mail}
/sbin/ldconfig
%if 0%{?suse_version} > 1210
%verifyscript
%verify_permissions -e %{_sbindir}/postqueue
%verify_permissions -e %{_sbindir}/postdrop
%verify_permissions -e %{_sysconfdir}/%{name}/sasl_passwd
%verify_permissions -e %{_sbindir}/sendmail
%{fillup_only postfix}
%else
%{fillup_and_insserv -y postfix}
%endif
# ---------------------------------------------------------------------------
%postun
%if 0%{?suse_version} > 1210
%service_del_postun %{name}.service
%else
%restart_on_update %{name}
%insserv_cleanup
%endif
/sbin/ldconfig
# ---------------------------------------------------------------------------
@ -579,8 +518,7 @@ fi
# ---------------------------------------------------------------------------
%files
%defattr(-,root,root)
%doc LICENSE
%license LICENSE
%config %{_sysconfdir}/pam.d/*
%{_fillupdir}/sysconfig.%{name}
%{_fillupdir}/sysconfig.mail-%{name}
@ -597,8 +535,11 @@ fi
%config(noreplace) %{_sysconfdir}/%{name}/ldap_aliases.cf
%config(noreplace) %{_sysconfdir}/%{name}/main.cf
%config(noreplace) %{_sysconfdir}/%{name}/master.cf
%config(noreplace) %{_sysconfdir}/%{name}/post-install
%config(noreplace) %{_sysconfdir}/%{name}/postfix-files
%attr(0750,root,root) %config %{_sysconfdir}/%{name}/post-install
%attr(0750,root,root) %config %{_sysconfdir}/%{name}/%{name}-tls-script
%attr(0750,root,root) %config %{_sysconfdir}/%{name}/%{name}-wrapper
%attr(0750,root,root) %config %{_sysconfdir}/%{name}/postmulti-script
%config(noreplace) %{_sysconfdir}/%{name}/%{name}-files
%config(noreplace) %{_sysconfdir}/%{name}/relay
%config(noreplace) %{_sysconfdir}/%{name}/relay_ccerts
%config(noreplace) %{_sysconfdir}/%{name}/sasl_passwd
@ -606,7 +547,7 @@ fi
%config(noreplace) %{_sysconfdir}/%{name}/virtual
%config %{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/smtp
%dir %{_sysconfdir}/sasl2/
%dir %{_sysconfdir}/sasl2
%config(noreplace) %{_sysconfdir}/sasl2/smtpd.conf
%config %{_sysconfdir}/%{name}/LICENSE
%config %{_sysconfdir}/%{name}/TLS_LICENSE
@ -615,16 +556,12 @@ fi
%attr(0644, root, root) %config %{_sysconfdir}/%{name}/makedefs.out
%{pf_shlib_directory}/%{name}-files
# create our default postfix ssl DIR (/etc/postfix/ssl)
%dir %{_sysconfdir}/postfix/ssl
%dir %{_sysconfdir}/postfix/ssl/certs
%{_sysconfdir}/postfix/ssl/cacerts
%if 0%{?suse_version} >= 1210
%dir %{_sysconfdir}/postfix/system
%config %attr(0755,root,root) %{_sysconfdir}/postfix/system/*
%{_unitdir}/system/postfix.service
%else
%config %attr(0755,root,root) %{_initddir}/%{name}
%endif
%dir %{_sysconfdir}/%{name}/ssl
%dir %{_sysconfdir}/%{name}/ssl/certs
%{_sysconfdir}/%{name}/ssl/cacerts
%dir %{_sysconfdir}/%{name}/system
%config %attr(0755,root,root) %{_sysconfdir}/%{name}/system/*
%{_unitdir}/%{name}.service
%verify(not mode) %attr(2755,root,%{pf_setgid_group}) %{_sbindir}/postdrop
%verify(not mode) %attr(2755,root,%{pf_setgid_group}) %{_sbindir}/postqueue
%{_bindir}/mailq
@ -633,7 +570,7 @@ fi
%attr(0755,root,root) %{_sbindir}/postalias
%attr(0755,root,root) %{_sbindir}/postcat
%attr(0755,root,root) %{_sbindir}/postconf
%attr(0755,root,root) %{_sbindir}/postfix
%attr(0755,root,root) %{_sbindir}/%{name}
%attr(0755,root,root) %{_sbindir}/postkick
%attr(0755,root,root) %{_sbindir}/postlock
%attr(0755,root,root) %{_sbindir}/postlog
@ -643,27 +580,27 @@ fi
%attr(0755,root,root) %{_sbindir}/qmqp-source
%attr(0755,root,root) %{_sbindir}/smtp-sink
%attr(0755,root,root) %{_sbindir}/smtp-source
%attr(0755,root,root) %{_sbindir}/mkpostfixcert
%attr(0755,root,root) %{_sbindir}/mk%{name}cert
%attr(0755,root,root) %{_sbindir}/check_mail_queue
%attr(0755,root,root) %{_sbindir}/config.postfix
%attr(0755,root,root) %{_sbindir}/config.%{name}
%{_sbindir}/rc%{name}
%{_libdir}/lib*
%{_libexecdir}/sendmail
%dir %{pf_shlib_directory}
%{pf_shlib_directory}/*[^.so]
%{pf_shlib_directory}/postfix-ldap.so
%{pf_shlib_directory}/postfix-pcre.so
%{pf_shlib_directory}/libpostfix-dns.so
%{pf_shlib_directory}/libpostfix-global.so
%{pf_shlib_directory}/libpostfix-master.so
%{pf_shlib_directory}/libpostfix-tls.so
%{pf_shlib_directory}/libpostfix-util.so
%{pf_shlib_directory}/%{name}-ldap.so
%{pf_shlib_directory}/%{name}-pcre.so
%{pf_shlib_directory}/lib%{name}-dns.so
%{pf_shlib_directory}/lib%{name}-global.so
%{pf_shlib_directory}/lib%{name}-master.so
%{pf_shlib_directory}/lib%{name}-tls.so
%{pf_shlib_directory}/lib%{name}-util.so
%{pf_shlib_directory}/main.cf.proto
%{pf_shlib_directory}/master.cf.proto
%{conf_backup_dir}
%dir %attr(0700,%{name},root) %{pf_data_directory}
%{_mandir}/man?/*.gz
%{_mandir}/man?/*%{?ext_man}
%dir %attr(0755,root,root) /%{pf_queue_directory}
%dir %attr(0700,%{name},root) /%{pf_queue_directory}/active
%dir %attr(0700,%{name},root) /%{pf_queue_directory}/bounce
@ -680,7 +617,6 @@ fi
%dir %attr(0710,%{name},maildrop) /%{pf_queue_directory}/public
%files devel
%defattr(-,root,root)
%{_includedir}/%{name}/
%files doc
@ -688,20 +624,17 @@ fi
%{pf_docdir}/
%files mysql
%defattr(-,root,root)
%doc %{name}-mysql/%{name}-mysql.sql
%config(noreplace) %attr(640, root, %{name}) %{_sysconfdir}/%{name}/*_maps.cf
%config(noreplace) %{_sysconfdir}/%{name}/main.cf-mysql
%{pf_shlib_directory}/postfix-mysql.so
%{pf_shlib_directory}/%{name}-mysql.so
%files postgresql
%defattr(-,root,root)
%{pf_shlib_directory}/postfix-pgsql.so
%{pf_shlib_directory}/%{name}-pgsql.so
%if %{with lmdb}
%files lmdb
%defattr(-,root,root)
%{pf_shlib_directory}/postfix-lmdb.so
%{pf_shlib_directory}/%{name}-lmdb.so
%endif
%changelog