summaryrefslogtreecommitdiff
path: root/libre/clamav/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'libre/clamav/PKGBUILD')
-rw-r--r--libre/clamav/PKGBUILD100
1 files changed, 51 insertions, 49 deletions
diff --git a/libre/clamav/PKGBUILD b/libre/clamav/PKGBUILD
index 9cb4e81f6..82d1e1d7b 100644
--- a/libre/clamav/PKGBUILD
+++ b/libre/clamav/PKGBUILD
@@ -8,44 +8,35 @@
_pkgname=clamav-libre
pkgname=clamav
-pkgver=0.99.2
-pkgrel=7.parabola1
+pkgver=0.99.3
+pkgrel=1.parabola1
pkgdesc='Anti-virus toolkit for Unix, without nonfree decompression engine for RAR archives'
-url='http://www.clamav.net/'
+url='https://www.clamav.net/'
license=('GPL')
arch=('i686' 'x86_64' 'armv7h')
-makedepends=('libmilter')
-depends=('bzip2' 'libltdl' 'libxml2' 'curl' 'pcre')
-validpgpkeys=('B964E6D7BC7D7C82CCB8D45840B8EA2364221D53'
- 'F79FB2D08751574C5D3FDFFBB3D5342C260429A0')
-mksource=("http://www.clamav.net/downloads/production/${pkgname}-${pkgver}.tar.gz"{,.sig})
-source=("https://repo.parabola.nu/other/${_pkgname}/${_pkgname}-${pkgver}.tar.gz"
- 'logrotate'
- 'tmpfiles.d'
- 'clamd.conf'
- 'freshclam.conf'
- 'clamd.service'
- 'freshclamd.service'
- 'make_it_compile_against_openssl_1_1_0.patch')
-mksha256sums=('167bd6a13e05ece326b968fdb539b05c2ffcfef6018a274a10aeda85c2c0027a'
- 'SKIP')
-sha256sums=('9cbca11e54c78129c0c9495ff40f42e83c34a430e832fdf86c9408bc397d6d07'
- 'ce4b9b8c300614641af600c9a73b52a00ee8e47ccc9f91b2428a113b0ecff21b'
- '0a61abee3b9bba94126afe3344e7d8e82da5120ca6dbd2b413b10f75da5b0b0d'
- 'afdb95f93f7e11e163d368caccd5f6814206c6f0d74816b4f712c0267b50572a'
- '127b39e13525ffb4242198cfb76f99d4d517e5f2fd9fa8dcad3f31fc9f82f952'
- 'e376ab0cefeefa5ac5f1cd611718452ea8646198e854aca3cc0026f5ffe58fb4'
- 'dd5ff6c79ee360da5f2221c4d9110a2a8886d86293f6c93c16bf74fdb126593c'
- '0a8e02a91bc3f2c99bd52dc475592637376baa991fe3f899b7745b840fc586c5')
-
+makedepends=('libmilter' 'systemd')
+depends=('bzip2' 'libltdl' 'libxml2' 'curl' 'pcre' 'libsystemd')
backup=('etc/clamav/clamd.conf'
'etc/clamav/freshclam.conf'
+ 'etc/clamav/clamav-milter.conf'
'etc/logrotate.d/clamav')
-install=install
+install=clamav.install
+mksource=(https://www.clamav.net/downloads/production/${pkgname}-${pkgver}.tar.gz{,.sig})
+source=(https://repo.parabola.nu/other/${_pkgname}/${_pkgname}-${pkgver}.tar.gz
+ clamav.logrotate
+ clamav.tmpfiles
+ clamav.sysusers)
+mksha256sums=('00fa5292a6e00a3a4035b826267748965d5d2c4943d8ff417d740238263e8e84'
+ 'SKIP')
+sha256sums=('fb59578c5793eac997a0472a85c6bfb1e9680b8b11e82f40ee10dfd48c1c5321'
+ 'c36e3ddf790fa6ea90169038ae08521a31652a372017e6e38858e28fc63b3f74'
+ '8e216c7e4763a273a120930787dcc444ea221bb719eed180a9d15b4c1d603a84'
+ '01a896c3a1cd34b323594403fd82a9e353b5aa848b8462137b621959558199e8')
+validpgpkeys=('65ED513993F08DA06F9639A6F13F9E16BCA5BFAD') # Talos (Talos, Cisco Systems Inc.) <research@sourcefire.com>
mksource() {
- cd "${srcdir}/${pkgname}-${pkgver}"
+ cd ${pkgname}-${pkgver}
msg2 "remove nonfree unRAR utility files from the source"
rm -rv libclamunrar
@@ -53,28 +44,42 @@ mksource() {
}
prepare() {
- cd "${srcdir}/${pkgname}-${pkgver}"
-
- patch -Np1 -i ../make_it_compile_against_openssl_1_1_0.patch
- autoreconf -fi
+ cd ${pkgname}-${pkgver}
+ sed -E 's|^(Example)$|#\1|' -i etc/{clamd,freshclam,clamav-milter}.conf.sample
+ sed -E 's|#(User) .+|\1 clamav|' -i etc/{clamd,freshclam,clamav-milter}.conf.sample
+ sed -E 's|#(LogFile) .+|\1 /var/log/clamav/clamd.log|' -i etc/clamd.conf.sample
+ sed -E 's|#(LogTime) .+|\1 yes|' -i etc/clamd.conf.sample etc/clamav-milter.conf.sample
+ sed -E 's|#(PidFile) .+|\1 /run/clamav/clamd.pid|' -i etc/clamd.conf.sample
+ sed -E 's|#(TemporaryDirectory) .+|\1 /tmp|' -i etc/{clamd,clamav-milter}.conf.sample
+ sed -E 's|#(LocalSocket) .+|\1 /run/clamav/clamd.ctl|' -i etc/clamd.conf.sample
+ sed -E 's|#(UpdateLogFile) .+|\1 /var/log/clamav/freshclam.log|' -i etc/freshclam.conf.sample
+ sed -E 's|#(DatabaseMirror) .+|\1 database.clamav.net|' -i etc/freshclam.conf.sample
+ sed -E 's|#(NotifyClamd) .+|\1 /etc/clamav/clamd.conf|' -i etc/freshclam.conf.sample
+ sed -E 's|#(PidFile) .+|\1 /run/clamav/freshclam.pid|' -i etc/freshclam.conf.sample
+ sed -E 's|#(LogFile) .+|\1 /var/log/clamav/clamav-milter.log|' -i etc/clamav-milter.conf.sample
+ sed -E 's|#(PidFile) .+|\1 /run/clamav/clamav-milter.pid|' -i etc/clamav-milter.conf.sample
+ autoreconf -fiv
}
build() {
- cd "${srcdir}/${pkgname}-${pkgver}"
-
- # --disable-zlib-vcheck:
- # the configure script thinks that zlib 1.2.11 is older than 1.2.2
+ cd ${pkgname}-${pkgver}
+ # --disable-zlib-vcheck because the configure script thinks that
+ # zlib 1.2.11 is older than 1.2.2
# --enable-llvm=no:
- # workaround for database update issues
+ # workaround for database update issues
./configure \
--prefix=/usr \
--sbindir=/usr/bin \
--sysconfdir=/etc/clamav \
--with-dbdir=/var/lib/clamav \
+ --with-user=clamav \
+ --with-group=clamav \
+ --disable-rpath \
--disable-clamav \
--disable-llvm \
- --disable-zlib-vcheck \
+ --enable-zlib-vcheck \
--enable-milter \
+ --enable-clamdtop \
--disable-unrar \
--enable-llvm=no
@@ -83,17 +88,14 @@ build() {
}
package() {
- cd "${srcdir}/${pkgname}-${pkgver}"
-
+ cd ${pkgname}-${pkgver}
make DESTDIR="${pkgdir}" install
- install -Dm644 ../clamd.conf "${pkgdir}"/etc/clamav/clamd.conf
- install -Dm644 ../freshclam.conf "${pkgdir}"/etc/clamav/freshclam.conf
- install -Dm644 ../freshclamd.service "${pkgdir}"/usr/lib/systemd/system/freshclamd.service
- install -Dm644 ../clamd.service "${pkgdir}"/usr/lib/systemd/system/clamd.service
- install -Dm644 ../tmpfiles.d "${pkgdir}"/usr/lib/tmpfiles.d/clamav.conf
- install -Dm644 ../logrotate "${pkgdir}"/etc/logrotate.d/clamav
+ mv "${pkgdir}"/etc/clamav/freshclam.conf{.sample,}
+ mv "${pkgdir}"/etc/clamav/clamd.conf{.sample,}
+ mv "${pkgdir}"/etc/clamav/clamav-milter.conf{.sample,}
- install -d -o 64 -g 64 "${pkgdir}"/var/log/clamav
- install -d -o 64 -g 64 "${pkgdir}"/var/lib/clamav
+ install -Dm 644 ../clamav.sysusers "${pkgdir}"/usr/lib/sysusers.d/clamav.conf
+ install -Dm 644 ../clamav.tmpfiles "${pkgdir}"/usr/lib/tmpfiles.d/clamav.conf
+ install -Dm 644 ../clamav.logrotate "${pkgdir}"/etc/logrotate.d/clamav
}