diff -r 43d642154330 -r 7a7cc794483b postfix/postfix.spec --- a/postfix/postfix.spec Wed Sep 12 19:10:15 2012 +0200 +++ b/postfix/postfix.spec Thu Sep 13 20:05:49 2012 +0200 @@ -48,6 +48,7 @@ %option with_pgsql no %option with_ldap no %option with_whoson no +%option with_spfsrs no %option with_fdsetsize no # list of sources @@ -59,6 +60,7 @@ Patch0: postfix.patch Patch1: postfix.patch.pfls Patch2: http://download.openpkg.org/components/versioned/postfix/postfix-%{V_whoson}-whoson.patch +Patch3: postfix-srs.patch # build information BuildPreReq: OpenPKG, openpkg >= 20100101, perl, gcc @@ -97,6 +99,10 @@ BuildPreReq: whoson PreReq: whoson %endif +%if "%{with_spfsrs}" == "yes" +BuildPreReq: libsrs2 +PreReq: libsrs2 +%endif Provides: MTA Conflicts: exim, sendmail, ssmtp @@ -117,6 +123,7 @@ o Optional PostgreSQL dictionary support (see package options) o Optional OpenLDAP dictionary support (see package options) o Optional WHOSON dictionary support (see package options) + o Optional SPF SRS protection support (see package options) %track prog postfix = { @@ -134,6 +141,11 @@ url = http://download.openpkg.org/components/versioned/postfix/ regex = postfix-(__VER__)-whoson.patch } + prog postfix:spfsrs = { + version = %{V_spfsrs} + url = http://www.codefrickler.de/srs/ + regex = postfix-srs-(__VER__).patch + } %prep # unpack distribution files @@ -149,6 +161,11 @@ %patch -p0 -P 2 %endif + # apply vendor SPF SRS patch +%if "%{with_spfsrs}" == "yes" + %patch -p0 -P 3 +%endif + # remove OpenPKG privelege model incompatible exit conditions %{l_shtool} subst \ -e 's;msg_fatal\(.*attribute specifies mail system\);msg_info\1;g' \ @@ -229,6 +246,10 @@ AUXLIBS="$AUXLIBS %{l_fsl_ldflags} %{l_fsl_libs}" CCARGS="$CCARGS -DUSE_SOFTLIMITONLY" %endif +%if "%{with_spfsrs}" == "yes" + CCARGS="$CCARGS -DHAS_SRS" + AUXLIBS="$AUXLIBS -lsrs2" +%endif %if "%{with_fdsetsize}" != "no" %if "%{with_fdsetsize}" == "yes" CCARGS="$CCARGS -DFD_SETSIZE=1024"