Gentoo Archives: gentoo-commits

From: "Tobias Scherbaum (dertobi123)" <dertobi123@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in mail-filter/spamassassin: ChangeLog spamassassin-3.2.1-r2.ebuild
Date: Fri, 01 Jan 2010 22:24:37
Message-Id: E1NQpv5-0008Q2-TC@stork.gentoo.org
1 dertobi123 10/01/01 22:24:31
2
3 Modified: ChangeLog
4 Added: spamassassin-3.2.1-r2.ebuild
5 Log:
6 Quick revbump to fix a (now, starting with 2010) wrong regexp in FH_DATE_PAST_20XX (#299256).
7 (Portage version: 2.2_rc61/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.163 mail-filter/spamassassin/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/spamassassin/ChangeLog?rev=1.163&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/spamassassin/ChangeLog?rev=1.163&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/spamassassin/ChangeLog?r1=1.162&r2=1.163
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/mail-filter/spamassassin/ChangeLog,v
19 retrieving revision 1.162
20 retrieving revision 1.163
21 diff -u -r1.162 -r1.163
22 --- ChangeLog 27 Oct 2009 07:22:18 -0000 1.162
23 +++ ChangeLog 1 Jan 2010 22:24:31 -0000 1.163
24 @@ -1,6 +1,13 @@
25 # ChangeLog for mail-filter/spamassassin
26 -# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/mail-filter/spamassassin/ChangeLog,v 1.162 2009/10/27 07:22:18 loki_val Exp $
28 +# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
29 +# $Header: /var/cvsroot/gentoo-x86/mail-filter/spamassassin/ChangeLog,v 1.163 2010/01/01 22:24:31 dertobi123 Exp $
30 +
31 +*spamassassin-3.2.1-r2 (01 Jan 2010)
32 +
33 + 01 Jan 2010; Tobias Scherbaum <dertobi123@g.o>
34 + +files/FH_DATE_PAST_20XX.patch, +spamassassin-3.2.1-r2.ebuild:
35 + Quick revbump to fix a (now, starting with 2010) wrong regexp in
36 + FH_DATE_PAST_20XX (#299256).
37
38 *spamassassin-3.2.5-r1 (27 Oct 2009)
39
40
41
42
43 1.1 mail-filter/spamassassin/spamassassin-3.2.1-r2.ebuild
44
45 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/spamassassin/spamassassin-3.2.1-r2.ebuild?rev=1.1&view=markup
46 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-filter/spamassassin/spamassassin-3.2.1-r2.ebuild?rev=1.1&content-type=text/plain
47
48 Index: spamassassin-3.2.1-r2.ebuild
49 ===================================================================
50 # Copyright 1999-2010 Gentoo Foundation
51 # Distributed under the terms of the GNU General Public License v2
52 # $Header: /var/cvsroot/gentoo-x86/mail-filter/spamassassin/spamassassin-3.2.1-r2.ebuild,v 1.1 2010/01/01 22:24:31 dertobi123 Exp $
53
54 inherit perl-module eutils
55
56 MY_P=Mail-SpamAssassin-${PV//_/-}
57 S=${WORKDIR}/${MY_P}
58 DESCRIPTION="SpamAssassin is an extensible email filter which is used to identify spam."
59 HOMEPAGE="http://spamassassin.apache.org/"
60 SRC_URI="mirror://gentoo/${MY_P}.tar.bz2"
61
62 #SRC_TEST="do"
63 LICENSE="Apache-2.0"
64 SLOT="0"
65 KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
66 #KEYWORDS="~amd64 ~sparc ~x86"
67 IUSE="berkdb qmail ssl doc ldap mysql postgres sqlite tools ipv6"
68
69 DEPEND=">=dev-lang/perl-5.8.2-r1
70 virtual/perl-MIME-Base64
71 >=virtual/perl-PodParser-1.32
72 virtual/perl-Storable
73 virtual/perl-Time-HiRes
74 >=dev-perl/HTML-Parser-3.43
75 >=dev-perl/Net-DNS-0.53
76 dev-perl/Digest-SHA1
77 dev-perl/libwww-perl
78 >=virtual/perl-Archive-Tar-1.26
79 app-crypt/gnupg
80 >=virtual/perl-IO-Zlib-1.04
81 >=dev-util/re2c-0.12.0
82 ssl? (
83 dev-perl/IO-Socket-SSL
84 dev-libs/openssl
85 )
86 berkdb? (
87 virtual/perl-DB_File
88 )
89 ldap? ( dev-perl/perl-ldap )
90 mysql? (
91 dev-perl/DBI
92 dev-perl/DBD-mysql
93 )
94 postgres? (
95 dev-perl/DBI
96 dev-perl/DBD-Pg
97 )
98 sqlite? (
99 dev-perl/DBI
100 dev-perl/DBD-SQLite
101 )
102
103 ipv6? (
104 dev-perl/IO-Socket-INET6
105 )"
106
107 src_unpack() {
108 unpack ${A}
109 cd "${S}"
110 epatch "${FILESDIR}/FH_DATE_PAST_20XX.patch"
111 }
112
113 src_compile() {
114 # - Set SYSCONFDIR explicitly so we can't get bitten by bug 48205 again
115 # (just to be sure, nobody knows how it could happen in the first place).
116 myconf="SYSCONFDIR=/etc DATADIR=/usr/share/spamassassin"
117
118 # If ssl is enabled, spamc can be built with ssl support
119 if use ssl; then
120 myconf="${myconf} ENABLE_SSL=yes"
121 else
122 myconf="${myconf} ENABLE_SSL=no"
123 fi
124
125 # Set the path to the Perl executable explictly. This will be used to
126 # create the initial sharpbang line in the scripts and might cause
127 # a versioned app name end in there, see
128 # <http://bugs.gentoo.org/show_bug.cgi?id=62276>
129 myconf="${myconf} PERL_BIN=/usr/bin/perl"
130
131 # If you are going to enable taint mode, make sure that the bug where
132 # spamd doesn't start when the PATH contains . is addressed, and make
133 # sure you deal with versions of razor <2.36-r1 not being taint-safe.
134 # <http://bugzilla.spamassassin.org/show_bug.cgi?id=2511> and
135 # <http://spamassassin.org/released/Razor2.patch>.
136 myconf="${myconf} PERL_TAINT=no"
137
138 # No settings needed for 'make all'.
139 mymake=""
140
141 # Neither for 'make install'.
142 myinst=""
143
144 # Add Gentoo tag to make it easier for the upstream devs to spot
145 # possible modifications or patches.
146 version_tag="g${PV:6}${PR}"
147 version_str="${PV//_/-}-${version_tag}"
148
149 # Create the Gentoo config file before Makefile.PL is called so it
150 # is copied later on.
151 echo "version_tag ${version_tag}" > rules/11_gentoo.cf
152
153 # Setting the following env var ensures that no questions are asked.
154 export PERL_MM_USE_DEFAULT=1
155 perl-module_src_prep
156 # Run the autoconf stuff now, just to make the build sequence look more
157 # familiar to the user :) Plus feeding the VERSION_STRING skips some
158 # calls to Perl.
159 make spamc/Makefile VERSION_STRING="${version_str}"
160
161 # Now compile all the stuff selected.
162 perl-module_src_compile
163 if use qmail; then
164 make spamc/qmail-spamc || die building qmail-spamc failed
165 fi
166
167 # Remove the MANIFEST files as they aren't docu files
168 rm -f MANIFEST*
169
170 use doc && make text_html_doc
171 }
172
173 src_install () {
174 perl-module_src_test
175 }
176
177 src_install () {
178 perl-module_src_install
179
180 # Create the stub dir used by sa-update and friends
181 dodir /var/lib/spamassassin
182
183 # Move spamd to sbin where it belongs.
184 dodir /usr/sbin
185 mv "${D}"/usr/bin/spamd "${D}"/usr/sbin/spamd || die
186
187 use qmail && dobin spamc/qmail-spamc
188
189 dosym /etc/mail/spamassassin /etc/spamassassin
190
191 # Disable plugin by default
192 sed -i -e 's/^loadplugin/\#loadplugin/g' ${D}/etc/mail/spamassassin/init.pre
193
194 # Add the init and config scripts.
195 newinitd "${FILESDIR}"/3.0.0-spamd.init spamd
196 newconfd "${FILESDIR}"/3.0.0-spamd.conf spamd
197
198 if use doc; then
199 dodoc NOTICE TRADEMARK CREDITS INSTALL UPGRADE BUGS USAGE \
200 sql/README.bayes sql/README.awl README.ldap procmailrc.example \
201 sample-nonspam.txt sample-spam.txt rules/STATISTICS-set0.txt \
202 STATISTICS-set1.txt STATISTICS-set2.txt STATISTICS-set3.txt \
203 spamd/PROTOCOL
204
205 # Rename some docu files so they don't clash with others
206 newdoc spamd/README README.spamd
207 newdoc sql/README README.sql
208 newdoc ldap/README README.ldap
209 use qmail && newdoc spamc/README.qmail README.qmail
210
211 dohtml doc/*.html
212 docinto sql
213 dodoc sql/*.sql
214 fi
215
216 # Install provided tools. See bug 108168
217 if use tools; then
218 docinto tools
219 dodoc tools/*
220 fi
221
222 cp ${FILESDIR}/secrets.cf ${D}/etc/mail/spamassassin/secrets.cf.example
223 fperms 0400 /etc/mail/spamassassin/secrets.cf.example
224 echo "">>${D}/etc/mail/spamassassin/local.cf.example
225 echo "# Sensitive data, such as database connection info, should">>${D}/etc/mail/spamassassin/local.cf.example
226 echo "# be stored in /etc/mail/spamassassin/secrets.cf with">>${D}/etc/mail/spamassassin/local.cf.example
227 echo "# appropriate permissions">>${D}/etc/mail/spamassassin/local.cf.example
228 }
229
230 pkg_postinst() {
231 perl-module_pkg_postinst
232
233 if ! has_version "perl-core/DB_File"; then
234 einfo "The Bayes backend requires the Berkeley DB to store its data. You"
235 einfo "need to emerge perl-core/DB_File or USE=berkdb to make it available."
236 fi
237
238 if has_version "mail-filter/razor"; then
239 if ! has_version ">=mail-filter/razor-2.61"; then
240 ewarn "You have $(best_version mail-filter/razor) installed but SpamAssassin"
241 if has_version "<mail-filter/razor-2.40"; then
242 ewarn "requires at least version 2.40, version 2.61 or later is recommended."
243 else
244 ewarn "recommends at least version 2.61."
245 fi
246 fi
247 fi
248
249 if use doc; then
250 einfo
251 einfo "Please read the file INSTALL in"
252 einfo " /usr/share/doc/${PF}/"
253 einfo "to find out which optional modules you need to install to enable"
254 einfo "additional features which depend on them."
255 einfo
256 einfo "If upgraded from 2.x, please read the file UPGRADE in"
257 einfo " /usr/share/doc/${PF}/"
258 einfo
259 fi
260
261 ewarn
262 ewarn "spamd is not designed to listen to an untrusted network"
263 ewarn "and is vulnerable to DoS attacks (and eternal doom) if"
264 ewarn "configured to do so"
265 ewarn
266 elog "If you plan on using the -u flag to spamd, please read the notes"
267 elog "in /etc/conf.d/spamd regarding the location of the pid file."
268
269 einfo
270 einfo "If you build ${PN} with optional dependancy support,"
271 einfo "you can enable them in /etc/mail/spamassassin/init.pre"
272 einfo
273
274 if has_version '>=dev-lang/perl-5.8.8'; then
275 elog "A note from the SA developers:"
276 elog "Perl 5.8 now uses Unicode internally by default, which causes trouble for"
277 elog "SpamAssassin (and almost all other reasonably complex pieces of perl"
278 elog "code!)."
279 elog ""
280 elog "We've worked around this in most places, as far as we know, but there may"
281 elog "still be some issues. In addition, there is a speed hit, which it would"
282 elog "be nice to avoid."
283 elog ""
284 elog "Setting the LANG environment variable before any invocation of"
285 elog "SpamAssassin sometimes seems to help fix it, like so:"
286 elog ""
287 elog " export LANG=en_US"
288 elog ""
289 elog "Notably, the LANG setting must not include \"utf8\". However, some folks"
290 elog "have reported that this makes no difference. ;)"
291 fi
292 einfo
293 if ! has_version 'dev-perl/Mail-SPF-Query'; then
294 elog "For spf support, please emerge dev-perl/Mail-SPF-Query"
295 fi
296 if ! has_version 'mail-filter/dcc'; then
297 elog "For dcc support, please emerge mail-filter/dcc"
298 fi
299 if ! has_version 'dev-python/pyzor'; then
300 elog "For pyzor support, please emerge dev-python/pyzor"
301 fi
302 if ! has_version 'mail-filter/razor'; then
303 elog "For razor support, please emerge mail-filter/razor"
304 fi
305 einfo
306 elog "For addtional functionality, you may wish to emerge:"
307 elog "dev-perl/IP-Country dev-perl/Net-Ident "
308 elog "dev-perl/Mail-DKIM"
309
310 }