postfix/postfix.spec

changeset 676
7a7cc794483b
parent 672
fcc7a5543835
     1.1 --- a/postfix/postfix.spec	Wed Sep 12 19:10:15 2012 +0200
     1.2 +++ b/postfix/postfix.spec	Thu Sep 13 20:05:49 2012 +0200
     1.3 @@ -48,6 +48,7 @@
     1.4  %option       with_pgsql     no
     1.5  %option       with_ldap      no
     1.6  %option       with_whoson    no
     1.7 +%option       with_spfsrs    no
     1.8  %option       with_fdsetsize no
     1.9  
    1.10  #   list of sources
    1.11 @@ -59,6 +60,7 @@
    1.12  Patch0:       postfix.patch
    1.13  Patch1:       postfix.patch.pfls
    1.14  Patch2:       http://download.openpkg.org/components/versioned/postfix/postfix-%{V_whoson}-whoson.patch
    1.15 +Patch3:       postfix-srs.patch
    1.16  
    1.17  #   build information
    1.18  BuildPreReq:  OpenPKG, openpkg >= 20100101, perl, gcc
    1.19 @@ -97,6 +99,10 @@
    1.20  BuildPreReq:  whoson
    1.21  PreReq:       whoson
    1.22  %endif
    1.23 +%if "%{with_spfsrs}" == "yes"
    1.24 +BuildPreReq:  libsrs2
    1.25 +PreReq:       libsrs2
    1.26 +%endif
    1.27  Provides:     MTA
    1.28  Conflicts:    exim, sendmail, ssmtp
    1.29  
    1.30 @@ -117,6 +123,7 @@
    1.31      o Optional PostgreSQL dictionary support (see package options)
    1.32      o Optional OpenLDAP dictionary support   (see package options)
    1.33      o Optional WHOSON dictionary support     (see package options)
    1.34 +    o Optional SPF SRS protection support    (see package options)
    1.35  
    1.36  %track
    1.37      prog postfix = {
    1.38 @@ -134,6 +141,11 @@
    1.39          url       = http://download.openpkg.org/components/versioned/postfix/
    1.40          regex     = postfix-(__VER__)-whoson.patch
    1.41      }
    1.42 +    prog postfix:spfsrs = {
    1.43 +        version   = %{V_spfsrs}
    1.44 +        url       = http://www.codefrickler.de/srs/
    1.45 +        regex     = postfix-srs-(__VER__).patch
    1.46 +    }
    1.47  
    1.48  %prep
    1.49      #   unpack distribution files
    1.50 @@ -149,6 +161,11 @@
    1.51      %patch -p0 -P 2
    1.52  %endif
    1.53  
    1.54 +    #   apply vendor SPF SRS patch
    1.55 +%if "%{with_spfsrs}" == "yes"
    1.56 +    %patch -p0 -P 3
    1.57 +%endif
    1.58 +
    1.59      #   remove OpenPKG privelege model incompatible exit conditions
    1.60      %{l_shtool} subst \
    1.61          -e 's;msg_fatal\(.*attribute specifies mail system\);msg_info\1;g' \
    1.62 @@ -229,6 +246,10 @@
    1.63      AUXLIBS="$AUXLIBS %{l_fsl_ldflags} %{l_fsl_libs}"
    1.64      CCARGS="$CCARGS -DUSE_SOFTLIMITONLY"
    1.65  %endif
    1.66 +%if "%{with_spfsrs}" == "yes"
    1.67 +    CCARGS="$CCARGS -DHAS_SRS"
    1.68 +    AUXLIBS="$AUXLIBS -lsrs2"
    1.69 +%endif
    1.70  %if "%{with_fdsetsize}" != "no"
    1.71  %if "%{with_fdsetsize}" == "yes"
    1.72      CCARGS="$CCARGS -DFD_SETSIZE=1024"

mercurial