summaryrefslogtreecommitdiffstats
path: root/main/clamav/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'main/clamav/APKBUILD')
-rw-r--r--main/clamav/APKBUILD69
1 files changed, 41 insertions, 28 deletions
diff --git a/main/clamav/APKBUILD b/main/clamav/APKBUILD
index 0b12df40..b59af1b9 100644
--- a/main/clamav/APKBUILD
+++ b/main/clamav/APKBUILD
@@ -1,7 +1,7 @@
# Contributor: Carlo Landmeter <clandmeter at gmail>
# Maintainer: Carlo Landmeter <clandmeter at gmail>
pkgname=clamav
-pkgver=0.95.3
+pkgver=0.96
pkgrel=0
pkgusers=clamav
pkggroups=clamav
@@ -21,48 +21,61 @@ source="http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz
clamav.logrotate
"
-build() {
- cd "$srcdir/$pkgname-$pkgver"
+_builddir="$srcdir/$pkgname-$pkgver"
+
+prepare() {
+ cd "$_builddir"
patch -p0 -i "$srcdir/clamav-0.95.1-nls.patch" || return 1
+}
+
+build() {
+ cd "$_builddir"
./configure --prefix=/usr \
--sysconfdir=/etc/clamav \
--mandir=/usr/share/man \
--infodir=/usr/share/info \
- --without-iconv
+ --without-iconv \
+ --disable-llvm
+
make || return 1
+}
+
+package() {
+ cd "$_builddir"
+
make DESTDIR="$pkgdir" install
- # Change /etc/clamd.conf to be usable out of the box
- sed -i -e "s:^\(Example\):\# \1:" \
- -e "s:.*\(PidFile\) .*:\1 /var/run/clamav/clamd.pid:" \
- -e "s:.*\(LocalSocket\) .*:\1 /var/run/clamav/clamd.sock:" \
- -e "s:.*\(User\) .*:\1 clamav:" \
- -e "s:^\#\(LogFile\) .*:\1 /var/log/clamav/clamd.log:" \
- -e "s:^\#\(LogTime\).*:\1 yes:" \
- -e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
- "$pkgdir"/etc/clamav/clamd.conf
+ # Change /etc/clamd.conf to be usable out of the box
+ sed -i -e "s:^\(Example\):\# \1:" \
+ -e "s:.*\(PidFile\) .*:\1 /var/run/clamav/clamd.pid:" \
+ -e "s:.*\(LocalSocket\) .*:\1 /var/run/clamav/clamd.sock:" \
+ -e "s:.*\(User\) .*:\1 clamav:" \
+ -e "s:^\#\(LogFile\) .*:\1 /var/log/clamav/clamd.log:" \
+ -e "s:^\#\(LogTime\).*:\1 yes:" \
+ -e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
+ "$pkgdir"/etc/clamav/clamd.conf
- # Do the same for /etc/freshclam.conf
- sed -i -e "s:^\(Example\):\# \1:" \
- -e "s:.*\(PidFile\) .*:\1 /var/run/clamav/freshclam.pid:" \
- -e "s:.*\(DatabaseOwner\) .*:\1 clamav:" \
- -e "s:^\#\(UpdateLogFile\) .*:\1 /var/log/clamav/freshclam.log:" \
- -e "s:^\#\(NotifyClamd\).*:\1 /etc/clamav/clamd.conf:" \
- -e "s:^\#\(ScriptedUpdates\).*:\1 yes:" \
- -e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
- "$pkgdir"/etc/clamav/freshclam.conf
+ # Do the same for /etc/freshclam.conf
+ sed -i -e "s:^\(Example\):\# \1:" \
+ -e "s:.*\(PidFile\) .*:\1 /var/run/clamav/freshclam.pid:" \
+ -e "s:.*\(DatabaseOwner\) .*:\1 clamav:" \
+ -e "s:^\#\(UpdateLogFile\) .*:\1 /var/log/clamav/freshclam.log:" \
+ -e "s:^\#\(NotifyClamd\).*:\1 /etc/clamav/clamd.conf:" \
+ -e "s:^\#\(ScriptedUpdates\).*:\1 yes:" \
+ -e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
+ "$pkgdir"/etc/clamav/freshclam.conf
- install -m755 -D "$srcdir"/clamd.initd "$pkgdir"/etc/init.d/clamd
- install -m644 -D "$srcdir"/clamd.confd "$pkgdir"/etc/conf.d/clamd
+ install -m755 -D "$srcdir"/clamd.initd "$pkgdir"/etc/init.d/clamd
+ install -m644 -D "$srcdir"/clamd.confd "$pkgdir"/etc/conf.d/clamd
install -m755 -D "$srcdir"/freshclam.initd "$pkgdir"/etc/init.d/freshclam
- install -m644 -D "$srcdir"/freshclam.confd "$pkgdir"/etc/conf.d/freshclam
- install -m644 -D "$srcdir"/clamav.logrotate "$pkgdir"/etc/logrotate.d/clamav
- mkdir -p "$pkgdir"/var/run/clamav "$pkgdir"/var/log/clamav
+ install -m644 -D "$srcdir"/freshclam.confd "$pkgdir"/etc/conf.d/freshclam
+ install -m644 -D "$srcdir"/clamav.logrotate "$pkgdir"/etc/logrotate.d/clamav
+ mkdir -p "$pkgdir"/var/run/clamav "$pkgdir"/var/log/clamav
}
-md5sums="eaf9fccc3cc3567605a9732313652967 clamav-0.95.3.tar.gz
+md5sums="28ac7bec4cc03627a8e2d6e8647ee661 clamav-0.96.tar.gz
d64432c463850663c5041c3097f3e903 clamd.initd
567bc32b657dd7031b9b7beaa946203a clamd.confd
f4d1f415322905128dc27135566ad136 freshclam.initd