1 |
Name: FuzzyOcr |
2 |
Version: 3.5.1 |
3 |
Release: 2%{?dist} |
4 |
Summary: An OCR plugin for SpamAssassin |
5 |
|
6 |
Group: Development/Libraries |
7 |
License: Apache |
8 |
URL: http://fuzzyocr.own-hero.net/wiki |
9 |
Source0: http://users.own-hero.net/~decoder/fuzzyocr/fuzzyocr-%{version}-devel.tar.gz |
10 |
Patch100: FuzzyOcr-3.5.1-locations.patch |
11 |
Patch101: FuzzyOcr-3.5.1-pamditherbw.patch |
12 |
Patch102: FuzzyOcr-3.5.1-scanorder.patch |
13 |
Patch103: FuzzyOcr-3.5.1-fixes.patch |
14 |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) |
15 |
BuildArch: noarch |
16 |
|
17 |
AutoReqProv: No |
18 |
Requires: perl |
19 |
Requires: gocr |
20 |
Requires: gifsicle |
21 |
Requires: ocrad |
22 |
Requires: netpbm-progs |
23 |
Requires: spamassassin >= 3.1.8 |
24 |
Requires: /usr/bin/giffix |
25 |
Requires: /usr/bin/giftext |
26 |
Requires: /usr/bin/gifinter |
27 |
Requires: perl(MLDBM) |
28 |
Requires: perl(String::Approx) |
29 |
Requires: perl(Time::HiRes) |
30 |
Requires: perl(MLDBM::Sync) |
31 |
Requires: perl(Log::Agent) |
32 |
Requires: perl(Tie::Cache) |
33 |
|
34 |
%description |
35 |
This plugin checks for specific keywords in GIF, JPEG, and PNG |
36 |
attachments, using gocr (an optical character recognition program). |
37 |
|
38 |
This plugin can be used to detect spam that puts all the real spam content |
39 |
in an attached image. The mail itself often will contain only random text |
40 |
and random html, without any URL's or identifiable information. |
41 |
|
42 |
This plugin has been extended to do approximate matches on words, so |
43 |
errors in recognition or attempts to obfuscate the text inside the image |
44 |
will not cause the detection to fail. |
45 |
|
46 |
|
47 |
%prep |
48 |
%setup |
49 |
%patch100 -p1 |
50 |
%patch101 -p1 |
51 |
%patch102 -p1 |
52 |
%patch103 -p1 |
53 |
%{__perl} -pi -e "s#/usr/local/bin/perl#/usr/bin/perl#g" Utils/* |
54 |
|
55 |
|
56 |
%install |
57 |
# Determine the proper perl directory: |
58 |
eval `%{__perl} -V:installsitelib` |
59 |
|
60 |
install -d %{buildroot}$installsitelib/Mail/SpamAssassin/Plugin/ |
61 |
install -d %{buildroot}$installsitelib/Mail/SpamAssassin/Plugin/FuzzyOcr/ |
62 |
install -d %{buildroot}%{_sysconfdir}/mail/spamassassin/ |
63 |
install -d %{buildroot}%{_bindir} |
64 |
|
65 |
install -m 644 FuzzyOcr.words %{buildroot}%{_sysconfdir}/mail/spamassassin/FuzzyOcr.words |
66 |
install -m 644 FuzzyOcr.cf %{buildroot}%{_sysconfdir}/mail/spamassassin/FuzzyOcr.cf |
67 |
install -m 644 FuzzyOcr.preps %{buildroot}%{_sysconfdir}/mail/spamassassin/FuzzyOcr.preps |
68 |
install -m 644 FuzzyOcr.scansets %{buildroot}%{_sysconfdir}/mail/spamassassin/FuzzyOcr.scansets |
69 |
install -m 644 FuzzyOcr.mysql %{buildroot}%{_sysconfdir}/mail/spamassassin/FuzzyOcr.mysql |
70 |
install -m 444 FuzzyOcr.pm %{buildroot}$installsitelib/Mail/SpamAssassin/Plugin/FuzzyOcr.pm |
71 |
install -m 444 FuzzyOcr/* %{buildroot}$installsitelib/Mail/SpamAssassin/Plugin/FuzzyOcr/ |
72 |
install -m 755 Utils/* %{buildroot}%{_bindir} |
73 |
|
74 |
# List files in perl directories above |
75 |
find %{buildroot}$installsitelib -type f \ |
76 |
| %{__perl} -pi -e 's#^%{buildroot}##g' > %{name}-%{version}-%{release}-filelist |
77 |
|
78 |
%pre |
79 |
|
80 |
%post |
81 |
|
82 |
%postun |
83 |
|
84 |
%clean |
85 |
rm -rf %{buildroot} |
86 |
|
87 |
%files -f %{name}-%{version}-%{release}-filelist |
88 |
%defattr(-,root,root) |
89 |
%doc INSTALL CHANGES |
90 |
|
91 |
%attr(0755,root,root) %{_bindir}/* |
92 |
%config %{_sysconfdir}/mail/spamassassin/* |
93 |
|
94 |
%changelog |
95 |
* Sun Apr 29 2007 Shad L. Lords <slords@mail.com> |
96 |
- Clean up spec so package can be built by koji/plague |
97 |
|
98 |
* Sun Jan 07 2007 Shad L. Lords <slords@mail.com 3.5.1-2 |
99 |
- Apply latest svn patches. |
100 |
- Update requires so el5 install works. [SME: 2628] |
101 |
|
102 |
* Sun Jan 07 2007 Shad L. Lords <slords@mail.com 3.5.1-1 |
103 |
- Upgrade to 3.5.1 |
104 |
|
105 |
* Sat Dec 23 2006 Shad L. Lords <slords@mail.com 3.5.0-0.rc1.sme.8 |
106 |
- Apply patchset 3 for rc1 |
107 |
|
108 |
* Thu Dec 14 2006 Shad L. Lords <slords@mail.com 3.5.0-0.rc1.sme.7 |
109 |
- Apply patchset 1 & 2 for rc1 |
110 |
|
111 |
* Mon Dec 11 2006 Shad L. Lords <slords@mail.com 3.5.0-0.rc1.sme.6 |
112 |
- Makek perl requires require perl modules not package names |
113 |
- Move FuzzyOcr perl modules to correct place |
114 |
- Finish patching netbpm stuff for CentOS |
115 |
|
116 |
* Sun Dec 10 2006 Greg Swallow <greg@runlevel7.ca> 3.5.0-0.rc1.sme.5 |
117 |
- add perl-MLDBM-Sync and perl-Time-Hires to requires, both are |
118 |
available from rpmforge |
119 |
- add perl-Log-Agent to requires - found src rpm here: |
120 |
http://apt.bea.ki.se/biorpms/fedora/linux/1/i386/SRPMS.biorpms/ |
121 |
(might work??) |
122 |
|
123 |
* Sun Dec 10 2006 Greg Swallow <greg@runlevel7.ca> 3.5.0-0.rc1 |
124 |
- Fix typo in FuzzyOcr.preps |
125 |
|
126 |
* Sun Dec 10 2006 Shad L. Lords <slords@mail.com> 3.5.0-0.rc1 |
127 |
- Fix location in cf file |
128 |
|
129 |
* Sun Dec 10 2006 Greg Swallow <greg@runlevel7.ca> 3.5.0-0.rc1 |
130 |
- Update to 3.5.0 rc1 version |
131 |
- listed a few more new files |
132 |
- added patch to work with netpbm in CentOS |
133 |
|
134 |
* Thu Dec 07 2006 Shad L. Lords <slords@mail.com> |
135 |
- Update to new release naming. No functional changes. |
136 |
- Make Packager generic |
137 |
|
138 |
* Mon Nov 20 2006 Japheth Cleaver <cleaver@redwire.net> 3.4.2-devel |
139 |
- new package |
140 |
|