source: projects/specs/branches/6/s/spamassassin/spamassassin-vl.spec @ 3346

Revision 3346, 13.7 KB checked in by tomop, 13 years ago (diff)

spamassassin-3.3.1-1

Line 
1
2%define pdir    Mail
3%define pnam    SpamAssassin
4
5%define version 3.3.1
6%define real_version 3.3.1
7%define release 1%{_dist_release}
8%define cfdate 20110406
9%define name spamassassin
10%define _initrddir /etc/rc.d/init.d/
11%define initdir %{_initrddir}
12#%define __find_provides /usr/lib/rpm/find-provides.perl
13#%define __find_requires /usr/lib/rpm/find-requires.perl
14
15Summary: a spam filter for email which can be invoked from mail delivery agents
16Summary(ja): MDA から起動できる spam email filter
17Group: Applications/Internet
18Name: %{name}
19Version: %{version}
20Release: %{release}
21License: Apache License 2.0
22URL: http://spamassassin.org/
23Source0: http://spamassassin.org/released/Mail-SpamAssassin-%{real_version}.tar.bz2
24Source1: sample-japanese-local.cf-%{cfdate}
25Source2: README.vine
26Source3: filter.sh
27Source4: sa-update.cronscript
28Source5: sa-update.crontab
29Source6: sa-update.logrotate
30Patch0: spamassassin-3.1.7_rules.patch
31Patch1: spamassassin-3.3.1-fix-deprecated.patch
32Patch2: spamassassin-3.3.1-fix-deprecated2.patch
33Buildroot: %{_tmppath}/%{name}-%{version}-root
34Requires(pre): /sbin/chkconfig
35Requires(pre): perl-Mail-SpamAssassin = %{version}-%{release}
36Requires(pre): spamassassin-tools = %{version}-%{release}
37Requires: perl >= 1:5.10.0
38Requires: perl(Pod::Usage), perl(HTML::Parser) >= 3.43 perl(Digest::SHA1)
39Requires: perl(Net::DNS)
40# sa-update's Requires
41Requires: perl(Archive::Tar) >= 1.23 perl(IO::Zlib) >= 1.04 perl(LWP)
42
43BuildRequires: perl >= 1:5.10.0 perl(HTML::Parser) >= 3.43 perl(Digest::SHA1)
44BuildRequires: perl(Archive::Tar) >= 1.23 perl(IO::Zlib) >= 1.04
45BuildRequires: perl(Net::DNS)
46BuildRequires: perl(NetAddr::IP)
47
48Vendor: Project Vine
49Distribution: Vine Linux
50
51%description
52SpamAssassin provides you with a way to reduce if not completely eliminate
53Unsolicited Commercial Email (spam) from your incoming email.  It can
54be invoked by a MDA such as sendmail or postfix, or can be called from
55a procmail script, .forward file, etc.  It uses a genetic-algorithm
56evolved scoring system to identify messages which look spammy, then
57adds headers to the message so they can be filtered by the user's mail
58reading software.  This distribution includes the spamd/spamc components
59which create a server that considerably speeds processing of mail.
60
61%description -l ja
62SpamAssassin は商用電子メール(スパム)を除去する手段を提供する filter です。
63
64sendmail または postfix のような MDA から SpamAssassin を起動することが
65可能です。
66また procmail スクリプト、.forward ファイルなどからも呼ぶことができます。
67
68SpamAssassin は、スパムメッセージを識別するために遺伝的アルゴリズムを
69発展させた、得点システムを使用しています。
70ユーザのメールソフト (MUA) がそれらをフィルタリングすることができるように、
71メッセージにヘッダーを加えます。
72また、メイルの処理速度を要求されるサーバーで用いる spamd/spamc コンポー
73ネントを含んでいます。
74
75日本語のスパムメール用の local.cf を含めています。
76/usr/doc/spamassassin-*/sample-japanese-local.conf を見てください。
77
78%package tools
79Summary: Miscellaneous tools for SpamAssassin
80Summary(ja): SpamAssassin 向けの各種ツール
81Group: Applications/Internet
82Requires(pre): perl-Mail-SpamAssassin = %{version}-%{release}
83Requires: perl >= 1:5.6.1
84Autoreq: no
85
86%description tools
87Miscellaneous tools from various authors, distributed with SpamAssassin.
88See /usr/share/doc/SpamAssassin-tools-*/.
89
90%package -n perl-Mail-SpamAssassin
91Summary: %{pdir}::%{pnam} -- SpamAssassin e-mail filter Perl modules
92Requires: perl >= 1:5.6.1 perl(Pod::Usage) perl(HTML::Parser) >= 3.43
93Group: Development/Libraries
94
95%description -n perl-Mail-SpamAssassin
96Mail::SpamAssassin is a module to identify spam using text analysis and
97several internet-based realtime blacklists. Using its rule base, it uses a
98wide range of heuristic tests on mail headers and body text to identify
99``spam'', also known as unsolicited commercial email. Once identified, the
100mail can then be optionally tagged as spam for later filtering using the
101user's own mail user-agent application.
102
103%prep -q
104%setup -q -n %{pdir}-%{pnam}-%{real_version}
105# %setup -D -a 1 -T -n %{pdir}-%{pnam}-%{real_version}
106
107%patch0 -p0 -b .rules
108
109%patch1 -p0 -b .fix-deprecated
110%patch2 -p0 -b .fix-deprecated2
111
112# Japanese sample file / README
113cp -p %{SOURCE1} sample-japanese-local.cf
114cp -p %{SOURCE2} README.vine
115cp -p %{SOURCE3} filter.sh
116# sa-update sample
117cp -p %{SOURCE4} .
118cp -p %{SOURCE5} .
119cp -p %{SOURCE6} .
120# change README filename
121cp spamd/README spamd/README.spamd
122
123%build
124CFLAGS="$RPM_OPT_FLAGS"; export CFLAGS
125%{__perl} Makefile.PL INSTALLDIRS=vendor < /dev/null
126%{__make}
127%{__make} spamd/libspamc.so
128
129%install
130[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
131
132make DESTDIR=$RPM_BUILD_ROOT install
133
134install -d $RPM_BUILD_ROOT/%{initdir}
135install -m 0755 spamd/redhat-rc-script.sh $RPM_BUILD_ROOT/%{initdir}/spamassassin
136mkdir -p $RPM_BUILD_ROOT/etc/mail/spamassassin
137mkdir -p $RPM_BUILD_ROOT/var/spool/spamassassin
138
139# [ -x /usr/lib/rpm/brp-compress ] && /usr/lib/rpm/brp-compress
140
141%clean
142[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
143
144%post
145# install
146# if [ $1 = 1 ]; then
147#         /sbin/chkconfig --add spamassassin
148# fi
149
150if [ -x /usr/bin/sa-update ] ; then
151echo "Update rules"
152/usr/bin/sa-update ||:
153fi
154
155# update
156if [ $1 = 2 ]; then
157    if [ -x /usr/bin/sa-learn ] ; then
158        echo "Sync DB (sa-learn --sync)"
159        /usr/bin/sa-learn --sync
160    fi
161    if [ -f /var/lock/subsys/spamassassin ]; then
162        echo "restarting spamd"
163        %{initdir}/spamassassin restart
164    else
165        echo 'If you use spamd,'
166        echo '  "/etc/rc.d/init.d/spamassassin start"'
167        echo 'to start the spamd daemon.'
168    fi
169fi
170
171%post -n perl-Mail-SpamAssassin
172if [ -x /usr/bin/sa-update ] ; then
173echo "Update rules"
174/usr/bin/sa-update ||:
175fi
176
177%pre -n perl-Mail-SpamAssassin
178# update
179if [ $1 = 2 ]; then
180    if [ -x /usr/bin/sa-learn ] ; then
181        echo "Sync DB (sa-learn --sync)"
182        /usr/bin/sa-learn --sync ||:
183    fi
184fi
185
186%preun
187# remove
188if [ $1 = 0 ]; then
189        if [ -f /var/lock/subsys/spamassassin ]; then
190                %{initdir}/spamassassin stop 1>&2
191        fi
192        /sbin/chkconfig --del spamassassin
193fi
194
195%files
196%defattr(-,root,root)
197%doc CREDITS Changes INSTALL INSTALL.VMS LICENSE MANIFEST MANIFEST.SKIP
198%doc NOTICE PACKAGING README README.vine TRADEMARK UPGRADE USAGE
199%doc sql
200%doc filter.sh
201%doc sample-nonspam.txt sample-spam.txt
202%doc spamd/README.spamd
203%doc sample-japanese-local.cf
204%doc sa-update.*
205%attr(755,root,root) %{_bindir}/*
206%config %attr(755,root,root) %{initdir}/spamassassin
207%{_mandir}/man1/*
208
209%files -n spamassassin-tools
210%defattr(644,root,root,755)
211%doc sql
212
213%files -n perl-Mail-SpamAssassin
214%defattr(644,root,root,755)
215%{perl_vendorlib}/Mail/*
216%{perl_vendorlib}/spamassassin-run.pod
217
218%config(noreplace) %{_sysconfdir}/mail/spamassassin
219%{_datadir}/spamassassin
220%{_mandir}/man3/*
221%attr(775,root,root) /var/spool/spamassassin
222
223%changelog
224* Fri Apr 08 2011 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.3.1-1
225- new upstream release.
226- replaced "Prereq:" and "BuildPrereq".
227- updated sample-japanese-local.cf.
228- added Patch1 and Patch2 for perl-5.12.x.
229
230* Mon Jun 22 2009 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.2.5-1
231- new upstream release.
232- wrote spec in UTF-8.
233- updated sample-japanese-local.cf.
234
235* Thu May  1 2008 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net>
236- 3.2.4-1
237- rebuilt with perl-5.10.0.
238
239* Sun Feb 24 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
240- 3.2.4-0vl1
241- new upstream release (built for VineSeed)
242- update Requires/BuildRequires tag perl(HTML::Parser) >= 3.43
243- enable Requires for sa-update
244- remove "(noreplace)" from init script
245- remove Vine 3.x if-endif section
246- remove script for upgrading from sa 2.x
247- turn on daemon restart message
248- update sample-japanese-local.cf
249
250* Wed Jan 02 2008 Shu KONNO <owa@bg.wakwak.com> 3.2.3-0vl1
251- new upstream release
252
253* Thu Feb 20 2007 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
254- 3.1.8-0vl2
255- rebuilt for VinePlus 4.x
256- installed perl modules to vendor_perl dir
257
258* Sun Feb 18 2007 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
259- 3.1.8-0vl1
260- built for VinePlus 3.x
261- installed perl modules to site_perl dir
262- add restart spamd process automactically (update)
263
264  - * Thu Dec 07 2006 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
265  - 3.1.7-0vl1.1
266  - fix file list
267  - sample-japanese-local.cf update
268  - README.vine update
269
270* Sun Feb 18 2007 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
271- 3.1.8-0vl0.1
272- test package (not released)
273- built for VinePlus 4.0
274- new upstream release with security fix (CVE-2007-0451)
275- add Source4,5,6 for sa-update sample file
276
277* Tue Nov 07 2006 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
278- 3.1.7-0vl3
279- fix file list
280- sample-japanese-local.cf update
281- README.vine update
282- fix changelog missing
283
284* Mon Oct 16 2006 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
285- 3.1.7-0vl2
286- built for VinePlus 4.0
287- This package is based on VinePlus 3.x package
288- installed perl modules to vendor_perl dir
289
290  - * Tue Jul 11 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.64-0vl3
291  - rebuilt with perl 5.8.6
292  - changed Group to Applications/Internet
293  - installed perl modules to vendor_perl dir
294
295* Sat Oct 14 2006 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
296- 3.1.7-0vl1
297- new upstream release
298- add %pre -n perl-Mail-SpamAssassin script for updating package
299- add README.vine filter.sh
300- change License to Apache License 2.0
301
302* Sat Oct 07 2006 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
303- 3.1.5-0vl1
304- new upstream release
305- built for VinePlus 3.2
306
307* Sat Nov 27 2004 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
308- 2.64-0vl2
309- rebuild for VinePlus 3.0
310
311* Sat Nov 27 2004 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
312- 2.64-0vl1
313- rebuild for VinePlus 2.5/2.6
314- Source version up
315- Sample-japanese-local.cf update
316
317* Sun Apr 10 2004 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
318- 2.63-0vl4
319- rebuild for VineSeed Plus
320- Sample-japanese-local.cf update
321
322* Mon Apr 05 2004 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
323- 2.63-0vl3
324- Source version up
325- Sample-japanese-local.cf update
326
327* Sun Apr 04 2004 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
328- 2.63-0vl2
329- Source version up
330- Sample-japanese-local.cf update
331
332* Sat Dec 23 2003 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
333- 2.61-0vl1
334- Source version up
335- Sample-japanese-local.cf update
336- Change make & install method for 2.61
337- fix Require
338- add post/preun script for update from 2.5x
339- add Vendor/Distribution tag
340
341* Sat May 24 2003 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
342- 2.55-0vl2
343- Sample-japanese-local.cf update
344
345* Sat May 24 2003 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
346- 2.55-0vl1
347- Source version up
348
349* Fri Apr 25 2003 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
350- 2.53-0vl1
351- Source version up
352- Sample-japanese-local.cf update
353
354* Fri Mar 28 2003 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
355- 2.52-0vl1
356- Source version up
357
358* Thu Feb 06 2003 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
359- 2.44-0vl1
360- Source version up
361- Sample-japanese-local.cf update
362- Fix japanese discription
363
364* Wed Oct 23 2002 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
365- 2.43-0vl2
366- Update & fix sample-japanese-local.cf
367
368* Fri Oct 18 2002 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
369- 2.43-0vl1
370- Source version up
371- Change make & install method for 2.43
372- Update sample-japanese-local.cf
373    - Thanx to MATSUDA Yoh-ichi <matsuda@palnet.or.jp> san
374- Change Buildprereq, Requires (perl 5.6.0 -> 5.6.1) for Vine 2.5
375- Add doc qmail
376- Fix cvs version tags (Patch0)
377
378* Thu Oct 10 2002 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
379- 2.42-3vl3
380- stop install sample-japanese-local.cf to /etc/mail/spamassassin
381- add japanese discription
382- Fix Buildrequires
383
384* Tue Oct 08 2002 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
385- 2.42-3vl2
386- Fix Requires, Buildrequires
387- add local.cf for Japanese (from Linux-Users ML spam filter)
388
389* Mon Oct 07 2002 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp>
390- 2.42-3vl1
391- first build for Vine Linux
392- NO run post/preun script
393- add requires perl(Time::HiRes)
394- add define _initrcdir
395
396* Sat Oct 05 2002 Theo Van Dinter <felicity@kluge.net> -3
397- fixed some small typos in the spec file
398
399* Fri Oct 04 2002 Theo Van Dinter <felicity@kluge.net> -2
400- small bug where 2.42 still called itself 2.42-cvs
401
402* Fri Oct 04 2002 Theo Van Dinter <felicity@kluge.net> -1
403- updated to SA 2.42
404
405* Wed Sep 11 2002 Justin Mason <jm-spec@jmason.org>
406- spamassassin RPM now requires perl-Mail-SpamAssassin; from Theo
407
408* Tue Sep 03 2002 Theo Van Dinter <felicity@kluge.net>
409- added INSTALL to documentation files
410- install man pages via _manpage macro to make things consistent
411- added perl requires statement
412- cleaned out some cruft
413- fixed "file listed twice" bug
414
415* Wed Aug 28 2002 Justin Mason <jm-spec@jmason.org>
416- merged code from PLD rpm, split into spamassassin, perl-Mail-SpamAssassin,
417  and spamassassin-tools rpms
418
419* Mon Jul 29 2002 Justin Mason <jm-spec@jmason.org>
420- removed migrate_cfs code, obsolete
421
422* Thu Jul 25 2002 Justin Mason <jm-spec@jmason.org>
423- removed findbin patch, obsolete
424
425* Fri Apr 19 2002 Theo Van Dinter <felicity@kluge.net>
426- Updated for 2.20 release
427- made /etc/mail/spamassassin a config directory so local.cf doesn't get wiped out
428- added a patch to remove findbin stuff
429
430* Wed Feb 27 2002 Craig Hughes <craig@hughes-family.org>
431- Updated for 2.1 release
432
433* Sat Feb 02 2002 Theo Van Dinter <felicity@kluge.net>
434- Updates for 2.01 release
435- Fixed rc file
436- RPM now buildable as non-root
437- fixed post_service errors
438- fixed provides to include perl modules
439- use file find instead of manually specifying files
440
441* Tue Jan 15 2002 Craig Hughes <craig@hughes-family.org>
442- Updated for 2.0 release
443
444* Wed Dec 05 2001 Craig Hughes <craig@hughes-family.org>
445- Updated for final 1.5 distribution.
446
447* Sun Nov 18 2001 Craig Hughes <craig@hughes-family.org>
448- first version of rpm.
449
Note: See TracBrowser for help on using the repository browser.