From 24b0b7c9a392ce310544b1abeb231f8d6f9cfa04 Mon Sep 17 00:00:00 2001 From: Hanno Boeck Date: Mon, 8 Mar 2010 19:25:25 +0000 Subject: [PATCH] courier version bump Package-Manager: portage-2.1.8.2/cvs/Linux x86_64 --- mail-mta/courier/ChangeLog | 7 +- mail-mta/courier/Manifest | 10 +- mail-mta/courier/courier-0.64.1.ebuild | 298 +++++++++++++++++++++++++ 3 files changed, 310 insertions(+), 5 deletions(-) create mode 100644 mail-mta/courier/courier-0.64.1.ebuild diff --git a/mail-mta/courier/ChangeLog b/mail-mta/courier/ChangeLog index ed24ef417438..42de7ef239ed 100644 --- a/mail-mta/courier/ChangeLog +++ b/mail-mta/courier/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for mail-mta/courier # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/courier/ChangeLog,v 1.125 2010/01/31 19:49:45 tove Exp $ +# $Header: /var/cvsroot/gentoo-x86/mail-mta/courier/ChangeLog,v 1.126 2010/03/08 19:25:25 hanno Exp $ + +*courier-0.64.1 (08 Mar 2010) + + 08 Mar 2010; Hanno Boeck +courier-0.64.1.ebuild: + Version bump. 31 Jan 2010; Torsten Veller courier-0.59.0.ebuild, courier-0.60.0.ebuild, courier-0.61.1.ebuild, courier-0.61.2.ebuild: diff --git a/mail-mta/courier/Manifest b/mail-mta/courier/Manifest index d58f8a1fa074..d44a3d6b677e 100644 --- a/mail-mta/courier/Manifest +++ b/mail-mta/courier/Manifest @@ -20,6 +20,7 @@ DIST courier-0.61.2.tar.bz2 7268675 RMD160 a738e534df69fee51aec50a53ce6e5d799f0e DIST courier-0.62.2.tar.bz2 7132042 RMD160 787b0240a0683350d0d1d7fc5220505d82579af7 SHA1 f7c49a86dc6560e4ab33870c9ac4983aac03949b SHA256 7b129ee12bb0f942354fb09527f706821556a0aa824798cafd004b8f60da2964 DIST courier-0.63.0.tar.bz2 7133009 RMD160 bb47bf049c831756b5352ad1df5f7f4a67a8d52b SHA1 79d8b3b2e4cdcc07cc54308bac689255816ef9e6 SHA256 3a52363605f75f4156105aefa6bd375626f742033fbf09b5592179f274322044 DIST courier-0.64.0.tar.bz2 7136191 RMD160 b38563ec054110068d1b2f6399bdb6539ec272a0 SHA1 921d69f2235be7fd548b9082abdaf0cc18e84223 SHA256 9e72165a6c369d135a128af7e69afa3cfa7be608f8f75049b517a077524aa9cc +DIST courier-0.64.1.tar.bz2 7131375 RMD160 f7a0733ab2c4f8e0743bbe8b0fb4c44a5d75ceec SHA1 c8b81a2deb87ce07c74033fae807a498e4958e52 SHA256 b1cc5d95b256b7467743bcd78536c952febe3bfd7926fcc51742bf105deaadee EBUILD courier-0.59.0.ebuild 10182 RMD160 1413ac22e5b57759999ff06a9c3bec995be8713a SHA1 4ee2d6678a5f6a5d666dcd6911d9fc14a573059a SHA256 8433ade399e4e008d2dbb93664b495217cd46b1b5267f100db95223d265f0bff EBUILD courier-0.60.0.ebuild 10058 RMD160 13a5eec2ea8aa98f31d2705bee260e2c79e44c71 SHA1 a81541e6ccdbc24aa6a75d09393b6a70162ff89f SHA256 44dc228aa76394241380bbb949ea5a06429f5ea847b441fa97afe676c26fffc9 EBUILD courier-0.61.1.ebuild 9858 RMD160 c695fd2e54d957c47d01802e6836df81e02a30aa SHA1 8cc728d9ae50b2564766262e25dc5d41c5a8e3bd SHA256 b9918da2a96533658cd1be657c5c9010678b8a52a0efbb08cfca5cf0ffab175e @@ -27,12 +28,13 @@ EBUILD courier-0.61.2.ebuild 9837 RMD160 0b829630e392c0ef4e4d7f712249617666f6850 EBUILD courier-0.62.2.ebuild 9286 RMD160 153b69c0e0560ff286cef03338c0c890b3a492db SHA1 28d2abad1538836ba73a6c8d32faf750dbed9468 SHA256 611d13b3cfec69437d99cc52f1f7ae08b46b5bf6efa01e261d56155d8e44bcb1 EBUILD courier-0.63.0.ebuild 9289 RMD160 c439f1922f943fac54f42a74a9eaa8dd0672c3ac SHA1 894a86396f4e88faaf7b4e25eff9f85a02f46e1c SHA256 c9c8ac2ea2d101036a145e7f514a13028ee0ae282bdff146ca5ba0d4129c9b7f EBUILD courier-0.64.0.ebuild 9291 RMD160 2ddc600a9a2ae6c6a65b945278e7763e42f96016 SHA1 db7aa900c1b4867a0e07afbb1b5ab9fbce9d6fe9 SHA256 3aaac9deb944d0326b5147b8aa7f648fbd654fc7beac460373ea663f338fe7a7 -MISC ChangeLog 31404 RMD160 3c08192e351aa2faf4dd3d9c0310236232f76293 SHA1 fd580a76879eaa2c6fd5f4ad255a1cc5ae9f4259 SHA256 8972ebf395d04c3027c8f72e941cddd2d7212e14cb8d6205626123e6c8a9ea1e +EBUILD courier-0.64.1.ebuild 9291 RMD160 a9145a796cf832a96c98771df262a9efae3ca8c2 SHA1 0e390c3459e19887b7c530bd2b38c4e10a08c96a SHA256 a0e132b59a715b1dadbf939da2aa34998aeef5095fcc25b5060ba0f93c3e52c1 +MISC ChangeLog 31523 RMD160 e0a4e4f8b31ff3319ea45d613834ab46208c8f2a SHA1 88d734e066c85cca73385d5f164cc7c42567f039 SHA256 1daa4f0966455ec03ee73f81de3b8b7c55fc81da66cb09b0b34925165b2a7a5d MISC metadata.xml 687 RMD160 753323e40a9add2b07fd1f138c672ce283d2f255 SHA1 2e8255902a9e0394bd27e13e488e84ba70f05845 SHA256 ea417e66d396e793212529ed20f5570b0c97eb666a5ba52bb3202bbfbc022be1 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (GNU/Linux) -iEYEARECAAYFAktl3t8ACgkQV3J2n04EauypnQCfeXRqEsIcHJajCLsq2EvYBNuW -CnEAniF48yqq1z2gI4dQUhgRLg2Su+/2 -=5Bnw +iEYEARECAAYFAkuVTysACgkQr2QksT29OyBRHwCgibj+VWIq2NurgdC4orzaih7g +m1YAn3tbkh0/kxpKYmIs8Sth8MuGjmHI +=IgzJ -----END PGP SIGNATURE----- diff --git a/mail-mta/courier/courier-0.64.1.ebuild b/mail-mta/courier/courier-0.64.1.ebuild new file mode 100644 index 000000000000..eda6ae8eafd4 --- /dev/null +++ b/mail-mta/courier/courier-0.64.1.ebuild @@ -0,0 +1,298 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/mail-mta/courier/courier-0.64.1.ebuild,v 1.1 2010/03/08 19:25:25 hanno Exp $ + +inherit eutils flag-o-matic + +DESCRIPTION="An MTA designed specifically for maildirs" +SRC_URI="mirror://sourceforge/courier/${P}.tar.bz2" +HOMEPAGE="http://www.courier-mta.org/" +SLOT="0" +LICENSE="GPL-2" +# not in keywords due to missing dependencies: ~arm ~s390 ~ppc64 ~mips +KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~sparc ~x86" +IUSE="postgres ldap mysql pam nls ipv6 spell fax crypt norewrite mailwrapper \ + fam web webmail" + +PROVIDE="virtual/mta + virtual/mda + virtual/imapd" + +DEPEND=" + >=net-libs/courier-authlib-0.61.0 + >=dev-libs/openssl-0.9.6 + >=sys-libs/gdbm-1.8.0 + dev-libs/libpcre + app-misc/mime-types + fax? ( >=media-libs/netpbm-9.12 app-text/ghostscript-gpl >=net-dialup/mgetty-1.1.28 ) + pam? ( virtual/pam ) + mysql? ( virtual/mysql ) + ldap? ( >=net-nds/openldap-1.2.11 ) + postgres? ( virtual/postgresql-base ) + spell? ( virtual/aspell-dict ) + fam? ( virtual/fam ) + !mailwrapper? ( !virtual/mta ) + !virtual/imapd + !mail-filter/maildrop" + +RDEPEND="${DEPEND} + dev-lang/perl + sys-process/procps" + +PDEPEND="mailwrapper? ( >=net-mail/mailwrapper-0.2 ) + pam? ( net-mail/mailbase ) + crypt? ( >=app-crypt/gnupg-1.0.4 )" + +src_unpack() { + unpack ${A} + cd "${S}" + use norewrite && epatch "${FILESDIR}/norewrite.patch" +} + +src_compile() { + filter-flags '-fomit-frame-pointer' + + local myconf + myconf="" + + use ldap && myconf="${myconf} --with-ldapconfig=/etc/courier/maildropldap.conf" + + econf ${myconf} \ + $(use_with fam) \ + $(use_with ipv6) \ + $(use_with spell ispell) \ + $(use_with ldap ldapaliasd) \ + $(use_enable ldap maildroldap) \ + --enable-mimetypes=/etc/mime.types \ + --prefix=/usr \ + --disable-root-check \ + --mandir=/usr/share/man \ + --sysconfdir=/etc/courier \ + --libexecdir=/usr/$(get_libdir)/courier \ + --datadir=/usr/share/courier \ + --sharedstatedir=/var/lib/courier/com \ + --localstatedir=/var/lib/courier \ + --with-piddir=/var/run/courier \ + --with-authdaemonvar=/var/lib/courier/authdaemon \ + --with-mailuser=mail \ + --with-mailgroup=mail \ + --with-paranoid-smtpext \ + --with-db=gdbm \ + --disable-autorenamesent \ + --cache-file="${S}/configuring.cache" \ + --host="${CHOST}" debug=true || die "./configure" + sed -e'/^install-perms-local:/a\ sed -e\"s|^|'"${D}"'|g\" -i permissions.dat' -i Makefile + emake || die "Compile problem" +} + +etc_courier() { + # Import existing /etc/courier/file if it exists. + # Add option only if it was not already set or even commented out + file="${1}" ; word="`echo \"${2}\" | sed -e\"s|=.*$||\" -e\"s|^.*opt ||\"`" + [ ! -e "${D}/etc/courier/${file}" ] && [ -e "/etc/courier/${file}" ] && \ + cp "/etc/courier/${file}" "${D}/etc/courier/${file}" + grep -q "${word}" "${D}/etc/courier/${file}" || \ + echo "${2}" >> "${D}/etc/courier/${file}" +} + +etc_courier_chg() { + file="${1}" ; key="${2}" ; value="${3}" ; section="${4}" + [ -z "${section}" ] && section="${2}" + grep -q "${key}" "${file}" && elog "Changing ${file}: ${key} to ${value}" + sed -i -e"/\#\#NAME: ${section}/,+30 s|${key}=.*|${key}=\"${value}\"|g" ${file} +} + +src_install() { + local f + diropts -o mail -g mail + keepdir /var/run/courier + keepdir /var/lib/courier/tmp + keepdir /var/lib/courier/msgs + make install DESTDIR="${D}" || die "install" + make install-configure || die "install-configure" + + # Get rid of files we dont want + if ! use webmail ; then + cd "${D}" + cat "${FILESDIR}/webmail_files" | xargs rm -rf + fi + + if ! use web ; then + cd "${D}" + cat "${FILESDIR}/webadmin_files" | xargs rm -rf + fi + + for dir2keep in $(cd "${D}" && find ./var/lib/courier -type d) ; do + keepdir "$dir2keep" || die "failed running keepdir: $dir2keep" + done + + newinitd "${FILESDIR}/courier-init-r2" "courier" + use fam || sed -i -e's|^.*use famd$||g' "${D}/etc/init.d/courier" + + cd "${D}/etc/courier" + if use webmail ; then + insinto /etc/courier + newins "${FILESDIR}/apache-sqwebmail.inc" apache-sqwebmail.inc + fi + + for f in *.dist ; do cp "${f}" "${f%%.dist}" ; done + if use ldap ; then + [ -e ldapaliasrc ] && ( chown root:0 ldapaliasrc ; chmod 400 ldapaliasrc ) + else + rm -f ldapaliasrc + fi + + ( [ -e /etc/courier/sizelimit ] && cat /etc/courier/sizelimit || echo 0 ) \ + > "${D}/etc/courier/sizelimit" + etc_courier maildroprc "" + etc_courier esmtproutes "" + etc_courier backuprelay "" + etc_courier locallowercase "" + etc_courier bofh "opt BOFHBADMIME=accept" + etc_courier bofh "opt BOFHSPFTRUSTME=1" + etc_courier bofh "opt BOFHSPFHELO=pass,neutral,unknown,none,error,softfail,fail" + etc_courier bofh "opt BOFHSPFHELO=pass,neutral,unknown,none" + etc_courier bofh "opt BOFHSPFFROM=all" + etc_courier bofh "opt BOFHSPFMAILFROM=all" + etc_courier bofh "#opt BOFHSPFHARDERROR=fail" + etc_courier esmtpd "BOFHBADMIME=accept" + etc_courier esmtpd-ssl "BOFHBADMIME=accept" + etc_courier esmtpd-msa "BOFHBADMIME=accept" + + use fam && etc_courier_chg imapd IMAP_CAPABILITY "IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA AUTH=CRAM-MD5 AUTH=CRAM-SHA1 AUTH=CRAM-SHA256 IDLE" + use fam || etc_courier_chg imapd IMAP_CAPABILITY "IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA AUTH=CRAM-MD5 AUTH=CRAM-SHA1 AUTH=CRAM-SHA256" + + # Fix for a sandbox violation on subsequential merges + # - ticho@gentoo.org, 2005-07-10 + rm "${D}"/usr/sbin/{pop3d,imapd}{,-ssl} + dosym /usr/share/courier/pop3d /usr/sbin/courier-pop3d + dosym /usr/share/courier/pop3d-ssl /usr/sbin/courier-pop3d-ssl + dosym /usr/share/courier/imapd /usr/sbin/courier-imapd + dosym /usr/share/courier/imapd-ssl /usr/sbin/courier-imapd-ssl + + cd "${S}" + cp imap/README README.imap + use nls && cp unicode/README README.unicode + dodoc AUTHORS BENCHMARKS COPYING* ChangeLog* INSTALL NEWS README* TODO courier/doc/*.txt + dodoc tcpd/README.couriertls + mv "${D}/usr/share/courier/htmldoc" "${D}/usr/share/doc/${P}/html" + + if use webmail ; then + insinto /usr/$(get_libdir)/courier/courier + insopts -m 755 -o mail -g mail + doins "${S}/courier/webmaild" + fi + + if use web ; then + insinto /etc/courier/webadmin + insopts -m 400 -o mail -g mail + doins "${FILESDIR}/password.dist" + fi + + # avoid name collisions in /usr/sbin, make webadmin match + cd "${D}/usr/sbin" + for f in imapd imapd-ssl pop3d pop3d-ssl ; do mv "${f}" "courier-${f}" ; done + if use web ; then + sed -i -e 's:\$sbindir\/imapd:\$sbindir\/courier-imapd:g' \ + -e 's:\$sbindir\/imapd-ssl:\$sbindir\/courier-imapd-ssl:g' \ + "${D}/usr/share/courier/courierwebadmin/admin-40imap.pl" \ + || ewarn "failed to fix webadmin" + sed -i -e 's:\$sbindir\/pop3d:\$sbindir\/courier-pop3d:g' \ + -e 's:\$sbindir\/pop3d-ssl:\$sbindir\/courier-pop3d-ssl:g' \ + "${D}/usr/share/courier/courierwebadmin/admin-45pop3.pl" \ + || ewarn "failed to fix webadmin" + fi + + # users should be able to send mail. Could be restricted with suictl. + chmod u+s "${D}/usr/bin/sendmail" + + if use mailwrapper ; then + mv "${D}/usr/bin/sendmail" "${D}/usr/bin/sendmail.courier" + mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.courier" + mv "${D}/usr/bin/mailq" "${D}/usr/bin/mailq.courier" + + mv "${D}/usr/share/man/man1/sendmail.1" \ + "${D}/usr/share/man/man1/sendmail-courier.1" + mv "${D}/usr/share/man/man1/mailq.1" \ + "${D}/usr/share/man/man1/mailq-courier.1" + mv "${D}/usr/share/man/man1/rmail.1" \ + "${D}/usr/share/man/man1/rmail-courier.1" + + insopts -m 444 -o mail -g mail + insinto /etc/mail + doins "${FILESDIR}/mailer.conf" + else + dosym /usr/bin/sendmail /usr/sbin/sendmail + fi +} + +src_test() { + if [ `whoami` != 'root' ]; then + emake -j1 check || die "Make check failed." + else + einfo "make check skipped, can't run as root." + einfo "You can enable it with FEATURES=\"userpriv\"" + fi +} + +pkg_postinst() { + use fam && elog "fam daemon is needed for courier-imapd" \ + || ewarn "courier was built without fam support" +} + +pkg_config() { + mailhost="$(hostname)" + export mailhost + + domainname="$(domainname)" + if [ "x$domainname" = "x(none)" ] ; then + domainname="$(echo ${mailhost} | sed -e "s/[^\.]*\.\(.*\)/\1/")" + fi + export domainname + + if [ "${ROOT}" = "/" ] ; then + file="${ROOT}/etc/courier/locals" + if [ ! -f "${file}" ] ; then + echo "localhost" > "${file}"; + echo "${domainname}" >> "${file}"; + fi + file="${ROOT}/etc/courier/esmtpacceptmailfor.dir/${domainname}" + if [ ! -f "${file}" ] ; then + echo "${domainname}" > "${file}" + /usr/sbin/makeacceptmailfor + fi + + file="${ROOT}/etc/courier/smtpaccess/${domainname}" + if [ ! -f "${file}" ] + then + netstat -nr | grep "^[1-9]" | while read network gateway netmask rest + do + i=1 + net="" + TIFS="${IFS}" + IFS="." + for o in "${netmask}" + do + if [ "${o}" == "255" ] + then + [ "_${net}" == "_" ] || net="${net}." + t="$(echo "${network}" | cut -d " " -f ${i})" + net="${net}${t}" + fi + i="$((${i} + 1))" + done + IFS="${TIFS}" + echo "doing configuration - relay control for the network ${net} !" + echo "${net} allow,RELAYCLIENT" >> ${file} + done + /usr/sbin/makesmtpaccess + fi + fi + + echo "creating cert for esmtpd-ssl:" + /usr/sbin/mkesmtpdcert + echo "creating cert for imapd-ssl:" + /usr/sbin/mkpop3dcert + echo "creating cert for pop3d-ssl:" + /usr/sbin/mkimapdcert +} -- 2.26.2