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