Lines 12-18
Link Here
|
12 |
|
12 |
|
13 |
LICENSE="GPL-2" |
13 |
LICENSE="GPL-2" |
14 |
SLOT="0" |
14 |
SLOT="0" |
15 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" |
15 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~sparc-solaris ~x86-solaris" |
16 |
IUSE="bzip2 clamdtop iconv ipv6 milter selinux static-libs" |
16 |
IUSE="bzip2 clamdtop iconv ipv6 milter selinux static-libs" |
17 |
|
17 |
|
18 |
CDEPEND="bzip2? ( app-arch/bzip2 ) |
18 |
CDEPEND="bzip2? ( app-arch/bzip2 ) |
Lines 31-38
Link Here
|
31 |
|
31 |
|
32 |
DOCS=( AUTHORS BUGS ChangeLog FAQ INSTALL NEWS README UPGRADE ) |
32 |
DOCS=( AUTHORS BUGS ChangeLog FAQ INSTALL NEWS README UPGRADE ) |
33 |
|
33 |
|
|
|
34 |
#Should be removed in the next release |
35 |
#interix.patch: https://bugzilla.clamav.net/show_bug.cgi?id=5612 |
36 |
#nls.patch: https://bugzilla.clamav.net/show_bug.cgi?id=5611 |
34 |
PATCHES=( |
37 |
PATCHES=( |
35 |
"${FILESDIR}"/${PN}-0.97-nls.patch |
38 |
"${FILESDIR}"/${PN}-0.97-nls.patch |
|
|
39 |
"${FILESDIR}"/${PN}-0.92.1-interix.patch |
36 |
) |
40 |
) |
37 |
|
41 |
|
38 |
pkg_setup() { |
42 |
pkg_setup() { |
Lines 45-61
Link Here
|
45 |
} |
49 |
} |
46 |
|
50 |
|
47 |
src_configure() { |
51 |
src_configure() { |
|
|
52 |
local myconf |
53 |
|
54 |
[[ ${CHOST} == *-interix* ]] && { |
55 |
export ac_cv_func_poll=no |
56 |
export ac_cv_header_inttypes_h=no |
57 |
export ac_cv_func_mmap_fixed_mapped=yes |
58 |
myconf="${myconf} --disable-gethostbyname_r" |
59 |
} |
60 |
|
48 |
econf \ |
61 |
econf \ |
49 |
--disable-experimental \ |
62 |
--disable-experimental \ |
50 |
--enable-id-check \ |
63 |
--enable-id-check \ |
51 |
--with-dbdir=/var/lib/clamav \ |
64 |
--with-dbdir=/var/lib/clamav \ |
52 |
--with-system-tommath \ |
65 |
--with-system-tommath \ |
|
|
66 |
--with-zlib="${EPREFIX}"/usr |
53 |
$(use_enable bzip2) \ |
67 |
$(use_enable bzip2) \ |
54 |
$(use_enable clamdtop) \ |
68 |
$(use_enable clamdtop) \ |
55 |
$(use_enable ipv6) \ |
69 |
$(use_enable ipv6) \ |
56 |
$(use_enable milter) \ |
70 |
$(use_enable milter) \ |
57 |
$(use_enable static-libs static) \ |
71 |
$(use_enable static-libs static) \ |
58 |
$(use_with iconv) |
72 |
$(use_with iconv) \ |
|
|
73 |
${myconf} |
59 |
} |
74 |
} |
60 |
|
75 |
|
61 |
src_install() { |
76 |
src_install() { |
Lines 78-95
Link Here
|
78 |
|
93 |
|
79 |
# Modify /etc/{clamd,freshclam}.conf to be usable out of the box |
94 |
# Modify /etc/{clamd,freshclam}.conf to be usable out of the box |
80 |
sed -i -e "s:^\(Example\):\# \1:" \ |
95 |
sed -i -e "s:^\(Example\):\# \1:" \ |
81 |
-e "s:.*\(PidFile\) .*:\1 /var/run/clamav/clamd.pid:" \ |
96 |
-e "s:.*\(PidFile\) .*:\1 ${EPREFIX}/var/run/clamav/clamd.pid:" \ |
82 |
-e "s:.*\(LocalSocket\) .*:\1 /var/run/clamav/clamd.sock:" \ |
97 |
-e "s:.*\(LocalSocket\) .*:\1 ${EPREFIX}/var/run/clamav/clamd.sock:" \ |
83 |
-e "s:.*\(User\) .*:\1 clamav:" \ |
98 |
-e "s:.*\(User\) .*:\1 clamav:" \ |
84 |
-e "s:^\#\(LogFile\) .*:\1 /var/log/clamav/clamd.log:" \ |
99 |
-e "s:^\#\(LogFile\) .*:\1 ${EPREFIX}/var/log/clamav/clamd.log:" \ |
85 |
-e "s:^\#\(LogTime\).*:\1 yes:" \ |
100 |
-e "s:^\#\(LogTime\).*:\1 yes:" \ |
86 |
-e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \ |
101 |
-e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \ |
87 |
"${ED}"/etc/clamd.conf |
102 |
"${ED}"/etc/clamd.conf |
88 |
sed -i -e "s:^\(Example\):\# \1:" \ |
103 |
sed -i -e "s:^\(Example\):\# \1:" \ |
89 |
-e "s:.*\(PidFile\) .*:\1 /var/run/clamav/freshclam.pid:" \ |
104 |
-e "s:.*\(PidFile\) .*:\1 ${EPREFIX}/var/run/clamav/freshclam.pid:" \ |
90 |
-e "s:.*\(DatabaseOwner\) .*:\1 clamav:" \ |
105 |
-e "s:.*\(DatabaseOwner\) .*:\1 clamav:" \ |
91 |
-e "s:^\#\(UpdateLogFile\) .*:\1 /var/log/clamav/freshclam.log:" \ |
106 |
-e "s:^\#\(UpdateLogFile\) .*:\1 ${EPREFIX}/var/log/clamav/freshclam.log:" \ |
92 |
-e "s:^\#\(NotifyClamd\).*:\1 /etc/clamd.conf:" \ |
107 |
-e "s:^\#\(NotifyClamd\).*:\1 ${EPREFIX}/etc/clamd.conf:" \ |
93 |
-e "s:^\#\(ScriptedUpdates\).*:\1 yes:" \ |
108 |
-e "s:^\#\(ScriptedUpdates\).*:\1 yes:" \ |
94 |
-e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \ |
109 |
-e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \ |
95 |
"${ED}"/etc/freshclam.conf |
110 |
"${ED}"/etc/freshclam.conf |
Lines 99-110
Link Here
|
99 |
# inet: which we want to leave |
114 |
# inet: which we want to leave |
100 |
dodoc "${FILESDIR}"/clamav-milter.README.gentoo |
115 |
dodoc "${FILESDIR}"/clamav-milter.README.gentoo |
101 |
sed -i -e "s:^\(Example\):\# \1:" \ |
116 |
sed -i -e "s:^\(Example\):\# \1:" \ |
102 |
-e "s:.*\(PidFile\) .*:\1 /var/run/clamav/clamav-milter.pid:" \ |
117 |
-e "s:.*\(PidFile\) .*:\1 ${EPREFIX}/var/run/clamav/clamav-milter.pid:" \ |
103 |
-e "s+^\#\(ClamdSocket\) .*+\1 unix:/var/run/clamav/clamd.sock+" \ |
118 |
-e "s+^\#\(ClamdSocket\) .*+\1 unix:${EPREFIX}/var/run/clamav/clamd.sock+" \ |
104 |
-e "s:.*\(User\) .*:\1 clamav:" \ |
119 |
-e "s:.*\(User\) .*:\1 clamav:" \ |
105 |
-e "s+^\#\(MilterSocket\) /.*+\1 unix:/var/run/clamav/clamav-milter.sock+" \ |
120 |
-e "s+^\#\(MilterSocket\) /.*+\1 unix:${EPREFIX}/var/run/clamav/clamav-milter.sock+" \ |
106 |
-e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \ |
121 |
-e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \ |
107 |
-e "s:^\#\(LogFile\) .*:\1 /var/log/clamav/clamav-milter.log:" \ |
122 |
-e "s:^\#\(LogFile\) .*:\1 ${EPREFIX}/var/log/clamav/clamav-milter.log:" \ |
108 |
"${ED}"/etc/clamav-milter.conf |
123 |
"${ED}"/etc/clamav-milter.conf |
109 |
cat > "${ED}"/etc/conf.d/clamd <<-EOF |
124 |
cat > "${ED}"/etc/conf.d/clamd <<-EOF |
110 |
MILTER_NICELEVEL=19 |
125 |
MILTER_NICELEVEL=19 |