Bug 135001 - [MAINTAINER UPDATE] Fix for mail/p5-Mail-SpamAssassin DKIM, signal and non base openssl
Summary: [MAINTAINER UPDATE] Fix for mail/p5-Mail-SpamAssassin DKIM, signal and non ba...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Gabor Kovesdan
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-05-27 18:40 UTC by Michael Scheidell
Modified: 2009-05-31 00:30 UTC (History)
0 users

See Also:


Attachments
file.diff (1.76 KB, patch)
2009-05-27 18:40 UTC, Michael Scheidell
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Scheidell 2009-05-27 18:40:01 UTC
Three issues.

#1 There were  problems with p5-Mail-DKIM 0.33 so I put in a pr for a upgrade to 0.35 (see pr 134964 http://www.freebsd.org/cgi/query-pr.cgi?pr=134964

#2, running spamassassin via procmail could close without generating a error code

see pr 134552 http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/134552
Thanks to 	Eric van Gyzen

#3, compiling spamc/spamd with NON base, ie PORTS openssl would fail. patch to makefile to include CFLAGS
Thanks to oliver@FreeBSD.org



Note: this requires  pr 134964 first, since it depends on dkim version 0.35.
Additionally, there was a 'problem' with dkim on perl 5.8.8 (resolved in 5.8.9) so please don't send me a pr on a problem with old version of perl (upgrade it)

Fix: Commit pr 134964 

then apply these patches: (here AND attached since the both get mangled now and then)



(generates a new file: files/patch-spamassassin.raw

diff -bBru /var/tmp/SA/ ./
diff -bBru /var/tmp/SA/Makefile ./Makefile
--- /var/tmp/SA/Makefile        2009-05-20 19:07:03.000000000 -0400
+++ ./Makefile  2009-05-27 12:53:59.000000000 -0400
@@ -7,7 +7,7 @@
 
 PORTNAME=      Mail-SpamAssassin
 PORTVERSION=   3.2.5
-PORTREVISION=  3
+PORTREVISION=  4
 CATEGORIES=    mail perl5
 MASTER_SITES=  ${MASTER_SITE_APACHE:S/$/:apache/} ${MASTER_SITE_PERL_CPAN:S/$/:cpan/}
 MASTER_SITE_SUBDIR=    spamassassin/source/:apache Mail/:cpan
@@ -98,7 +98,7 @@
 .endif
 
 .if defined(WITH_DKIM)
-RUN_DEPENDS+=  p5-Mail-DKIM>=0.33:${PORTSDIR}/mail/p5-Mail-DKIM
+RUN_DEPENDS+=  p5-Mail-DKIM>=0.34:${PORTSDIR}/mail/p5-Mail-DKIM
 RUN_DEPENDS+=  ${SITE_PERL}/IO/Socket/SSL.pm:${PORTSDIR}/security/p5-IO-Socket-SSL
 RUN_DEPENDS+=  p5-Crypt-OpenSSL-RSA>=0.24:${PORTSDIR}/security/p5-Crypt-OpenSSL-RSA
 .endif
@@ -207,7 +207,8 @@
                -e 's#B_CONFDIR)/v320.pre#B_CONFDIR)/v320.pre.sample#g' \
                -e 's/require DBI/0/' \
                ${WRKSRC}/Makefile.PL
-       @${REINPLACE_CMD} -e '/^CC =/d' ${WRKSRC}/spamc/Makefile.in
+       @${REINPLACE_CMD} -e '/^CC =/d; \
+               s|@SSLCFLAGS@|& $${CFLAGS}|g' ${WRKSRC}/spamc/Makefile.in
 
 .if defined(WITH_RAZOR)
        ${REINPLACE_CMD} -e '/Razor2/s/^#loadplugin/loadplugin/' ${WRKSRC}/rules/v312.pre
diff -bBru /var/tmp/SA/files/patch-spamassassin.raw ./files/patch-spamassassin.raw
--- /var/tmp/SA/files/patch-spamassassin.raw    2009-05-27 12:56:40.000000000 -0400
+++ ./files/patch-spamassassin.raw      2009-05-27 12:56:27.000000000 -0400
@@ -0,0 +1,12 @@
+--- spamassassin.raw.orig      2009-05-14 20:48:01.000000000 -0500
++++ spamassassin.raw   2009-05-14 20:48:19.000000000 -0500
+@@ -530,7 +530,7 @@
+     $mail->finish();      # bug 5626: remove temp files etc.
+     $mail = undef;
+   }
+-  exit 0;
++  exit 15;
+ }
+ 
+ # ---------------------------------------------------------------------------
+


Patch attached with submission follows:
How-To-Repeat: sign dkim emails, try to verify, some fail

run procmail, see spamassassin PR: 
When SpamAssassin 3.2.5 is killed by a signal, it exits with a zero
exit status. When used with procmail, this causes mail to be lost,
because procmail thinks spamassassin completed successfully, but
spamassassin did not write the filtered mail to stdout to be
reclaimed by procmail for further processing and delivery.

For details, see:

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6033



Hi,
when OpenSSL is not installed in the base but only in $PREFIX,
p5-Mail-Spamassasin fails to compile:
cc -DSPAMC_SSL -DPIC -fPIC spamc/libspamc.c spamc/utils.c  -o spamc/libsslspamc.so -shared  -L/usr/local/lib -lssl -lcrypto -lz
In file included from spamc/libspamc.c:28:
spamc/utils.h:29:28: error: openssl/crypto.h: No such file or directory
spamc/utils.h:30:25: error: openssl/pem.h: No such file or directory
spamc/utils.h:31:25: error: openssl/ssl.h: No such file or directory
spamc/utils.h:32:25: error: openssl/err.h: No such file or directory
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2009-05-27 18:40:11 UTC
Responsible Changed
From-To: freebsd-ports-bugs->gabor

gabor@ wants his PRs (via the GNATS Auto Assign Tool)
Comment 2 dfilter service freebsd_committer freebsd_triage 2009-05-31 00:27:33 UTC
gabor       2009-05-30 23:27:23 UTC

  FreeBSD ports repository

  Modified files:
    mail/p5-Mail-SpamAssassin Makefile 
  Added files:
    mail/p5-Mail-SpamAssassin/files patch-spamassassin.raw 
  Log:
  - Fixing 3 issues:
  
          #1 There were problems with p5-Mail-DKIM 0.33, requiring >=0.34 [1]
  
          #2, running spamassassin via procmail could close without generating
              a error code [1] [2]
  
          #3, compiling spamc/spamd with NON base, ie PORTS openssl would fail.
              patch to makefile to include CFLAGS [1] [3]
  
  - Bump PORTREVISION
  
  PR:             ports/135001 [1], ports/134552 [2]
  Submitted by:   Michael Scheidell <scheidell@secnap.net> (maintainer) [1],
                  Eric van Gyzen <eric@vangyzen.net> [2],
                  olivier [3]
  
  Revision  Changes    Path
  1.125     +5 -3      ports/mail/p5-Mail-SpamAssassin/Makefile
  1.5       +12 -0     ports/mail/p5-Mail-SpamAssassin/files/patch-spamassassin.raw (new)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 3 Gabor Kovesdan freebsd_committer freebsd_triage 2009-05-31 00:29:04 UTC
State Changed
From-To: open->closed

Committed, thanks.