From ab1a76054e476edd4a0342d01ac765af084b7a92 Mon Sep 17 00:00:00 2001 From: Carlo Landmeter Date: Wed, 12 May 2010 10:49:38 +0000 Subject: main/clamav: upgrade to 0.96 --- main/clamav/APKBUILD | 71 +++++++++++++++++++++++++++++++--------------------- 1 file changed, 42 insertions(+), 29 deletions(-) (limited to 'main/clamav/APKBUILD') diff --git a/main/clamav/APKBUILD b/main/clamav/APKBUILD index fc5b194141..b59af1b953 100644 --- a/main/clamav/APKBUILD +++ b/main/clamav/APKBUILD @@ -1,8 +1,8 @@ # Contributor: Carlo Landmeter # Maintainer: Carlo Landmeter pkgname=clamav -pkgver=0.95.3 -pkgrel=1 +pkgver=0.96 +pkgrel=0 pkgusers=clamav pkggroups=clamav pkgdesc="An anti-virus toolkit for UNIX" @@ -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 -- cgit v1.2.3