- add p5-Mail-SPF-*|p5-Mail-SPF-Query-* as a run dep for SpamAssassin (two

options; either can be used but they conflict, so allow both as suggested
by giovanni@).

- install a few more doc files.

- move html mini-howto to a README.
This commit is contained in:
sthen 2011-09-21 08:02:07 +00:00
parent 768a233411
commit 50c90d0c04
4 changed files with 64 additions and 55 deletions

View File

@ -1,11 +1,11 @@
# $OpenBSD: Makefile,v 1.74 2011/07/01 06:39:17 giovanni Exp $
# $OpenBSD: Makefile,v 1.75 2011/09/21 08:02:07 sthen Exp $
COMMENT= mailfilter to identify and mark spam
VER= 3.3.2
DISTNAME= Mail-SpamAssassin-${VER}
PKGNAME= p5-${DISTNAME:S/-rc/rc/}
REVISION= 0
REVISION= 1
RULESNAME= Mail-SpamAssassin-rules-${VER}-r1104058.tar.gz
CATEGORIES= mail perl5
@ -38,6 +38,7 @@ COMMON_DEPENDS= www/p5-HTML-Parser>=3.31 \
BUILD_DEPENDS= ${COMMON_DEPENDS}
RUN_DEPENDS= ${COMMON_DEPENDS} \
p5-Mail-SPF-*|p5-Mail-SPF-Query-*:mail/p5-Mail-SPF \
security/gnupg \
devel/re2c
@ -60,20 +61,18 @@ SUBST_VARS= CONFDIR LOCALSTATEDIR
# regress insists on creating files in $HOME
PORTHOME= ${WRKDIR}/temp-home
FAQ= OpenBSD-SpamAssassin-mini-howto.html
DOCS= README UPGRADE LICENSE procmailrc.example \
sample-nonspam.txt sample-spam.txt
DOCS= CREDITS NOTICE README UPGRADE USAGE LICENSE TRADEMARK \
procmailrc.example sample-nonspam.txt sample-spam.txt
post-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/doc/SpamAssassin
${INSTALL_DATA_DIR} ${PREFIX}/share/doc/SpamAssassin/sql
${INSTALL_DATA_DIR} ${SAMPLE_CONFDIR}
${SUBST_CMD} -c ${FILESDIR}/${FAQ} ${WRKSRC}/${FAQ}
pod2man --section=1 ${WRKSRC}/spamc/spamc.pod > \
${PREFIX}/man/man1/spamc.1
${INSTALL_DATA} ${WRKSRC}/rules/local.cf ${WRKSRC}/rules/*.pre \
${SAMPLE_CONFDIR}
.for i in ${FAQ} ${DOCS}
.for i in ${DOCS}
${INSTALL_DATA} ${WRKSRC}/${i} ${PREFIX}/share/doc/SpamAssassin
.endfor
${INSTALL_DATA} ${WRKSRC}/sql/* ${PREFIX}/share/doc/SpamAssassin/sql

View File

@ -1,46 +0,0 @@
<HTML><HEAD><TITLE>SpamAssassin mini-howto</TITLE><META NAME="generator" CONTENT="txt2html v1.28"></HEAD><BODY>
<p><b>Usage:</b><br>
You can use spamassassin in many ways. But the lightest for the machine is by
making use of the spamc/spamd combination.
<p>Add this line to <b><code>/etc/rc.local</b></code>:
<pre><b># ${PREFIX}/bin/spamd -u _spamdaemon -d</b></pre>
<br> Use that same line to start spamd now.
<p>The final step: put this at the top of your <b><code>.procmailrc</b></code>.
If you do not want to use procmail please check the
<A HREF="http://spamassassin.org/doc.html">online docs</A>
<ul><pre>
:0fw
* < 256000
| spamc
:0e
{
EXITCODE=$?
}
:0:
* ^X-Spam-Status: Yes
caughtspam # This is the mailbox where all spam goes.</pre></ul>
<p><b>Customizing:</b><br>
The spam filtering is not perfect. But since the feedback is very extensive you
should be able to do what is necessary to get most spam filtered.
<p>If you want to add custom settings to spamassassin you can create the
file<code><b> ${SYSCONFDIR}/mail/spamassassin/local.cf </b></code>. All possible options are
described in:<code><b> man Mail::SpamAssassin::Conf</b></code>
<p><b>Much more info:</b><br>
This is just a mini-HOWTO to get you up and running if you are in a hurry.
Please go to <A HREF="http://spamassassin.apache.org">spamassassin.apache.org</A> for further
information.
</BODY></HTML>

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST,v 1.31 2011/07/01 06:39:17 giovanni Exp $
@comment $OpenBSD: PLIST,v 1.32 2011/09/21 08:02:07 sthen Exp $
@pkgpath mail/p5-Mail-SpamAssassin
@newgroup _spamdaemon:506
@newuser _spamdaemon:506:506:daemon:SpamAssassin:${LOCALSTATEDIR}:/sbin/nologin
@ -192,10 +192,13 @@ ${P5SITE}/spamassassin-run.pod
@man man/man3p/Mail::SpamAssassin::Util::RegistrarBoundaries.3p
@man man/man3p/spamassassin-run.3p
share/doc/SpamAssassin/
share/doc/SpamAssassin/CREDITS
share/doc/SpamAssassin/LICENSE
share/doc/SpamAssassin/OpenBSD-SpamAssassin-mini-howto.html
share/doc/SpamAssassin/NOTICE
share/doc/SpamAssassin/README
share/doc/SpamAssassin/TRADEMARK
share/doc/SpamAssassin/UPGRADE
share/doc/SpamAssassin/USAGE
share/doc/SpamAssassin/procmailrc.example
share/doc/SpamAssassin/sample-nonspam.txt
share/doc/SpamAssassin/sample-spam.txt
@ -210,6 +213,7 @@ share/doc/SpamAssassin/sql/bayes_mysql.sql
share/doc/SpamAssassin/sql/bayes_pg.sql
share/doc/SpamAssassin/sql/userpref_mysql.sql
share/doc/SpamAssassin/sql/userpref_pg.sql
share/doc/pkg-readmes/${FULLPKGNAME}
share/examples/SpamAssassin/
share/examples/SpamAssassin/init.pre
@sample ${CONFDIR}/init.pre

View File

@ -0,0 +1,52 @@
$OpenBSD: README,v 1.1 2011/09/21 08:02:07 sthen Exp $
+-----------------------------------------------------------------------
| Running ${FULLPKGNAME} on OpenBSD
+-----------------------------------------------------------------------
This is just a mini-README to get you up and running if you are in a
hurry. Please go to http://spamassassin.apache.org/ for further information.
Configuration
=============
You can use spamassassin in many ways. Larger installations might use
it in combination with smtp-vilter, MailScanner or amavisd-new (all are
available in packages). A common method for a simple setup is to use
the spamc/spamd combination with procmail. To configure this, start
spamassassin from pkg_scripts as usual in /etc/rc.conf.local:
pkg_scripts="${pkg_scripts} spamassassin"
(Use "/etc/rc.d/spamassassin start" to start the daemon right away).
The final step: put this at the top of your .procmailrc.
-- cut here -- -- -- -- -- -- --
:0fw
* < 256000
| spamc
:0e
{
EXITCODE=$?
}
:0:
* ^X-Spam-Status: Yes
caughtspam # This is the mailbox where all spam goes.
-- -- -- -- -- -- -- -- -- -- --
If you do not want to use procmail, please check the online docs at
http://spamassassin.apache.org/doc.html and the documentation for any
other software you use to implement spamassassin (MailScanner, etc).
Customizing
===========
The spam filtering is not perfect. But since the feedback is very
extensive you should be able to do what is necessary to get most spam
filtered.
If you want to add custom settings to spamassassin you can create the
file ${SYSCONFDIR}/mail/spamassassin/local.cf . All possible options
are described in: man Mail::SpamAssassin::Conf