Gentoo Archives: gentoo-commits

From: "Thomas Raschbacher (lordvan)" <lordvan@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-antivirus/clamav: metadata.xml clamav-0.98.5.ebuild ChangeLog
Date: Thu, 27 Nov 2014 09:30:44
Message-Id: 20141127093040.D9324B02A@oystercatcher.gentoo.org
1 lordvan 14/11/27 09:30:40
2
3 Modified: metadata.xml ChangeLog
4 Added: clamav-0.98.5.ebuild
5 Log:
6 version bump - fixes bug #529728
7
8 (Portage version: 2.2.8-r1/cvs/Linux x86_64, signed Manifest commit with key )
9
10 Revision Changes Path
11 1.3 app-antivirus/clamav/metadata.xml
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-antivirus/clamav/metadata.xml?rev=1.3&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-antivirus/clamav/metadata.xml?rev=1.3&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-antivirus/clamav/metadata.xml?r1=1.2&r2=1.3
16
17 Index: metadata.xml
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/app-antivirus/clamav/metadata.xml,v
20 retrieving revision 1.2
21 retrieving revision 1.3
22 diff -u -r1.2 -r1.3
23 --- metadata.xml 3 Apr 2009 08:20:19 -0000 1.2
24 +++ metadata.xml 27 Nov 2014 09:30:40 -0000 1.3
25 @@ -5,5 +5,6 @@
26 <herd>antivirus</herd>
27 <use>
28 <flag name="clamdtop">A Top like tool which shows what clamd is currently scanning amongst other things</flag>
29 + <flag name="metadata-analysis-api">Enables collection of file property metadata using ClamAV API for analysis by ClamAV bytecode programs.</flag>
30 </use>
31 </pkgmetadata>
32
33
34
35 1.491 app-antivirus/clamav/ChangeLog
36
37 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-antivirus/clamav/ChangeLog?rev=1.491&view=markup
38 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-antivirus/clamav/ChangeLog?rev=1.491&content-type=text/plain
39 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-antivirus/clamav/ChangeLog?r1=1.490&r2=1.491
40
41 Index: ChangeLog
42 ===================================================================
43 RCS file: /var/cvsroot/gentoo-x86/app-antivirus/clamav/ChangeLog,v
44 retrieving revision 1.490
45 retrieving revision 1.491
46 diff -u -r1.490 -r1.491
47 --- ChangeLog 2 Nov 2014 09:01:47 -0000 1.490
48 +++ ChangeLog 27 Nov 2014 09:30:40 -0000 1.491
49 @@ -1,6 +1,13 @@
50 # ChangeLog for app-antivirus/clamav
51 # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
52 -# $Header: /var/cvsroot/gentoo-x86/app-antivirus/clamav/ChangeLog,v 1.490 2014/11/02 09:01:47 ago Exp $
53 +# $Header: /var/cvsroot/gentoo-x86/app-antivirus/clamav/ChangeLog,v 1.491 2014/11/27 09:30:40 lordvan Exp $
54 +
55 +*clamav-0.98.5 (27 Nov 2014)
56 +
57 + 27 Nov 2014; Thomas Raschbacher <lordvan@g.o> +clamav-0.98.5.ebuild,
58 + metadata.xml:
59 + version bump + local use flag for new feature.
60 + Fixes bug #529728
61
62 02 Nov 2014; Agostino Sarubbo <ago@g.o> clamav-0.98.4.ebuild:
63 Stable for alpha, wrt bug #521478
64
65
66
67 1.1 app-antivirus/clamav/clamav-0.98.5.ebuild
68
69 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-antivirus/clamav/clamav-0.98.5.ebuild?rev=1.1&view=markup
70 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-antivirus/clamav/clamav-0.98.5.ebuild?rev=1.1&content-type=text/plain
71
72 Index: clamav-0.98.5.ebuild
73 ===================================================================
74 # Copyright 1999-2014 Gentoo Foundation
75 # Distributed under the terms of the GNU General Public License v2
76 # $Header: /var/cvsroot/gentoo-x86/app-antivirus/clamav/clamav-0.98.5.ebuild,v 1.1 2014/11/27 09:30:40 lordvan Exp $
77
78 EAPI=5
79
80 inherit eutils flag-o-matic user systemd
81
82 DESCRIPTION="Clam Anti-Virus Scanner"
83 HOMEPAGE="http://www.clamav.net/"
84 SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
85
86 LICENSE="GPL-2"
87 SLOT="0"
88 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~sparc-solaris ~x86-solaris"
89 IUSE="bzip2 clamdtop iconv ipv6 milter metadata-analysis-api selinux static-libs uclibc"
90
91 CDEPEND="bzip2? ( app-arch/bzip2 )
92 clamdtop? ( sys-libs/ncurses )
93 iconv? ( virtual/libiconv )
94 metadata-analysis-api? ( dev-libs/json-c )
95 milter? ( || ( mail-filter/libmilter mail-mta/sendmail ) )
96 dev-libs/libtommath
97 >=sys-libs/zlib-1.2.2
98 dev-libs/openssl
99 sys-devel/libtool"
100 # openssl is now *required* see this link as to why
101 # http://www.clamav.net/lang/en/2014/02/22/introducing-openssl-as-a-dependency-to-clamav/
102 DEPEND="${CDEPEND}
103 virtual/pkgconfig"
104 RDEPEND="${CDEPEND}
105 selinux? ( sec-policy/selinux-clamav )"
106
107 DOCS=( AUTHORS BUGS ChangeLog FAQ INSTALL NEWS README UPGRADE )
108
109 pkg_setup() {
110 enewgroup clamav
111 enewuser clamav -1 -1 /dev/null clamav
112 }
113
114 src_prepare() {
115 use ppc64 && append-flags -mminimal-toc
116 use uclibc && export ac_cv_type_error_t=yes
117 }
118
119 src_configure() {
120 econf \
121 --disable-experimental \
122 --disable-fanotify \
123 --enable-id-check \
124 --with-dbdir="${EPREFIX}"/var/lib/clamav \
125 --with-system-tommath \
126 --with-zlib="${EPREFIX}"/usr \
127 $(use_enable bzip2) \
128 $(use_enable clamdtop) \
129 $(use_enable ipv6) \
130 $(use_enable milter) \
131 $(use_enable static-libs static) \
132 $(use_with iconv) \
133 $(use_with metadata-analysis-api libjson /usr)
134 }
135
136 src_install() {
137 default
138
139 rm -rf "${ED}"/var/lib/clamav
140 newinitd "${FILESDIR}"/clamd.initd-r6 clamd
141 newconfd "${FILESDIR}"/clamd.conf-r1 clamd
142
143 systemd_dotmpfilesd "${FILESDIR}/tmpfiles.d/clamav.conf"
144 systemd_newunit "${FILESDIR}/clamd_at.service" "clamd@.service"
145 systemd_dounit "${FILESDIR}/clamd.service"
146 systemd_dounit "${FILESDIR}/freshclamd.service"
147
148 keepdir /var/lib/clamav
149 fowners clamav:clamav /var/lib/clamav
150 keepdir /var/log/clamav
151 fowners clamav:clamav /var/log/clamav
152
153 dodir /etc/logrotate.d
154 insinto /etc/logrotate.d
155 newins "${FILESDIR}"/clamav.logrotate clamav
156
157 # Modify /etc/{clamd,freshclam}.conf to be usable out of the box
158 sed -i -e "s:^\(Example\):\# \1:" \
159 -e "s:.*\(PidFile\) .*:\1 ${EPREFIX}/var/run/clamav/clamd.pid:" \
160 -e "s:.*\(LocalSocket\) .*:\1 ${EPREFIX}/var/run/clamav/clamd.sock:" \
161 -e "s:.*\(User\) .*:\1 clamav:" \
162 -e "s:^\#\(LogFile\) .*:\1 ${EPREFIX}/var/log/clamav/clamd.log:" \
163 -e "s:^\#\(LogTime\).*:\1 yes:" \
164 -e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
165 "${ED}"/etc/clamd.conf.sample || die
166 sed -i -e "s:^\(Example\):\# \1:" \
167 -e "s:.*\(PidFile\) .*:\1 ${EPREFIX}/var/run/clamav/freshclam.pid:" \
168 -e "s:.*\(DatabaseOwner\) .*:\1 clamav:" \
169 -e "s:^\#\(UpdateLogFile\) .*:\1 ${EPREFIX}/var/log/clamav/freshclam.log:" \
170 -e "s:^\#\(NotifyClamd\).*:\1 ${EPREFIX}/etc/clamd.conf:" \
171 -e "s:^\#\(ScriptedUpdates\).*:\1 yes:" \
172 -e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
173 "${ED}"/etc/freshclam.conf.sample || die
174
175 if use milter ; then
176 # MilterSocket one to include ' /' because there is a 2nd line for
177 # inet: which we want to leave
178 dodoc "${FILESDIR}"/clamav-milter.README.gentoo
179 sed -i -e "s:^\(Example\):\# \1:" \
180 -e "s:.*\(PidFile\) .*:\1 ${EPREFIX}/var/run/clamav/clamav-milter.pid:" \
181 -e "s+^\#\(ClamdSocket\) .*+\1 unix:${EPREFIX}/var/run/clamav/clamd.sock+" \
182 -e "s:.*\(User\) .*:\1 clamav:" \
183 -e "s+^\#\(MilterSocket\) /.*+\1 unix:${EPREFIX}/var/run/clamav/clamav-milter.sock+" \
184 -e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
185 -e "s:^\#\(LogFile\) .*:\1 ${EPREFIX}/var/log/clamav/clamav-milter.log:" \
186 "${ED}"/etc/clamav-milter.conf.sample || die
187 cat >> "${ED}"/etc/conf.d/clamd <<-EOF
188 MILTER_NICELEVEL=19
189 START_MILTER=no
190 EOF
191
192 systemd_newunit "${FILESDIR}/clamav-milter.service-r1" clamav-milter.service
193 fi
194
195 for i in clamd freshclam clamav-milter
196 do
197 [[ -f "${D}"/etc/"${i}".conf.sample ]] && mv "${D}"/etc/"${i}".conf{.sample,}
198 done
199
200 prune_libtool_files --all
201 }
202
203 pkg_postinst() {
204 if use milter ; then
205 elog "For simple instructions how to setup the clamav-milter read the"
206 elog "clamav-milter.README.gentoo in /usr/share/doc/${PF}"
207 fi
208 if test -z $(find "${ROOT}"var/lib/clamav -maxdepth 1 -name 'main.c*' -print -quit) ; then
209 ewarn "You must run freshclam manually to populate the virus database files"
210 ewarn "before starting clamav for the first time.\n"
211 fi
212 }