# Maintainer: Valery Kartel # Contributor: Valery Kartel pkgname=rmilter pkgver=1.7.4 pkgrel=0 pkgdesc="Rspamd mail filter" url="https://rspamd.com" arch="all" license="BSD" pkgusers="rmilter" pkggroups="rmilter" depends="" depends_dev="" makedepends="$depends_dev cmake bison flex bsd-compat-headers openssl-dev pcre-dev libmilter-dev opendkim-dev hiredis-dev" install="$pkgname.pre-install" subpackages="$pkgname-doc" source="$pkgname-$pkgver.tar.gz::https://github.com/vstakhov/$pkgname/archive/$pkgver.tar.gz $pkgname.conf $pkgname.confd $pkgname.initd config_dir.patch system_hiredis.patch " _builddir="$srcdir"/$pkgname-$pkgver prepare() { cd "$_builddir" for i in $source; do case $i in *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; esac done } build() { cd "$_builddir" cmake CMakeLists.txt \ -DCMAKE_INSTALL_PREFIX=/usr \ -DRMILTER_USER=$pkgusers \ -DRMILTER_GROUP=$pkggroups \ || return 1 make || return 1 } package() { cd "$_builddir" make DESTDIR="$pkgdir" install || return 1 install -d "$pkgdir"/etc/mail/dkim install -Dm755 "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname install -Dm644 "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname install -Dm644 "$srcdir"/$pkgname.conf "$pkgdir"/etc/$pkgname/$pkgname.conf } md5sums="19bfb8c918ecd56c1ab9994e2e2a80d9 rmilter-1.7.4.tar.gz 74b3a71b9e14d548f9bbade386cdacae rmilter.conf e159e4461b765b487f72c05b3d504a9c rmilter.confd a3fa9ba78d3392716d04f27e40e40ac8 rmilter.initd 9fe7aea93e81b7e36020f186c5b9288d config_dir.patch 388470c71ad9d98088e2338a7b7066b7 system_hiredis.patch" sha256sums="ad32c2efe23c8b49f6b52a5b78b80943b93082d30c799e3de05f9df1c02b83fb rmilter-1.7.4.tar.gz 65f602b802766ff71807ca5537c2c17b400e0dfd915223ddeb306db074162019 rmilter.conf fad2d6baea215c3b31750e8128efe557a27024974eca2ff359b8fa921acb9076 rmilter.confd ce592d80851b0a52138bfa97f70c3e98a21555daa9e8a9f3966b7cafca1acc3c rmilter.initd 863d36c15386e8927775fd368fdba4b234bbab83bfbd6a156f328b356880a91b config_dir.patch 49d964572ba4660bf4a9893eca5ed90b20a64ed02258d99e43687aeed6222852 system_hiredis.patch" sha512sums="189f792664e30a0d60c618b902c393a4af570bea38810001aa759acae27fbb625389576eb3923678fddaca806b946e99e0444738b24aa3124e988bbc2ab1552b rmilter-1.7.4.tar.gz 4b577dbe63277dd932be74fad78989366056e3d0b7945af17906da17f685b19d0c58078398277ece4cff6304af8e20f45e61d196c86f933c7c5857efdecbdd81 rmilter.conf d222bcf307e89f110efed524c2d708d3512d4400235091de0250d1f60358f65871667112bdad61bbcd948a9abdb8a46d8c3952cf78585cfb59fcf94f15849062 rmilter.confd 2ec3eb3fece210867001cf3a799336c77dfec7dd770442852a14b337205893aaefe24999ca5c0d92706bf8e9f1c8a192282e5c48b7bde2e591b03f721560e6e3 rmilter.initd cd6cd168e0d0d14d62a74e59be7eebff4951f14f017e1b5e688aff78f5f119729c067074e9d12518fe8b4699aaa4c6a78de8c19226b91316844c636ab667fc8e config_dir.patch 536d35c2a8797f375f8dc77eb86c2012712ba7a4861f33513c795ef1d902f5db83383a0033e486bac02a5631e012aff96b600216119ab71ffce510a17880c554 system_hiredis.patch"