Files
void-packages/srcpkgs/dovecot/template
Đoàn Trần Công Danh b6bcd8cd34 srcpkgs/d*: convert patches to -Np1
* daemontools and dmraid is kept at -Np0

```sh

git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

116 lines
3.7 KiB
Bash

# Template file for 'dovecot'
# revbump dovecot-plugin-pigeonhole when updating dovecot!
pkgname=dovecot
version=2.3.14
revision=2
build_style=gnu-configure
configure_args="--with-moduledir=/usr/lib/dovecot/modules --with-sql=plugin
--disable-static --with-pam --with-mysql --with-pgsql --with-lucene
--with-sqlite --with-ssl=openssl --with-ssldir=/etc/dovecot/ssl
--with-gssapi --with-ldap=plugin --with-zlib --with-bzlib --with-lzma
--with-lz4 --with-libcap --with-solr --with-docs --sbindir=/usr/bin"
hostmakedepends="pkg-config perl"
makedepends=" liblz4-devel zlib-devel bzip2-devel liblzma-devel openssl-devel
mit-krb5-devel libmariadbclient-devel postgresql-libs-devel sqlite-devel
clucene-devel libldap-devel libcap-devel pam-devel libcurl-devel expat-devel
libsodium-devel"
short_desc="IMAP and POP3 server written with security primarily in mind"
maintainer="Leah Neukirchen <leah@vuxu.org>"
license="LGPL-2.1-or-later"
homepage="https://dovecot.org/"
distfiles="${homepage}/releases/2.3/${pkgname}-${version}.tar.gz"
checksum=c8b3d7f3af1e558a3ff0f970309d4013a4d3ce136f8c02a53a3b05f345b9a34a
keep_libtool_archives=yes
if [ "$CROSS_BUILD" ]; then
_tsize=${XBPS_TARGET_WORDSIZE}
# FIXME: remove for time64 rebuild
#[ "$XBPS_TARGET_LIBC" = "musl" ] && _tsize=64
configure_args+="
i_cv_epoll_works=yes
i_cv_inotify_works=yes
i_cv_posix_fallocate_works=yes
i_cv_signed_size_t=no
i_cv_gmtime_max_time_t=${_tsize}
i_cv_signed_time_t=yes
i_cv_mmap_plays_with_write=yes
i_cv_fd_passing=yes
i_cv_c99_vsnprintf=yes
i_cv_gssapi_spnego=yes
lib_cv_va_copy=yes
lib_cv___va_copy=yes
lib_cv_va_val_copy=yes"
fi
# For SSL support.
depends="ca-certificates"
system_accounts="_dovecot _dovenull"
post_install() {
vsconf doc/dovecot-openssl.cnf
vsconf doc/mkcert.sh
mv ${DESTDIR}/usr/share/doc/dovecot/example-config/* \
${DESTDIR}/usr/share/examples/dovecot
mv ${DESTDIR}/usr/share/examples/dovecot/*.ext \
${DESTDIR}/usr/share/examples/dovecot/conf.d
rm ${DESTDIR}/etc/dovecot/README
vsv dovecot
}
dovecot-devel_package() {
depends="dovecot>=${version}"
short_desc+=" - development files"
pkg_install() {
vmove usr/include
vmove usr/share/aclocal
vmove usr/lib/dovecot/dovecot-config
}
}
dovecot-plugin-ldap_package() {
depends="dovecot>=${version}"
short_desc+=" - LDAP plugin"
pkg_install() {
vmove usr/lib/dovecot/libdovecot-ldap.*
vmove usr/lib/dovecot/modules/dict/libdict_ldap.so
vmove usr/lib/dovecot/modules/auth/libauthdb_ldap.so
vmove usr/share/examples/dovecot/conf.d/auth-ldap.conf.ext
vmove usr/share/examples/dovecot/conf.d/dovecot-ldap.conf.ext
}
}
dovecot-plugin-lucene_package() {
depends="dovecot>=${version}"
short_desc+=" - Full Text Search plugin (Lucene)"
pkg_install() {
vmove usr/lib/dovecot/modules/doveadm/lib20_doveadm_fts_lucene_plugin.so
vmove usr/lib/dovecot/modules/lib21_fts_lucene_plugin.so
}
}
dovecot-plugin-mysql_package() {
depends="dovecot>=${version}"
short_desc+=" - MySQL plugin"
pkg_install() {
vmove usr/lib/dovecot/modules/auth/libdriver_mysql.so
vmove usr/lib/dovecot/modules/dict/libdriver_mysql.so
vmove usr/lib/dovecot/modules/libdriver_mysql.so
}
}
dovecot-plugin-pgsql_package() {
depends="dovecot>=${version}"
short_desc+=" - PostgreSQL plugin"
pkg_install() {
vmove usr/lib/dovecot/modules/auth/libdriver_pgsql.so
vmove usr/lib/dovecot/modules/dict/libdriver_pgsql.so
vmove usr/lib/dovecot/modules/libdriver_pgsql.so
}
}
dovecot-plugin-sqlite_package() {
depends="dovecot>=${version}"
short_desc+=" - SQLite plugin"
pkg_install() {
vmove usr/lib/dovecot/modules/auth/libdriver_sqlite.so
vmove usr/lib/dovecot/modules/dict/libdriver_sqlite.so
vmove usr/lib/dovecot/modules/libdriver_sqlite.so
}
}