From: "Agostino Sarubbo" <ago@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-mail/dbmail/
Date: Wed, 4 Apr 2018 20:03:37 +0000 (UTC) [thread overview]
Message-ID: <1522872209.bb2db800978bb3f4e205f0c833666932c9a76cdb.ago@gentoo> (raw)
commit: bb2db800978bb3f4e205f0c833666932c9a76cdb
Author: Agostino Sarubbo <ago <AT> gentoo <DOT> org>
AuthorDate: Wed Apr 4 19:31:49 2018 +0000
Commit: Agostino Sarubbo <ago <AT> gentoo <DOT> org>
CommitDate: Wed Apr 4 20:03:29 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bb2db800
net-mail/dbmail: add systemd support, install docs via dodocs, fix DESCRIPTION.toolong. Leave the upstream suggestions to the maintainer judgment
Bug: https://bugs.gentoo.org/588690
Package-Manager: Portage-2.3.24, Repoman-2.3.6
net-mail/dbmail/dbmail-3.2.3-r2.ebuild | 135 +++++++++++++++++++++++++++++++++
1 file changed, 135 insertions(+)
diff --git a/net-mail/dbmail/dbmail-3.2.3-r2.ebuild b/net-mail/dbmail/dbmail-3.2.3-r2.ebuild
new file mode 100644
index 00000000000..6d19833506f
--- /dev/null
+++ b/net-mail/dbmail/dbmail-3.2.3-r2.ebuild
@@ -0,0 +1,135 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit systemd versionator user
+
+DESCRIPTION="Fast and scalable sql based email services"
+HOMEPAGE="http://www.dbmail.org/"
+SRC_URI="http://www.dbmail.org/download/$(get_version_component_range 1-2)/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="ldap sieve ssl static"
+
+DEPEND="dev-db/libzdb
+ sieve? ( >=mail-filter/libsieve-2.2.1 )
+ ldap? ( >=net-nds/openldap-2.3.33 )
+ app-text/asciidoc
+ app-text/xmlto
+ app-crypt/mhash
+ sys-libs/zlib
+ dev-libs/gmime:2.6
+ >=dev-libs/glib-2.16
+ dev-libs/libevent
+ ssl? ( dev-libs/openssl )"
+RDEPEND="${DEPEND}"
+
+pkg_setup() {
+ enewgroup dbmail
+ enewuser dbmail -1 -1 /var/lib/dbmail dbmail
+}
+
+src_configure() {
+ econf \
+ --enable-manpages \
+ --enable-systemd \
+ --sysconfdir=/etc/dbmail \
+ $(use_enable static) \
+ $(use_with sieve) \
+ $(use_with ldap auth-ldap)
+}
+
+src_install() {
+ emake DESTDIR="${D}" SYSTEMD_UNIT_DIR="$(systemd_get_systemunitdir)" install
+
+ DOCS=( AUTHORS README.md INSTALL THANKS UPGRADING )
+ einstalldocs
+
+ docompress -x /usr/share/doc/${PF}/sql
+ dodoc -r sql
+ dodoc -r test-scripts
+ dodoc -r contrib
+ ## TODO: install other contrib stuff
+
+ sed -i -e "s:nobody:dbmail:" dbmail.conf || die
+ sed -i -e "s:nogroup:dbmail:" dbmail.conf || die
+ sed -i -e "s:/var/run:/run/dbmail:" dbmail.conf || die
+
+ insinto /etc/dbmail
+ newins dbmail.conf dbmail.conf.dist
+
+ # change config path to our default and use the conf.d and init.d files from the contrib dir
+ sed -i -e "s:/etc/dbmail.conf:/etc/dbmail/dbmail.conf:" contrib/startup-scripts/gentoo/init.d-dbmail || die
+ #sed -i -e "s:exit 0:return 1:" contrib/startup-scripts/gentoo/init.d-dbmail || die
+ #sed -i -e "s:/var/run:/var/run/dbmail:" contrib/startup-scripts/gentoo/init.d-dbmail || die
+ #newconfd contrib/startup-scripts/gentoo/conf.d-dbmail dbmail
+ #newinitd contrib/startup-scripts/gentoo/init.d-dbmail dbmail
+ # use custom init scripts until updated in upstream contrib
+ newinitd "${FILESDIR}/dbmail-imapd.initd" dbmail-imapd
+ newinitd "${FILESDIR}/dbmail-lmtpd.initd" dbmail-lmtpd
+ newinitd "${FILESDIR}/dbmail-pop3d.initd" dbmail-pop3d
+ newinitd "${FILESDIR}/dbmail-timsieved.initd" dbmail-timsieved
+ sed -i -e "s:/var/run:/run:" "${D}"/etc/init.d/dbmail-* || die
+
+ dobin contrib/mailbox2dbmail/mailbox2dbmail
+ doman contrib/mailbox2dbmail/mailbox2dbmail.1
+
+ # ldap schema
+ if use ldap; then
+ insinto /etc/openldap/schema
+ doins "${S}/dbmail.schema"
+ fi
+
+ keepdir /var/lib/dbmail
+ fperms 750 /var/lib/dbmail
+ fowners dbmail:dbmail /var/lib/dbmail
+ # create this through init-scripts instead of at install time (bug #455002)
+ #keepdir /run/dbmail
+ #fowners dbmail:dbmail /run/dbmail
+}
+
+pkg_postinst() {
+ elog "Please read the INSTALL file in /usr/share/doc/${PF}/"
+ elog "for remaining instructions on setting up dbmail users and "
+ elog "for finishing configuration to connect to your MTA and "
+ elog "to connect to your db."
+ echo
+ elog "DBMail requires either SQLite, PostgreSQL or MySQL."
+ elog "Database schemes can be found in /usr/share/doc/${PF}/"
+ elog "You will also want to follow the installation instructions"
+ elog "on setting up the maintenance program to delete old messages."
+ elog "Don't forget to edit /etc/dbmail/dbmail.conf as well."
+ echo
+ elog "For regular maintenance, add this to crontab:"
+ elog "0 3 * * * /usr/bin/dbmail-util -cpdy >/dev/null 2>&1"
+ echo
+ elog "Please make sure to run etc-update."
+ elog "If you get an error message about plugins not found"
+ elog "please add the library_directory configuration switch to"
+ elog "dbmail.conf and set it to the correct path"
+ elog "(usually /usr/lib/dbmail or /usr/lib64/dbmail on amd64)"
+ elog "A sample can be found in dbmail.conf.dist after etc-update."
+ echo
+ elog "We are now using the init script from upstream."
+ elog "Please edit /etc/conf.d/dbmail to set which services to start"
+ elog "and delete /etc/init.d/dbmail-* when you are done. (don't"
+ elog "forget to rc-update del dbmail-* first)"
+ echo
+ elog "Changed pid directory to /run/dbmail (see"
+ elog "http://www.dbmail.org/mantis/view.php?id=949 for details)"
+ echo
+ ewarn "The database config has changed to support libzdb db URI"
+ ewarn "Please check the documentation (or Bug #479664)"
+ echo
+ ewarn "The database schema has changed since 3.0.x make sure"
+ ewarn "to run the migration script"
+ echo
+ ewarn "Please be aware, that the single init-script for all services"
+ ewarn "has been replaced with seperate init scripts for the individual services."
+ ewarn "Make sure to add dbmail-(imapd|lmtpd|pop3d|timsieved) using rc-update"
+ ewarn "and remove dbmail if you want to take advantage of this change."
+ echo
+}
next reply other threads:[~2018-04-04 20:03 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-04 20:03 Agostino Sarubbo [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-06-25 4:15 [gentoo-commits] repo/gentoo:master commit in: net-mail/dbmail/ Sam James
2022-03-22 23:32 Sam James
2021-05-02 12:51 Mikle Kolyada
2021-03-12 21:56 Thomas Raschbacher
2021-01-30 10:26 Sam James
2021-01-07 10:14 David Seifert
2020-12-31 1:20 Sam James
2018-05-20 13:34 Johannes Huber
2018-05-20 13:34 Johannes Huber
2018-04-24 21:21 Aaron Bauman
2017-08-19 0:31 Thomas Deutschmann
2017-07-15 17:04 Tobias Klausmann
2017-01-25 23:34 Patrice Clement
2016-11-25 21:35 Thomas Raschbacher
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1522872209.bb2db800978bb3f4e205f0c833666932c9a76cdb.ago@gentoo \
--to=ago@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox