From 401101f9c8077911929d3f2b60a37098460a5d89 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Thu, 24 Mar 2022 23:59:54 +0000 Subject: gentoo resync : 25.03.2022 --- mail-mta/Manifest.gz | Bin 2378 -> 2379 bytes mail-mta/courier/Manifest | 4 +- mail-mta/courier/courier-1.1.5-r1.ebuild | 312 ---------- mail-mta/courier/courier-1.1.5-r2.ebuild | 312 ++++++++++ mail-mta/courier/courier-1.1.8-r1.ebuild | 313 ++++++++++ mail-mta/courier/courier-1.1.8.ebuild | 313 ---------- mail-mta/exim/Manifest | 6 +- mail-mta/exim/exim-4.94.2-r4.ebuild | 623 ------------------- mail-mta/exim/exim-4.94.2-r6.ebuild | 665 --------------------- mail-mta/exim/exim-4.94.2-r7.ebuild | 623 +++++++++++++++++++ mail-mta/exim/exim-4.94.2-r8.ebuild | 665 +++++++++++++++++++++ mail-mta/exim/exim-4.95-r1.ebuild | 662 ++++++++++++++++++++ mail-mta/exim/exim-4.95.ebuild | 662 -------------------- mail-mta/msmtp/Manifest | 6 +- mail-mta/msmtp/msmtp-1.8.18.ebuild | 145 ----- mail-mta/msmtp/msmtp-1.8.19.ebuild | 4 +- mail-mta/msmtp/msmtp-1.8.20.ebuild | 145 +++++ mail-mta/nullmailer/Manifest | 2 +- mail-mta/nullmailer/nullmailer-2.2-r2.ebuild | 7 +- mail-mta/postfix/Manifest | 11 +- mail-mta/postfix/files/postfix-glibc-2.34.patch | 12 - mail-mta/postfix/postfix-3.6.3.ebuild | 290 --------- mail-mta/postfix/postfix-3.6.4.ebuild | 290 --------- mail-mta/postfix/postfix-3.6.5-r1.ebuild | 286 --------- mail-mta/postfix/postfix-3.6.5-r2.ebuild | 286 +++++++++ mail-mta/postfix/postfix-3.7.0-r1.ebuild | 294 +++++++++ mail-mta/postfix/postfix-3.7.0.ebuild | 294 --------- mail-mta/postfix/postfix-3.8_pre20220220-r1.ebuild | 294 +++++++++ mail-mta/postfix/postfix-3.8_pre20220220.ebuild | 294 --------- mail-mta/sendmail/Manifest | 4 +- mail-mta/sendmail/sendmail-8.16.1-r1.ebuild | 206 ------- mail-mta/sendmail/sendmail-8.16.1-r2.ebuild | 206 +++++++ mail-mta/sendmail/sendmail-8.17.1-r1.ebuild | 207 ------- mail-mta/sendmail/sendmail-8.17.1-r2.ebuild | 207 +++++++ 34 files changed, 4029 insertions(+), 4621 deletions(-) delete mode 100644 mail-mta/courier/courier-1.1.5-r1.ebuild create mode 100644 mail-mta/courier/courier-1.1.5-r2.ebuild create mode 100644 mail-mta/courier/courier-1.1.8-r1.ebuild delete mode 100644 mail-mta/courier/courier-1.1.8.ebuild delete mode 100644 mail-mta/exim/exim-4.94.2-r4.ebuild delete mode 100644 mail-mta/exim/exim-4.94.2-r6.ebuild create mode 100644 mail-mta/exim/exim-4.94.2-r7.ebuild create mode 100644 mail-mta/exim/exim-4.94.2-r8.ebuild create mode 100644 mail-mta/exim/exim-4.95-r1.ebuild delete mode 100644 mail-mta/exim/exim-4.95.ebuild delete mode 100644 mail-mta/msmtp/msmtp-1.8.18.ebuild create mode 100644 mail-mta/msmtp/msmtp-1.8.20.ebuild delete mode 100644 mail-mta/postfix/files/postfix-glibc-2.34.patch delete mode 100644 mail-mta/postfix/postfix-3.6.3.ebuild delete mode 100644 mail-mta/postfix/postfix-3.6.4.ebuild delete mode 100644 mail-mta/postfix/postfix-3.6.5-r1.ebuild create mode 100644 mail-mta/postfix/postfix-3.6.5-r2.ebuild create mode 100644 mail-mta/postfix/postfix-3.7.0-r1.ebuild delete mode 100644 mail-mta/postfix/postfix-3.7.0.ebuild create mode 100644 mail-mta/postfix/postfix-3.8_pre20220220-r1.ebuild delete mode 100644 mail-mta/postfix/postfix-3.8_pre20220220.ebuild delete mode 100644 mail-mta/sendmail/sendmail-8.16.1-r1.ebuild create mode 100644 mail-mta/sendmail/sendmail-8.16.1-r2.ebuild delete mode 100644 mail-mta/sendmail/sendmail-8.17.1-r1.ebuild create mode 100644 mail-mta/sendmail/sendmail-8.17.1-r2.ebuild (limited to 'mail-mta') diff --git a/mail-mta/Manifest.gz b/mail-mta/Manifest.gz index 16e3096c85cf..b91e09d75306 100644 Binary files a/mail-mta/Manifest.gz and b/mail-mta/Manifest.gz differ diff --git a/mail-mta/courier/Manifest b/mail-mta/courier/Manifest index 355974900109..b1bdcca8df88 100644 --- a/mail-mta/courier/Manifest +++ b/mail-mta/courier/Manifest @@ -4,6 +4,6 @@ AUX norewrite.patch 488 BLAKE2B 663b52ff5936d5c8aa24ce2a226cd803f09a972a2f358b7f AUX password.dist 247 BLAKE2B 1803a6663c32ccc74c4dfb1d591a01d4416f9de9c4bf35c9a7ca277c2007b8c29a8899f4285c78eeb8592766457eef0caf377a344adee7a61be15bbf8b80c7de SHA512 f488b0ab1a909c9b878b9f3f3147641a9ed6d8d2ad44c67cd641934b800b18a62de2a7f5f51fdbecfbbcdd7c39c753734984cc0836c905a3b708858e1b91093d DIST courier-1.1.5.tar.bz2 7654159 BLAKE2B 7ad09b4b3c8ec201ea275851aec4efb34861a2881c765228b58063d26f17580fbe8ffe4e882d43b74ed048c3bf711e0eb08cb45eb1ba25ab2073a8c411a6cd4f SHA512 6b7040a73b09a4fc0ad4d93c576d7d7026aa743e5bbfe3ae14d2474dd9cffdb3419eceb14000cc0beeae40886796d9973e9f8611a7ea925cf2e0ab928904038a DIST courier-1.1.8.tar.bz2 7655220 BLAKE2B 189c87e416fe8d232e1fab8be47ff8258a54de2a6eccf1b02bd2839c6925018ee5b0ff3172ba791076c979d5c15a9dbcac1e7f515b0683066f3ff55369ea91a9 SHA512 9a0d96a20a75794fba57df11305326eb990091bd503763cd091ad29a4b34d9c1576d40c2e2d6eb81f3705e2d4b0a265c174df6e307a60fbbc1dc26110d931133 -EBUILD courier-1.1.5-r1.ebuild 9232 BLAKE2B f8e4aefbf3fad7bbed0bb53bd1d3b3d384735ad69d281365dcd8df8eac3c7fd97a1fd069975384b3d4370095417ffab6361f096c6939afb07104a6836340b973 SHA512 eee78c3e80d2ee3e84a1086ab6edddc16a4c48c6ed345ebf2d11205787f3fd5421895fb5b1f3d5564bc187345f0053e0c96379196bd854af5223fa1785f49cf0 -EBUILD courier-1.1.8.ebuild 9238 BLAKE2B 20125f895e47cbd04e69eb8607236aa6df62239522cceb48a196fc9fadc8c2ee28fccc16dc87194872f717f6066280a185cbec94b92da82eb0417acadee5c2f3 SHA512 7eeded65e2bcfafa5eb3e7a80da35a75357f9eaa7cb2326e7b5ad56b0118af8e0c7cae2a6db1a6e02a2213543ee945c916922655b2f7a6dafac41cd14d418544 +EBUILD courier-1.1.5-r2.ebuild 9234 BLAKE2B 4122d0f243ccbdea905a2ee5d5de94477746965f10253da2063bf0ecbaeee0a73afd93d5f8fa32b334ef8c2676073452e7bc9f16313791c8f1138fe090b04839 SHA512 e9d0ce3cb7196a8fcdd611e3ef7182554510c6ef4d5f2d7c1f86cbb04036f02c57a6f09754968250d20e678626f326b8260cd2c5b15c51feb430d4dc9b4308ff +EBUILD courier-1.1.8-r1.ebuild 9240 BLAKE2B ed240f38e8d32ce3e0055d8119ad2a38e18c236ca2af594cb84ab5cfa2d1529a7ce1c26b8a24dbc9bb48abaec045557a78004afed1b117249a250dfaf19a375c SHA512 4037f388235dc6847944c150e0bf5ee8ee7d0ac10719f95a1ad08bf7d9f8a33686ae47fbbfab6226144ee9853822e77de033a7cd9b64d22baf37026e701d95b4 MISC metadata.xml 756 BLAKE2B e3d128790b1620d9005c9a14cef1c452488fc8e465b235791cc196f431cb2ea8348aba342b0867282878d0c73392694be0db0686dc048d9345b286c3bccf1cab SHA512 c3fcd1ba4b22f91b1acf49faeee41562a7963b51d37e1593156086b79a1eb4172a12e7226b71a9aa55b5a4ef7d734351752451a2300375d061ae20481778b273 diff --git a/mail-mta/courier/courier-1.1.5-r1.ebuild b/mail-mta/courier/courier-1.1.5-r1.ebuild deleted file mode 100644 index 25c09f86bdf3..000000000000 --- a/mail-mta/courier/courier-1.1.5-r1.ebuild +++ /dev/null @@ -1,312 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit flag-o-matic multilib - -DESCRIPTION="An MTA designed specifically for maildirs" -HOMEPAGE="https://www.courier-mta.org/" -SRC_URI="mirror://sourceforge/courier/${P}.tar.bz2" - -LICENSE="GPL-3" -SLOT="0" -KEYWORDS="~alpha amd64 arm ~hppa ~ia64 ~ppc ppc64 ~riscv ~s390 sparc x86" -IUSE="postgres ldap mysql pam nls ipv6 spell fax crypt norewrite \ - fam web webmail gnutls" - -DEPEND=" - >=net-libs/courier-authlib-0.71.3 - >=net-libs/courier-unicode-2.2.3:= - net-dns/libidn:= - gnutls? ( net-libs/gnutls:= ) - !gnutls? ( - dev-libs/openssl:0= - ) - >=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? ( sys-libs/pam ) - mysql? ( dev-db/mysql-connector-c ) - ldap? ( >=net-nds/openldap-1.2.11 ) - postgres? ( dev-db/postgresql:= ) - spell? ( app-text/aspell ) - fam? ( virtual/fam ) - !mail-filter/maildrop - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/mini-qmail - !mail-mta/msmtp[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/postfix - !mail-mta/qmail-ldap - !mail-mta/sendmail - !mail-mta/ssmtp[mta] - !mail-mta/opensmtpd - !net-mail/dot-forward - !sys-apps/ucspi-tcp - " - -RDEPEND="${DEPEND} - dev-lang/perl - sys-process/procps" - -# get rid of old style virtual/imapd - bug 350792 -# all blockers really needed? -RDEPEND="${RDEPEND} - !net-mail/bincimap - !net-mail/courier-imap - !net-mail/cyrus-imapd - !net-mail/uw-imap" - -PDEPEND="pam? ( net-mail/mailbase ) - crypt? ( >=app-crypt/gnupg-1.0.4 )" - -src_prepare() { - use norewrite && eapply "${FILESDIR}/norewrite.patch" - default -} - -src_configure() { - 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) \ - $(use_with gnutls) \ - --with-notice=unicode \ - --enable-mimetypes=/etc/mime.types \ - --prefix=/usr \ - --disable-root-check \ - --mandir=/usr/share/man \ - --sysconfdir=/etc/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 -} - -src_compile() { - default -} - -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/lib/courier/tmp - keepdir /var/lib/courier/msgs - make install DESTDIR="${D}" || die "install" - make install-configure || die "install-configure" - - # init script takes care of this - rm -rf "${D}/var/run" - - # Get rid of files we dont want - if ! use webmail ; then - rm -rf "${D}/usr/$(get_libdir)/courier/courier/webmail" \ - "${D}/usr/$(get_libdir)/courier/courier/sqwebmaild" \ - "${D}/usr/share/courier/sqwebmail/" \ - "${D}/usr/sbin/webmaild" \ - "${D}/usr/sbin/webgpg" \ - "${D}/etc/courier/webmail.authpam" \ - "${D}/var/lib/courier/webmail-logincache" \ - "${D}"/etc/courier/sqwebmaild* - fi - - if ! use web ; then - rm -rf "${D}/usr/share/courier/courierwebadmin/" \ - "${D}/etc/courier/webadmin" - 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-r4" "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:mail ldapaliasrc ; chmod 640 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 - dosym ../share/courier/pop3d /usr/sbin/courier-pop3d - dosym ../share/courier/pop3d-ssl /usr/sbin/courier-pop3d-ssl - dosym ../share/courier/imapd /usr/sbin/courier-imapd - dosym ../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 libs/tcpd/README.couriertls - mv "${D}/usr/share/courier/htmldoc" "${D}/usr/share/doc/${PF}/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" - - dosym ../bin/sendmail /usr/sbin/sendmail -} - -src_test() { - if [ `whoami` != 'root' ]; then - emake -j1 check - 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 -} diff --git a/mail-mta/courier/courier-1.1.5-r2.ebuild b/mail-mta/courier/courier-1.1.5-r2.ebuild new file mode 100644 index 000000000000..3ef7bf19c50c --- /dev/null +++ b/mail-mta/courier/courier-1.1.5-r2.ebuild @@ -0,0 +1,312 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit flag-o-matic multilib + +DESCRIPTION="An MTA designed specifically for maildirs" +HOMEPAGE="https://www.courier-mta.org/" +SRC_URI="mirror://sourceforge/courier/${P}.tar.bz2" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~alpha amd64 arm ~hppa ~ia64 ~ppc ppc64 ~riscv ~s390 sparc x86" +IUSE="postgres ldap mysql pam nls ipv6 spell fax crypt norewrite \ + fam web webmail gnutls" + +DEPEND=" + >=net-libs/courier-authlib-0.71.3 + >=net-libs/courier-unicode-2.2.3:= + net-dns/libidn:= + gnutls? ( net-libs/gnutls:= ) + !gnutls? ( + dev-libs/openssl:0= + ) + >=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? ( sys-libs/pam ) + mysql? ( dev-db/mysql-connector-c ) + ldap? ( >=net-nds/openldap-1.2.11:= ) + postgres? ( dev-db/postgresql:= ) + spell? ( app-text/aspell ) + fam? ( virtual/fam ) + !mail-filter/maildrop + !mail-mta/esmtp + !mail-mta/exim + !mail-mta/mini-qmail + !mail-mta/msmtp[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/postfix + !mail-mta/qmail-ldap + !mail-mta/sendmail + !mail-mta/ssmtp[mta] + !mail-mta/opensmtpd + !net-mail/dot-forward + !sys-apps/ucspi-tcp + " + +RDEPEND="${DEPEND} + dev-lang/perl + sys-process/procps" + +# get rid of old style virtual/imapd - bug 350792 +# all blockers really needed? +RDEPEND="${RDEPEND} + !net-mail/bincimap + !net-mail/courier-imap + !net-mail/cyrus-imapd + !net-mail/uw-imap" + +PDEPEND="pam? ( net-mail/mailbase ) + crypt? ( >=app-crypt/gnupg-1.0.4 )" + +src_prepare() { + use norewrite && eapply "${FILESDIR}/norewrite.patch" + default +} + +src_configure() { + 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) \ + $(use_with gnutls) \ + --with-notice=unicode \ + --enable-mimetypes=/etc/mime.types \ + --prefix=/usr \ + --disable-root-check \ + --mandir=/usr/share/man \ + --sysconfdir=/etc/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 +} + +src_compile() { + default +} + +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/lib/courier/tmp + keepdir /var/lib/courier/msgs + make install DESTDIR="${D}" || die "install" + make install-configure || die "install-configure" + + # init script takes care of this + rm -rf "${D}/var/run" + + # Get rid of files we dont want + if ! use webmail ; then + rm -rf "${D}/usr/$(get_libdir)/courier/courier/webmail" \ + "${D}/usr/$(get_libdir)/courier/courier/sqwebmaild" \ + "${D}/usr/share/courier/sqwebmail/" \ + "${D}/usr/sbin/webmaild" \ + "${D}/usr/sbin/webgpg" \ + "${D}/etc/courier/webmail.authpam" \ + "${D}/var/lib/courier/webmail-logincache" \ + "${D}"/etc/courier/sqwebmaild* + fi + + if ! use web ; then + rm -rf "${D}/usr/share/courier/courierwebadmin/" \ + "${D}/etc/courier/webadmin" + 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-r4" "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:mail ldapaliasrc ; chmod 640 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 + dosym ../share/courier/pop3d /usr/sbin/courier-pop3d + dosym ../share/courier/pop3d-ssl /usr/sbin/courier-pop3d-ssl + dosym ../share/courier/imapd /usr/sbin/courier-imapd + dosym ../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 libs/tcpd/README.couriertls + mv "${D}/usr/share/courier/htmldoc" "${D}/usr/share/doc/${PF}/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" + + dosym ../bin/sendmail /usr/sbin/sendmail +} + +src_test() { + if [ `whoami` != 'root' ]; then + emake -j1 check + 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 +} diff --git a/mail-mta/courier/courier-1.1.8-r1.ebuild b/mail-mta/courier/courier-1.1.8-r1.ebuild new file mode 100644 index 000000000000..55023ee74943 --- /dev/null +++ b/mail-mta/courier/courier-1.1.8-r1.ebuild @@ -0,0 +1,313 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit flag-o-matic multilib + +DESCRIPTION="An MTA designed specifically for maildirs" +HOMEPAGE="https://www.courier-mta.org/" +SRC_URI="mirror://sourceforge/courier/${P}.tar.bz2" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" +IUSE="postgres ldap mysql pam nls ipv6 spell fax crypt norewrite \ + fam web webmail gnutls" + +DEPEND=" + >=net-libs/courier-authlib-0.71.3 + >=net-libs/courier-unicode-2.2.3:= + net-dns/libidn:= + gnutls? ( net-libs/gnutls:= ) + !gnutls? ( + dev-libs/openssl:0= + ) + >=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? ( sys-libs/pam ) + mysql? ( dev-db/mysql-connector-c ) + ldap? ( >=net-nds/openldap-1.2.11:= ) + postgres? ( dev-db/postgresql:= ) + spell? ( app-text/aspell ) + fam? ( virtual/fam ) + !mail-filter/maildrop + !mail-mta/esmtp + !mail-mta/exim + !mail-mta/mini-qmail + !mail-mta/msmtp[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/postfix + !mail-mta/qmail-ldap + !mail-mta/sendmail + !mail-mta/ssmtp[mta] + !mail-mta/opensmtpd + !net-mail/dot-forward + !sys-apps/ucspi-tcp + " + +RDEPEND="${DEPEND} + dev-lang/perl + sys-process/procps" + +# get rid of old style virtual/imapd - bug 350792 +# all blockers really needed? +RDEPEND="${RDEPEND} + !net-mail/bincimap + !net-mail/courier-imap + !net-mail/cyrus-imapd + !net-mail/uw-imap" + +PDEPEND="pam? ( net-mail/mailbase ) + crypt? ( >=app-crypt/gnupg-1.0.4 )" + +src_prepare() { + use norewrite && eapply "${FILESDIR}/norewrite.patch" + default +} + +src_configure() { + 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) \ + $(use_with gnutls) \ + --with-notice=unicode \ + --enable-mimetypes=/etc/mime.types \ + --prefix=/usr \ + --disable-root-check \ + --mandir=/usr/share/man \ + --sysconfdir=/etc/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" +} + +src_compile() { + default +} + +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/lib/courier/tmp + keepdir /var/lib/courier/msgs + make install DESTDIR="${D}" || die "install" + make install-configure DESTDIR="${D}" || die "install-configure" + + # init script takes care of this + rm -rf "${D}/var/run" + + # Get rid of files we dont want + if ! use webmail ; then + rm -rf "${D}/usr/$(get_libdir)/courier/courier/webmail" \ + "${D}/usr/$(get_libdir)/courier/courier/sqwebmaild" \ + "${D}/usr/share/courier/sqwebmail/" \ + "${D}/usr/sbin/webmaild" \ + "${D}/usr/sbin/webgpg" \ + "${D}/etc/courier/webmail.authpam" \ + "${D}/var/lib/courier/webmail-logincache" \ + "${D}"/etc/courier/sqwebmaild* + fi + + if ! use web ; then + rm -rf "${D}/usr/share/courier/courierwebadmin/" \ + "${D}/etc/courier/webadmin" + 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-r4" "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:mail ldapaliasrc ; chmod 640 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 + dosym ../share/courier/pop3d /usr/sbin/courier-pop3d + dosym ../share/courier/pop3d-ssl /usr/sbin/courier-pop3d-ssl + dosym ../share/courier/imapd /usr/sbin/courier-imapd + dosym ../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 libs/tcpd/README.couriertls + mv "${D}/usr/share/courier/htmldoc" "${D}/usr/share/doc/${PF}/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" + + dosym ../bin/sendmail /usr/sbin/sendmail +} + +src_test() { + if [ `whoami` != 'root' ]; then + # Disable valgrind checks + echo '#!/bin/sh' > libs/imap/testsuitevalgrind + emake -j1 check + 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 +} diff --git a/mail-mta/courier/courier-1.1.8.ebuild b/mail-mta/courier/courier-1.1.8.ebuild deleted file mode 100644 index 507a0b4b8027..000000000000 --- a/mail-mta/courier/courier-1.1.8.ebuild +++ /dev/null @@ -1,313 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit flag-o-matic multilib - -DESCRIPTION="An MTA designed specifically for maildirs" -HOMEPAGE="https://www.courier-mta.org/" -SRC_URI="mirror://sourceforge/courier/${P}.tar.bz2" - -LICENSE="GPL-3" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" -IUSE="postgres ldap mysql pam nls ipv6 spell fax crypt norewrite \ - fam web webmail gnutls" - -DEPEND=" - >=net-libs/courier-authlib-0.71.3 - >=net-libs/courier-unicode-2.2.3:= - net-dns/libidn:= - gnutls? ( net-libs/gnutls:= ) - !gnutls? ( - dev-libs/openssl:0= - ) - >=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? ( sys-libs/pam ) - mysql? ( dev-db/mysql-connector-c ) - ldap? ( >=net-nds/openldap-1.2.11 ) - postgres? ( dev-db/postgresql:= ) - spell? ( app-text/aspell ) - fam? ( virtual/fam ) - !mail-filter/maildrop - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/mini-qmail - !mail-mta/msmtp[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/postfix - !mail-mta/qmail-ldap - !mail-mta/sendmail - !mail-mta/ssmtp[mta] - !mail-mta/opensmtpd - !net-mail/dot-forward - !sys-apps/ucspi-tcp - " - -RDEPEND="${DEPEND} - dev-lang/perl - sys-process/procps" - -# get rid of old style virtual/imapd - bug 350792 -# all blockers really needed? -RDEPEND="${RDEPEND} - !net-mail/bincimap - !net-mail/courier-imap - !net-mail/cyrus-imapd - !net-mail/uw-imap" - -PDEPEND="pam? ( net-mail/mailbase ) - crypt? ( >=app-crypt/gnupg-1.0.4 )" - -src_prepare() { - use norewrite && eapply "${FILESDIR}/norewrite.patch" - default -} - -src_configure() { - 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) \ - $(use_with gnutls) \ - --with-notice=unicode \ - --enable-mimetypes=/etc/mime.types \ - --prefix=/usr \ - --disable-root-check \ - --mandir=/usr/share/man \ - --sysconfdir=/etc/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" -} - -src_compile() { - default -} - -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/lib/courier/tmp - keepdir /var/lib/courier/msgs - make install DESTDIR="${D}" || die "install" - make install-configure DESTDIR="${D}" || die "install-configure" - - # init script takes care of this - rm -rf "${D}/var/run" - - # Get rid of files we dont want - if ! use webmail ; then - rm -rf "${D}/usr/$(get_libdir)/courier/courier/webmail" \ - "${D}/usr/$(get_libdir)/courier/courier/sqwebmaild" \ - "${D}/usr/share/courier/sqwebmail/" \ - "${D}/usr/sbin/webmaild" \ - "${D}/usr/sbin/webgpg" \ - "${D}/etc/courier/webmail.authpam" \ - "${D}/var/lib/courier/webmail-logincache" \ - "${D}"/etc/courier/sqwebmaild* - fi - - if ! use web ; then - rm -rf "${D}/usr/share/courier/courierwebadmin/" \ - "${D}/etc/courier/webadmin" - 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-r4" "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:mail ldapaliasrc ; chmod 640 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 - dosym ../share/courier/pop3d /usr/sbin/courier-pop3d - dosym ../share/courier/pop3d-ssl /usr/sbin/courier-pop3d-ssl - dosym ../share/courier/imapd /usr/sbin/courier-imapd - dosym ../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 libs/tcpd/README.couriertls - mv "${D}/usr/share/courier/htmldoc" "${D}/usr/share/doc/${PF}/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" - - dosym ../bin/sendmail /usr/sbin/sendmail -} - -src_test() { - if [ `whoami` != 'root' ]; then - # Disable valgrind checks - echo '#!/bin/sh' > libs/imap/testsuitevalgrind - emake -j1 check - 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 -} diff --git a/mail-mta/exim/Manifest b/mail-mta/exim/Manifest index 0d3390e0f2d2..092ed9460c3b 100644 --- a/mail-mta/exim/Manifest +++ b/mail-mta/exim/Manifest @@ -23,7 +23,7 @@ DIST exim-4.95.tar.xz 1865172 BLAKE2B 0dc8dbc394c1bf4c6075e6ae1c1609b3f41841b2bb DIST exim-pdf-4.94.2.tar.xz 2092248 BLAKE2B 973ab4f117fdb58afa017bc41b4496fac1277e707a9926d67317c455b0bd617021c17cba6c8d793d8962aacef12c0790d5add7174017512b7b1ea070f8e8533d SHA512 3a661f69d81a992798d4b7e5b7def7cfffa297a7b3c02a6631be426cefff5a6e8783fa322a1bd105d01f7b06968d01e77963e6ab7be3157f63eb62eb6ff172b0 DIST exim-pdf-4.95.tar.xz 2117384 BLAKE2B ac310ec7741110a067f2df135b6397a8219e48a1e8989c66118f6c62820467e6f7b1c391799ff9b7ddef7896e1340208c4bed21f126014fa94c24d338f681f94 SHA512 47f30f3c82fe2cb5b0836594b325da1d255c53d2514af90e720d4bf6c74cff43d4a6b1ab5fb7b148253e5330da74e8ebb80e29b3a08fbe1faed2f004476c9d6a DIST system_filter.exim.gz 3075 BLAKE2B d05e872b5cef377d29126cda03fc0a74c8777b2119b76ff43da6e8de808035eb9bfcb034a85d81824f135d484e864bfc0629fc1af2c228a7277d5ee7cf9cde79 SHA512 cb358d3ce2499a0bb5920d962a06f2af8486e55ec90c8c928bd8e3aefb279aa57f5f960d5adfcef68bd94110b405eaa144e9629cfe6014a529c79c544600bbf3 -EBUILD exim-4.94.2-r4.ebuild 14986 BLAKE2B df83115910e67dbaf91d951ab8526a3956beccf03fdb4c74037aafc82ab41f111aa46a55335a9888e1eaf3f1f449567b53a3b6225ea8a1858f892855ed47dda4 SHA512 8e944fef3d85846d2f0c35cfc943ff50bf9e2e9502cef2f29e168a676793921922d94b1b1e83fae2f0a24a8bfdbf2f6c8b4e335c8ad05d1eaddcf0fc8af8aa0b -EBUILD exim-4.94.2-r6.ebuild 16252 BLAKE2B d79e87c1d0d31dbb152b82f335f4bc1ee29eeb34a4967413354cb9f663250ee5288db9e7cef9b15537cbbe9b379e3704b1d83ab5ea731436729e8779ee29f98f SHA512 50bc5ae66aff222cb2aedf62d6775ae14b9b921478219a0a520ad5115c784c8cb0f6a2b34f12ddcb82fdc31d71b8645e3e0c1f614841c8e34632dd4988b1671e -EBUILD exim-4.95.ebuild 16112 BLAKE2B f11d51849af1f1293c13adfd1cc8096b26acee9cd1372125e1dae515611cbdf10c72ed134396631825969d0c8aa5dbdd88ab499012aa7b25e74afcffd3c2583a SHA512 6b60ac7660960febb38d7d7073b99295ebbc2e0228553d1598a52f376c2a41a116079e682cb1e6403853a67498b77c291d2e1ffb6fe0143821209744cb6f213e +EBUILD exim-4.94.2-r7.ebuild 14992 BLAKE2B 41b12e90e25606d117b47c213fa8d4c27124da935d1ddfc6df28144fdee585b60194110884ebfcf7fbcd34c5798e4b3c0386ca7f35174932ec371d31d00329fc SHA512 d70ea9bd3e4dca90d3f528f6f1a642f01f623e0de6ebdd04268ad4cc9ef20764fd046ec14707485955aaf710a4c4275c7285867579ecf275262acb578f2281e7 +EBUILD exim-4.94.2-r8.ebuild 16260 BLAKE2B 829c9ec037b421849e55acbf4bf911f90d262b89e26bd1698c44894ce03ae760ff7cd9008b5b71f58f69cf77fdc9876527014071fe54e31946f1de6ea1fc048f SHA512 a4820d3df1d51f33020984c64e8c19951aaf90430c8974de067bdc3c9287d95825f1a851a8135cdd2aaad5b2eaab94822abdee80bdcce70752f2f0e9ec518e9d +EBUILD exim-4.95-r1.ebuild 16120 BLAKE2B 8cdbfefe384febb1119fc337e4cf1f6ccdc206bb164874067c75b37233d6cab85c3de92baf485f3ad7bac671d7574e8f874d9372d04812b371de880d3fad91ca SHA512 21bf068b95cfd82ef0b6dee73165a5417ac1a364051cabec722e9ec3ed4fa70d7dcf9fe394862ccb62fc363e379226ff2ce13e405e853685384fec2e0dc8cd20 MISC metadata.xml 2759 BLAKE2B 4f5d0d9fbd244b0836de4bd0d3b84f45376628a12e019c89e49e6dbd7128c19f16281fdfb401d852f57f27f547184351000382cc7333a524f7be280e0799d8d8 SHA512 85a2eaef07eb68d51a1307c6d76bef6620e7311ffda593750ebee5fe84affac2e026c971818500004c0ab9722a8e84c8eb0394fb66bb2ba6cd3465cf7e1f1a73 diff --git a/mail-mta/exim/exim-4.94.2-r4.ebuild b/mail-mta/exim/exim-4.94.2-r4.ebuild deleted file mode 100644 index 1e756b4ae797..000000000000 --- a/mail-mta/exim/exim-4.94.2-r4.ebuild +++ /dev/null @@ -1,623 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -inherit db-use toolchain-funcs multilib pam systemd - -IUSE="arc +dane dcc +dkim dlfunc dmarc +dnsdb doc dovecot-sasl dsn exiscan-acl gnutls idn ipv6 ldap lmtp maildir mbx mysql nis pam perl pkcs11 postgres +prdr proxy radius redis sasl selinux spf sqlite srs +srs-alt srs-native +ssl syslog tcpd +tpda X" -REQUIRED_USE=" - arc? ( dkim spf ) - dane? ( ssl !gnutls ) - dmarc? ( dkim spf ) - dkim? ( ssl !gnutls ) - gnutls? ( ssl ) - pkcs11? ( ssl ) - spf? ( exiscan-acl ) - srs? ( - exiscan-acl - ^^ ( srs-alt srs-native ) - ) -" -# NOTE on USE="gnutls dane", gnutls[dane] is masked in base, unmasked -# for x86 and amd64 only, due to this, repoman won't allow depending on -# gnutls[dane] for all else. Because we cannot express USE=dane when -# USE=gnutls is in effect only in package.use.mask, the only option we -# have left is to a) ignore the dependency (but that results in bug -# #661164) or b) mask the usage of USE=dane with USE=gnutls. Both are -# incorrect, but b) is the only "correct" view from repoman. - -SDIR=$([[ ${PV} == *_rc* ]] && echo /test - [[ ${PV} == *.*.*.* ]] && echo /fixes) -COMM_URI="https://downloads.exim.org/exim4${SDIR}" - -DESCRIPTION="A highly configurable, drop-in replacement for sendmail" -SRC_URI="${COMM_URI}/${P//_rc/-RC}.tar.xz - mirror://gentoo/system_filter.exim.gz - doc? ( ${COMM_URI}/${PN}-pdf-${PV//_rc/-RC}.tar.xz )" -HOMEPAGE="https://www.exim.org/" - -SLOT="0" -LICENSE="GPL-2" -KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ~ppc ppc64 sparc x86 ~x86-solaris" - -COMMON_DEPEND=">=sys-apps/sed-4.0.5 - ( >=sys-libs/db-3.2:= =net-nds/openldap-2.0.7 ) - nis? ( - elibc_glibc? ( - net-libs/libtirpc - >=net-libs/libnsl-1:= - ) - ) - mysql? ( dev-db/mysql-connector-c:= ) - postgres? ( dev-db/postgresql:= ) - sasl? ( >=dev-libs/cyrus-sasl-2.1.26-r2 ) - redis? ( dev-libs/hiredis ) - spf? ( >=mail-filter/libspf2-1.2.5-r1 ) - dmarc? ( mail-filter/opendmarc:= ) - srs? ( srs-alt? ( mail-filter/libsrs_alt ) ) - X? ( - x11-libs/libX11 - x11-libs/libXmu - x11-libs/libXt - x11-libs/libXaw - ) - sqlite? ( dev-db/sqlite ) - radius? ( net-dialup/freeradius-client ) - virtual/libcrypt:= - virtual/libiconv - elibc_glibc? ( net-libs/libnsl ) - " - # added X check for #57206 -BDEPEND="virtual/pkgconfig" -DEPEND="${COMMON_DEPEND}" -RDEPEND="${COMMON_DEPEND} - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/mini-qmail - !=mail-mta/msmtp-1.4.19-r1[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/postfix - !mail-mta/qmail-ldap - !mail-mta/sendmail - !mail-mta/opensmtpd - !=mail-mta/ssmtp-2.64-r2[mta] - !net-mail/mailwrapper - >=net-mail/mailbase-0.00-r5 - virtual/logger - dcc? ( mail-filter/dcc ) - selinux? ( sec-policy/selinux-exim ) - " - -S=${WORKDIR}/${P//_rc/-RC} - -src_prepare() { - # Legacy patches which need a respin for -p1 - eapply -p0 "${FILESDIR}"/exim-4.14-tail.patch - eapply -p0 "${FILESDIR}"/exim-4.74-radius-db-ENV-clash.patch # 287426 - eapply "${FILESDIR}"/exim-4.93-as-needed-ldflags.patch # 352265, 391279 - eapply -p0 "${FILESDIR}"/exim-4.76-crosscompile.patch # 266591 - eapply "${FILESDIR}"/exim-4.69-r1.27021.patch - eapply "${FILESDIR}"/exim-4.94-localscan_dlopen.patch - - # for this reason we have a := dep on opendmarc, they changed their - # API in a minor release - if use dmarc && has_version ">=mail-filter/opendmarc-1.4" ; then - eapply "${FILESDIR}"/exim-4.94-opendmarc-1.4.patch - fi - - if use maildir ; then - eapply "${FILESDIR}"/exim-4.94-maildir.patch - else - eapply -p0 "${FILESDIR}"/exim-4.80-spool-mail-group.patch # 438606 - fi - - eapply_user - - # user Exim believes it should be - MAILUSER=mail - MAILGROUP=mail - if use prefix && [[ ${EUID} != 0 ]] ; then - MAILUSER=$(id -un) - MAILGROUP=$(id -gn) - fi -} - -src_configure() { - # general config and paths - - local aliases="${EPREFIX}/etc/mail/aliases" - sed -i \ - -e "/SYSTEM_ALIASES_FILE/s'SYSTEM_ALIASES_FILE'${aliases}'" \ - src/configure.default || die - - sed -i -e 's/^buildname=.*/buildname=exim-gentoo/' Makefile || die - - if use elibc_musl; then - sed -i -e 's/^LIBS = -lnsl/LIBS =/g' OS/Makefile-Linux || die - fi - - local conffile="${EPREFIX}/etc/exim/exim.conf" - sed -e "48i\CFLAGS=${CFLAGS}" \ - -e "s:BIN_DIRECTORY=/usr/exim/bin:BIN_DIRECTORY=${EPREFIX}/usr/sbin:" \ - -e "s;EXIM_USER=;EXIM_USER=ref:${MAILUSER};" \ - -e "s:CONFIGURE_FILE=.*$:CONFIGURE_FILE=${conffile}:" \ - -e "s:ZCAT_COMMAND=.*$:ZCAT_COMMAND=${EPREFIX}/bin/zcat:" \ - -e "s:COMPRESS_COMMAND=.*$:COMPRESS_COMMAND=${EPREFIX}/bin/gzip:" \ - src/EDITME > Local/Makefile || die - - # work on Local/Makefile from now on - cd Local - - cat >> Makefile <<- EOC - INFO_DIRECTORY=${EPREFIX}/usr/share/info - PID_FILE_PATH=${EPREFIX}/run/exim.pid - SPOOL_DIRECTORY=${EPREFIX}/var/spool/exim - HAVE_ICONV=yes - EOC - - # if we use libiconv, now is the time to tell so - if use !elibc_glibc && use !elibc_musl ; then - cat >> Makefile <<- EOC - EXTRALIBS_EXIM=-liconv - EOC - fi - - # support for IPv6 - if use ipv6; then - cat >> Makefile <<- EOC - HAVE_IPV6=YES - EOC - fi - - # support i18n/IDNA - if use idn; then - cat >> Makefile <<- EOC - SUPPORT_I18N=yes - SUPPORT_I18N_2008=yes - EXTRALIBS_EXIM += -lidn -lidn2 - EOC - fi - - # - # mail storage formats - # - - # mailstore is Exim's traditional storage format - cat >> Makefile <<- EOC - SUPPORT_MAILSTORE=yes - EOC - - # mbox - if use mbx; then - cat >> Makefile <<- EOC - SUPPORT_MBX=yes - EOC - fi - - # maildir - if use maildir; then - cat >> Makefile <<- EOC - SUPPORT_MAILDIR=yes - EOC - fi - - # - # lookup methods - - # use the "native" interfaces to the DBM and CDB libraries, support - # passwd and directory lookups by default - local DB_VERS="5.3 5.1 4.8 4.7 4.6 4.5 4.4 4.3 4.2 3.2" - cat >> Makefile <<- EOC - USE_DB=yes - LOOKUP_CDB=yes - LOOKUP_PASSWD=yes - LOOKUP_DSEARCH=yes - # keep include in CFLAGS because exim.h -> dbstuff.h -> db.h - CFLAGS += -I$(db_includedir ${DB_VERS}) - DBMLIB = -l$(db_libname ${DB_VERS}) - EOC - - if ! use dnsdb; then - # DNSDB lookup is enabled by default - sed -i -e 's:^LOOKUP_DNSDB=yes:# LOOKUP_DNSDB=yes:' Makefile || die - fi - - if use ldap; then - cat >> Makefile <<- EOC - LOOKUP_LDAP=yes - LDAP_LIB_TYPE=OPENLDAP2 - LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/ldap - LOOKUP_LIBS += -lldap -llber - EOC - fi - - if use mysql; then - cat >> Makefile <<- EOC - LOOKUP_MYSQL=yes - LOOKUP_INCLUDE += $(mysql_config --include) - LOOKUP_LIBS += $(mysql_config --libs) - EOC - fi - - if use nis; then - cat >> Makefile <<- EOC - LOOKUP_NIS=yes - LOOKUP_NISPLUS=yes - EOC - if use elibc_glibc ; then - cat >> Makefile <<- EOC - LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/tirpc - LOOKUP_LIBS += -lnsl - EOC - fi - fi - - if use postgres; then - cat >> Makefile <<- EOC - LOOKUP_PGSQL=yes - LOOKUP_INCLUDE += -I$(pg_config --includedir) - LOOKUP_LIBS += -L$(pg_config --libdir) -lpq - EOC - fi - - if use sqlite; then - cat >> Makefile <<- EOC - LOOKUP_SQLITE=yes - LOOKUP_SQLITE_PC=sqlite3 - EOC - fi - - if use redis; then - cat >> Makefile <<- EOC - LOOKUP_REDIS=yes - LOOKUP_LIBS += -lhiredis - EOC - fi - - # Exim monitor, enabled by default, controlled via X USE-flag, - # disable if not requested, bug #46778 - if use X; then - cp ../exim_monitor/EDITME eximon.conf || die - cat >> Makefile <<- EOC - EXIM_MONITOR=eximon.bin - EOC - fi - - # - # features - # - - # content scanning support - if use exiscan-acl; then - cat >> Makefile <<- EOC - WITH_CONTENT_SCAN=yes - EOC - fi - - # DomainKeys Identified Mail, RFC4871 - if ! use dkim; then - # DKIM is enabled by default - cat >> Makefile <<- EOC - DISABLE_DKIM=yes - EOC - fi - - # Per-Recipient-Data-Response - if ! use prdr; then - # PRDR is enabled by default - cat >> Makefile <<- EOC - DISABLE_PRDR=yes - EOC - fi - - # Transport post-delivery actions - if use !tpda && use !dane; then - # EVENT is enabled by default - cat >> Makefile <<- EOC - DISABLE_EVENT=yes - EOC - fi - - # log to syslog - if use syslog; then - local eximlog="${EPREFIX}/var/log/exim/exim_%s.log" - sed -i \ - -e "s:LOG_FILE_PATH=${eximlog}:LOG_FILE_PATH=syslog:" \ - Makefile || die - cat >> Makefile <<- EOC - LOG_FILE_PATH=syslog - EOC - else - cat >> Makefile <<- EOC - LOG_FILE_PATH=${EPREFIX}/var/log/exim/exim_%s.log - EOC - fi - - # starttls support (ssl) - if use ssl; then - if use gnutls; then - echo "USE_GNUTLS=yes" >> Makefile - echo "USE_GNUTLS_PC=gnutls $(use dane && echo gnutls-dane)" \ - >> Makefile - use pkcs11 || echo "AVOID_GNUTLS_PKCS11=yes" >> Makefile - else - echo "USE_OPENSSL=yes" >> Makefile - echo "USE_OPENSSL_PC=openssl" >> Makefile - fi - else - echo "DISABLE_TLS=yes" >> Makefile - fi - - # TCP wrappers - if use tcpd; then - cat >> Makefile <<- EOC - USE_TCP_WRAPPERS=yes - EXTRALIBS_EXIM += -lwrap - EOC - fi - - # Light Mail Transport Protocol - if use lmtp; then - cat >> Makefile <<- EOC - TRANSPORT_LMTP=yes - EOC - fi - - # embedded Perl - if use perl; then - cat >> Makefile <<- EOC - EXIM_PERL=perl.o - EOC - fi - - # dlfunc - if use dlfunc; then - cat >> Makefile <<- EOC - EXPAND_DLFUNC=yes - HAVE_LOCAL_SCAN=yes - DLOPEN_LOCAL_SCAN=yes - EOC - fi - - # Proxy Protocol - if use proxy; then - cat >> Makefile <<- EOC - SUPPORT_PROXY=yes - EOC - fi - - # DANE - if use !dane; then - # DANE is enabled by default - sed -i -e 's:^SUPPORT_DANE=yes:# SUPPORT_DANE=yes:' Makefile || die - fi - - # DMARC - if use dmarc; then - cat >> Makefile <<- EOC - SUPPORT_DMARC=yes - EXTRALIBS_EXIM += -lopendmarc - EOC - fi - - # Sender Policy Framework - if use spf; then - cat >> Makefile <<- EOC - SUPPORT_SPF=yes - EXTRALIBS_EXIM += -lspf2 - EOC - fi - - # - # experimental features - # - - # Authenticated Receive Chain - if use arc; then - echo "EXPERIMENTAL_ARC=yes">> Makefile - fi - - # Distributed Checksum Clearinghouse - if use dcc; then - echo "EXPERIMENTAL_DCC=yes">> Makefile - fi - - # Sender Rewriting Scheme - if use srs; then - # NOTE: we currently USE-default to srs-alt, because this is - # what USE=srs used to be. Eventually we want to rid ourselves - # of this external implementation. - if use srs-alt; then - # historical default, from 4.95 this becomes - # EXPERIMENTAL_SRS_ALT - cat >> Makefile <<- EOC - EXPERIMENTAL_SRS=yes - EXTRALIBS_EXIM += -lsrs_alt - EOC - fi - if use srs-native; then - # this one becomes SUPPORT_SRS in 4.95 - cat >> Makefile <<- EOC - EXPERIMENTAL_SRS_NATIVE=yes - EOC - fi - fi - - # Delivery Sender Notifications extra information in fail message - if use dsn; then - cat >> Makefile <<- EOC - EXPERIMENTAL_DSN_INFO=yes - EOC - fi - - # - # authentication (SMTP AUTH) - # - - # standard bits - cat >> Makefile <<- EOC - AUTH_SPA=yes - AUTH_CRAM_MD5=yes - AUTH_PLAINTEXT=yes - EOC - - # Cyrus SASL - if use sasl; then - cat >> Makefile <<- EOC - CYRUS_SASLAUTHD_SOCKET=${EPREFIX}/run/saslauthd/mux - AUTH_CYRUS_SASL=yes - AUTH_LIBS += -lsasl2 - EOC - fi - - # Dovecot - if use dovecot-sasl; then - cat >> Makefile <<- EOC - AUTH_DOVECOT=yes - EOC - fi - - # Pluggable Authentication Modules - if use pam; then - cat >> Makefile <<- EOC - SUPPORT_PAM=yes - AUTH_LIBS += -lpam - EOC - fi - - # Radius - if use radius; then - cat >> Makefile <<- EOC - RADIUS_CONFIG_FILE=${EPREFIX}/etc/radiusclient/radiusclient.conf - RADIUS_LIB_TYPE=RADIUSCLIENTNEW - AUTH_LIBS += -lfreeradius-client - EOC - fi -} - -src_compile() { - emake CC="$(tc-getCC)" HOSTCC="$(tc-getBUILD_CC)" \ - AR="$(tc-getAR) cq" RANLIB="$(tc-getRANLIB)" FULLECHO='' -} - -src_install() { - cd "${S}"/build-exim-gentoo || die - dosbin exim - if use X; then - dosbin eximon.bin - dosbin eximon - fi - fperms 4755 /usr/sbin/exim - - dosym exim /usr/sbin/sendmail - dosym exim /usr/sbin/rsmtp - dosym exim /usr/sbin/rmail - dosym ../sbin/exim /usr/bin/mailq - dosym ../sbin/exim /usr/bin/newaliases - dosym ../sbin/sendmail /usr/lib/sendmail - - for i in exicyclog exim_dbmbuild exim_dumpdb exim_fixdb exim_lock \ - exim_tidydb exinext exiwhat exigrep eximstats exiqsumm exiqgrep \ - convert4r3 convert4r4 exipick - do - dosbin $i - done - - dodoc -r "${S}"/doc/. - doman "${S}"/doc/exim.8 - use dsn && dodoc "${S}"/README.DSN - use doc && dodoc "${WORKDIR}"/${PN}-pdf-${PV//rc/RC}/doc/*.pdf - - # conf files - insinto /etc/exim - newins "${S}"/src/configure.default exim.conf.dist - if use exiscan-acl; then - newins "${S}"/src/configure.default exim.conf.exiscan-acl - fi - doins "${WORKDIR}"/system_filter.exim - doins "${FILESDIR}"/auth_conf.sub - - if use pam; then - pamd_mimic system-auth exim auth account - fi - - # headers, #436406 - if use dlfunc ; then - # fixup includes so they actually can be found when including - sed -i \ - -e '/#include "\(config\|store\|mytypes\).h"/s:"\(.\+\)"::' \ - local_scan.h || die - insinto /usr/include/exim - doins {config,local_scan}.h ../src/{mytypes,store}.h - fi - - insinto /etc/logrotate.d - newins "${FILESDIR}/exim.logrotate" exim - - newinitd "${FILESDIR}"/exim.rc10 exim - newconfd "${FILESDIR}"/exim.confd exim - - systemd_dounit \ - "${FILESDIR}"/{exim.service,exim.socket,exim-submission.socket} - systemd_newunit \ - "${FILESDIR}"/exim_at.service 'exim@.service' - systemd_newunit \ - "${FILESDIR}"/exim-submission_at.service 'exim-submission@.service' - - diropts -m 0750 -o ${MAILUSER} -g ${MAILGROUP} - keepdir /var/log/${PN} -} - -pkg_postinst() { - if [[ ! -f ${EROOT}/etc/exim/exim.conf ]] ; then - einfo "${EROOT}/etc/exim/system_filter.exim is a sample system_filter." - einfo "${EROOT}/etc/exim/auth_conf.sub contains the configuration sub" - einfo "for using smtp auth." - einfo "Please create ${EROOT}/etc/exim/exim.conf from" - einfo " ${EROOT}/etc/exim/exim.conf.dist." - fi - if use dmarc ; then - einfo "DMARC support requires ${EROOT}/etc/exim/opendmarc.tlds" - einfo "you can populate this file with the contents downloaded from" - einfo " https://publicsuffix.org/list/public_suffix_list.dat" - fi - if use dcc ; then - einfo "DCC support is experimental, you can find some limited" - einfo "documentation at the bottom of this prerelease message:" - einfo " http://article.gmane.org/gmane.mail.exim.devel/3579" - fi - if use srs ; then - einfo "SRS support is experimental in this release of Exim" - if use srs-alt; then - elog "You are using libsrs_alt to implement SRS support." - elog "In future release of Exim, the native SRS implementation" - elog "(USE=srs-native) will become the default. Please prepare" - elog "your package.use or switch to USE=srs-native now." - fi - fi - use dsn && einfo "extra information in fail DSN message is experimental" - einfo - elog "Note that this release contains a tainted variable check that" - elog "is likely to break your configuration used with Exim 4.93 and before." - elog "Please check your transports for occurences of \$local_part, and" - elog "use a replacement like \$local_part_data where possible." -} diff --git a/mail-mta/exim/exim-4.94.2-r6.ebuild b/mail-mta/exim/exim-4.94.2-r6.ebuild deleted file mode 100644 index d611d18f89d9..000000000000 --- a/mail-mta/exim/exim-4.94.2-r6.ebuild +++ /dev/null @@ -1,665 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -inherit db-use toolchain-funcs multilib pam systemd - -IUSE="arc berkdb +dane dcc +dkim dlfunc dmarc +dnsdb doc dovecot-sasl -dsn exiscan-acl gdbm gnutls idn ipv6 ldap lmtp maildir mbx -mysql nis pam perl pkcs11 postgres +prdr proxy radius redis sasl selinux -socks5 spf sqlite srs +srs-alt srs-native +ssl syslog tdb tcpd +tpda X" -REQUIRED_USE=" - arc? ( dkim spf ) - dane? ( ssl !gnutls ) - dmarc? ( dkim spf ) - dkim? ( ssl !gnutls ) - gnutls? ( ssl ) - pkcs11? ( ssl ) - spf? ( exiscan-acl ) - srs? ( - exiscan-acl - ^^ ( srs-alt srs-native ) - ) - || ( berkdb gdbm tdb ) -" -# NOTE on USE="gnutls dane", gnutls[dane] is masked in base, unmasked -# for x86 and amd64 only, due to this, repoman won't allow depending on -# gnutls[dane] for all else. Because we cannot express USE=dane when -# USE=gnutls is in effect only in package.use.mask, the only option we -# have left is to a) ignore the dependency (but that results in bug -# #661164) or b) mask the usage of USE=dane with USE=gnutls. Both are -# incorrect, but b) is the only "correct" view from repoman. -# We cannot express a required use for berkdb/gdbm/tdb correctly because -# berkdb and gdbm are both enabled in base profile - -SDIR=$([[ ${PV} == *_rc* ]] && echo /test - [[ ${PV} == *.*.*.* ]] && echo /fixes) -COMM_URI="https://downloads.exim.org/exim4${SDIR}" - -DESCRIPTION="A highly configurable, drop-in replacement for sendmail" -SRC_URI="${COMM_URI}/${P//_rc/-RC}.tar.xz - mirror://gentoo/system_filter.exim.gz - doc? ( ${COMM_URI}/${PN}-pdf-${PV//_rc/-RC}.tar.xz )" -HOMEPAGE="https://www.exim.org/" - -SLOT="0" -LICENSE="GPL-2" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-solaris" - -COMMON_DEPEND=">=sys-apps/sed-4.0.5 - dev-libs/libpcre:= - tdb? ( sys-libs/tdb:= ) - !tdb? ( berkdb? ( >=sys-libs/db-3.2:= =net-nds/openldap-2.0.7 ) - elibc_glibc? ( - net-libs/libnsl - nis? ( - net-libs/libtirpc - >=net-libs/libnsl-1:= - ) - ) - mysql? ( dev-db/mysql-connector-c:= ) - postgres? ( dev-db/postgresql:= ) - sasl? ( >=dev-libs/cyrus-sasl-2.1.26-r2 ) - redis? ( dev-libs/hiredis ) - spf? ( >=mail-filter/libspf2-1.2.5-r1 ) - dmarc? ( mail-filter/opendmarc:= ) - srs? ( srs-alt? ( mail-filter/libsrs_alt ) ) - X? ( - x11-libs/libX11 - x11-libs/libXmu - x11-libs/libXt - x11-libs/libXaw - ) - sqlite? ( dev-db/sqlite ) - radius? ( net-dialup/freeradius-client ) - virtual/libcrypt:= - virtual/libiconv - " - # added X check for #57206 -BDEPEND="virtual/pkgconfig" -DEPEND="${COMMON_DEPEND}" -RDEPEND="${COMMON_DEPEND} - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/mini-qmail - !=mail-mta/msmtp-1.4.19-r1[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/postfix - !mail-mta/qmail-ldap - !mail-mta/sendmail - !mail-mta/opensmtpd - !=mail-mta/ssmtp-2.64-r2[mta] - !net-mail/mailwrapper - >=net-mail/mailbase-0.00-r5 - virtual/logger - dcc? ( mail-filter/dcc ) - selinux? ( sec-policy/selinux-exim ) - " - -S=${WORKDIR}/${P//_rc/-RC} - -src_prepare() { - # Legacy patches which need a respin for -p1 - eapply -p0 "${FILESDIR}"/exim-4.14-tail.patch - eapply -p0 "${FILESDIR}"/exim-4.74-radius-db-ENV-clash.patch # 287426 - eapply "${FILESDIR}"/exim-4.93-as-needed-ldflags.patch # 352265, 391279 - eapply -p0 "${FILESDIR}"/exim-4.76-crosscompile.patch # 266591 - eapply "${FILESDIR}"/exim-4.69-r1.27021.patch - eapply "${FILESDIR}"/exim-4.94-localscan_dlopen.patch - eapply "${FILESDIR}"/exim-4.94.2-fix-crash-resolve.patch # 799368 upstr - - # for this reason we have a := dep on opendmarc, they changed their - # API in a minor release - if use dmarc && has_version ">=mail-filter/opendmarc-1.4" ; then - eapply "${FILESDIR}"/exim-4.94-opendmarc-1.4.patch - fi - - if use maildir ; then - eapply "${FILESDIR}"/exim-4.94-maildir.patch - else - eapply -p0 "${FILESDIR}"/exim-4.80-spool-mail-group.patch # 438606 - fi - - eapply_user - - # user Exim believes it should be - MAILUSER=mail - MAILGROUP=mail - if use prefix && [[ ${EUID} != 0 ]] ; then - MAILUSER=$(id -un) - MAILGROUP=$(id -gn) - fi -} - -src_configure() { - # general config and paths - - local aliases="${EPREFIX}/etc/mail/aliases" - sed -i \ - -e "/SYSTEM_ALIASES_FILE/s'SYSTEM_ALIASES_FILE'${aliases}'" \ - src/configure.default || die - - sed -i -e 's/^buildname=.*/buildname=exim-gentoo/' Makefile || die - - if use elibc_musl; then - sed -i -e 's/^LIBS = -lnsl/LIBS =/g' OS/Makefile-Linux || die - fi - - local conffile="${EPREFIX}/etc/exim/exim.conf" - sed -e "48i\CFLAGS=${CFLAGS}" \ - -e "s:BIN_DIRECTORY=/usr/exim/bin:BIN_DIRECTORY=${EPREFIX}/usr/sbin:" \ - -e "s;EXIM_USER=;EXIM_USER=ref:${MAILUSER};" \ - -e "s:CONFIGURE_FILE=.*$:CONFIGURE_FILE=${conffile}:" \ - -e "s:ZCAT_COMMAND=.*$:ZCAT_COMMAND=${EPREFIX}/bin/zcat:" \ - -e "s:COMPRESS_COMMAND=.*$:COMPRESS_COMMAND=${EPREFIX}/bin/gzip:" \ - src/EDITME > Local/Makefile || die - - # work on Local/Makefile from now on - cd Local - - cat >> Makefile <<- EOC - INFO_DIRECTORY=${EPREFIX}/usr/share/info - PID_FILE_PATH=${EPREFIX}/run/exim.pid - SPOOL_DIRECTORY=${EPREFIX}/var/spool/exim - HAVE_ICONV=yes - EOC - - # configure db implementation, Exim always needs one for its hints - # database, we prefer tdb and gdbm, since bdb is kind of getting - # less and less support - if use tdb ; then - cat >> Makefile <<- EOC - USE_TDB=yes - DBMLIB = -ltdb - EOC - sed -i -e 's:^USE_DB=yes:# USE_DB=yes:' Makefile || die - sed -i -e 's:^USE_GDBM=yes:# USE_GDBM=yes:' Makefile || die - elif use berkdb ; then - # use the "native" interfaces to the DBM and CDB libraries, support - # passwd and directory lookups by default - local DB_VERS="5.3 5.1 4.8 4.7 4.6 4.5 4.4 4.3 4.2 3.2" - cat >> Makefile <<- EOC - USE_DB=yes - # keep include in CFLAGS because exim.h -> dbstuff.h -> db.h - CFLAGS += -I$(db_includedir ${DB_VERS}) - DBMLIB = -l$(db_libname ${DB_VERS}) - EOC - sed -i -e 's:^USE_GDBM=yes:# USE_GDBM=yes:' Makefile || die - sed -i -e 's:^USE_TDB=yes:# USE_TDB=yes:' Makefile || die - else # must be gdbm via required_use - cat >> Makefile <<- EOC - USE_GDBM=yes - DBMLIB = -lgdbm - EOC - sed -i -e 's:^USE_DB=yes:# USE_DB=yes:' Makefile || die - sed -i -e 's:^USE_TDB=yes:# USE_TDB=yes:' Makefile || die - fi - - # if we use libiconv, now is the time to tell so - if use !elibc_glibc && use !elibc_musl ; then - cat >> Makefile <<- EOC - EXTRALIBS_EXIM=-liconv - EOC - fi - - # support for IPv6 - if use ipv6; then - cat >> Makefile <<- EOC - HAVE_IPV6=YES - EOC - fi - - # support i18n/IDNA - if use idn; then - cat >> Makefile <<- EOC - SUPPORT_I18N=yes - SUPPORT_I18N_2008=yes - EXTRALIBS_EXIM += -lidn -lidn2 - EOC - fi - - # - # mail storage formats - # - - # mailstore is Exim's traditional storage format - cat >> Makefile <<- EOC - SUPPORT_MAILSTORE=yes - EOC - - # mbox - if use mbx; then - cat >> Makefile <<- EOC - SUPPORT_MBX=yes - EOC - fi - - # maildir - if use maildir; then - cat >> Makefile <<- EOC - SUPPORT_MAILDIR=yes - EOC - fi - - # - # lookup methods - # - - # support passwd and directory lookups by default - cat >> Makefile <<- EOC - LOOKUP_CDB=yes - LOOKUP_PASSWD=yes - LOOKUP_DSEARCH=yes - EOC - - if ! use dnsdb; then - # DNSDB lookup is enabled by default - sed -i -e 's:^LOOKUP_DNSDB=yes:# LOOKUP_DNSDB=yes:' Makefile || die - fi - - if use ldap; then - cat >> Makefile <<- EOC - LOOKUP_LDAP=yes - LDAP_LIB_TYPE=OPENLDAP2 - LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/ldap - LOOKUP_LIBS += -lldap -llber - EOC - fi - - if use mysql; then - cat >> Makefile <<- EOC - LOOKUP_MYSQL=yes - LOOKUP_INCLUDE += $(mysql_config --include) - LOOKUP_LIBS += $(mysql_config --libs) - EOC - fi - - if use nis; then - cat >> Makefile <<- EOC - LOOKUP_NIS=yes - LOOKUP_NISPLUS=yes - EOC - if use elibc_glibc ; then - cat >> Makefile <<- EOC - LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/tirpc - LOOKUP_LIBS += -lnsl - EOC - fi - fi - - if use postgres; then - cat >> Makefile <<- EOC - LOOKUP_PGSQL=yes - LOOKUP_INCLUDE += -I$(pg_config --includedir) - LOOKUP_LIBS += -L$(pg_config --libdir) -lpq - EOC - fi - - if use sqlite; then - cat >> Makefile <<- EOC - LOOKUP_SQLITE=yes - LOOKUP_SQLITE_PC=sqlite3 - EOC - fi - - if use redis; then - cat >> Makefile <<- EOC - LOOKUP_REDIS=yes - LOOKUP_LIBS += -lhiredis - EOC - fi - - # Exim monitor, enabled by default, controlled via X USE-flag, - # disable if not requested, bug #46778 - if use X; then - cp ../exim_monitor/EDITME eximon.conf || die - cat >> Makefile <<- EOC - EXIM_MONITOR=eximon.bin - EOC - fi - - # - # features - # - - # content scanning support - if use exiscan-acl; then - cat >> Makefile <<- EOC - WITH_CONTENT_SCAN=yes - EOC - fi - - # DomainKeys Identified Mail, RFC4871 - if ! use dkim; then - # DKIM is enabled by default - cat >> Makefile <<- EOC - DISABLE_DKIM=yes - EOC - fi - - # Per-Recipient-Data-Response - if ! use prdr; then - # PRDR is enabled by default - cat >> Makefile <<- EOC - DISABLE_PRDR=yes - EOC - fi - - # Transport post-delivery actions - if use !tpda && use !dane; then - # EVENT is enabled by default - cat >> Makefile <<- EOC - DISABLE_EVENT=yes - EOC - fi - - # log to syslog - if use syslog; then - local eximlog="${EPREFIX}/var/log/exim/exim_%s.log" - sed -i \ - -e "s:LOG_FILE_PATH=${eximlog}:LOG_FILE_PATH=syslog:" \ - Makefile || die - cat >> Makefile <<- EOC - LOG_FILE_PATH=syslog - EOC - else - cat >> Makefile <<- EOC - LOG_FILE_PATH=${EPREFIX}/var/log/exim/exim_%s.log - EOC - fi - - # starttls support (ssl) - if use ssl; then - if use gnutls; then - echo "USE_GNUTLS=yes" >> Makefile - echo "USE_GNUTLS_PC=gnutls $(use dane && echo gnutls-dane)" \ - >> Makefile - use pkcs11 || echo "AVOID_GNUTLS_PKCS11=yes" >> Makefile - else - echo "USE_OPENSSL=yes" >> Makefile - echo "USE_OPENSSL_PC=openssl" >> Makefile - fi - else - echo "DISABLE_TLS=yes" >> Makefile - fi - - # TCP wrappers - if use tcpd; then - cat >> Makefile <<- EOC - USE_TCP_WRAPPERS=yes - EXTRALIBS_EXIM += -lwrap - EOC - fi - - # Light Mail Transport Protocol - if use lmtp; then - cat >> Makefile <<- EOC - TRANSPORT_LMTP=yes - EOC - fi - - # embedded Perl - if use perl; then - cat >> Makefile <<- EOC - EXIM_PERL=perl.o - EOC - fi - - # dlfunc - if use dlfunc; then - cat >> Makefile <<- EOC - EXPAND_DLFUNC=yes - HAVE_LOCAL_SCAN=yes - DLOPEN_LOCAL_SCAN=yes - EOC - fi - - # Proxy Protocol - if use proxy; then - cat >> Makefile <<- EOC - SUPPORT_PROXY=yes - EOC - fi - - # SOCKS5 (outbound) proxy support - if use socks5; then - cat >> Makefile <<- EOC - SUPPORT_SOCKS=yes - EOC - fi - - # DANE - if use !dane; then - # DANE is enabled by default - sed -i -e 's:^SUPPORT_DANE=yes:# SUPPORT_DANE=yes:' Makefile || die - fi - - # DMARC - if use dmarc; then - cat >> Makefile <<- EOC - SUPPORT_DMARC=yes - EXTRALIBS_EXIM += -lopendmarc - EOC - fi - - # Sender Policy Framework - if use spf; then - cat >> Makefile <<- EOC - SUPPORT_SPF=yes - EXTRALIBS_EXIM += -lspf2 - EOC - fi - - # - # experimental features - # - - # Authenticated Receive Chain - if use arc; then - echo "EXPERIMENTAL_ARC=yes">> Makefile - fi - - # Distributed Checksum Clearinghouse - if use dcc; then - echo "EXPERIMENTAL_DCC=yes">> Makefile - fi - - # Sender Rewriting Scheme - if use srs; then - # NOTE: we currently USE-default to srs-alt, because this is - # what USE=srs used to be. Eventually we want to rid ourselves - # of this external implementation. - if use srs-alt; then - # historical default, from 4.95 this becomes - # EXPERIMENTAL_SRS_ALT - cat >> Makefile <<- EOC - EXPERIMENTAL_SRS=yes - EXTRALIBS_EXIM += -lsrs_alt - EOC - fi - if use srs-native; then - # this one becomes SUPPORT_SRS in 4.95 - cat >> Makefile <<- EOC - EXPERIMENTAL_SRS_NATIVE=yes - EOC - fi - fi - - # Delivery Sender Notifications extra information in fail message - if use dsn; then - cat >> Makefile <<- EOC - EXPERIMENTAL_DSN_INFO=yes - EOC - fi - - # - # authentication (SMTP AUTH) - # - - # standard bits - cat >> Makefile <<- EOC - AUTH_SPA=yes - AUTH_CRAM_MD5=yes - AUTH_PLAINTEXT=yes - EOC - - # Cyrus SASL - if use sasl; then - cat >> Makefile <<- EOC - CYRUS_SASLAUTHD_SOCKET=${EPREFIX}/run/saslauthd/mux - AUTH_CYRUS_SASL=yes - AUTH_LIBS += -lsasl2 - EOC - fi - - # Dovecot - if use dovecot-sasl; then - cat >> Makefile <<- EOC - AUTH_DOVECOT=yes - EOC - fi - - # Pluggable Authentication Modules - if use pam; then - cat >> Makefile <<- EOC - SUPPORT_PAM=yes - AUTH_LIBS += -lpam - EOC - fi - - # Radius - if use radius; then - cat >> Makefile <<- EOC - RADIUS_CONFIG_FILE=${EPREFIX}/etc/radiusclient/radiusclient.conf - RADIUS_LIB_TYPE=RADIUSCLIENTNEW - AUTH_LIBS += -lfreeradius-client - EOC - fi -} - -src_compile() { - emake CC="$(tc-getCC)" HOSTCC="$(tc-getBUILD_CC)" \ - AR="$(tc-getAR) cq" RANLIB="$(tc-getRANLIB)" FULLECHO='' -} - -src_install() { - cd "${S}"/build-exim-gentoo || die - dosbin exim - if use X; then - dosbin eximon.bin - dosbin eximon - fi - fperms 4755 /usr/sbin/exim - - dosym exim /usr/sbin/sendmail - dosym exim /usr/sbin/rsmtp - dosym exim /usr/sbin/rmail - dosym ../sbin/exim /usr/bin/mailq - dosym ../sbin/exim /usr/bin/newaliases - dosym ../sbin/sendmail /usr/lib/sendmail - - for i in exicyclog exim_dbmbuild exim_dumpdb exim_fixdb exim_lock \ - exim_tidydb exinext exiwhat exigrep eximstats exiqsumm exiqgrep \ - convert4r3 convert4r4 exipick - do - dosbin $i - done - - dodoc -r "${S}"/doc/. - doman "${S}"/doc/exim.8 - use dsn && dodoc "${S}"/README.DSN - use doc && dodoc "${WORKDIR}"/${PN}-pdf-${PV//rc/RC}/doc/*.pdf - - # conf files - insinto /etc/exim - newins "${S}"/src/configure.default exim.conf.dist - if use exiscan-acl; then - newins "${S}"/src/configure.default exim.conf.exiscan-acl - fi - doins "${WORKDIR}"/system_filter.exim - doins "${FILESDIR}"/auth_conf.sub - - if use pam; then - pamd_mimic system-auth exim auth account - fi - - # headers, #436406 - if use dlfunc ; then - # fixup includes so they actually can be found when including - sed -i \ - -e '/#include "\(config\|store\|mytypes\).h"/s:"\(.\+\)"::' \ - local_scan.h || die - insinto /usr/include/exim - doins {config,local_scan}.h ../src/{mytypes,store}.h - fi - - insinto /etc/logrotate.d - newins "${FILESDIR}/exim.logrotate" exim - - newinitd "${FILESDIR}"/exim.rc10 exim - newconfd "${FILESDIR}"/exim.confd exim - - systemd_dounit \ - "${FILESDIR}"/{exim.service,exim.socket,exim-submission.socket} - systemd_newunit \ - "${FILESDIR}"/exim_at.service 'exim@.service' - systemd_newunit \ - "${FILESDIR}"/exim-submission_at.service 'exim-submission@.service' - - diropts -m 0750 -o ${MAILUSER} -g ${MAILGROUP} - keepdir /var/log/${PN} -} - -pkg_postinst() { - if [[ ! -f ${EROOT}/etc/exim/exim.conf ]] ; then - einfo "${EROOT}/etc/exim/system_filter.exim is a sample system_filter." - einfo "${EROOT}/etc/exim/auth_conf.sub contains the configuration sub" - einfo "for using smtp auth." - einfo "Please create ${EROOT}/etc/exim/exim.conf from" - einfo " ${EROOT}/etc/exim/exim.conf.dist." - fi - if use dmarc ; then - einfo "DMARC support requires ${EROOT}/etc/exim/opendmarc.tlds" - einfo "you can populate this file with the contents downloaded from" - einfo " https://publicsuffix.org/list/public_suffix_list.dat" - fi - if use dcc ; then - einfo "DCC support is experimental, you can find some limited" - einfo "documentation at the bottom of this prerelease message:" - einfo " http://article.gmane.org/gmane.mail.exim.devel/3579" - fi - if use srs ; then - einfo "SRS support is experimental in this release of Exim" - if use srs-alt; then - elog "You are using libsrs_alt to implement SRS support." - elog "In future release of Exim, the native SRS implementation" - elog "(USE=srs-native) will become the default. Please prepare" - elog "your package.use or switch to USE=srs-native now." - fi - fi - use dsn && einfo "extra information in fail DSN message is experimental" - einfo - elog "Note that this release contains a tainted variable check that" - elog "is likely to break your configuration used with Exim 4.93 and before." - elog "Please check your transports for occurences of \$local_part, and" - elog "use a replacement like \$local_part_data where possible." -} diff --git a/mail-mta/exim/exim-4.94.2-r7.ebuild b/mail-mta/exim/exim-4.94.2-r7.ebuild new file mode 100644 index 000000000000..4d949c4c4c01 --- /dev/null +++ b/mail-mta/exim/exim-4.94.2-r7.ebuild @@ -0,0 +1,623 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +inherit db-use toolchain-funcs multilib pam systemd + +IUSE="arc +dane dcc +dkim dlfunc dmarc +dnsdb doc dovecot-sasl dsn exiscan-acl gnutls idn ipv6 ldap lmtp maildir mbx mysql nis pam perl pkcs11 postgres +prdr proxy radius redis sasl selinux spf sqlite srs +srs-alt srs-native +ssl syslog tcpd +tpda X" +REQUIRED_USE=" + arc? ( dkim spf ) + dane? ( ssl !gnutls ) + dmarc? ( dkim spf ) + dkim? ( ssl !gnutls ) + gnutls? ( ssl ) + pkcs11? ( ssl ) + spf? ( exiscan-acl ) + srs? ( + exiscan-acl + ^^ ( srs-alt srs-native ) + ) +" +# NOTE on USE="gnutls dane", gnutls[dane] is masked in base, unmasked +# for x86 and amd64 only, due to this, repoman won't allow depending on +# gnutls[dane] for all else. Because we cannot express USE=dane when +# USE=gnutls is in effect only in package.use.mask, the only option we +# have left is to a) ignore the dependency (but that results in bug +# #661164) or b) mask the usage of USE=dane with USE=gnutls. Both are +# incorrect, but b) is the only "correct" view from repoman. + +SDIR=$([[ ${PV} == *_rc* ]] && echo /test + [[ ${PV} == *.*.*.* ]] && echo /fixes) +COMM_URI="https://downloads.exim.org/exim4${SDIR}" + +DESCRIPTION="A highly configurable, drop-in replacement for sendmail" +SRC_URI="${COMM_URI}/${P//_rc/-RC}.tar.xz + mirror://gentoo/system_filter.exim.gz + doc? ( ${COMM_URI}/${PN}-pdf-${PV//_rc/-RC}.tar.xz )" +HOMEPAGE="https://www.exim.org/" + +SLOT="0" +LICENSE="GPL-2" +KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ~ppc ppc64 sparc x86 ~x86-solaris" + +COMMON_DEPEND=">=sys-apps/sed-4.0.5 + ( >=sys-libs/db-3.2:= =net-nds/openldap-2.0.7:= ) + nis? ( + elibc_glibc? ( + net-libs/libtirpc:= + >=net-libs/libnsl-1:= + ) + ) + mysql? ( dev-db/mysql-connector-c:= ) + postgres? ( dev-db/postgresql:= ) + sasl? ( >=dev-libs/cyrus-sasl-2.1.26-r2 ) + redis? ( dev-libs/hiredis:= ) + spf? ( >=mail-filter/libspf2-1.2.5-r1 ) + dmarc? ( mail-filter/opendmarc:= ) + srs? ( srs-alt? ( mail-filter/libsrs_alt ) ) + X? ( + x11-libs/libX11 + x11-libs/libXmu + x11-libs/libXt + x11-libs/libXaw + ) + sqlite? ( dev-db/sqlite ) + radius? ( net-dialup/freeradius-client ) + virtual/libcrypt:= + virtual/libiconv + elibc_glibc? ( net-libs/libnsl ) + " + # added X check for #57206 +BDEPEND="virtual/pkgconfig" +DEPEND="${COMMON_DEPEND}" +RDEPEND="${COMMON_DEPEND} + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/mini-qmail + !=mail-mta/msmtp-1.4.19-r1[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/postfix + !mail-mta/qmail-ldap + !mail-mta/sendmail + !mail-mta/opensmtpd + !=mail-mta/ssmtp-2.64-r2[mta] + !net-mail/mailwrapper + >=net-mail/mailbase-0.00-r5 + virtual/logger + dcc? ( mail-filter/dcc ) + selinux? ( sec-policy/selinux-exim ) + " + +S=${WORKDIR}/${P//_rc/-RC} + +src_prepare() { + # Legacy patches which need a respin for -p1 + eapply -p0 "${FILESDIR}"/exim-4.14-tail.patch + eapply -p0 "${FILESDIR}"/exim-4.74-radius-db-ENV-clash.patch # 287426 + eapply "${FILESDIR}"/exim-4.93-as-needed-ldflags.patch # 352265, 391279 + eapply -p0 "${FILESDIR}"/exim-4.76-crosscompile.patch # 266591 + eapply "${FILESDIR}"/exim-4.69-r1.27021.patch + eapply "${FILESDIR}"/exim-4.94-localscan_dlopen.patch + + # for this reason we have a := dep on opendmarc, they changed their + # API in a minor release + if use dmarc && has_version ">=mail-filter/opendmarc-1.4" ; then + eapply "${FILESDIR}"/exim-4.94-opendmarc-1.4.patch + fi + + if use maildir ; then + eapply "${FILESDIR}"/exim-4.94-maildir.patch + else + eapply -p0 "${FILESDIR}"/exim-4.80-spool-mail-group.patch # 438606 + fi + + eapply_user + + # user Exim believes it should be + MAILUSER=mail + MAILGROUP=mail + if use prefix && [[ ${EUID} != 0 ]] ; then + MAILUSER=$(id -un) + MAILGROUP=$(id -gn) + fi +} + +src_configure() { + # general config and paths + + local aliases="${EPREFIX}/etc/mail/aliases" + sed -i \ + -e "/SYSTEM_ALIASES_FILE/s'SYSTEM_ALIASES_FILE'${aliases}'" \ + src/configure.default || die + + sed -i -e 's/^buildname=.*/buildname=exim-gentoo/' Makefile || die + + if use elibc_musl; then + sed -i -e 's/^LIBS = -lnsl/LIBS =/g' OS/Makefile-Linux || die + fi + + local conffile="${EPREFIX}/etc/exim/exim.conf" + sed -e "48i\CFLAGS=${CFLAGS}" \ + -e "s:BIN_DIRECTORY=/usr/exim/bin:BIN_DIRECTORY=${EPREFIX}/usr/sbin:" \ + -e "s;EXIM_USER=;EXIM_USER=ref:${MAILUSER};" \ + -e "s:CONFIGURE_FILE=.*$:CONFIGURE_FILE=${conffile}:" \ + -e "s:ZCAT_COMMAND=.*$:ZCAT_COMMAND=${EPREFIX}/bin/zcat:" \ + -e "s:COMPRESS_COMMAND=.*$:COMPRESS_COMMAND=${EPREFIX}/bin/gzip:" \ + src/EDITME > Local/Makefile || die + + # work on Local/Makefile from now on + cd Local + + cat >> Makefile <<- EOC + INFO_DIRECTORY=${EPREFIX}/usr/share/info + PID_FILE_PATH=${EPREFIX}/run/exim.pid + SPOOL_DIRECTORY=${EPREFIX}/var/spool/exim + HAVE_ICONV=yes + EOC + + # if we use libiconv, now is the time to tell so + if use !elibc_glibc && use !elibc_musl ; then + cat >> Makefile <<- EOC + EXTRALIBS_EXIM=-liconv + EOC + fi + + # support for IPv6 + if use ipv6; then + cat >> Makefile <<- EOC + HAVE_IPV6=YES + EOC + fi + + # support i18n/IDNA + if use idn; then + cat >> Makefile <<- EOC + SUPPORT_I18N=yes + SUPPORT_I18N_2008=yes + EXTRALIBS_EXIM += -lidn -lidn2 + EOC + fi + + # + # mail storage formats + # + + # mailstore is Exim's traditional storage format + cat >> Makefile <<- EOC + SUPPORT_MAILSTORE=yes + EOC + + # mbox + if use mbx; then + cat >> Makefile <<- EOC + SUPPORT_MBX=yes + EOC + fi + + # maildir + if use maildir; then + cat >> Makefile <<- EOC + SUPPORT_MAILDIR=yes + EOC + fi + + # + # lookup methods + + # use the "native" interfaces to the DBM and CDB libraries, support + # passwd and directory lookups by default + local DB_VERS="5.3 5.1 4.8 4.7 4.6 4.5 4.4 4.3 4.2 3.2" + cat >> Makefile <<- EOC + USE_DB=yes + LOOKUP_CDB=yes + LOOKUP_PASSWD=yes + LOOKUP_DSEARCH=yes + # keep include in CFLAGS because exim.h -> dbstuff.h -> db.h + CFLAGS += -I$(db_includedir ${DB_VERS}) + DBMLIB = -l$(db_libname ${DB_VERS}) + EOC + + if ! use dnsdb; then + # DNSDB lookup is enabled by default + sed -i -e 's:^LOOKUP_DNSDB=yes:# LOOKUP_DNSDB=yes:' Makefile || die + fi + + if use ldap; then + cat >> Makefile <<- EOC + LOOKUP_LDAP=yes + LDAP_LIB_TYPE=OPENLDAP2 + LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/ldap + LOOKUP_LIBS += -lldap -llber + EOC + fi + + if use mysql; then + cat >> Makefile <<- EOC + LOOKUP_MYSQL=yes + LOOKUP_INCLUDE += $(mysql_config --include) + LOOKUP_LIBS += $(mysql_config --libs) + EOC + fi + + if use nis; then + cat >> Makefile <<- EOC + LOOKUP_NIS=yes + LOOKUP_NISPLUS=yes + EOC + if use elibc_glibc ; then + cat >> Makefile <<- EOC + LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/tirpc + LOOKUP_LIBS += -lnsl + EOC + fi + fi + + if use postgres; then + cat >> Makefile <<- EOC + LOOKUP_PGSQL=yes + LOOKUP_INCLUDE += -I$(pg_config --includedir) + LOOKUP_LIBS += -L$(pg_config --libdir) -lpq + EOC + fi + + if use sqlite; then + cat >> Makefile <<- EOC + LOOKUP_SQLITE=yes + LOOKUP_SQLITE_PC=sqlite3 + EOC + fi + + if use redis; then + cat >> Makefile <<- EOC + LOOKUP_REDIS=yes + LOOKUP_LIBS += -lhiredis + EOC + fi + + # Exim monitor, enabled by default, controlled via X USE-flag, + # disable if not requested, bug #46778 + if use X; then + cp ../exim_monitor/EDITME eximon.conf || die + cat >> Makefile <<- EOC + EXIM_MONITOR=eximon.bin + EOC + fi + + # + # features + # + + # content scanning support + if use exiscan-acl; then + cat >> Makefile <<- EOC + WITH_CONTENT_SCAN=yes + EOC + fi + + # DomainKeys Identified Mail, RFC4871 + if ! use dkim; then + # DKIM is enabled by default + cat >> Makefile <<- EOC + DISABLE_DKIM=yes + EOC + fi + + # Per-Recipient-Data-Response + if ! use prdr; then + # PRDR is enabled by default + cat >> Makefile <<- EOC + DISABLE_PRDR=yes + EOC + fi + + # Transport post-delivery actions + if use !tpda && use !dane; then + # EVENT is enabled by default + cat >> Makefile <<- EOC + DISABLE_EVENT=yes + EOC + fi + + # log to syslog + if use syslog; then + local eximlog="${EPREFIX}/var/log/exim/exim_%s.log" + sed -i \ + -e "s:LOG_FILE_PATH=${eximlog}:LOG_FILE_PATH=syslog:" \ + Makefile || die + cat >> Makefile <<- EOC + LOG_FILE_PATH=syslog + EOC + else + cat >> Makefile <<- EOC + LOG_FILE_PATH=${EPREFIX}/var/log/exim/exim_%s.log + EOC + fi + + # starttls support (ssl) + if use ssl; then + if use gnutls; then + echo "USE_GNUTLS=yes" >> Makefile + echo "USE_GNUTLS_PC=gnutls $(use dane && echo gnutls-dane)" \ + >> Makefile + use pkcs11 || echo "AVOID_GNUTLS_PKCS11=yes" >> Makefile + else + echo "USE_OPENSSL=yes" >> Makefile + echo "USE_OPENSSL_PC=openssl" >> Makefile + fi + else + echo "DISABLE_TLS=yes" >> Makefile + fi + + # TCP wrappers + if use tcpd; then + cat >> Makefile <<- EOC + USE_TCP_WRAPPERS=yes + EXTRALIBS_EXIM += -lwrap + EOC + fi + + # Light Mail Transport Protocol + if use lmtp; then + cat >> Makefile <<- EOC + TRANSPORT_LMTP=yes + EOC + fi + + # embedded Perl + if use perl; then + cat >> Makefile <<- EOC + EXIM_PERL=perl.o + EOC + fi + + # dlfunc + if use dlfunc; then + cat >> Makefile <<- EOC + EXPAND_DLFUNC=yes + HAVE_LOCAL_SCAN=yes + DLOPEN_LOCAL_SCAN=yes + EOC + fi + + # Proxy Protocol + if use proxy; then + cat >> Makefile <<- EOC + SUPPORT_PROXY=yes + EOC + fi + + # DANE + if use !dane; then + # DANE is enabled by default + sed -i -e 's:^SUPPORT_DANE=yes:# SUPPORT_DANE=yes:' Makefile || die + fi + + # DMARC + if use dmarc; then + cat >> Makefile <<- EOC + SUPPORT_DMARC=yes + EXTRALIBS_EXIM += -lopendmarc + EOC + fi + + # Sender Policy Framework + if use spf; then + cat >> Makefile <<- EOC + SUPPORT_SPF=yes + EXTRALIBS_EXIM += -lspf2 + EOC + fi + + # + # experimental features + # + + # Authenticated Receive Chain + if use arc; then + echo "EXPERIMENTAL_ARC=yes">> Makefile + fi + + # Distributed Checksum Clearinghouse + if use dcc; then + echo "EXPERIMENTAL_DCC=yes">> Makefile + fi + + # Sender Rewriting Scheme + if use srs; then + # NOTE: we currently USE-default to srs-alt, because this is + # what USE=srs used to be. Eventually we want to rid ourselves + # of this external implementation. + if use srs-alt; then + # historical default, from 4.95 this becomes + # EXPERIMENTAL_SRS_ALT + cat >> Makefile <<- EOC + EXPERIMENTAL_SRS=yes + EXTRALIBS_EXIM += -lsrs_alt + EOC + fi + if use srs-native; then + # this one becomes SUPPORT_SRS in 4.95 + cat >> Makefile <<- EOC + EXPERIMENTAL_SRS_NATIVE=yes + EOC + fi + fi + + # Delivery Sender Notifications extra information in fail message + if use dsn; then + cat >> Makefile <<- EOC + EXPERIMENTAL_DSN_INFO=yes + EOC + fi + + # + # authentication (SMTP AUTH) + # + + # standard bits + cat >> Makefile <<- EOC + AUTH_SPA=yes + AUTH_CRAM_MD5=yes + AUTH_PLAINTEXT=yes + EOC + + # Cyrus SASL + if use sasl; then + cat >> Makefile <<- EOC + CYRUS_SASLAUTHD_SOCKET=${EPREFIX}/run/saslauthd/mux + AUTH_CYRUS_SASL=yes + AUTH_LIBS += -lsasl2 + EOC + fi + + # Dovecot + if use dovecot-sasl; then + cat >> Makefile <<- EOC + AUTH_DOVECOT=yes + EOC + fi + + # Pluggable Authentication Modules + if use pam; then + cat >> Makefile <<- EOC + SUPPORT_PAM=yes + AUTH_LIBS += -lpam + EOC + fi + + # Radius + if use radius; then + cat >> Makefile <<- EOC + RADIUS_CONFIG_FILE=${EPREFIX}/etc/radiusclient/radiusclient.conf + RADIUS_LIB_TYPE=RADIUSCLIENTNEW + AUTH_LIBS += -lfreeradius-client + EOC + fi +} + +src_compile() { + emake CC="$(tc-getCC)" HOSTCC="$(tc-getBUILD_CC)" \ + AR="$(tc-getAR) cq" RANLIB="$(tc-getRANLIB)" FULLECHO='' +} + +src_install() { + cd "${S}"/build-exim-gentoo || die + dosbin exim + if use X; then + dosbin eximon.bin + dosbin eximon + fi + fperms 4755 /usr/sbin/exim + + dosym exim /usr/sbin/sendmail + dosym exim /usr/sbin/rsmtp + dosym exim /usr/sbin/rmail + dosym ../sbin/exim /usr/bin/mailq + dosym ../sbin/exim /usr/bin/newaliases + dosym ../sbin/sendmail /usr/lib/sendmail + + for i in exicyclog exim_dbmbuild exim_dumpdb exim_fixdb exim_lock \ + exim_tidydb exinext exiwhat exigrep eximstats exiqsumm exiqgrep \ + convert4r3 convert4r4 exipick + do + dosbin $i + done + + dodoc -r "${S}"/doc/. + doman "${S}"/doc/exim.8 + use dsn && dodoc "${S}"/README.DSN + use doc && dodoc "${WORKDIR}"/${PN}-pdf-${PV//rc/RC}/doc/*.pdf + + # conf files + insinto /etc/exim + newins "${S}"/src/configure.default exim.conf.dist + if use exiscan-acl; then + newins "${S}"/src/configure.default exim.conf.exiscan-acl + fi + doins "${WORKDIR}"/system_filter.exim + doins "${FILESDIR}"/auth_conf.sub + + if use pam; then + pamd_mimic system-auth exim auth account + fi + + # headers, #436406 + if use dlfunc ; then + # fixup includes so they actually can be found when including + sed -i \ + -e '/#include "\(config\|store\|mytypes\).h"/s:"\(.\+\)"::' \ + local_scan.h || die + insinto /usr/include/exim + doins {config,local_scan}.h ../src/{mytypes,store}.h + fi + + insinto /etc/logrotate.d + newins "${FILESDIR}/exim.logrotate" exim + + newinitd "${FILESDIR}"/exim.rc10 exim + newconfd "${FILESDIR}"/exim.confd exim + + systemd_dounit \ + "${FILESDIR}"/{exim.service,exim.socket,exim-submission.socket} + systemd_newunit \ + "${FILESDIR}"/exim_at.service 'exim@.service' + systemd_newunit \ + "${FILESDIR}"/exim-submission_at.service 'exim-submission@.service' + + diropts -m 0750 -o ${MAILUSER} -g ${MAILGROUP} + keepdir /var/log/${PN} +} + +pkg_postinst() { + if [[ ! -f ${EROOT}/etc/exim/exim.conf ]] ; then + einfo "${EROOT}/etc/exim/system_filter.exim is a sample system_filter." + einfo "${EROOT}/etc/exim/auth_conf.sub contains the configuration sub" + einfo "for using smtp auth." + einfo "Please create ${EROOT}/etc/exim/exim.conf from" + einfo " ${EROOT}/etc/exim/exim.conf.dist." + fi + if use dmarc ; then + einfo "DMARC support requires ${EROOT}/etc/exim/opendmarc.tlds" + einfo "you can populate this file with the contents downloaded from" + einfo " https://publicsuffix.org/list/public_suffix_list.dat" + fi + if use dcc ; then + einfo "DCC support is experimental, you can find some limited" + einfo "documentation at the bottom of this prerelease message:" + einfo " http://article.gmane.org/gmane.mail.exim.devel/3579" + fi + if use srs ; then + einfo "SRS support is experimental in this release of Exim" + if use srs-alt; then + elog "You are using libsrs_alt to implement SRS support." + elog "In future release of Exim, the native SRS implementation" + elog "(USE=srs-native) will become the default. Please prepare" + elog "your package.use or switch to USE=srs-native now." + fi + fi + use dsn && einfo "extra information in fail DSN message is experimental" + einfo + elog "Note that this release contains a tainted variable check that" + elog "is likely to break your configuration used with Exim 4.93 and before." + elog "Please check your transports for occurences of \$local_part, and" + elog "use a replacement like \$local_part_data where possible." +} diff --git a/mail-mta/exim/exim-4.94.2-r8.ebuild b/mail-mta/exim/exim-4.94.2-r8.ebuild new file mode 100644 index 000000000000..7cce1a0a02e3 --- /dev/null +++ b/mail-mta/exim/exim-4.94.2-r8.ebuild @@ -0,0 +1,665 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +inherit db-use toolchain-funcs multilib pam systemd + +IUSE="arc berkdb +dane dcc +dkim dlfunc dmarc +dnsdb doc dovecot-sasl +dsn exiscan-acl gdbm gnutls idn ipv6 ldap lmtp maildir mbx +mysql nis pam perl pkcs11 postgres +prdr proxy radius redis sasl selinux +socks5 spf sqlite srs +srs-alt srs-native +ssl syslog tdb tcpd +tpda X" +REQUIRED_USE=" + arc? ( dkim spf ) + dane? ( ssl !gnutls ) + dmarc? ( dkim spf ) + dkim? ( ssl !gnutls ) + gnutls? ( ssl ) + pkcs11? ( ssl ) + spf? ( exiscan-acl ) + srs? ( + exiscan-acl + ^^ ( srs-alt srs-native ) + ) + || ( berkdb gdbm tdb ) +" +# NOTE on USE="gnutls dane", gnutls[dane] is masked in base, unmasked +# for x86 and amd64 only, due to this, repoman won't allow depending on +# gnutls[dane] for all else. Because we cannot express USE=dane when +# USE=gnutls is in effect only in package.use.mask, the only option we +# have left is to a) ignore the dependency (but that results in bug +# #661164) or b) mask the usage of USE=dane with USE=gnutls. Both are +# incorrect, but b) is the only "correct" view from repoman. +# We cannot express a required use for berkdb/gdbm/tdb correctly because +# berkdb and gdbm are both enabled in base profile + +SDIR=$([[ ${PV} == *_rc* ]] && echo /test + [[ ${PV} == *.*.*.* ]] && echo /fixes) +COMM_URI="https://downloads.exim.org/exim4${SDIR}" + +DESCRIPTION="A highly configurable, drop-in replacement for sendmail" +SRC_URI="${COMM_URI}/${P//_rc/-RC}.tar.xz + mirror://gentoo/system_filter.exim.gz + doc? ( ${COMM_URI}/${PN}-pdf-${PV//_rc/-RC}.tar.xz )" +HOMEPAGE="https://www.exim.org/" + +SLOT="0" +LICENSE="GPL-2" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-solaris" + +COMMON_DEPEND=">=sys-apps/sed-4.0.5 + dev-libs/libpcre:= + tdb? ( sys-libs/tdb:= ) + !tdb? ( berkdb? ( >=sys-libs/db-3.2:= =net-nds/openldap-2.0.7:= ) + elibc_glibc? ( + net-libs/libnsl:= + nis? ( + net-libs/libtirpc:= + >=net-libs/libnsl-1:= + ) + ) + mysql? ( dev-db/mysql-connector-c:= ) + postgres? ( dev-db/postgresql:= ) + sasl? ( >=dev-libs/cyrus-sasl-2.1.26-r2 ) + redis? ( dev-libs/hiredis:= ) + spf? ( >=mail-filter/libspf2-1.2.5-r1 ) + dmarc? ( mail-filter/opendmarc:= ) + srs? ( srs-alt? ( mail-filter/libsrs_alt ) ) + X? ( + x11-libs/libX11 + x11-libs/libXmu + x11-libs/libXt + x11-libs/libXaw + ) + sqlite? ( dev-db/sqlite ) + radius? ( net-dialup/freeradius-client ) + virtual/libcrypt:= + virtual/libiconv + " + # added X check for #57206 +BDEPEND="virtual/pkgconfig" +DEPEND="${COMMON_DEPEND}" +RDEPEND="${COMMON_DEPEND} + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/mini-qmail + !=mail-mta/msmtp-1.4.19-r1[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/postfix + !mail-mta/qmail-ldap + !mail-mta/sendmail + !mail-mta/opensmtpd + !=mail-mta/ssmtp-2.64-r2[mta] + !net-mail/mailwrapper + >=net-mail/mailbase-0.00-r5 + virtual/logger + dcc? ( mail-filter/dcc ) + selinux? ( sec-policy/selinux-exim ) + " + +S=${WORKDIR}/${P//_rc/-RC} + +src_prepare() { + # Legacy patches which need a respin for -p1 + eapply -p0 "${FILESDIR}"/exim-4.14-tail.patch + eapply -p0 "${FILESDIR}"/exim-4.74-radius-db-ENV-clash.patch # 287426 + eapply "${FILESDIR}"/exim-4.93-as-needed-ldflags.patch # 352265, 391279 + eapply -p0 "${FILESDIR}"/exim-4.76-crosscompile.patch # 266591 + eapply "${FILESDIR}"/exim-4.69-r1.27021.patch + eapply "${FILESDIR}"/exim-4.94-localscan_dlopen.patch + eapply "${FILESDIR}"/exim-4.94.2-fix-crash-resolve.patch # 799368 upstr + + # for this reason we have a := dep on opendmarc, they changed their + # API in a minor release + if use dmarc && has_version ">=mail-filter/opendmarc-1.4" ; then + eapply "${FILESDIR}"/exim-4.94-opendmarc-1.4.patch + fi + + if use maildir ; then + eapply "${FILESDIR}"/exim-4.94-maildir.patch + else + eapply -p0 "${FILESDIR}"/exim-4.80-spool-mail-group.patch # 438606 + fi + + eapply_user + + # user Exim believes it should be + MAILUSER=mail + MAILGROUP=mail + if use prefix && [[ ${EUID} != 0 ]] ; then + MAILUSER=$(id -un) + MAILGROUP=$(id -gn) + fi +} + +src_configure() { + # general config and paths + + local aliases="${EPREFIX}/etc/mail/aliases" + sed -i \ + -e "/SYSTEM_ALIASES_FILE/s'SYSTEM_ALIASES_FILE'${aliases}'" \ + src/configure.default || die + + sed -i -e 's/^buildname=.*/buildname=exim-gentoo/' Makefile || die + + if use elibc_musl; then + sed -i -e 's/^LIBS = -lnsl/LIBS =/g' OS/Makefile-Linux || die + fi + + local conffile="${EPREFIX}/etc/exim/exim.conf" + sed -e "48i\CFLAGS=${CFLAGS}" \ + -e "s:BIN_DIRECTORY=/usr/exim/bin:BIN_DIRECTORY=${EPREFIX}/usr/sbin:" \ + -e "s;EXIM_USER=;EXIM_USER=ref:${MAILUSER};" \ + -e "s:CONFIGURE_FILE=.*$:CONFIGURE_FILE=${conffile}:" \ + -e "s:ZCAT_COMMAND=.*$:ZCAT_COMMAND=${EPREFIX}/bin/zcat:" \ + -e "s:COMPRESS_COMMAND=.*$:COMPRESS_COMMAND=${EPREFIX}/bin/gzip:" \ + src/EDITME > Local/Makefile || die + + # work on Local/Makefile from now on + cd Local + + cat >> Makefile <<- EOC + INFO_DIRECTORY=${EPREFIX}/usr/share/info + PID_FILE_PATH=${EPREFIX}/run/exim.pid + SPOOL_DIRECTORY=${EPREFIX}/var/spool/exim + HAVE_ICONV=yes + EOC + + # configure db implementation, Exim always needs one for its hints + # database, we prefer tdb and gdbm, since bdb is kind of getting + # less and less support + if use tdb ; then + cat >> Makefile <<- EOC + USE_TDB=yes + DBMLIB = -ltdb + EOC + sed -i -e 's:^USE_DB=yes:# USE_DB=yes:' Makefile || die + sed -i -e 's:^USE_GDBM=yes:# USE_GDBM=yes:' Makefile || die + elif use berkdb ; then + # use the "native" interfaces to the DBM and CDB libraries, support + # passwd and directory lookups by default + local DB_VERS="5.3 5.1 4.8 4.7 4.6 4.5 4.4 4.3 4.2 3.2" + cat >> Makefile <<- EOC + USE_DB=yes + # keep include in CFLAGS because exim.h -> dbstuff.h -> db.h + CFLAGS += -I$(db_includedir ${DB_VERS}) + DBMLIB = -l$(db_libname ${DB_VERS}) + EOC + sed -i -e 's:^USE_GDBM=yes:# USE_GDBM=yes:' Makefile || die + sed -i -e 's:^USE_TDB=yes:# USE_TDB=yes:' Makefile || die + else # must be gdbm via required_use + cat >> Makefile <<- EOC + USE_GDBM=yes + DBMLIB = -lgdbm + EOC + sed -i -e 's:^USE_DB=yes:# USE_DB=yes:' Makefile || die + sed -i -e 's:^USE_TDB=yes:# USE_TDB=yes:' Makefile || die + fi + + # if we use libiconv, now is the time to tell so + if use !elibc_glibc && use !elibc_musl ; then + cat >> Makefile <<- EOC + EXTRALIBS_EXIM=-liconv + EOC + fi + + # support for IPv6 + if use ipv6; then + cat >> Makefile <<- EOC + HAVE_IPV6=YES + EOC + fi + + # support i18n/IDNA + if use idn; then + cat >> Makefile <<- EOC + SUPPORT_I18N=yes + SUPPORT_I18N_2008=yes + EXTRALIBS_EXIM += -lidn -lidn2 + EOC + fi + + # + # mail storage formats + # + + # mailstore is Exim's traditional storage format + cat >> Makefile <<- EOC + SUPPORT_MAILSTORE=yes + EOC + + # mbox + if use mbx; then + cat >> Makefile <<- EOC + SUPPORT_MBX=yes + EOC + fi + + # maildir + if use maildir; then + cat >> Makefile <<- EOC + SUPPORT_MAILDIR=yes + EOC + fi + + # + # lookup methods + # + + # support passwd and directory lookups by default + cat >> Makefile <<- EOC + LOOKUP_CDB=yes + LOOKUP_PASSWD=yes + LOOKUP_DSEARCH=yes + EOC + + if ! use dnsdb; then + # DNSDB lookup is enabled by default + sed -i -e 's:^LOOKUP_DNSDB=yes:# LOOKUP_DNSDB=yes:' Makefile || die + fi + + if use ldap; then + cat >> Makefile <<- EOC + LOOKUP_LDAP=yes + LDAP_LIB_TYPE=OPENLDAP2 + LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/ldap + LOOKUP_LIBS += -lldap -llber + EOC + fi + + if use mysql; then + cat >> Makefile <<- EOC + LOOKUP_MYSQL=yes + LOOKUP_INCLUDE += $(mysql_config --include) + LOOKUP_LIBS += $(mysql_config --libs) + EOC + fi + + if use nis; then + cat >> Makefile <<- EOC + LOOKUP_NIS=yes + LOOKUP_NISPLUS=yes + EOC + if use elibc_glibc ; then + cat >> Makefile <<- EOC + LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/tirpc + LOOKUP_LIBS += -lnsl + EOC + fi + fi + + if use postgres; then + cat >> Makefile <<- EOC + LOOKUP_PGSQL=yes + LOOKUP_INCLUDE += -I$(pg_config --includedir) + LOOKUP_LIBS += -L$(pg_config --libdir) -lpq + EOC + fi + + if use sqlite; then + cat >> Makefile <<- EOC + LOOKUP_SQLITE=yes + LOOKUP_SQLITE_PC=sqlite3 + EOC + fi + + if use redis; then + cat >> Makefile <<- EOC + LOOKUP_REDIS=yes + LOOKUP_LIBS += -lhiredis + EOC + fi + + # Exim monitor, enabled by default, controlled via X USE-flag, + # disable if not requested, bug #46778 + if use X; then + cp ../exim_monitor/EDITME eximon.conf || die + cat >> Makefile <<- EOC + EXIM_MONITOR=eximon.bin + EOC + fi + + # + # features + # + + # content scanning support + if use exiscan-acl; then + cat >> Makefile <<- EOC + WITH_CONTENT_SCAN=yes + EOC + fi + + # DomainKeys Identified Mail, RFC4871 + if ! use dkim; then + # DKIM is enabled by default + cat >> Makefile <<- EOC + DISABLE_DKIM=yes + EOC + fi + + # Per-Recipient-Data-Response + if ! use prdr; then + # PRDR is enabled by default + cat >> Makefile <<- EOC + DISABLE_PRDR=yes + EOC + fi + + # Transport post-delivery actions + if use !tpda && use !dane; then + # EVENT is enabled by default + cat >> Makefile <<- EOC + DISABLE_EVENT=yes + EOC + fi + + # log to syslog + if use syslog; then + local eximlog="${EPREFIX}/var/log/exim/exim_%s.log" + sed -i \ + -e "s:LOG_FILE_PATH=${eximlog}:LOG_FILE_PATH=syslog:" \ + Makefile || die + cat >> Makefile <<- EOC + LOG_FILE_PATH=syslog + EOC + else + cat >> Makefile <<- EOC + LOG_FILE_PATH=${EPREFIX}/var/log/exim/exim_%s.log + EOC + fi + + # starttls support (ssl) + if use ssl; then + if use gnutls; then + echo "USE_GNUTLS=yes" >> Makefile + echo "USE_GNUTLS_PC=gnutls $(use dane && echo gnutls-dane)" \ + >> Makefile + use pkcs11 || echo "AVOID_GNUTLS_PKCS11=yes" >> Makefile + else + echo "USE_OPENSSL=yes" >> Makefile + echo "USE_OPENSSL_PC=openssl" >> Makefile + fi + else + echo "DISABLE_TLS=yes" >> Makefile + fi + + # TCP wrappers + if use tcpd; then + cat >> Makefile <<- EOC + USE_TCP_WRAPPERS=yes + EXTRALIBS_EXIM += -lwrap + EOC + fi + + # Light Mail Transport Protocol + if use lmtp; then + cat >> Makefile <<- EOC + TRANSPORT_LMTP=yes + EOC + fi + + # embedded Perl + if use perl; then + cat >> Makefile <<- EOC + EXIM_PERL=perl.o + EOC + fi + + # dlfunc + if use dlfunc; then + cat >> Makefile <<- EOC + EXPAND_DLFUNC=yes + HAVE_LOCAL_SCAN=yes + DLOPEN_LOCAL_SCAN=yes + EOC + fi + + # Proxy Protocol + if use proxy; then + cat >> Makefile <<- EOC + SUPPORT_PROXY=yes + EOC + fi + + # SOCKS5 (outbound) proxy support + if use socks5; then + cat >> Makefile <<- EOC + SUPPORT_SOCKS=yes + EOC + fi + + # DANE + if use !dane; then + # DANE is enabled by default + sed -i -e 's:^SUPPORT_DANE=yes:# SUPPORT_DANE=yes:' Makefile || die + fi + + # DMARC + if use dmarc; then + cat >> Makefile <<- EOC + SUPPORT_DMARC=yes + EXTRALIBS_EXIM += -lopendmarc + EOC + fi + + # Sender Policy Framework + if use spf; then + cat >> Makefile <<- EOC + SUPPORT_SPF=yes + EXTRALIBS_EXIM += -lspf2 + EOC + fi + + # + # experimental features + # + + # Authenticated Receive Chain + if use arc; then + echo "EXPERIMENTAL_ARC=yes">> Makefile + fi + + # Distributed Checksum Clearinghouse + if use dcc; then + echo "EXPERIMENTAL_DCC=yes">> Makefile + fi + + # Sender Rewriting Scheme + if use srs; then + # NOTE: we currently USE-default to srs-alt, because this is + # what USE=srs used to be. Eventually we want to rid ourselves + # of this external implementation. + if use srs-alt; then + # historical default, from 4.95 this becomes + # EXPERIMENTAL_SRS_ALT + cat >> Makefile <<- EOC + EXPERIMENTAL_SRS=yes + EXTRALIBS_EXIM += -lsrs_alt + EOC + fi + if use srs-native; then + # this one becomes SUPPORT_SRS in 4.95 + cat >> Makefile <<- EOC + EXPERIMENTAL_SRS_NATIVE=yes + EOC + fi + fi + + # Delivery Sender Notifications extra information in fail message + if use dsn; then + cat >> Makefile <<- EOC + EXPERIMENTAL_DSN_INFO=yes + EOC + fi + + # + # authentication (SMTP AUTH) + # + + # standard bits + cat >> Makefile <<- EOC + AUTH_SPA=yes + AUTH_CRAM_MD5=yes + AUTH_PLAINTEXT=yes + EOC + + # Cyrus SASL + if use sasl; then + cat >> Makefile <<- EOC + CYRUS_SASLAUTHD_SOCKET=${EPREFIX}/run/saslauthd/mux + AUTH_CYRUS_SASL=yes + AUTH_LIBS += -lsasl2 + EOC + fi + + # Dovecot + if use dovecot-sasl; then + cat >> Makefile <<- EOC + AUTH_DOVECOT=yes + EOC + fi + + # Pluggable Authentication Modules + if use pam; then + cat >> Makefile <<- EOC + SUPPORT_PAM=yes + AUTH_LIBS += -lpam + EOC + fi + + # Radius + if use radius; then + cat >> Makefile <<- EOC + RADIUS_CONFIG_FILE=${EPREFIX}/etc/radiusclient/radiusclient.conf + RADIUS_LIB_TYPE=RADIUSCLIENTNEW + AUTH_LIBS += -lfreeradius-client + EOC + fi +} + +src_compile() { + emake CC="$(tc-getCC)" HOSTCC="$(tc-getBUILD_CC)" \ + AR="$(tc-getAR) cq" RANLIB="$(tc-getRANLIB)" FULLECHO='' +} + +src_install() { + cd "${S}"/build-exim-gentoo || die + dosbin exim + if use X; then + dosbin eximon.bin + dosbin eximon + fi + fperms 4755 /usr/sbin/exim + + dosym exim /usr/sbin/sendmail + dosym exim /usr/sbin/rsmtp + dosym exim /usr/sbin/rmail + dosym ../sbin/exim /usr/bin/mailq + dosym ../sbin/exim /usr/bin/newaliases + dosym ../sbin/sendmail /usr/lib/sendmail + + for i in exicyclog exim_dbmbuild exim_dumpdb exim_fixdb exim_lock \ + exim_tidydb exinext exiwhat exigrep eximstats exiqsumm exiqgrep \ + convert4r3 convert4r4 exipick + do + dosbin $i + done + + dodoc -r "${S}"/doc/. + doman "${S}"/doc/exim.8 + use dsn && dodoc "${S}"/README.DSN + use doc && dodoc "${WORKDIR}"/${PN}-pdf-${PV//rc/RC}/doc/*.pdf + + # conf files + insinto /etc/exim + newins "${S}"/src/configure.default exim.conf.dist + if use exiscan-acl; then + newins "${S}"/src/configure.default exim.conf.exiscan-acl + fi + doins "${WORKDIR}"/system_filter.exim + doins "${FILESDIR}"/auth_conf.sub + + if use pam; then + pamd_mimic system-auth exim auth account + fi + + # headers, #436406 + if use dlfunc ; then + # fixup includes so they actually can be found when including + sed -i \ + -e '/#include "\(config\|store\|mytypes\).h"/s:"\(.\+\)"::' \ + local_scan.h || die + insinto /usr/include/exim + doins {config,local_scan}.h ../src/{mytypes,store}.h + fi + + insinto /etc/logrotate.d + newins "${FILESDIR}/exim.logrotate" exim + + newinitd "${FILESDIR}"/exim.rc10 exim + newconfd "${FILESDIR}"/exim.confd exim + + systemd_dounit \ + "${FILESDIR}"/{exim.service,exim.socket,exim-submission.socket} + systemd_newunit \ + "${FILESDIR}"/exim_at.service 'exim@.service' + systemd_newunit \ + "${FILESDIR}"/exim-submission_at.service 'exim-submission@.service' + + diropts -m 0750 -o ${MAILUSER} -g ${MAILGROUP} + keepdir /var/log/${PN} +} + +pkg_postinst() { + if [[ ! -f ${EROOT}/etc/exim/exim.conf ]] ; then + einfo "${EROOT}/etc/exim/system_filter.exim is a sample system_filter." + einfo "${EROOT}/etc/exim/auth_conf.sub contains the configuration sub" + einfo "for using smtp auth." + einfo "Please create ${EROOT}/etc/exim/exim.conf from" + einfo " ${EROOT}/etc/exim/exim.conf.dist." + fi + if use dmarc ; then + einfo "DMARC support requires ${EROOT}/etc/exim/opendmarc.tlds" + einfo "you can populate this file with the contents downloaded from" + einfo " https://publicsuffix.org/list/public_suffix_list.dat" + fi + if use dcc ; then + einfo "DCC support is experimental, you can find some limited" + einfo "documentation at the bottom of this prerelease message:" + einfo " http://article.gmane.org/gmane.mail.exim.devel/3579" + fi + if use srs ; then + einfo "SRS support is experimental in this release of Exim" + if use srs-alt; then + elog "You are using libsrs_alt to implement SRS support." + elog "In future release of Exim, the native SRS implementation" + elog "(USE=srs-native) will become the default. Please prepare" + elog "your package.use or switch to USE=srs-native now." + fi + fi + use dsn && einfo "extra information in fail DSN message is experimental" + einfo + elog "Note that this release contains a tainted variable check that" + elog "is likely to break your configuration used with Exim 4.93 and before." + elog "Please check your transports for occurences of \$local_part, and" + elog "use a replacement like \$local_part_data where possible." +} diff --git a/mail-mta/exim/exim-4.95-r1.ebuild b/mail-mta/exim/exim-4.95-r1.ebuild new file mode 100644 index 000000000000..79d8f53f3470 --- /dev/null +++ b/mail-mta/exim/exim-4.95-r1.ebuild @@ -0,0 +1,662 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="7" + +inherit db-use toolchain-funcs multilib pam systemd + +IUSE="arc berkdb +dane dcc +dkim dlfunc dmarc +dnsdb doc dovecot-sasl +dsn exiscan-acl gdbm gnutls idn ipv6 ldap lmtp maildir mbx +mysql nis pam perl pkcs11 postgres +prdr proxy radius redis sasl selinux +socks5 spf sqlite srs srs-alt +srs-native +ssl syslog tdb tcpd +tpda X" +REQUIRED_USE=" + arc? ( dkim spf ) + dane? ( ssl !gnutls ) + dmarc? ( dkim spf ) + dkim? ( ssl !gnutls ) + gnutls? ( ssl ) + pkcs11? ( ssl ) + spf? ( exiscan-acl ) + srs? ( + exiscan-acl + ^^ ( srs-alt srs-native ) + ) + || ( berkdb gdbm tdb ) +" +# NOTE on USE="gnutls dane", gnutls[dane] is masked in base, unmasked +# for x86 and amd64 only, due to this, repoman won't allow depending on +# gnutls[dane] for all else. Because we cannot express USE=dane when +# USE=gnutls is in effect only in package.use.mask, the only option we +# have left is to a) ignore the dependency (but that results in bug +# #661164) or b) mask the usage of USE=dane with USE=gnutls. Both are +# incorrect, but b) is the only "correct" view from repoman. +# We cannot express a required use for berkdb/gdbm/tdb correctly because +# berkdb and gdbm are both enabled in base profile + +SDIR=$([[ ${PV} == *_rc* ]] && echo /test + [[ ${PV} == *.*.*.* ]] && echo /fixes) +COMM_URI="https://downloads.exim.org/exim4${SDIR}" + +DESCRIPTION="A highly configurable, drop-in replacement for sendmail" +SRC_URI="${COMM_URI}/${P//_rc/-RC}.tar.xz + mirror://gentoo/system_filter.exim.gz + doc? ( ${COMM_URI}/${PN}-pdf-${PV//_rc/-RC}.tar.xz )" +HOMEPAGE="https://www.exim.org/" + +SLOT="0" +LICENSE="GPL-2" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-solaris" + +COMMON_DEPEND=">=sys-apps/sed-4.0.5 + dev-libs/libpcre:= + tdb? ( sys-libs/tdb:= ) + !tdb? ( berkdb? ( >=sys-libs/db-3.2:= =net-nds/openldap-2.0.7:= ) + elibc_glibc? ( + net-libs/libnsl:= + nis? ( + net-libs/libtirpc:= + >=net-libs/libnsl-1:= + ) + ) + mysql? ( dev-db/mysql-connector-c:= ) + postgres? ( dev-db/postgresql:= ) + sasl? ( >=dev-libs/cyrus-sasl-2.1.26-r2 ) + redis? ( dev-libs/hiredis:= ) + spf? ( >=mail-filter/libspf2-1.2.5-r1 ) + dmarc? ( mail-filter/opendmarc:= ) + srs? ( srs-alt? ( mail-filter/libsrs_alt ) ) + X? ( + x11-libs/libX11 + x11-libs/libXmu + x11-libs/libXt + x11-libs/libXaw + ) + sqlite? ( dev-db/sqlite ) + radius? ( net-dialup/freeradius-client ) + virtual/libcrypt:= + virtual/libiconv + " + # added X check for #57206 +BDEPEND="virtual/pkgconfig" +DEPEND="${COMMON_DEPEND}" +RDEPEND="${COMMON_DEPEND} + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/mini-qmail + !=mail-mta/msmtp-1.4.19-r1[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/postfix + !mail-mta/qmail-ldap + !mail-mta/sendmail + !mail-mta/opensmtpd + !=mail-mta/ssmtp-2.64-r2[mta] + !net-mail/mailwrapper + >=net-mail/mailbase-0.00-r5 + virtual/logger + dcc? ( mail-filter/dcc ) + selinux? ( sec-policy/selinux-exim ) + " + +S=${WORKDIR}/${P//_rc/-RC} + +src_prepare() { + # Legacy patches which need a respin for -p1 + eapply -p0 "${FILESDIR}"/exim-4.14-tail.patch + eapply -p0 "${FILESDIR}"/exim-4.74-radius-db-ENV-clash.patch # 287426 + eapply "${FILESDIR}"/exim-4.93-as-needed-ldflags.patch # 352265, 391279 + eapply -p0 "${FILESDIR}"/exim-4.76-crosscompile.patch # 266591 + eapply "${FILESDIR}"/exim-4.69-r1.27021.patch + eapply "${FILESDIR}"/exim-4.95-localscan_dlopen.patch + + # for this reason we have a := dep on opendmarc, they changed their + # API in a minor release + if use dmarc && has_version ">=mail-filter/opendmarc-1.4" ; then + eapply "${FILESDIR}"/exim-4.94-opendmarc-1.4.patch + fi + + if use maildir ; then + eapply "${FILESDIR}"/exim-4.94-maildir.patch + else + eapply -p0 "${FILESDIR}"/exim-4.80-spool-mail-group.patch # 438606 + fi + + eapply_user + + # user Exim believes it should be + MAILUSER=mail + MAILGROUP=mail + if use prefix && [[ ${EUID} != 0 ]] ; then + MAILUSER=$(id -un) + MAILGROUP=$(id -gn) + fi +} + +src_configure() { + # general config and paths + + local aliases="${EPREFIX}/etc/mail/aliases" + sed -i \ + -e "/SYSTEM_ALIASES_FILE/s'SYSTEM_ALIASES_FILE'${aliases}'" \ + src/configure.default || die + + sed -i -e 's/^buildname=.*/buildname=exim-gentoo/' Makefile || die + + if use elibc_musl; then + sed -i -e 's/^LIBS = -lnsl/LIBS =/g' OS/Makefile-Linux || die + fi + + local conffile="${EPREFIX}/etc/exim/exim.conf" + sed -e "48i\CFLAGS=${CFLAGS}" \ + -e "s:BIN_DIRECTORY=/usr/exim/bin:BIN_DIRECTORY=${EPREFIX}/usr/sbin:" \ + -e "s;EXIM_USER=;EXIM_USER=ref:${MAILUSER};" \ + -e "s:CONFIGURE_FILE=.*$:CONFIGURE_FILE=${conffile}:" \ + -e "s:ZCAT_COMMAND=.*$:ZCAT_COMMAND=${EPREFIX}/bin/zcat:" \ + -e "s:COMPRESS_COMMAND=.*$:COMPRESS_COMMAND=${EPREFIX}/bin/gzip:" \ + src/EDITME > Local/Makefile || die + + # work on Local/Makefile from now on + cd Local + + cat >> Makefile <<- EOC + INFO_DIRECTORY=${EPREFIX}/usr/share/info + PID_FILE_PATH=${EPREFIX}/run/exim.pid + SPOOL_DIRECTORY=${EPREFIX}/var/spool/exim + HAVE_ICONV=yes + EOC + + # configure db implementation, Exim always needs one for its hints + # database, we prefer tdb and gdbm, since bdb is kind of getting + # less and less support + if use tdb ; then + cat >> Makefile <<- EOC + USE_TDB=yes + DBMLIB = -ltdb + EOC + sed -i -e 's:^USE_DB=yes:# USE_DB=yes:' Makefile || die + sed -i -e 's:^USE_GDBM=yes:# USE_GDBM=yes:' Makefile || die + elif use berkdb ; then + # use the "native" interfaces to the DBM and CDB libraries, support + # passwd and directory lookups by default + local DB_VERS="5.3 5.1 4.8 4.7 4.6 4.5 4.4 4.3 4.2 3.2" + cat >> Makefile <<- EOC + USE_DB=yes + # keep include in CFLAGS because exim.h -> dbstuff.h -> db.h + CFLAGS += -I$(db_includedir ${DB_VERS}) + DBMLIB = -l$(db_libname ${DB_VERS}) + EOC + sed -i -e 's:^USE_GDBM=yes:# USE_GDBM=yes:' Makefile || die + sed -i -e 's:^USE_TDB=yes:# USE_TDB=yes:' Makefile || die + else # must be gdbm via required_use + cat >> Makefile <<- EOC + USE_GDBM=yes + DBMLIB = -lgdbm + EOC + sed -i -e 's:^USE_DB=yes:# USE_DB=yes:' Makefile || die + sed -i -e 's:^USE_TDB=yes:# USE_TDB=yes:' Makefile || die + fi + + # if we use libiconv, now is the time to tell so + if use !elibc_glibc && use !elibc_musl ; then + cat >> Makefile <<- EOC + EXTRALIBS_EXIM=-liconv + EOC + fi + + # support for IPv6 + if use ipv6; then + cat >> Makefile <<- EOC + HAVE_IPV6=YES + EOC + fi + + # support i18n/IDNA + if use idn; then + cat >> Makefile <<- EOC + SUPPORT_I18N=yes + SUPPORT_I18N_2008=yes + EXTRALIBS_EXIM += -lidn -lidn2 + EOC + fi + + # + # mail storage formats + # + + # mailstore is Exim's traditional storage format + cat >> Makefile <<- EOC + SUPPORT_MAILSTORE=yes + EOC + + # mbox + if use mbx; then + cat >> Makefile <<- EOC + SUPPORT_MBX=yes + EOC + fi + + # maildir + if use maildir; then + cat >> Makefile <<- EOC + SUPPORT_MAILDIR=yes + EOC + fi + + # + # lookup methods + # + + # support passwd and directory lookups by default + cat >> Makefile <<- EOC + LOOKUP_CDB=yes + LOOKUP_PASSWD=yes + LOOKUP_DSEARCH=yes + EOC + + if ! use dnsdb; then + # DNSDB lookup is enabled by default + sed -i -e 's:^LOOKUP_DNSDB=yes:# LOOKUP_DNSDB=yes:' Makefile || die + fi + + if use ldap; then + cat >> Makefile <<- EOC + LOOKUP_LDAP=yes + LDAP_LIB_TYPE=OPENLDAP2 + LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/ldap + LOOKUP_LIBS += -lldap -llber + EOC + fi + + if use mysql; then + cat >> Makefile <<- EOC + LOOKUP_MYSQL=yes + LOOKUP_INCLUDE += $(mysql_config --include) + LOOKUP_LIBS += $(mysql_config --libs) + EOC + fi + + if use nis; then + cat >> Makefile <<- EOC + LOOKUP_NIS=yes + LOOKUP_NISPLUS=yes + EOC + if use elibc_glibc ; then + cat >> Makefile <<- EOC + LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/tirpc + LOOKUP_LIBS += -lnsl + EOC + fi + fi + + if use postgres; then + cat >> Makefile <<- EOC + LOOKUP_PGSQL=yes + LOOKUP_INCLUDE += -I$(pg_config --includedir) + LOOKUP_LIBS += -L$(pg_config --libdir) -lpq + EOC + fi + + if use sqlite; then + cat >> Makefile <<- EOC + LOOKUP_SQLITE=yes + LOOKUP_SQLITE_PC=sqlite3 + EOC + fi + + if use redis; then + cat >> Makefile <<- EOC + LOOKUP_REDIS=yes + LOOKUP_LIBS += -lhiredis + EOC + fi + + # Exim monitor, enabled by default, controlled via X USE-flag, + # disable if not requested, bug #46778 + if use X; then + cp ../exim_monitor/EDITME eximon.conf || die + cat >> Makefile <<- EOC + EXIM_MONITOR=eximon.bin + EOC + fi + + # + # features + # + + # content scanning support + if use exiscan-acl; then + cat >> Makefile <<- EOC + WITH_CONTENT_SCAN=yes + EOC + fi + + # DomainKeys Identified Mail, RFC4871 + if ! use dkim; then + # DKIM is enabled by default + cat >> Makefile <<- EOC + DISABLE_DKIM=yes + EOC + fi + + # Per-Recipient-Data-Response + if ! use prdr; then + # PRDR is enabled by default + cat >> Makefile <<- EOC + DISABLE_PRDR=yes + EOC + fi + + # Transport post-delivery actions + if use !tpda && use !dane; then + # EVENT is enabled by default + cat >> Makefile <<- EOC + DISABLE_EVENT=yes + EOC + fi + + # log to syslog + if use syslog; then + local eximlog="${EPREFIX}/var/log/exim/exim_%s.log" + sed -i \ + -e "s:LOG_FILE_PATH=${eximlog}:LOG_FILE_PATH=syslog:" \ + Makefile || die + cat >> Makefile <<- EOC + LOG_FILE_PATH=syslog + EOC + else + cat >> Makefile <<- EOC + LOG_FILE_PATH=${EPREFIX}/var/log/exim/exim_%s.log + EOC + fi + + # starttls support (ssl) + if use ssl; then + if use gnutls; then + echo "USE_GNUTLS=yes" >> Makefile + echo "USE_GNUTLS_PC=gnutls $(use dane && echo gnutls-dane)" \ + >> Makefile + use pkcs11 || echo "AVOID_GNUTLS_PKCS11=yes" >> Makefile + else + echo "USE_OPENSSL=yes" >> Makefile + echo "USE_OPENSSL_PC=openssl" >> Makefile + fi + else + echo "DISABLE_TLS=yes" >> Makefile + fi + + # TCP wrappers + if use tcpd; then + cat >> Makefile <<- EOC + USE_TCP_WRAPPERS=yes + EXTRALIBS_EXIM += -lwrap + EOC + fi + + # Light Mail Transport Protocol + if use lmtp; then + cat >> Makefile <<- EOC + TRANSPORT_LMTP=yes + EOC + fi + + # embedded Perl + if use perl; then + cat >> Makefile <<- EOC + EXIM_PERL=perl.o + EOC + fi + + # dlfunc + if use dlfunc; then + cat >> Makefile <<- EOC + EXPAND_DLFUNC=yes + HAVE_LOCAL_SCAN=yes + DLOPEN_LOCAL_SCAN=yes + EOC + fi + + # Proxy Protocol + if use proxy; then + cat >> Makefile <<- EOC + SUPPORT_PROXY=yes + EOC + fi + + # SOCKS5 (outbound) proxy support + if use socks5; then + cat >> Makefile <<- EOC + SUPPORT_SOCKS=yes + EOC + fi + + # DANE + if use !dane; then + # DANE is enabled by default + sed -i -e 's:^SUPPORT_DANE=yes:# SUPPORT_DANE=yes:' Makefile || die + fi + + # DMARC + if use dmarc; then + cat >> Makefile <<- EOC + SUPPORT_DMARC=yes + EXTRALIBS_EXIM += -lopendmarc + EOC + fi + + # Sender Policy Framework + if use spf; then + cat >> Makefile <<- EOC + SUPPORT_SPF=yes + EXTRALIBS_EXIM += -lspf2 + EOC + fi + + # + # experimental features + # + + # Authenticated Receive Chain + if use arc; then + echo "EXPERIMENTAL_ARC=yes">> Makefile + fi + + # Distributed Checksum Clearinghouse + if use dcc; then + echo "EXPERIMENTAL_DCC=yes">> Makefile + fi + + # Sender Rewriting Scheme + if use srs; then + # NOTE: we currently USE-default to srs-alt, because this is + # what USE=srs used to be. Eventually we want to rid ourselves + # of this external implementation. + if use srs-alt; then + # historical default, until 4.95 + cat >> Makefile <<- EOC + EXPERIMENTAL_SRS_ALT=yes + EXTRALIBS_EXIM += -lsrs_alt + EOC + fi + if use srs-native; then + # this one is the default/supported variant since 4.95 + cat >> Makefile <<- EOC + SUPPORT_SRS=yes + EOC + fi + fi + + # Delivery Sender Notifications extra information in fail message + if use dsn; then + cat >> Makefile <<- EOC + EXPERIMENTAL_DSN_INFO=yes + EOC + fi + + # + # authentication (SMTP AUTH) + # + + # standard bits + cat >> Makefile <<- EOC + AUTH_SPA=yes + AUTH_CRAM_MD5=yes + AUTH_PLAINTEXT=yes + EOC + + # Cyrus SASL + if use sasl; then + cat >> Makefile <<- EOC + CYRUS_SASLAUTHD_SOCKET=${EPREFIX}/run/saslauthd/mux + AUTH_CYRUS_SASL=yes + AUTH_LIBS += -lsasl2 + EOC + fi + + # Dovecot + if use dovecot-sasl; then + cat >> Makefile <<- EOC + AUTH_DOVECOT=yes + EOC + fi + + # Pluggable Authentication Modules + if use pam; then + cat >> Makefile <<- EOC + SUPPORT_PAM=yes + AUTH_LIBS += -lpam + EOC + fi + + # Radius + if use radius; then + cat >> Makefile <<- EOC + RADIUS_CONFIG_FILE=${EPREFIX}/etc/radiusclient/radiusclient.conf + RADIUS_LIB_TYPE=RADIUSCLIENTNEW + AUTH_LIBS += -lfreeradius-client + EOC + fi +} + +src_compile() { + emake CC="$(tc-getCC)" HOSTCC="$(tc-getBUILD_CC)" \ + AR="$(tc-getAR) cq" RANLIB="$(tc-getRANLIB)" FULLECHO='' +} + +src_install() { + cd "${S}"/build-exim-gentoo || die + dosbin exim + if use X; then + dosbin eximon.bin + dosbin eximon + fi + fperms 4755 /usr/sbin/exim + + dosym exim /usr/sbin/sendmail + dosym exim /usr/sbin/rsmtp + dosym exim /usr/sbin/rmail + dosym ../sbin/exim /usr/bin/mailq + dosym ../sbin/exim /usr/bin/newaliases + dosym ../sbin/sendmail /usr/lib/sendmail + + for i in exicyclog exim_dbmbuild exim_dumpdb exim_fixdb exim_lock \ + exim_tidydb exinext exiwhat exigrep eximstats exiqsumm exiqgrep \ + convert4r3 convert4r4 exipick + do + dosbin $i + done + + dodoc -r "${S}"/doc/. + doman "${S}"/doc/exim.8 + use dsn && dodoc "${S}"/README.DSN + use doc && dodoc "${WORKDIR}"/${PN}-pdf-${PV//rc/RC}/doc/*.pdf + + # conf files + insinto /etc/exim + newins "${S}"/src/configure.default exim.conf.dist + if use exiscan-acl; then + newins "${S}"/src/configure.default exim.conf.exiscan-acl + fi + doins "${WORKDIR}"/system_filter.exim + doins "${FILESDIR}"/auth_conf.sub + + if use pam; then + pamd_mimic system-auth exim auth account + fi + + # headers, #436406 + if use dlfunc ; then + # fixup includes so they actually can be found when including + sed -i \ + -e '/#include "\(config\|store\|mytypes\).h"/s:"\(.\+\)"::' \ + local_scan.h || die + insinto /usr/include/exim + doins {config,local_scan}.h ../src/{mytypes,store}.h + fi + + insinto /etc/logrotate.d + newins "${FILESDIR}/exim.logrotate" exim + + newinitd "${FILESDIR}"/exim.rc10 exim + newconfd "${FILESDIR}"/exim.confd exim + + systemd_dounit \ + "${FILESDIR}"/{exim.service,exim.socket,exim-submission.socket} + systemd_newunit \ + "${FILESDIR}"/exim_at.service 'exim@.service' + systemd_newunit \ + "${FILESDIR}"/exim-submission_at.service 'exim-submission@.service' + + diropts -m 0750 -o ${MAILUSER} -g ${MAILGROUP} + keepdir /var/log/${PN} +} + +pkg_postinst() { + if [[ ! -f ${EROOT}/etc/exim/exim.conf ]] ; then + einfo "${EROOT}/etc/exim/system_filter.exim is a sample system_filter." + einfo "${EROOT}/etc/exim/auth_conf.sub contains the configuration sub" + einfo "for using smtp auth." + einfo "Please create ${EROOT}/etc/exim/exim.conf from" + einfo " ${EROOT}/etc/exim/exim.conf.dist." + fi + if use dmarc ; then + einfo "DMARC support requires ${EROOT}/etc/exim/opendmarc.tlds" + einfo "you can populate this file with the contents downloaded from" + einfo " https://publicsuffix.org/list/public_suffix_list.dat" + fi + if use dcc ; then + einfo "DCC support is experimental, you can find some limited" + einfo "documentation at the bottom of this prerelease message:" + einfo " http://article.gmane.org/gmane.mail.exim.devel/3579" + fi + if use srs-alt; then + einfo "SRS support using libsrs_alt is experimental in this" + einfo "release of Exim" + elog "You are using libsrs_alt to implement SRS support." + elog "The native SRS implementation (USE=srs-native) is the" + elog "default implementation, which means libsrs_alt may go" + elog "away in a future release." + fi + use dsn && einfo "extra information in fail DSN message is experimental" + einfo + elog "Note that this release contains a tainted variable check that" + elog "is likely to break your configuration used with Exim 4.93 and before." + elog "Please check your transports for occurences of \$local_part, and" + elog "use a replacement like \$local_part_data where possible." +} diff --git a/mail-mta/exim/exim-4.95.ebuild b/mail-mta/exim/exim-4.95.ebuild deleted file mode 100644 index 240cb0969e01..000000000000 --- a/mail-mta/exim/exim-4.95.ebuild +++ /dev/null @@ -1,662 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -inherit db-use toolchain-funcs multilib pam systemd - -IUSE="arc berkdb +dane dcc +dkim dlfunc dmarc +dnsdb doc dovecot-sasl -dsn exiscan-acl gdbm gnutls idn ipv6 ldap lmtp maildir mbx -mysql nis pam perl pkcs11 postgres +prdr proxy radius redis sasl selinux -socks5 spf sqlite srs srs-alt +srs-native +ssl syslog tdb tcpd +tpda X" -REQUIRED_USE=" - arc? ( dkim spf ) - dane? ( ssl !gnutls ) - dmarc? ( dkim spf ) - dkim? ( ssl !gnutls ) - gnutls? ( ssl ) - pkcs11? ( ssl ) - spf? ( exiscan-acl ) - srs? ( - exiscan-acl - ^^ ( srs-alt srs-native ) - ) - || ( berkdb gdbm tdb ) -" -# NOTE on USE="gnutls dane", gnutls[dane] is masked in base, unmasked -# for x86 and amd64 only, due to this, repoman won't allow depending on -# gnutls[dane] for all else. Because we cannot express USE=dane when -# USE=gnutls is in effect only in package.use.mask, the only option we -# have left is to a) ignore the dependency (but that results in bug -# #661164) or b) mask the usage of USE=dane with USE=gnutls. Both are -# incorrect, but b) is the only "correct" view from repoman. -# We cannot express a required use for berkdb/gdbm/tdb correctly because -# berkdb and gdbm are both enabled in base profile - -SDIR=$([[ ${PV} == *_rc* ]] && echo /test - [[ ${PV} == *.*.*.* ]] && echo /fixes) -COMM_URI="https://downloads.exim.org/exim4${SDIR}" - -DESCRIPTION="A highly configurable, drop-in replacement for sendmail" -SRC_URI="${COMM_URI}/${P//_rc/-RC}.tar.xz - mirror://gentoo/system_filter.exim.gz - doc? ( ${COMM_URI}/${PN}-pdf-${PV//_rc/-RC}.tar.xz )" -HOMEPAGE="https://www.exim.org/" - -SLOT="0" -LICENSE="GPL-2" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-solaris" - -COMMON_DEPEND=">=sys-apps/sed-4.0.5 - dev-libs/libpcre:= - tdb? ( sys-libs/tdb:= ) - !tdb? ( berkdb? ( >=sys-libs/db-3.2:= =net-nds/openldap-2.0.7 ) - elibc_glibc? ( - net-libs/libnsl - nis? ( - net-libs/libtirpc - >=net-libs/libnsl-1:= - ) - ) - mysql? ( dev-db/mysql-connector-c:= ) - postgres? ( dev-db/postgresql:= ) - sasl? ( >=dev-libs/cyrus-sasl-2.1.26-r2 ) - redis? ( dev-libs/hiredis ) - spf? ( >=mail-filter/libspf2-1.2.5-r1 ) - dmarc? ( mail-filter/opendmarc:= ) - srs? ( srs-alt? ( mail-filter/libsrs_alt ) ) - X? ( - x11-libs/libX11 - x11-libs/libXmu - x11-libs/libXt - x11-libs/libXaw - ) - sqlite? ( dev-db/sqlite ) - radius? ( net-dialup/freeradius-client ) - virtual/libcrypt:= - virtual/libiconv - " - # added X check for #57206 -BDEPEND="virtual/pkgconfig" -DEPEND="${COMMON_DEPEND}" -RDEPEND="${COMMON_DEPEND} - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/mini-qmail - !=mail-mta/msmtp-1.4.19-r1[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/postfix - !mail-mta/qmail-ldap - !mail-mta/sendmail - !mail-mta/opensmtpd - !=mail-mta/ssmtp-2.64-r2[mta] - !net-mail/mailwrapper - >=net-mail/mailbase-0.00-r5 - virtual/logger - dcc? ( mail-filter/dcc ) - selinux? ( sec-policy/selinux-exim ) - " - -S=${WORKDIR}/${P//_rc/-RC} - -src_prepare() { - # Legacy patches which need a respin for -p1 - eapply -p0 "${FILESDIR}"/exim-4.14-tail.patch - eapply -p0 "${FILESDIR}"/exim-4.74-radius-db-ENV-clash.patch # 287426 - eapply "${FILESDIR}"/exim-4.93-as-needed-ldflags.patch # 352265, 391279 - eapply -p0 "${FILESDIR}"/exim-4.76-crosscompile.patch # 266591 - eapply "${FILESDIR}"/exim-4.69-r1.27021.patch - eapply "${FILESDIR}"/exim-4.95-localscan_dlopen.patch - - # for this reason we have a := dep on opendmarc, they changed their - # API in a minor release - if use dmarc && has_version ">=mail-filter/opendmarc-1.4" ; then - eapply "${FILESDIR}"/exim-4.94-opendmarc-1.4.patch - fi - - if use maildir ; then - eapply "${FILESDIR}"/exim-4.94-maildir.patch - else - eapply -p0 "${FILESDIR}"/exim-4.80-spool-mail-group.patch # 438606 - fi - - eapply_user - - # user Exim believes it should be - MAILUSER=mail - MAILGROUP=mail - if use prefix && [[ ${EUID} != 0 ]] ; then - MAILUSER=$(id -un) - MAILGROUP=$(id -gn) - fi -} - -src_configure() { - # general config and paths - - local aliases="${EPREFIX}/etc/mail/aliases" - sed -i \ - -e "/SYSTEM_ALIASES_FILE/s'SYSTEM_ALIASES_FILE'${aliases}'" \ - src/configure.default || die - - sed -i -e 's/^buildname=.*/buildname=exim-gentoo/' Makefile || die - - if use elibc_musl; then - sed -i -e 's/^LIBS = -lnsl/LIBS =/g' OS/Makefile-Linux || die - fi - - local conffile="${EPREFIX}/etc/exim/exim.conf" - sed -e "48i\CFLAGS=${CFLAGS}" \ - -e "s:BIN_DIRECTORY=/usr/exim/bin:BIN_DIRECTORY=${EPREFIX}/usr/sbin:" \ - -e "s;EXIM_USER=;EXIM_USER=ref:${MAILUSER};" \ - -e "s:CONFIGURE_FILE=.*$:CONFIGURE_FILE=${conffile}:" \ - -e "s:ZCAT_COMMAND=.*$:ZCAT_COMMAND=${EPREFIX}/bin/zcat:" \ - -e "s:COMPRESS_COMMAND=.*$:COMPRESS_COMMAND=${EPREFIX}/bin/gzip:" \ - src/EDITME > Local/Makefile || die - - # work on Local/Makefile from now on - cd Local - - cat >> Makefile <<- EOC - INFO_DIRECTORY=${EPREFIX}/usr/share/info - PID_FILE_PATH=${EPREFIX}/run/exim.pid - SPOOL_DIRECTORY=${EPREFIX}/var/spool/exim - HAVE_ICONV=yes - EOC - - # configure db implementation, Exim always needs one for its hints - # database, we prefer tdb and gdbm, since bdb is kind of getting - # less and less support - if use tdb ; then - cat >> Makefile <<- EOC - USE_TDB=yes - DBMLIB = -ltdb - EOC - sed -i -e 's:^USE_DB=yes:# USE_DB=yes:' Makefile || die - sed -i -e 's:^USE_GDBM=yes:# USE_GDBM=yes:' Makefile || die - elif use berkdb ; then - # use the "native" interfaces to the DBM and CDB libraries, support - # passwd and directory lookups by default - local DB_VERS="5.3 5.1 4.8 4.7 4.6 4.5 4.4 4.3 4.2 3.2" - cat >> Makefile <<- EOC - USE_DB=yes - # keep include in CFLAGS because exim.h -> dbstuff.h -> db.h - CFLAGS += -I$(db_includedir ${DB_VERS}) - DBMLIB = -l$(db_libname ${DB_VERS}) - EOC - sed -i -e 's:^USE_GDBM=yes:# USE_GDBM=yes:' Makefile || die - sed -i -e 's:^USE_TDB=yes:# USE_TDB=yes:' Makefile || die - else # must be gdbm via required_use - cat >> Makefile <<- EOC - USE_GDBM=yes - DBMLIB = -lgdbm - EOC - sed -i -e 's:^USE_DB=yes:# USE_DB=yes:' Makefile || die - sed -i -e 's:^USE_TDB=yes:# USE_TDB=yes:' Makefile || die - fi - - # if we use libiconv, now is the time to tell so - if use !elibc_glibc && use !elibc_musl ; then - cat >> Makefile <<- EOC - EXTRALIBS_EXIM=-liconv - EOC - fi - - # support for IPv6 - if use ipv6; then - cat >> Makefile <<- EOC - HAVE_IPV6=YES - EOC - fi - - # support i18n/IDNA - if use idn; then - cat >> Makefile <<- EOC - SUPPORT_I18N=yes - SUPPORT_I18N_2008=yes - EXTRALIBS_EXIM += -lidn -lidn2 - EOC - fi - - # - # mail storage formats - # - - # mailstore is Exim's traditional storage format - cat >> Makefile <<- EOC - SUPPORT_MAILSTORE=yes - EOC - - # mbox - if use mbx; then - cat >> Makefile <<- EOC - SUPPORT_MBX=yes - EOC - fi - - # maildir - if use maildir; then - cat >> Makefile <<- EOC - SUPPORT_MAILDIR=yes - EOC - fi - - # - # lookup methods - # - - # support passwd and directory lookups by default - cat >> Makefile <<- EOC - LOOKUP_CDB=yes - LOOKUP_PASSWD=yes - LOOKUP_DSEARCH=yes - EOC - - if ! use dnsdb; then - # DNSDB lookup is enabled by default - sed -i -e 's:^LOOKUP_DNSDB=yes:# LOOKUP_DNSDB=yes:' Makefile || die - fi - - if use ldap; then - cat >> Makefile <<- EOC - LOOKUP_LDAP=yes - LDAP_LIB_TYPE=OPENLDAP2 - LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/ldap - LOOKUP_LIBS += -lldap -llber - EOC - fi - - if use mysql; then - cat >> Makefile <<- EOC - LOOKUP_MYSQL=yes - LOOKUP_INCLUDE += $(mysql_config --include) - LOOKUP_LIBS += $(mysql_config --libs) - EOC - fi - - if use nis; then - cat >> Makefile <<- EOC - LOOKUP_NIS=yes - LOOKUP_NISPLUS=yes - EOC - if use elibc_glibc ; then - cat >> Makefile <<- EOC - LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/tirpc - LOOKUP_LIBS += -lnsl - EOC - fi - fi - - if use postgres; then - cat >> Makefile <<- EOC - LOOKUP_PGSQL=yes - LOOKUP_INCLUDE += -I$(pg_config --includedir) - LOOKUP_LIBS += -L$(pg_config --libdir) -lpq - EOC - fi - - if use sqlite; then - cat >> Makefile <<- EOC - LOOKUP_SQLITE=yes - LOOKUP_SQLITE_PC=sqlite3 - EOC - fi - - if use redis; then - cat >> Makefile <<- EOC - LOOKUP_REDIS=yes - LOOKUP_LIBS += -lhiredis - EOC - fi - - # Exim monitor, enabled by default, controlled via X USE-flag, - # disable if not requested, bug #46778 - if use X; then - cp ../exim_monitor/EDITME eximon.conf || die - cat >> Makefile <<- EOC - EXIM_MONITOR=eximon.bin - EOC - fi - - # - # features - # - - # content scanning support - if use exiscan-acl; then - cat >> Makefile <<- EOC - WITH_CONTENT_SCAN=yes - EOC - fi - - # DomainKeys Identified Mail, RFC4871 - if ! use dkim; then - # DKIM is enabled by default - cat >> Makefile <<- EOC - DISABLE_DKIM=yes - EOC - fi - - # Per-Recipient-Data-Response - if ! use prdr; then - # PRDR is enabled by default - cat >> Makefile <<- EOC - DISABLE_PRDR=yes - EOC - fi - - # Transport post-delivery actions - if use !tpda && use !dane; then - # EVENT is enabled by default - cat >> Makefile <<- EOC - DISABLE_EVENT=yes - EOC - fi - - # log to syslog - if use syslog; then - local eximlog="${EPREFIX}/var/log/exim/exim_%s.log" - sed -i \ - -e "s:LOG_FILE_PATH=${eximlog}:LOG_FILE_PATH=syslog:" \ - Makefile || die - cat >> Makefile <<- EOC - LOG_FILE_PATH=syslog - EOC - else - cat >> Makefile <<- EOC - LOG_FILE_PATH=${EPREFIX}/var/log/exim/exim_%s.log - EOC - fi - - # starttls support (ssl) - if use ssl; then - if use gnutls; then - echo "USE_GNUTLS=yes" >> Makefile - echo "USE_GNUTLS_PC=gnutls $(use dane && echo gnutls-dane)" \ - >> Makefile - use pkcs11 || echo "AVOID_GNUTLS_PKCS11=yes" >> Makefile - else - echo "USE_OPENSSL=yes" >> Makefile - echo "USE_OPENSSL_PC=openssl" >> Makefile - fi - else - echo "DISABLE_TLS=yes" >> Makefile - fi - - # TCP wrappers - if use tcpd; then - cat >> Makefile <<- EOC - USE_TCP_WRAPPERS=yes - EXTRALIBS_EXIM += -lwrap - EOC - fi - - # Light Mail Transport Protocol - if use lmtp; then - cat >> Makefile <<- EOC - TRANSPORT_LMTP=yes - EOC - fi - - # embedded Perl - if use perl; then - cat >> Makefile <<- EOC - EXIM_PERL=perl.o - EOC - fi - - # dlfunc - if use dlfunc; then - cat >> Makefile <<- EOC - EXPAND_DLFUNC=yes - HAVE_LOCAL_SCAN=yes - DLOPEN_LOCAL_SCAN=yes - EOC - fi - - # Proxy Protocol - if use proxy; then - cat >> Makefile <<- EOC - SUPPORT_PROXY=yes - EOC - fi - - # SOCKS5 (outbound) proxy support - if use socks5; then - cat >> Makefile <<- EOC - SUPPORT_SOCKS=yes - EOC - fi - - # DANE - if use !dane; then - # DANE is enabled by default - sed -i -e 's:^SUPPORT_DANE=yes:# SUPPORT_DANE=yes:' Makefile || die - fi - - # DMARC - if use dmarc; then - cat >> Makefile <<- EOC - SUPPORT_DMARC=yes - EXTRALIBS_EXIM += -lopendmarc - EOC - fi - - # Sender Policy Framework - if use spf; then - cat >> Makefile <<- EOC - SUPPORT_SPF=yes - EXTRALIBS_EXIM += -lspf2 - EOC - fi - - # - # experimental features - # - - # Authenticated Receive Chain - if use arc; then - echo "EXPERIMENTAL_ARC=yes">> Makefile - fi - - # Distributed Checksum Clearinghouse - if use dcc; then - echo "EXPERIMENTAL_DCC=yes">> Makefile - fi - - # Sender Rewriting Scheme - if use srs; then - # NOTE: we currently USE-default to srs-alt, because this is - # what USE=srs used to be. Eventually we want to rid ourselves - # of this external implementation. - if use srs-alt; then - # historical default, until 4.95 - cat >> Makefile <<- EOC - EXPERIMENTAL_SRS_ALT=yes - EXTRALIBS_EXIM += -lsrs_alt - EOC - fi - if use srs-native; then - # this one is the default/supported variant since 4.95 - cat >> Makefile <<- EOC - SUPPORT_SRS=yes - EOC - fi - fi - - # Delivery Sender Notifications extra information in fail message - if use dsn; then - cat >> Makefile <<- EOC - EXPERIMENTAL_DSN_INFO=yes - EOC - fi - - # - # authentication (SMTP AUTH) - # - - # standard bits - cat >> Makefile <<- EOC - AUTH_SPA=yes - AUTH_CRAM_MD5=yes - AUTH_PLAINTEXT=yes - EOC - - # Cyrus SASL - if use sasl; then - cat >> Makefile <<- EOC - CYRUS_SASLAUTHD_SOCKET=${EPREFIX}/run/saslauthd/mux - AUTH_CYRUS_SASL=yes - AUTH_LIBS += -lsasl2 - EOC - fi - - # Dovecot - if use dovecot-sasl; then - cat >> Makefile <<- EOC - AUTH_DOVECOT=yes - EOC - fi - - # Pluggable Authentication Modules - if use pam; then - cat >> Makefile <<- EOC - SUPPORT_PAM=yes - AUTH_LIBS += -lpam - EOC - fi - - # Radius - if use radius; then - cat >> Makefile <<- EOC - RADIUS_CONFIG_FILE=${EPREFIX}/etc/radiusclient/radiusclient.conf - RADIUS_LIB_TYPE=RADIUSCLIENTNEW - AUTH_LIBS += -lfreeradius-client - EOC - fi -} - -src_compile() { - emake CC="$(tc-getCC)" HOSTCC="$(tc-getBUILD_CC)" \ - AR="$(tc-getAR) cq" RANLIB="$(tc-getRANLIB)" FULLECHO='' -} - -src_install() { - cd "${S}"/build-exim-gentoo || die - dosbin exim - if use X; then - dosbin eximon.bin - dosbin eximon - fi - fperms 4755 /usr/sbin/exim - - dosym exim /usr/sbin/sendmail - dosym exim /usr/sbin/rsmtp - dosym exim /usr/sbin/rmail - dosym ../sbin/exim /usr/bin/mailq - dosym ../sbin/exim /usr/bin/newaliases - dosym ../sbin/sendmail /usr/lib/sendmail - - for i in exicyclog exim_dbmbuild exim_dumpdb exim_fixdb exim_lock \ - exim_tidydb exinext exiwhat exigrep eximstats exiqsumm exiqgrep \ - convert4r3 convert4r4 exipick - do - dosbin $i - done - - dodoc -r "${S}"/doc/. - doman "${S}"/doc/exim.8 - use dsn && dodoc "${S}"/README.DSN - use doc && dodoc "${WORKDIR}"/${PN}-pdf-${PV//rc/RC}/doc/*.pdf - - # conf files - insinto /etc/exim - newins "${S}"/src/configure.default exim.conf.dist - if use exiscan-acl; then - newins "${S}"/src/configure.default exim.conf.exiscan-acl - fi - doins "${WORKDIR}"/system_filter.exim - doins "${FILESDIR}"/auth_conf.sub - - if use pam; then - pamd_mimic system-auth exim auth account - fi - - # headers, #436406 - if use dlfunc ; then - # fixup includes so they actually can be found when including - sed -i \ - -e '/#include "\(config\|store\|mytypes\).h"/s:"\(.\+\)"::' \ - local_scan.h || die - insinto /usr/include/exim - doins {config,local_scan}.h ../src/{mytypes,store}.h - fi - - insinto /etc/logrotate.d - newins "${FILESDIR}/exim.logrotate" exim - - newinitd "${FILESDIR}"/exim.rc10 exim - newconfd "${FILESDIR}"/exim.confd exim - - systemd_dounit \ - "${FILESDIR}"/{exim.service,exim.socket,exim-submission.socket} - systemd_newunit \ - "${FILESDIR}"/exim_at.service 'exim@.service' - systemd_newunit \ - "${FILESDIR}"/exim-submission_at.service 'exim-submission@.service' - - diropts -m 0750 -o ${MAILUSER} -g ${MAILGROUP} - keepdir /var/log/${PN} -} - -pkg_postinst() { - if [[ ! -f ${EROOT}/etc/exim/exim.conf ]] ; then - einfo "${EROOT}/etc/exim/system_filter.exim is a sample system_filter." - einfo "${EROOT}/etc/exim/auth_conf.sub contains the configuration sub" - einfo "for using smtp auth." - einfo "Please create ${EROOT}/etc/exim/exim.conf from" - einfo " ${EROOT}/etc/exim/exim.conf.dist." - fi - if use dmarc ; then - einfo "DMARC support requires ${EROOT}/etc/exim/opendmarc.tlds" - einfo "you can populate this file with the contents downloaded from" - einfo " https://publicsuffix.org/list/public_suffix_list.dat" - fi - if use dcc ; then - einfo "DCC support is experimental, you can find some limited" - einfo "documentation at the bottom of this prerelease message:" - einfo " http://article.gmane.org/gmane.mail.exim.devel/3579" - fi - if use srs-alt; then - einfo "SRS support using libsrs_alt is experimental in this" - einfo "release of Exim" - elog "You are using libsrs_alt to implement SRS support." - elog "The native SRS implementation (USE=srs-native) is the" - elog "default implementation, which means libsrs_alt may go" - elog "away in a future release." - fi - use dsn && einfo "extra information in fail DSN message is experimental" - einfo - elog "Note that this release contains a tainted variable check that" - elog "is likely to break your configuration used with Exim 4.93 and before." - elog "Please check your transports for occurences of \$local_part, and" - elog "use a replacement like \$local_part_data where possible." -} diff --git a/mail-mta/msmtp/Manifest b/mail-mta/msmtp/Manifest index 29a7d8e400e1..3b2b09c15500 100644 --- a/mail-mta/msmtp/Manifest +++ b/mail-mta/msmtp/Manifest @@ -1,9 +1,9 @@ AUX msmtpd.confd 518 BLAKE2B e537ca90e9c4debd53936b227352b73f5ca1e7114ba8daa3121f1979dfc3495996a820276292ec6da63ce79d8f42bafb45c74daacb6778e5b56656aa9688ecbd SHA512 e6f4f39da73aace9f5a4f8e080ca897f51265b8806836366121d61f5367596955eefca377c5fe9c4094f3a9ecbe04801cf38fcc6017c73a9e4b7a68fc9a81528 AUX msmtpd.init 347 BLAKE2B 9faea920dc23ebcdb62b05595acf4f70dd3d654645ed0f5ba6f76316762986c9951905f675c2e527c5e0b5eee2bcf53a14e018d8d64080b97e82da4e3abaa0b8 SHA512 e3080dc1fb7b72b6332ebcd4f807780dc04d32b8d3e5740b62f618d5d8f39f7c2a119604e26282e1d98c1365fff7920944401c399267461fab7ae2cdfdac44d7 DIST msmtp-1.8.16.tar.xz 375372 BLAKE2B 4567c323bf2f53fa878ed315dc4a2c524918de22305d2034be476373409bc61a9c841f0b9c6075e06e47eceb816ea24e9d6cb71c2bd94d9ba6738ae36ccb09b7 SHA512 5e7e39927007fe8e1763b13a83f44f6456e8e9efade8e1c3148f34d5c2b5aff51b1e4519337628776e6bce91066de9f145c7c2957927cadb0962a25452a47247 -DIST msmtp-1.8.18.tar.xz 380776 BLAKE2B 33d1c4da55537248fcd317d1813eff43951e70dea86cfeabd387cbd1443be062a48fc0362452a7b744a3e6371ccfc88881493d244e48c3793ae13c1d2c8b772f SHA512 904da49a4ab92011f05403f32c8a23065ce2ba1afaaa3eea3a2607c98caf5f7e2f786e49695c37cb51f7c1551236eb555d404b49576b9026cf163d229b7f94d8 DIST msmtp-1.8.19.tar.xz 383100 BLAKE2B 4a24fc63f8d1057bceaede09050bd2fa81ae9cfe20f5663dd1766b261634af580a190fdbbff36a0373e804fe2d6b357268d349bf78a4c8c47ec87b63e03f7798 SHA512 0be193fc0a415824e311f88b57521898caaed49737370b6ae688c7f75e3ff5bc3dc9d87d9d08289b46a1b9650b2a48fb3cd40fb156f894b3fe805136d124f1bd +DIST msmtp-1.8.20.tar.xz 385696 BLAKE2B cf75715538a65ac0f6fb3b8407e5b7cec865d552b6ecc5a450f5e35d4e42581cfb9f15bb7edc67dae1846018a834769d4e3be5da60ae0e52390cb61531a29a87 SHA512 cc5ad4ab21d05f24bac75ab25607d1ede50f5ac24ce40d72cf1b61f9cdfc48e9af477f9975d799a93f1990d0c2e24b651e5a3b3aa6b71279b37a4a43fce11f11 EBUILD msmtp-1.8.16.ebuild 3295 BLAKE2B 9dcf98f1472fcbce1de4ee38115179f85bba01fb1c807a1159d657f2d4e52cb7fb1e6a4df380d446481fea19052f27080da0e9cd70a2e5eb1164d2b932c0fa23 SHA512 58d31fb4cecbdc3c54491cb32d2012d2cba31a418689cb124e5d5bef3f862ee0a101f32ef77e27245e9f4b526dcd079d1c94a9243e9578ddb6cad373ba10a589 -EBUILD msmtp-1.8.18.ebuild 3300 BLAKE2B 0467ac0de1dbf509ecc99fa7b6075f09922d997670c03f76e1dd54ff056ab309a8be78e4a282d6d17b751bc3ada33bad305bf4daa395b833ef57bfd3b00e7a14 SHA512 4ce6bbbe0cefed26aab4e5bbb375d57114a898a962f5d70c3b10df76a4e518896c9817be8d21b7f4f8596b3463718f7d6187ce514440b19cc7b44d33dcc92368 -EBUILD msmtp-1.8.19.ebuild 3300 BLAKE2B 0467ac0de1dbf509ecc99fa7b6075f09922d997670c03f76e1dd54ff056ab309a8be78e4a282d6d17b751bc3ada33bad305bf4daa395b833ef57bfd3b00e7a14 SHA512 4ce6bbbe0cefed26aab4e5bbb375d57114a898a962f5d70c3b10df76a4e518896c9817be8d21b7f4f8596b3463718f7d6187ce514440b19cc7b44d33dcc92368 +EBUILD msmtp-1.8.19.ebuild 3299 BLAKE2B 124794fa326657a26837572cd41abc3e30fdd5da52a2ce0353583274f4752c2412c096f2d6bf8a36f88eac7db4dcfe0e4faefd1af240ba753d83a30e4ed4f96d SHA512 cb332cf18439942410a535d6a8b195a4b1509ecf85e6f2e9ecd764e36480f4907138a6a28e3d252961fbada7376ae4bfe646deb0093443ce9a866e9395dd3d60 +EBUILD msmtp-1.8.20.ebuild 3300 BLAKE2B 0e264e5cba8d1c45b8a648e022b79570f47a36954e3f5d108a3005e4e1a91b4951f3cd6f94505d6f25c8d2b7ad488b4764a4a14f72b756c6cd2aedd33f2d065c SHA512 2b0def7bce8f14d8c707d3324f6530cfade6cfa204eb2e086c75af0b9e222cb1300493709bf6efb0e877f3d5fcbe102f6b2460159be693d7eacd2aa6fee2ae15 MISC metadata.xml 471 BLAKE2B 2f73e5ba3eb891844f14bcd4792a4a1df6f2bc90839819a4489fca29128d4268962e6f4cc781b99942e0f54b85a99554293e50f8be4680c58df38fb90f199916 SHA512 22bf1461c446daf3c854cccce644cf6647881878c346f2bd6390f69eb397dfa608d15cfca75bdc3a58fa4c86b2f69e1224bab181c336e883726d9564a358db7a diff --git a/mail-mta/msmtp/msmtp-1.8.18.ebuild b/mail-mta/msmtp/msmtp-1.8.18.ebuild deleted file mode 100644 index 9e91391eb5d4..000000000000 --- a/mail-mta/msmtp/msmtp-1.8.18.ebuild +++ /dev/null @@ -1,145 +0,0 @@ -# Copyright 2004-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -inherit fcaps - -DESCRIPTION="An SMTP client and SMTP plugin for mail user agents such as Mutt" -HOMEPAGE="https://marlam.de/msmtp/" -SRC_URI="https://marlam.de/msmtp/releases/${P}.tar.xz" - -LICENSE="GPL-3" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos" -IUSE="daemon doc gnome-keyring idn +mta nls sasl ssl vim-syntax" - -# fcaps.eclass unconditionally defines "filecaps" USE flag which we need for -# USE="daemon" in order to set the caps we need. -REQUIRED_USE="daemon? ( filecaps )" - -# Upstream discourages usage of openssl. See also -# https://marlam.de/msmtp/news/openssl-discouraged/ -DEPEND=" - gnome-keyring? ( app-crypt/libsecret ) - idn? ( net-dns/libidn2:= ) - nls? ( virtual/libintl ) - sasl? ( virtual/gsasl ) - ssl? ( net-libs/gnutls[idn?] ) -" - -RDEPEND="${DEPEND} - net-mail/mailbase - daemon? ( - acct-group/msmtpd - acct-user/msmtpd - ) - mta? ( - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/mini-qmail - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/postfix - !mail-mta/qmail-ldap - !mail-mta/sendmail - !mail-mta/opensmtpd - !=mail-mta/ssmtp-2.64-r2[mta] - ) -" - -BDEPEND=" - doc? ( virtual/texi2dvi ) - nls? ( sys-devel/gettext ) - virtual/pkgconfig -" - -DOCS="AUTHORS ChangeLog NEWS README THANKS doc/msmtprc*" - -src_prepare() { - # Use default Gentoo location for mail aliases - sed 's:/etc/aliases:/etc/mail/aliases:' \ - -i scripts/find_alias/find_alias_for_msmtp.sh || die - - default -} - -src_configure() { - local myeconfargs=( - --disable-gai-idn - $(use_enable nls) - $(use_with daemon msmtpd) - $(use_with gnome-keyring libsecret) - $(use_with idn libidn) - $(use_with sasl libgsasl) - $(use_with ssl tls gnutls) - ) - econf "${myeconfargs[@]}" -} - -src_compile() { - default - - if use doc ; then - cd doc || die - emake html pdf - fi -} - -src_install() { - default - - if use daemon ; then - fcaps CAP_NET_BIND_SERVICE usr/bin/msmtpd - newinitd "${FILESDIR}"/msmtpd.init msmtpd - newconfd "${FILESDIR}"/msmtpd.confd msmtpd - fi - - if use doc ; then - dodoc doc/msmtp.{html,pdf} - fi - - if use mta ; then - dosym ../bin/msmtp /usr/sbin/sendmail - dosym ../bin/msmtp /usr/$(get_libdir)/sendmail - fi - - if use vim-syntax ; then - insinto /usr/share/vim/vimfiles/syntax - doins scripts/vim/msmtp.vim - fi - - insinto /etc - newins doc/msmtprc-system.example msmtprc - - src_install_contrib find_alias find_alias_for_msmtp.sh - src_install_contrib msmtpqueue "*.sh" "README ChangeLog" - src_install_contrib msmtpq "msmtpq msmtp-queue" README.msmtpq - src_install_contrib set_sendmail set_sendmail.sh set_sendmail.conf -} - -pkg_postinst() { - if [[ -z ${REPLACING_VERSIONS} ]]; then - einfo "Please edit ${EROOT}/etc/msmtprc before first use." - einfo "In addition, per user configuration files can be placed" - einfo "as '~/.msmtprc'. See the msmtprc-user.example file under" - einfo "/usr/share/doc/${PF}/ for an example." - fi -} - -src_install_contrib() { - subdir="$1" - bins="$2" - docs="$3" - local dir=/usr/share/${PN}/${subdir} - insinto ${dir} - exeinto ${dir} - for i in ${bins} ; do - doexe scripts/${subdir}/${i} - done - for i in ${docs} ; do - newdoc scripts/${subdir}/${i} ${subdir}.${i} - done -} diff --git a/mail-mta/msmtp/msmtp-1.8.19.ebuild b/mail-mta/msmtp/msmtp-1.8.19.ebuild index 9e91391eb5d4..468bdb943971 100644 --- a/mail-mta/msmtp/msmtp-1.8.19.ebuild +++ b/mail-mta/msmtp/msmtp-1.8.19.ebuild @@ -1,4 +1,4 @@ -# Copyright 2004-2021 Gentoo Authors +# Copyright 2004-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -11,7 +11,7 @@ SRC_URI="https://marlam.de/msmtp/releases/${P}.tar.xz" LICENSE="GPL-3" SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos" +KEYWORDS="~alpha amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos" IUSE="daemon doc gnome-keyring idn +mta nls sasl ssl vim-syntax" # fcaps.eclass unconditionally defines "filecaps" USE flag which we need for diff --git a/mail-mta/msmtp/msmtp-1.8.20.ebuild b/mail-mta/msmtp/msmtp-1.8.20.ebuild new file mode 100644 index 000000000000..5999471c9317 --- /dev/null +++ b/mail-mta/msmtp/msmtp-1.8.20.ebuild @@ -0,0 +1,145 @@ +# Copyright 2004-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit fcaps + +DESCRIPTION="An SMTP client and SMTP plugin for mail user agents such as Mutt" +HOMEPAGE="https://marlam.de/msmtp/" +SRC_URI="https://marlam.de/msmtp/releases/${P}.tar.xz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos" +IUSE="daemon doc gnome-keyring idn +mta nls sasl ssl vim-syntax" + +# fcaps.eclass unconditionally defines "filecaps" USE flag which we need for +# USE="daemon" in order to set the caps we need. +REQUIRED_USE="daemon? ( filecaps )" + +# Upstream discourages usage of openssl. See also +# https://marlam.de/msmtp/news/openssl-discouraged/ +DEPEND=" + gnome-keyring? ( app-crypt/libsecret ) + idn? ( net-dns/libidn2:= ) + nls? ( virtual/libintl ) + sasl? ( virtual/gsasl ) + ssl? ( net-libs/gnutls[idn?] ) +" + +RDEPEND="${DEPEND} + net-mail/mailbase + daemon? ( + acct-group/msmtpd + acct-user/msmtpd + ) + mta? ( + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/exim + !mail-mta/mini-qmail + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/postfix + !mail-mta/qmail-ldap + !mail-mta/sendmail + !mail-mta/opensmtpd + !=mail-mta/ssmtp-2.64-r2[mta] + ) +" + +BDEPEND=" + doc? ( virtual/texi2dvi ) + nls? ( sys-devel/gettext ) + virtual/pkgconfig +" + +DOCS="AUTHORS ChangeLog NEWS README THANKS doc/msmtprc*" + +src_prepare() { + # Use default Gentoo location for mail aliases + sed 's:/etc/aliases:/etc/mail/aliases:' \ + -i scripts/find_alias/find_alias_for_msmtp.sh || die + + default +} + +src_configure() { + local myeconfargs=( + --disable-gai-idn + $(use_enable nls) + $(use_with daemon msmtpd) + $(use_with gnome-keyring libsecret) + $(use_with idn libidn) + $(use_with sasl libgsasl) + $(use_with ssl tls gnutls) + ) + econf "${myeconfargs[@]}" +} + +src_compile() { + default + + if use doc ; then + cd doc || die + emake html pdf + fi +} + +src_install() { + default + + if use daemon ; then + fcaps CAP_NET_BIND_SERVICE usr/bin/msmtpd + newinitd "${FILESDIR}"/msmtpd.init msmtpd + newconfd "${FILESDIR}"/msmtpd.confd msmtpd + fi + + if use doc ; then + dodoc doc/msmtp.{html,pdf} + fi + + if use mta ; then + dosym ../bin/msmtp /usr/sbin/sendmail + dosym ../bin/msmtp /usr/$(get_libdir)/sendmail + fi + + if use vim-syntax ; then + insinto /usr/share/vim/vimfiles/syntax + doins scripts/vim/msmtp.vim + fi + + insinto /etc + newins doc/msmtprc-system.example msmtprc + + src_install_contrib find_alias find_alias_for_msmtp.sh + src_install_contrib msmtpqueue "*.sh" "README ChangeLog" + src_install_contrib msmtpq "msmtpq msmtp-queue" README.msmtpq + src_install_contrib set_sendmail set_sendmail.sh set_sendmail.conf +} + +pkg_postinst() { + if [[ -z ${REPLACING_VERSIONS} ]]; then + einfo "Please edit ${EROOT}/etc/msmtprc before first use." + einfo "In addition, per user configuration files can be placed" + einfo "as '~/.msmtprc'. See the msmtprc-user.example file under" + einfo "/usr/share/doc/${PF}/ for an example." + fi +} + +src_install_contrib() { + subdir="$1" + bins="$2" + docs="$3" + local dir=/usr/share/${PN}/${subdir} + insinto ${dir} + exeinto ${dir} + for i in ${bins} ; do + doexe scripts/${subdir}/${i} + done + for i in ${docs} ; do + newdoc scripts/${subdir}/${i} ${subdir}.${i} + done +} diff --git a/mail-mta/nullmailer/Manifest b/mail-mta/nullmailer/Manifest index 7cb9dfd9be0b..122875e1f311 100644 --- a/mail-mta/nullmailer/Manifest +++ b/mail-mta/nullmailer/Manifest @@ -5,5 +5,5 @@ AUX nullmailer-2.2-disable-smtp-auth-tests.patch 2383 BLAKE2B 07f2fc7517df280fac AUX nullmailer-2.2-fix-test-racecondition.patch 890 BLAKE2B 7d12af8a9b6071f11e70c6aedbe0471f042c2c2e611eedf768071715b7f42a94b2b41e814a87dd87777810cbb823d20138d40f6aa3aba93ebaec89ebb6d9e2f3 SHA512 10873e538dbc89e8899047e732515d30108b25fd0ff6bb2fc695f5790a94ac32629f41c470a2fec951357169fead36ee4512f543ad0e02c52f09799334b815c7 AUX remotes.sample-2.0 920 BLAKE2B 26e777624086267e543354f130d3abc9591d832afbd80b8efd1fd2ce2391ed16641877077d90cef7d491a844e94fec3cba0a45dd452aa7f29151dd5873871200 SHA512 21694c7cceb3bdd743e30e2241b5e3293a3ad0fcdc4345d200f2e81c26b72b8a53c6cc3912a4e5f1de6411658a2144803746b44b59d48024cb3de33d72238354 DIST nullmailer-2.2.tar.gz 257740 BLAKE2B 18821caa1a377a899e3fedc84530d7c672f345cafb627da05e6c7bcd7d2708d54fc4ff4b761a6a23b2ddbabe73514473a5ec2abf3182dce2f5d3d4fbe3618fed SHA512 21b29d59f3c386c13ce4541ae11dc5cd69f842085479d7fc9a69a540abc608ce5c1825f06bd3566536b392931f7eeb1b2d35addd816849e6f431877bb18c8268 -EBUILD nullmailer-2.2-r2.ebuild 4283 BLAKE2B 3a26d50b8d8e28bc380c0da3da89d3e41ec37e575787bad28d249027a80f7d535744df24e629c99b687a9a73c78a79d2e34883fa075ab4eadc76b48acd32ca7c SHA512 d192241c789aec59652fa8c45fd0f03f556ca42a2b6a2e5d04603d2cb28e0e15cf2aa051af992d33ef43c0f93660c0dd28ed44923ccd25770cfcfff706e5b428 +EBUILD nullmailer-2.2-r2.ebuild 4348 BLAKE2B dbd2c301ffe99c0ace7a81a483662cd0c19e8dc50c3b9d79d2edf77263a25da1189106b8db367d6dccffb6e1715fd046a7cf365bd150f4467d95aff19b99bd5a SHA512 0f3d8f7d861cb65e51991031026c8c1e38541bf3700dc40d05b68df7cba1f3760582a95158697b885ef9770dabf52240d228b39ecbd4ed0c7b4f4b71d39ba2b2 MISC metadata.xml 343 BLAKE2B 875614e5e584c0c08adda33673e9606fa5bd02261cce775e9e01ef537926fd9a078af23418f917add1b7ecaf2ecfd09f28b0f37e2421228bd80a1005ea677afd SHA512 bbd2a53c352c2197b75ee2286af771c2ff56ebd9a7ae9927e0edca9e1a3ba6e530ca3d3cf888746b500d4adfb36524aa045a9073746392b7ec075ad252836e20 diff --git a/mail-mta/nullmailer/nullmailer-2.2-r2.ebuild b/mail-mta/nullmailer/nullmailer-2.2-r2.ebuild index d92c894e445a..f06e6f5c175b 100644 --- a/mail-mta/nullmailer/nullmailer-2.2-r2.ebuild +++ b/mail-mta/nullmailer/nullmailer-2.2-r2.ebuild @@ -3,7 +3,7 @@ EAPI=7 -inherit autotools flag-o-matic systemd +inherit autotools flag-o-matic systemd toolchain-funcs DESCRIPTION="Simple relay-only local mail transport agent" HOMEPAGE="http://untroubled.org/nullmailer/ https://github.com/bruceg/nullmailer" @@ -73,6 +73,11 @@ src_configure() { $(use_enable ssl tls) } +src_compile() { + tc-export AR RANLIB + default +} + src_install() { default diff --git a/mail-mta/postfix/Manifest b/mail-mta/postfix/Manifest index 41ce0db4529e..ff4a4c561ce1 100644 --- a/mail-mta/postfix/Manifest +++ b/mail-mta/postfix/Manifest @@ -1,16 +1,11 @@ -AUX postfix-glibc-2.34.patch 274 BLAKE2B 65cfdef91aa7fc20a2c1997a73003cd5a9d108e697fb29967bdfa3de1223552467e953237d63e930f59a36357bc8a1f44b486599b65e14937c3e22e48e86a05a SHA512 8710c5e8363fac633378b004f65fedfc4852bfdd470a939b31cc35b95f83008bec037e6ebbe5adbabc47d4c373a2360d843b84c6991e546583cb67d244569a07 AUX postfix.rc6.2.7 2107 BLAKE2B 4ea7006a381b76d5926a7d1794ab45e30d4829a17acfa0fd8c0580450cdd8d902df285f8bdd7dee79df6776e4a28ce0ecec00f1070c00f19f077358d80d61cfa SHA512 4c0f5f333ec02065cad1578b3a95e50d072317ee5e6cc65c4e9176d0b8687ce8e7e03d5e653f7a93a838a5bdde66230874a3c7f71a315fe2839706c91a8d954e AUX postfix.service 662 BLAKE2B dcf9ceb71ad483b580d126fcb5ac68889cdeb898df3333d38f195227190b73cf0fb41cd68a86e97cfe844cc7f9f095cba0a17afe9ce7c8697e0aa30f5faecde6 SHA512 04b475040b153f488a9358567ff9ee2eb8f263c619dadc23c837d17c19106041296e3652bcaded2be0c7c8b9eee7fd5f2ad55bed3e7f9b3a4bf9655f4762d563 AUX smtp.pass 29 BLAKE2B 589915bd2856fa64e22caa12fca54ef342eb07606de38d3879c13ac395413c84de6c3b733c83cc0625a4433167efcc7d504b2f87fa26c05b2facde9c3d103021 SHA512 a8a940099a77ea0547004daf5392a6efc0cd643f10072803d65e37763012464ad25b1b925ae9e32bffb3c3e8a5d4b2d3bb5619a174d58fdc4ea5d4090db0d365 AUX smtp.sasl 42 BLAKE2B 67e9108101779b6027fa1e5cc7c9256a606d440e15bb037a0da186e6b4983ab26e88ede2f0604737c78144c03e182f66005062f1d49e10443d1ddb9757461d1f SHA512 a48e2bd173c4443dd2c389f6973a541dbcba4223b52b42b409a68d934a7fc82a98d4027267befcd5db6ec628cce6a9dffdf044e6fbd774b6e748f07f4106db47 -DIST postfix-3.6.3.tar.gz 4750833 BLAKE2B 2a68e0f18227e09c0ce855901503fa83a58805f036f57eff9003102f5933a241e624e5f3f7a7af4f3d89784d95bc0be6ac1d17f30712f61491808ed6a90ce2d3 SHA512 7179aaeeaf27838b867d9a07f9a889d7cd6b7f5053e123caef4dff2820d4df6d5be167effedde6c857b4468966b8449c631e56405e1ac2d589716fb4e3f15e3b -DIST postfix-3.6.4.tar.gz 4751433 BLAKE2B 2b410413e18cc2792bab7b75bcb8bcf36191c6abca8f2fea0ce54053f7a0be681352542ea8a3e26752a60ddc026bbc6ce84c926cc721811b43f3debc07b557cf SHA512 f5813801377a5887d27720cc7f85a6a68f8ca82fc7a9e852b27c8967996b3d64f651cc16e2b021d55316a074b4778e19155bb60c8f0885d4aaf72766cab7c4cd DIST postfix-3.6.5.tar.gz 4751485 BLAKE2B 7d53ccf76d978db269fe0ab8641abcb3ba91a72c97fa739a2c8ea80c45bb3ecdaca51d08f7db03582887a0cdcdf96be423e3e35b4f2ab2fbb0fbe4e98dd60758 SHA512 510c7b387b38c8683bda33371468c1c1209285baca7d8f237fdb668b313fa4b4d6727f7e4eb79fc81c4155f0839b4e95995dff186e62621b26e5b8b31cff15d5 DIST postfix-3.7.0.tar.gz 4823087 BLAKE2B 7388ad49862c97e20179a2d3ed26069f21e8a578790fcb8adc9f5b648202269bd4c07905931237dab905d991002bcfd9f03d11e6a85b46fcf0e3b72412d852eb SHA512 f2fb5c0399100c19e428b68728a8ce62b1fb74d365038373f22ed698c1d0fece506b3f1335c322b949875a4a9fa96fa0a7680b12641d596d09615e8fef061da4 DIST postfix-3.8-20220220.tar.gz 4821731 BLAKE2B 1d09dd29de8b888c1466019096cf0f4120c3fae30b2812fc621842387b77222b41ae32ce66b3430d7540b3de1e07a72d531544d016fc668e099d3d6598ee06e2 SHA512 21f2cc192213b22ba3a36a225ad7cfc0ec36f25e16a155c814eb2682db6a9eed81bad2223c2af5c1764a2b943a70bab85140c7e3e722aa0f4351cef26fd8fe59 -EBUILD postfix-3.6.3.ebuild 7966 BLAKE2B f9e3ea4c3979b034a6fb6412b30576d8dc843d03fbaa7dfe940fdce74e52cb4806bc52166e161ef357b8f61c0f03d5042fd10b8ad7b857733d163f15e9e69ef4 SHA512 7126c58d6e642752d3c8c2c70f189f7967d0859f39b0290077b0f0c4ffee9178bac3e3535bddbb2104ae7da1504c0dc1cdd54105717406e9e03bc4869c54cae8 -EBUILD postfix-3.6.4.ebuild 7972 BLAKE2B 468fe0e9427efec7c1143721bf93ae851143f87ff8067604c0d19a9c504a9b493a35a605a749e55e16a78e4241d4a0225ff19b94f43a2c744f9a7ea458f90bc6 SHA512 b24cd791c9221099940ebab8709978326afae8a29597f764db2714c8a97ad7b2d48e37314250635549c53838c32a2be874ebba5750256197ac3511e622846ce0 -EBUILD postfix-3.6.5-r1.ebuild 7915 BLAKE2B 049480c9bd06aa6687debe594e9a07280392d66469bf503bae286b31a9c2d3e4b67f6e02e7c12936c79a1cf5e92a0114db24c6f07cf16f9808ea5d4daff72e19 SHA512 4074989175d25d11fcdaa8d45df21f96e8f2c2203c106b4bf7a87b65e5571d3e06fb0ca67c8d7511694a713c98f7baad167968136bf948bb8ede2b3d6aa3ef25 -EBUILD postfix-3.7.0.ebuild 8063 BLAKE2B 75e5ebbc6ddcff256dc8dcf49c589c8eb17d632c2c71d5148b942afeebb6a86a58bad498d8147a131e2029a759b0929b7f8f66e51d2fde6fa9967b5ace6056da SHA512 71e021597fdcb2a4a549ebe6b2acc1cb578da7c5c1e04235204928fa514a3a970416d6ab9701c9ef02e61da602bff91d10956d748f33582a8c7bace6540c776c -EBUILD postfix-3.8_pre20220220.ebuild 8066 BLAKE2B 612224bead57f3343ce9f95136a955adf58fdc014a8a3a30a8d89471cde7511f0fb9349ec13eb967c26d5b49c80183dd3fd1bdd18ceb77f3e85c6bad9b24304f SHA512 0b48087bdb54b3c03c5d6a4508fe8743287864f807c6aa545721b8a58bdf467d34f909f56c70c65d96992bbe40d767de45b3e3d552182f7ac6ef3196fdd0835e +EBUILD postfix-3.6.5-r2.ebuild 7919 BLAKE2B a88bc775ef810df0889974c9048cac9d44246bee07619eb4149324565c32214441792a3a840ae812210404b6e821851a3e3855469d14c9d53c3d7cf712464cc6 SHA512 3568560769a1781721182fb9ae5fd4518e3a70e23db1fd539ee032778cd6bf6c3361c10b3d65f17b0c88d6d05ef8e577a7041722d57c1f39ba78cda398d71720 +EBUILD postfix-3.7.0-r1.ebuild 8067 BLAKE2B ce219a3680e65c6c8d63950765357b893576c8572149d01e04656a91070cc3dfd5a5a1da1c60d05c89ed40d805281c6c0a5c8aa8945cebf2213e45b55e19ecda SHA512 b1d6c5951db3cad2c2ca9487d24bd26bf4faf92c4b9ca6908f35ead42db50d82f6e3de432674009ce99bb9daf359ff588131784a95e3dc56fa055533ea39d4cc +EBUILD postfix-3.8_pre20220220-r1.ebuild 8070 BLAKE2B 4e7e2a9d2c87156f654ec8214d67c2ac8c6203115122b517af8d6ce5751f1f1a450dc80d7c4532b9093efdde6acb0493524a098277cc3b1f0b3b783570e05949 SHA512 42ab250f9c56d6aeb4e9788b9661d2c300421a8524967c1f7fe7a1159c06edfb6f1864c2c03eb68dba58eca54b4683e8e3432edf8b22b56109d96886b4872637 MISC metadata.xml 867 BLAKE2B 1839d35c91007bb07e1a722b6b4751e9f7754e00109859efe5850df16486bafbaeb019326d006438471678553aca9474462fa32eaba445362113ced6927bf4ab SHA512 ff898bdce2b60bc52a0d326f8f8221bd474cc4fa31def2ccc5526ba59ad396b0b26f22cc98ca4e1181e3c38e5476615e53bde2db1e643ae5b9209ac581ecc1fd diff --git a/mail-mta/postfix/files/postfix-glibc-2.34.patch b/mail-mta/postfix/files/postfix-glibc-2.34.patch deleted file mode 100644 index 0da3ddf5ecdb..000000000000 --- a/mail-mta/postfix/files/postfix-glibc-2.34.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- a/src/util/sys_defs.h 2020-05-21 16:34:23.000000000 +0300 -+++ b/src/util/sys_defs.h 2021-08-07 19:14:20.000000000 +0300 -@@ -827,6 +827,9 @@ - #define HAVE_POSIX_GETPW_R - #endif - #endif -+#if HAVE_GLIBC_API_VERSION_SUPPORT(2, 34) -+#define HAS_CLOSEFROM -+#endif - - #endif - diff --git a/mail-mta/postfix/postfix-3.6.3.ebuild b/mail-mta/postfix/postfix-3.6.3.ebuild deleted file mode 100644 index 8a2e5709ee55..000000000000 --- a/mail-mta/postfix/postfix-3.6.3.ebuild +++ /dev/null @@ -1,290 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 -inherit pam systemd toolchain-funcs - -MY_PV="${PV/_rc/-RC}" -MY_SRC="${PN}-${MY_PV}" -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" -RC_VER="2.7" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail" -HOMEPAGE="http://www.postfix.org/" -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz" - -LICENSE="|| ( IBM EPL-2.0 )" -SLOT="0" -KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 ~s390 ~sparc x86" -IUSE="+berkdb cdb dovecot-sasl +eai ldap ldap-bind lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl" - -DEPEND=" - acct-group/postfix - acct-group/postdrop - acct-user/postfix - >=dev-libs/libpcre-3.4 - dev-lang/perl - berkdb? ( >=sys-libs/db-3.2:* ) - cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) ) - eai? ( dev-libs/icu:= ) - ldap? ( net-nds/openldap ) - ldap-bind? ( net-nds/openldap[sasl] ) - lmdb? ( >=dev-db/lmdb-0.9.11:= ) - mysql? ( dev-db/mysql-connector-c:0= ) - nis? ( net-libs/libnsl:= ) - pam? ( sys-libs/pam ) - postgres? ( dev-db/postgresql:* ) - sasl? ( >=dev-libs/cyrus-sasl-2 ) - sqlite? ( dev-db/sqlite:3 ) - ssl? ( >=dev-libs/openssl-1.1.1:0= ) - " - -RDEPEND="${DEPEND} - memcached? ( net-misc/memcached ) - net-mail/mailbase - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/msmtp[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/sendmail - !mail-mta/opensmtpd - !mail-mta/ssmtp[mta] - selinux? ( sec-policy/selinux-postfix )" - -REQUIRED_USE="ldap-bind? ( ldap sasl )" - -S="${WORKDIR}/${MY_SRC}" - -PATCHES=( - "${FILESDIR}/${PN}-glibc-2.34.patch" -) - -src_prepare() { - default - sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - # change default paths to better comply with portage standard paths - sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" -} - -src_configure() { - for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE - do - local AUXLIBS_${name}="" - done - - # Make sure LDFLAGS get passed down to the executables. - local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl" - AUXLIBS_PCRE="$(pcre-config --libs)" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap; then - mycc="${mycc} -DHAS_LDAP" - AUXLIBS_LDAP="-lldap -llber" - fi - - if use mysql; then - mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)" - AUXLIBS_MYSQL="$(mysql_config --libs)" - fi - - if use postgres; then - mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" - AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq" - fi - - if use sqlite; then - mycc="${mycc} -DHAS_SQLITE" - AUXLIBS_SQLITE="-lsqlite3 -lpthread" - fi - - if use ssl; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use lmdb; then - mycc="${mycc} -DHAS_LMDB" - AUXLIBS_LMDB="-llmdb -lpthread" - fi - - if ! use eai; then - mycc="${mycc} -DNO_EAI" - fi - - # broken. and "in other words, not supported" by upstream. - # Use inet_protocols setting in main.cf - #if ! use ipv6; then - # mycc="${mycc} -DNO_IPV6" - #fi - - if use sasl; then - if use dovecot-sasl; then - # Set dovecot as default. - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" - fi - if use ldap-bind; then - mycc="${mycc} -DUSE_LDAP_SASL" - fi - mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - elif use dovecot-sasl; then - mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" - fi - - if ! use nis; then - mycc="${mycc} -DNO_NIS" - fi - - if ! use berkdb; then - mycc="${mycc} -DNO_DB" - if use cdb; then - # change default hash format from Berkeley DB to cdb - mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\"" - fi - fi - - if use cdb; then - mycc="${mycc} -DHAS_CDB -I/usr/include/cdb" - # Tinycdb is preferred. - if has_version dev-db/tinycdb ; then - einfo "Building with dev-db/tinycdb" - AUXLIBS_CDB="-lcdb" - else - einfo "Building with dev-db/cdb" - CDB_PATH="/usr/$(get_libdir)" - for i in cdb.a alloc.a buffer.a unix.a byte.a ; do - AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}" - done - fi - fi - - sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs - sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs - - emake makefiles shared=yes dynamicmaps=no pie=yes \ - shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \ - DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \ - AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \ - AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \ - AUXLIBS_SQLITE="${AUXLIBS_SQLITE}" -} - -src_install() { - LD_LIBRARY_PATH="${S}/lib" \ - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/etc/postfix" \ - manpage_directory="/usr/share/man" \ - command_directory="/usr/sbin" \ - mailq_path="/usr/bin/mailq" \ - newaliases_path="/usr/bin/newaliases" \ - sendmail_path="/usr/sbin/sendmail" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade - rm -Rf "${D}"/var - keepdir /var/spool/postfix - - # Install rmail for UUCP, closes bug #19127 - dobin auxiliary/rmail/rmail - - # Provide another link for legacy FSH - dosym ../sbin/sendmail /usr/$(get_libdir)/sendmail - - # Install qshape, posttls-finger and collate and tlstype - dobin auxiliary/qshape/qshape.pl - doman man/man1/qshape.1 - dobin bin/posttls-finger - doman man/man1/posttls-finger.1 - dobin auxiliary/collate/collate.pl - newdoc auxiliary/collate/README README.collate - dobin auxiliary/collate/tlstype.pl - dodoc auxiliary/collate/README.tlstype - - # Performance tuning tools and their manuals - dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink} - doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1 - - # Set proper permissions on required files/directories - keepdir /var/lib/postfix - fowners -R postfix:postfix /var/lib/postfix - fperms 0750 /var/lib/postfix - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02755 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - keepdir /etc/postfix/postfix-files.d - if use mbox; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - LD_LIBRARY_PATH="${S}/lib" \ - "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \ - -e ${mypostconf} || die "postconf failed" - - insinto /etc/postfix - newins "${FILESDIR}"/smtp.pass saslpass - fperms 600 /etc/postfix/saslpass - - newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix - # do not start mysql/postgres unnecessarily - bug #359913 - use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" - use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" - - dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES* - mv "${S}"/examples "${D}"/usr/share/doc/${PF}/ - # postfix set-permissions expects uncompressed man files - docompress -x /usr/share/man - - if use pam; then - pamd_mimic_system smtp auth account - fi - - if use sasl; then - insinto /etc/sasl2 - newins "${FILESDIR}"/smtp.sasl smtpd.conf - fi - - # header files - insinto /usr/include/postfix - doins include/*.h - - if has_version mail-mta/postfix; then - # let the sysadmin decide when to change the compatibility_level - sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die - fi - - systemd_dounit "${FILESDIR}/${PN}.service" -} - -pkg_postinst() { - if [[ ! -e /etc/mail/aliases.db ]] ; then - ewarn - ewarn "You must edit /etc/mail/aliases to suit your needs" - ewarn "and then run /usr/bin/newaliases. Postfix will not" - ewarn "work correctly without it." - ewarn - fi - - # check and fix file permissions - "${EROOT}"/usr/sbin/postfix set-permissions - - # configure tls - if use ssl ; then - if "${EROOT}"/usr/sbin/postfix tls all-default-client; then - elog "To configure client side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-client - fi - if "${EROOT}"/usr/sbin/postfix tls all-default-server; then - elog "To configure server side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-server - fi - fi -} diff --git a/mail-mta/postfix/postfix-3.6.4.ebuild b/mail-mta/postfix/postfix-3.6.4.ebuild deleted file mode 100644 index 16ec4506ca6e..000000000000 --- a/mail-mta/postfix/postfix-3.6.4.ebuild +++ /dev/null @@ -1,290 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 -inherit pam systemd toolchain-funcs - -MY_PV="${PV/_rc/-RC}" -MY_SRC="${PN}-${MY_PV}" -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" -RC_VER="2.7" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail" -HOMEPAGE="http://www.postfix.org/" -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz" - -LICENSE="|| ( IBM EPL-2.0 )" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86" -IUSE="+berkdb cdb dovecot-sasl +eai ldap ldap-bind lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl" - -DEPEND=" - acct-group/postfix - acct-group/postdrop - acct-user/postfix - >=dev-libs/libpcre-3.4 - dev-lang/perl - berkdb? ( >=sys-libs/db-3.2:* ) - cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) ) - eai? ( dev-libs/icu:= ) - ldap? ( net-nds/openldap ) - ldap-bind? ( net-nds/openldap[sasl] ) - lmdb? ( >=dev-db/lmdb-0.9.11:= ) - mysql? ( dev-db/mysql-connector-c:0= ) - nis? ( net-libs/libnsl:= ) - pam? ( sys-libs/pam ) - postgres? ( dev-db/postgresql:* ) - sasl? ( >=dev-libs/cyrus-sasl-2 ) - sqlite? ( dev-db/sqlite:3 ) - ssl? ( >=dev-libs/openssl-1.1.1:0= ) - " - -RDEPEND="${DEPEND} - memcached? ( net-misc/memcached ) - net-mail/mailbase - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/msmtp[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/sendmail - !mail-mta/opensmtpd - !mail-mta/ssmtp[mta] - selinux? ( sec-policy/selinux-postfix )" - -REQUIRED_USE="ldap-bind? ( ldap sasl )" - -S="${WORKDIR}/${MY_SRC}" - -PATCHES=( - "${FILESDIR}/${PN}-glibc-2.34.patch" -) - -src_prepare() { - default - sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - # change default paths to better comply with portage standard paths - sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" -} - -src_configure() { - for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE - do - local AUXLIBS_${name}="" - done - - # Make sure LDFLAGS get passed down to the executables. - local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl" - AUXLIBS_PCRE="$(pcre-config --libs)" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap; then - mycc="${mycc} -DHAS_LDAP" - AUXLIBS_LDAP="-lldap -llber" - fi - - if use mysql; then - mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)" - AUXLIBS_MYSQL="$(mysql_config --libs)" - fi - - if use postgres; then - mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" - AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq" - fi - - if use sqlite; then - mycc="${mycc} -DHAS_SQLITE" - AUXLIBS_SQLITE="-lsqlite3 -lpthread" - fi - - if use ssl; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use lmdb; then - mycc="${mycc} -DHAS_LMDB" - AUXLIBS_LMDB="-llmdb -lpthread" - fi - - if ! use eai; then - mycc="${mycc} -DNO_EAI" - fi - - # broken. and "in other words, not supported" by upstream. - # Use inet_protocols setting in main.cf - #if ! use ipv6; then - # mycc="${mycc} -DNO_IPV6" - #fi - - if use sasl; then - if use dovecot-sasl; then - # Set dovecot as default. - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" - fi - if use ldap-bind; then - mycc="${mycc} -DUSE_LDAP_SASL" - fi - mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - elif use dovecot-sasl; then - mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" - fi - - if ! use nis; then - mycc="${mycc} -DNO_NIS" - fi - - if ! use berkdb; then - mycc="${mycc} -DNO_DB" - if use cdb; then - # change default hash format from Berkeley DB to cdb - mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\"" - fi - fi - - if use cdb; then - mycc="${mycc} -DHAS_CDB -I/usr/include/cdb" - # Tinycdb is preferred. - if has_version dev-db/tinycdb ; then - einfo "Building with dev-db/tinycdb" - AUXLIBS_CDB="-lcdb" - else - einfo "Building with dev-db/cdb" - CDB_PATH="/usr/$(get_libdir)" - for i in cdb.a alloc.a buffer.a unix.a byte.a ; do - AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}" - done - fi - fi - - sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs - sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs - - emake makefiles shared=yes dynamicmaps=no pie=yes \ - shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \ - DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \ - AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \ - AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \ - AUXLIBS_SQLITE="${AUXLIBS_SQLITE}" -} - -src_install() { - LD_LIBRARY_PATH="${S}/lib" \ - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/etc/postfix" \ - manpage_directory="/usr/share/man" \ - command_directory="/usr/sbin" \ - mailq_path="/usr/bin/mailq" \ - newaliases_path="/usr/bin/newaliases" \ - sendmail_path="/usr/sbin/sendmail" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade - rm -Rf "${D}"/var - keepdir /var/spool/postfix - - # Install rmail for UUCP, closes bug #19127 - dobin auxiliary/rmail/rmail - - # Provide another link for legacy FSH - dosym ../sbin/sendmail /usr/$(get_libdir)/sendmail - - # Install qshape, posttls-finger and collate and tlstype - dobin auxiliary/qshape/qshape.pl - doman man/man1/qshape.1 - dobin bin/posttls-finger - doman man/man1/posttls-finger.1 - dobin auxiliary/collate/collate.pl - newdoc auxiliary/collate/README README.collate - dobin auxiliary/collate/tlstype.pl - dodoc auxiliary/collate/README.tlstype - - # Performance tuning tools and their manuals - dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink} - doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1 - - # Set proper permissions on required files/directories - keepdir /var/lib/postfix - fowners -R postfix:postfix /var/lib/postfix - fperms 0750 /var/lib/postfix - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02755 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - keepdir /etc/postfix/postfix-files.d - if use mbox; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - LD_LIBRARY_PATH="${S}/lib" \ - "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \ - -e ${mypostconf} || die "postconf failed" - - insinto /etc/postfix - newins "${FILESDIR}"/smtp.pass saslpass - fperms 600 /etc/postfix/saslpass - - newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix - # do not start mysql/postgres unnecessarily - bug #359913 - use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" - use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" - - dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES* - mv "${S}"/examples "${D}"/usr/share/doc/${PF}/ - # postfix set-permissions expects uncompressed man files - docompress -x /usr/share/man - - if use pam; then - pamd_mimic_system smtp auth account - fi - - if use sasl; then - insinto /etc/sasl2 - newins "${FILESDIR}"/smtp.sasl smtpd.conf - fi - - # header files - insinto /usr/include/postfix - doins include/*.h - - if has_version mail-mta/postfix; then - # let the sysadmin decide when to change the compatibility_level - sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die - fi - - systemd_dounit "${FILESDIR}/${PN}.service" -} - -pkg_postinst() { - if [[ ! -e /etc/mail/aliases.db ]] ; then - ewarn - ewarn "You must edit /etc/mail/aliases to suit your needs" - ewarn "and then run /usr/bin/newaliases. Postfix will not" - ewarn "work correctly without it." - ewarn - fi - - # check and fix file permissions - "${EROOT}"/usr/sbin/postfix set-permissions - - # configure tls - if use ssl ; then - if "${EROOT}"/usr/sbin/postfix tls all-default-client; then - elog "To configure client side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-client - fi - if "${EROOT}"/usr/sbin/postfix tls all-default-server; then - elog "To configure server side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-server - fi - fi -} diff --git a/mail-mta/postfix/postfix-3.6.5-r1.ebuild b/mail-mta/postfix/postfix-3.6.5-r1.ebuild deleted file mode 100644 index 008332eec380..000000000000 --- a/mail-mta/postfix/postfix-3.6.5-r1.ebuild +++ /dev/null @@ -1,286 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 -inherit pam systemd toolchain-funcs - -MY_PV="${PV/_rc/-RC}" -MY_SRC="${PN}-${MY_PV}" -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" -RC_VER="2.7" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail" -HOMEPAGE="http://www.postfix.org/" -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz" - -LICENSE="|| ( IBM EPL-2.0 )" -SLOT="0" -KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 ~s390 ~sparc x86" -IUSE="+berkdb cdb dovecot-sasl +eai ldap ldap-bind lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl" - -DEPEND=" - acct-group/postfix - acct-group/postdrop - acct-user/postfix - >=dev-libs/libpcre-3.4 - dev-lang/perl - berkdb? ( >=sys-libs/db-3.2:* ) - cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) ) - eai? ( dev-libs/icu:= ) - ldap? ( net-nds/openldap ) - ldap-bind? ( net-nds/openldap[sasl] ) - lmdb? ( >=dev-db/lmdb-0.9.11:= ) - mysql? ( dev-db/mysql-connector-c:0= ) - nis? ( net-libs/libnsl:= ) - pam? ( sys-libs/pam ) - postgres? ( dev-db/postgresql:* ) - sasl? ( >=dev-libs/cyrus-sasl-2 ) - sqlite? ( dev-db/sqlite:3 ) - ssl? ( >=dev-libs/openssl-1.1.1:0= ) - " - -RDEPEND="${DEPEND} - memcached? ( net-misc/memcached ) - net-mail/mailbase - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/msmtp[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/sendmail - !mail-mta/opensmtpd - !mail-mta/ssmtp[mta] - selinux? ( sec-policy/selinux-postfix )" - -REQUIRED_USE="ldap-bind? ( ldap sasl )" - -S="${WORKDIR}/${MY_SRC}" - -src_prepare() { - default - sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - # change default paths to better comply with portage standard paths - sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" -} - -src_configure() { - for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE - do - local AUXLIBS_${name}="" - done - - # Make sure LDFLAGS get passed down to the executables. - local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl" - AUXLIBS_PCRE="$(pcre-config --libs)" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap; then - mycc="${mycc} -DHAS_LDAP" - AUXLIBS_LDAP="-lldap -llber" - fi - - if use mysql; then - mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)" - AUXLIBS_MYSQL="$(mysql_config --libs)" - fi - - if use postgres; then - mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" - AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq" - fi - - if use sqlite; then - mycc="${mycc} -DHAS_SQLITE" - AUXLIBS_SQLITE="-lsqlite3 -lpthread" - fi - - if use ssl; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use lmdb; then - mycc="${mycc} -DHAS_LMDB" - AUXLIBS_LMDB="-llmdb -lpthread" - fi - - if ! use eai; then - mycc="${mycc} -DNO_EAI" - fi - - # broken. and "in other words, not supported" by upstream. - # Use inet_protocols setting in main.cf - #if ! use ipv6; then - # mycc="${mycc} -DNO_IPV6" - #fi - - if use sasl; then - if use dovecot-sasl; then - # Set dovecot as default. - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" - fi - if use ldap-bind; then - mycc="${mycc} -DUSE_LDAP_SASL" - fi - mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - elif use dovecot-sasl; then - mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" - fi - - if ! use nis; then - mycc="${mycc} -DNO_NIS" - fi - - if ! use berkdb; then - mycc="${mycc} -DNO_DB" - if use cdb; then - # change default hash format from Berkeley DB to cdb - mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\"" - fi - fi - - if use cdb; then - mycc="${mycc} -DHAS_CDB -I/usr/include/cdb" - # Tinycdb is preferred. - if has_version dev-db/tinycdb ; then - einfo "Building with dev-db/tinycdb" - AUXLIBS_CDB="-lcdb" - else - einfo "Building with dev-db/cdb" - CDB_PATH="/usr/$(get_libdir)" - for i in cdb.a alloc.a buffer.a unix.a byte.a ; do - AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}" - done - fi - fi - - sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs - sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs - - emake makefiles shared=yes dynamicmaps=no pie=yes \ - shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \ - DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \ - AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \ - AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \ - AUXLIBS_SQLITE="${AUXLIBS_SQLITE}" -} - -src_install() { - LD_LIBRARY_PATH="${S}/lib" \ - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/etc/postfix" \ - manpage_directory="/usr/share/man" \ - command_directory="/usr/sbin" \ - mailq_path="/usr/bin/mailq" \ - newaliases_path="/usr/bin/newaliases" \ - sendmail_path="/usr/sbin/sendmail" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade - rm -Rf "${D}"/var - keepdir /var/spool/postfix - - # Install rmail for UUCP, closes bug #19127 - dobin auxiliary/rmail/rmail - - # Provide another link for legacy FSH - dosym ../sbin/sendmail /usr/$(get_libdir)/sendmail - - # Install qshape, posttls-finger and collate and tlstype - dobin auxiliary/qshape/qshape.pl - doman man/man1/qshape.1 - dobin bin/posttls-finger - doman man/man1/posttls-finger.1 - dobin auxiliary/collate/collate.pl - newdoc auxiliary/collate/README README.collate - dobin auxiliary/collate/tlstype.pl - dodoc auxiliary/collate/README.tlstype - - # Performance tuning tools and their manuals - dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink} - doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1 - - # Set proper permissions on required files/directories - keepdir /var/lib/postfix - fowners -R postfix:postfix /var/lib/postfix - fperms 0750 /var/lib/postfix - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02755 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - keepdir /etc/postfix/postfix-files.d - if use mbox; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - LD_LIBRARY_PATH="${S}/lib" \ - "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \ - -e ${mypostconf} || die "postconf failed" - - insinto /etc/postfix - newins "${FILESDIR}"/smtp.pass saslpass - fperms 600 /etc/postfix/saslpass - - newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix - # do not start mysql/postgres unnecessarily - bug #359913 - use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" - use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" - - dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES* - mv "${S}"/examples "${D}"/usr/share/doc/${PF}/ - # postfix set-permissions expects uncompressed man files - docompress -x /usr/share/man - - if use pam; then - pamd_mimic_system smtp auth account - fi - - if use sasl; then - insinto /etc/sasl2 - newins "${FILESDIR}"/smtp.sasl smtpd.conf - fi - - # header files - insinto /usr/include/postfix - doins include/*.h - - if has_version mail-mta/postfix; then - # let the sysadmin decide when to change the compatibility_level - sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die - fi - - systemd_dounit "${FILESDIR}/${PN}.service" -} - -pkg_postinst() { - if [[ ! -e /etc/mail/aliases.db ]] ; then - ewarn - ewarn "You must edit /etc/mail/aliases to suit your needs" - ewarn "and then run /usr/bin/newaliases. Postfix will not" - ewarn "work correctly without it." - ewarn - fi - - # check and fix file permissions - "${EROOT}"/usr/sbin/postfix set-permissions - - # configure tls - if use ssl ; then - if "${EROOT}"/usr/sbin/postfix tls all-default-client; then - elog "To configure client side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-client - fi - if "${EROOT}"/usr/sbin/postfix tls all-default-server; then - elog "To configure server side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-server - fi - fi -} diff --git a/mail-mta/postfix/postfix-3.6.5-r2.ebuild b/mail-mta/postfix/postfix-3.6.5-r2.ebuild new file mode 100644 index 000000000000..5169a940aef1 --- /dev/null +++ b/mail-mta/postfix/postfix-3.6.5-r2.ebuild @@ -0,0 +1,286 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +inherit pam systemd toolchain-funcs + +MY_PV="${PV/_rc/-RC}" +MY_SRC="${PN}-${MY_PV}" +MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" +RC_VER="2.7" + +DESCRIPTION="A fast and secure drop-in replacement for sendmail" +HOMEPAGE="http://www.postfix.org/" +SRC_URI="${MY_URI}/${MY_SRC}.tar.gz" + +LICENSE="|| ( IBM EPL-2.0 )" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 ~s390 ~sparc x86" +IUSE="+berkdb cdb dovecot-sasl +eai ldap ldap-bind lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl" + +DEPEND=" + acct-group/postfix + acct-group/postdrop + acct-user/postfix + >=dev-libs/libpcre-3.4 + dev-lang/perl + berkdb? ( >=sys-libs/db-3.2:* ) + cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) ) + eai? ( dev-libs/icu:= ) + ldap? ( net-nds/openldap:= ) + ldap-bind? ( net-nds/openldap:=[sasl] ) + lmdb? ( >=dev-db/lmdb-0.9.11:= ) + mysql? ( dev-db/mysql-connector-c:0= ) + nis? ( net-libs/libnsl:= ) + pam? ( sys-libs/pam ) + postgres? ( dev-db/postgresql:* ) + sasl? ( >=dev-libs/cyrus-sasl-2 ) + sqlite? ( dev-db/sqlite:3 ) + ssl? ( >=dev-libs/openssl-1.1.1:0= ) + " + +RDEPEND="${DEPEND} + memcached? ( net-misc/memcached ) + net-mail/mailbase + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/exim + !mail-mta/msmtp[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/sendmail + !mail-mta/opensmtpd + !mail-mta/ssmtp[mta] + selinux? ( sec-policy/selinux-postfix )" + +REQUIRED_USE="ldap-bind? ( ldap sasl )" + +S="${WORKDIR}/${MY_SRC}" + +src_prepare() { + default + sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ + src/util/sys_defs.h || die "sed failed" + # change default paths to better comply with portage standard paths + sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" +} + +src_configure() { + for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE + do + local AUXLIBS_${name}="" + done + + # Make sure LDFLAGS get passed down to the executables. + local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl" + AUXLIBS_PCRE="$(pcre-config --libs)" + + use pam && mylibs="${mylibs} -lpam" + + if use ldap; then + mycc="${mycc} -DHAS_LDAP" + AUXLIBS_LDAP="-lldap -llber" + fi + + if use mysql; then + mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)" + AUXLIBS_MYSQL="$(mysql_config --libs)" + fi + + if use postgres; then + mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" + AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq" + fi + + if use sqlite; then + mycc="${mycc} -DHAS_SQLITE" + AUXLIBS_SQLITE="-lsqlite3 -lpthread" + fi + + if use ssl; then + mycc="${mycc} -DUSE_TLS" + mylibs="${mylibs} -lssl -lcrypto" + fi + + if use lmdb; then + mycc="${mycc} -DHAS_LMDB" + AUXLIBS_LMDB="-llmdb -lpthread" + fi + + if ! use eai; then + mycc="${mycc} -DNO_EAI" + fi + + # broken. and "in other words, not supported" by upstream. + # Use inet_protocols setting in main.cf + #if ! use ipv6; then + # mycc="${mycc} -DNO_IPV6" + #fi + + if use sasl; then + if use dovecot-sasl; then + # Set dovecot as default. + mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" + fi + if use ldap-bind; then + mycc="${mycc} -DUSE_LDAP_SASL" + fi + mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" + mylibs="${mylibs} -lsasl2" + elif use dovecot-sasl; then + mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" + fi + + if ! use nis; then + mycc="${mycc} -DNO_NIS" + fi + + if ! use berkdb; then + mycc="${mycc} -DNO_DB" + if use cdb; then + # change default hash format from Berkeley DB to cdb + mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\"" + fi + fi + + if use cdb; then + mycc="${mycc} -DHAS_CDB -I/usr/include/cdb" + # Tinycdb is preferred. + if has_version dev-db/tinycdb ; then + einfo "Building with dev-db/tinycdb" + AUXLIBS_CDB="-lcdb" + else + einfo "Building with dev-db/cdb" + CDB_PATH="/usr/$(get_libdir)" + for i in cdb.a alloc.a buffer.a unix.a byte.a ; do + AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}" + done + fi + fi + + sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs + sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs + + emake makefiles shared=yes dynamicmaps=no pie=yes \ + shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \ + DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ + AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \ + AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \ + AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \ + AUXLIBS_SQLITE="${AUXLIBS_SQLITE}" +} + +src_install() { + LD_LIBRARY_PATH="${S}/lib" \ + /bin/sh postfix-install \ + -non-interactive \ + install_root="${D}" \ + config_directory="/etc/postfix" \ + manpage_directory="/usr/share/man" \ + command_directory="/usr/sbin" \ + mailq_path="/usr/bin/mailq" \ + newaliases_path="/usr/bin/newaliases" \ + sendmail_path="/usr/sbin/sendmail" \ + || die "postfix-install failed" + + # Fix spool removal on upgrade + rm -Rf "${D}"/var + keepdir /var/spool/postfix + + # Install rmail for UUCP, closes bug #19127 + dobin auxiliary/rmail/rmail + + # Provide another link for legacy FSH + dosym ../sbin/sendmail /usr/$(get_libdir)/sendmail + + # Install qshape, posttls-finger and collate and tlstype + dobin auxiliary/qshape/qshape.pl + doman man/man1/qshape.1 + dobin bin/posttls-finger + doman man/man1/posttls-finger.1 + dobin auxiliary/collate/collate.pl + newdoc auxiliary/collate/README README.collate + dobin auxiliary/collate/tlstype.pl + dodoc auxiliary/collate/README.tlstype + + # Performance tuning tools and their manuals + dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink} + doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1 + + # Set proper permissions on required files/directories + keepdir /var/lib/postfix + fowners -R postfix:postfix /var/lib/postfix + fperms 0750 /var/lib/postfix + fowners root:postdrop /usr/sbin/post{drop,queue} + fperms 02755 /usr/sbin/post{drop,queue} + + keepdir /etc/postfix + keepdir /etc/postfix/postfix-files.d + if use mbox; then + mypostconf="mail_spool_directory=/var/spool/mail" + else + mypostconf="home_mailbox=.maildir/" + fi + LD_LIBRARY_PATH="${S}/lib" \ + "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \ + -e ${mypostconf} || die "postconf failed" + + insinto /etc/postfix + newins "${FILESDIR}"/smtp.pass saslpass + fperms 600 /etc/postfix/saslpass + + newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix + # do not start mysql/postgres unnecessarily - bug #359913 + use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" + use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" + + dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES* + mv "${S}"/examples "${D}"/usr/share/doc/${PF}/ + # postfix set-permissions expects uncompressed man files + docompress -x /usr/share/man + + if use pam; then + pamd_mimic_system smtp auth account + fi + + if use sasl; then + insinto /etc/sasl2 + newins "${FILESDIR}"/smtp.sasl smtpd.conf + fi + + # header files + insinto /usr/include/postfix + doins include/*.h + + if has_version mail-mta/postfix; then + # let the sysadmin decide when to change the compatibility_level + sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die + fi + + systemd_dounit "${FILESDIR}/${PN}.service" +} + +pkg_postinst() { + if [[ ! -e /etc/mail/aliases.db ]] ; then + ewarn + ewarn "You must edit /etc/mail/aliases to suit your needs" + ewarn "and then run /usr/bin/newaliases. Postfix will not" + ewarn "work correctly without it." + ewarn + fi + + # check and fix file permissions + "${EROOT}"/usr/sbin/postfix set-permissions + + # configure tls + if use ssl ; then + if "${EROOT}"/usr/sbin/postfix tls all-default-client; then + elog "To configure client side TLS settings:" + elog "${EROOT}"/usr/sbin/postfix tls enable-client + fi + if "${EROOT}"/usr/sbin/postfix tls all-default-server; then + elog "To configure server side TLS settings:" + elog "${EROOT}"/usr/sbin/postfix tls enable-server + fi + fi +} diff --git a/mail-mta/postfix/postfix-3.7.0-r1.ebuild b/mail-mta/postfix/postfix-3.7.0-r1.ebuild new file mode 100644 index 000000000000..e99f67f1d0df --- /dev/null +++ b/mail-mta/postfix/postfix-3.7.0-r1.ebuild @@ -0,0 +1,294 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit pam systemd toolchain-funcs + +MY_PV="${PV/_rc/-RC}" +MY_SRC="${PN}-${MY_PV}" +MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" +RC_VER="2.7" + +DESCRIPTION="A fast and secure drop-in replacement for sendmail" +HOMEPAGE="http://www.postfix.org/" +SRC_URI="${MY_URI}/${MY_SRC}.tar.gz" + +LICENSE="|| ( IBM EPL-2.0 )" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86" +IUSE="+berkdb cdb dovecot-sasl +eai ldap ldap-bind lmdb mbox memcached mysql nis pam postgres sasl selinux sqlite ssl" + +DEPEND=" + acct-group/postfix + acct-group/postdrop + acct-user/postfix + || ( dev-libs/libpcre2:0 dev-libs/libpcre ) + dev-lang/perl + berkdb? ( >=sys-libs/db-3.2:* ) + cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) ) + eai? ( dev-libs/icu:= ) + ldap? ( net-nds/openldap:= ) + ldap-bind? ( net-nds/openldap:=[sasl] ) + lmdb? ( >=dev-db/lmdb-0.9.11:= ) + mysql? ( dev-db/mysql-connector-c:0= ) + nis? ( net-libs/libnsl:= ) + pam? ( sys-libs/pam ) + postgres? ( dev-db/postgresql:* ) + sasl? ( >=dev-libs/cyrus-sasl-2 ) + sqlite? ( dev-db/sqlite:3 ) + ssl? ( >=dev-libs/openssl-1.1.1:0= ) + " + +RDEPEND="${DEPEND} + memcached? ( net-misc/memcached ) + net-mail/mailbase + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/exim + !mail-mta/msmtp[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/sendmail + !mail-mta/opensmtpd + !mail-mta/ssmtp[mta] + selinux? ( sec-policy/selinux-postfix )" + +REQUIRED_USE="ldap-bind? ( ldap sasl )" + +S="${WORKDIR}/${MY_SRC}" + +src_prepare() { + default + sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ + src/util/sys_defs.h || die "sed failed" + # change default paths to better comply with portage standard paths + sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" +} + +src_configure() { + for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE + do + local AUXLIBS_${name}="" + done + + # Make sure LDFLAGS get passed down to the executables. + local mycc="" mylibs="${LDFLAGS} -ldl" + + # libpcre is EOL. prefer libpcre2 + if has_version dev-libs/libpcre2; then + mycc="-DHAS_PCRE=2" + AUXLIBS_PCRE="$(pcre2-config --libs8)" + else + mycc="-DHAS_PCRE=1" + AUXLIBS_PCRE="$(pcre-config --libs)" + fi + + use pam && mylibs="${mylibs} -lpam" + + if use ldap; then + mycc="${mycc} -DHAS_LDAP" + AUXLIBS_LDAP="-lldap -llber" + fi + + if use mysql; then + mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)" + AUXLIBS_MYSQL="$(mysql_config --libs)" + fi + + if use postgres; then + mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" + AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq" + fi + + if use sqlite; then + mycc="${mycc} -DHAS_SQLITE" + AUXLIBS_SQLITE="-lsqlite3 -lpthread" + fi + + if use ssl; then + mycc="${mycc} -DUSE_TLS" + mylibs="${mylibs} -lssl -lcrypto" + fi + + if use lmdb; then + mycc="${mycc} -DHAS_LMDB" + AUXLIBS_LMDB="-llmdb -lpthread" + fi + + if ! use eai; then + mycc="${mycc} -DNO_EAI" + fi + + # broken. and "in other words, not supported" by upstream. + # Use inet_protocols setting in main.cf + #if ! use ipv6; then + # mycc="${mycc} -DNO_IPV6" + #fi + + if use sasl; then + if use dovecot-sasl; then + # Set dovecot as default. + mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" + fi + if use ldap-bind; then + mycc="${mycc} -DUSE_LDAP_SASL" + fi + mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" + mylibs="${mylibs} -lsasl2" + elif use dovecot-sasl; then + mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" + fi + + if ! use nis; then + mycc="${mycc} -DNO_NIS" + fi + + if ! use berkdb; then + mycc="${mycc} -DNO_DB" + # change default database type + if use cdb; then + mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\"" + elif use lmdb; then + mycc="${mycc} -DDEF_DB_TYPE=\\\"lmdb\\\"" + fi + fi + + if use cdb; then + mycc="${mycc} -DHAS_CDB -I/usr/include/cdb" + # Tinycdb is preferred. + if has_version dev-db/tinycdb ; then + AUXLIBS_CDB="-lcdb" + else + CDB_PATH="/usr/$(get_libdir)" + for i in cdb.a alloc.a buffer.a unix.a byte.a ; do + AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}" + done + fi + fi + + sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs + sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs + + emake makefiles shared=yes dynamicmaps=no pie=yes \ + shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \ + DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ + AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \ + AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \ + AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \ + AUXLIBS_SQLITE="${AUXLIBS_SQLITE}" +} + +src_install() { + LD_LIBRARY_PATH="${S}/lib" \ + /bin/sh postfix-install \ + -non-interactive \ + install_root="${D}" \ + config_directory="/etc/postfix" \ + manpage_directory="/usr/share/man" \ + command_directory="/usr/sbin" \ + mailq_path="/usr/bin/mailq" \ + newaliases_path="/usr/bin/newaliases" \ + sendmail_path="/usr/sbin/sendmail" \ + || die "postfix-install failed" + + # Fix spool removal on upgrade + rm -Rf "${D}"/var + keepdir /var/spool/postfix + + # Install rmail for UUCP, closes bug #19127 + dobin auxiliary/rmail/rmail + + # Provide another link for legacy FSH + dosym ../sbin/sendmail /usr/$(get_libdir)/sendmail + + # Install qshape, posttls-finger, collate and tlstype + dobin auxiliary/qshape/qshape.pl + doman man/man1/qshape.1 + dobin bin/posttls-finger + doman man/man1/posttls-finger.1 + dobin auxiliary/collate/collate.pl + newdoc auxiliary/collate/README README.collate + dobin auxiliary/collate/tlstype.pl + dodoc auxiliary/collate/README.tlstype + + # Performance tuning tools and their manuals + dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink} + doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1 + + # Set proper permissions on required files/directories + keepdir /var/lib/postfix + fowners -R postfix:postfix /var/lib/postfix + fperms 0750 /var/lib/postfix + fowners root:postdrop /usr/sbin/post{drop,queue,log} + fperms 02755 /usr/sbin/post{drop,queue,log} + + keepdir /etc/postfix + keepdir /etc/postfix/postfix-files.d + if use mbox; then + mypostconf="mail_spool_directory=/var/spool/mail" + else + mypostconf="home_mailbox=.maildir/" + fi + LD_LIBRARY_PATH="${S}/lib" \ + "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \ + -e ${mypostconf} || die "postconf failed" + + insinto /etc/postfix + newins "${FILESDIR}"/smtp.pass saslpass + fperms 600 /etc/postfix/saslpass + + newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix + # do not start mysql/postgres unnecessarily - bug #359913 + use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" + use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" + + dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES* + dodoc -r README_FILES/ examples/ + # postfix set-permissions expects uncompressed man files + docompress -x /usr/share/man + + if use pam; then + pamd_mimic_system smtp auth account + fi + + if use sasl; then + insinto /etc/sasl2 + newins "${FILESDIR}"/smtp.sasl smtpd.conf + fi + + # header files + insinto /usr/include/postfix + doins include/*.h + + if has_version mail-mta/postfix; then + # let the sysadmin decide when to change the compatibility_level + sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die + fi + + systemd_dounit "${FILESDIR}/${PN}.service" +} + +pkg_postinst() { + if [[ ! -e /etc/mail/aliases.db ]] ; then + ewarn + ewarn "You must edit /etc/mail/aliases to suit your needs" + ewarn "and then run /usr/bin/newaliases. Postfix will not" + ewarn "work correctly without it." + ewarn + fi + + # check and fix file permissions + "${EROOT}"/usr/sbin/postfix set-permissions + + # configure tls + if use ssl ; then + if "${EROOT}"/usr/sbin/postfix tls all-default-client; then + elog "To configure client side TLS settings:" + elog "${EROOT}"/usr/sbin/postfix tls enable-client + fi + if "${EROOT}"/usr/sbin/postfix tls all-default-server; then + elog "To configure server side TLS settings:" + elog "${EROOT}"/usr/sbin/postfix tls enable-server + fi + fi +} diff --git a/mail-mta/postfix/postfix-3.7.0.ebuild b/mail-mta/postfix/postfix-3.7.0.ebuild deleted file mode 100644 index 19f6b3f39750..000000000000 --- a/mail-mta/postfix/postfix-3.7.0.ebuild +++ /dev/null @@ -1,294 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 -inherit pam systemd toolchain-funcs - -MY_PV="${PV/_rc/-RC}" -MY_SRC="${PN}-${MY_PV}" -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" -RC_VER="2.7" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail" -HOMEPAGE="http://www.postfix.org/" -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz" - -LICENSE="|| ( IBM EPL-2.0 )" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86" -IUSE="+berkdb cdb dovecot-sasl +eai ldap ldap-bind lmdb mbox memcached mysql nis pam postgres sasl selinux sqlite ssl" - -DEPEND=" - acct-group/postfix - acct-group/postdrop - acct-user/postfix - || ( dev-libs/libpcre2:0 dev-libs/libpcre ) - dev-lang/perl - berkdb? ( >=sys-libs/db-3.2:* ) - cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) ) - eai? ( dev-libs/icu:= ) - ldap? ( net-nds/openldap ) - ldap-bind? ( net-nds/openldap[sasl] ) - lmdb? ( >=dev-db/lmdb-0.9.11:= ) - mysql? ( dev-db/mysql-connector-c:0= ) - nis? ( net-libs/libnsl:= ) - pam? ( sys-libs/pam ) - postgres? ( dev-db/postgresql:* ) - sasl? ( >=dev-libs/cyrus-sasl-2 ) - sqlite? ( dev-db/sqlite:3 ) - ssl? ( >=dev-libs/openssl-1.1.1:0= ) - " - -RDEPEND="${DEPEND} - memcached? ( net-misc/memcached ) - net-mail/mailbase - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/msmtp[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/sendmail - !mail-mta/opensmtpd - !mail-mta/ssmtp[mta] - selinux? ( sec-policy/selinux-postfix )" - -REQUIRED_USE="ldap-bind? ( ldap sasl )" - -S="${WORKDIR}/${MY_SRC}" - -src_prepare() { - default - sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - # change default paths to better comply with portage standard paths - sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" -} - -src_configure() { - for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE - do - local AUXLIBS_${name}="" - done - - # Make sure LDFLAGS get passed down to the executables. - local mycc="" mylibs="${LDFLAGS} -ldl" - - # libpcre is EOL. prefer libpcre2 - if has_version dev-libs/libpcre2; then - mycc="-DHAS_PCRE=2" - AUXLIBS_PCRE="$(pcre2-config --libs8)" - else - mycc="-DHAS_PCRE=1" - AUXLIBS_PCRE="$(pcre-config --libs)" - fi - - use pam && mylibs="${mylibs} -lpam" - - if use ldap; then - mycc="${mycc} -DHAS_LDAP" - AUXLIBS_LDAP="-lldap -llber" - fi - - if use mysql; then - mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)" - AUXLIBS_MYSQL="$(mysql_config --libs)" - fi - - if use postgres; then - mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" - AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq" - fi - - if use sqlite; then - mycc="${mycc} -DHAS_SQLITE" - AUXLIBS_SQLITE="-lsqlite3 -lpthread" - fi - - if use ssl; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use lmdb; then - mycc="${mycc} -DHAS_LMDB" - AUXLIBS_LMDB="-llmdb -lpthread" - fi - - if ! use eai; then - mycc="${mycc} -DNO_EAI" - fi - - # broken. and "in other words, not supported" by upstream. - # Use inet_protocols setting in main.cf - #if ! use ipv6; then - # mycc="${mycc} -DNO_IPV6" - #fi - - if use sasl; then - if use dovecot-sasl; then - # Set dovecot as default. - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" - fi - if use ldap-bind; then - mycc="${mycc} -DUSE_LDAP_SASL" - fi - mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - elif use dovecot-sasl; then - mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" - fi - - if ! use nis; then - mycc="${mycc} -DNO_NIS" - fi - - if ! use berkdb; then - mycc="${mycc} -DNO_DB" - # change default database type - if use cdb; then - mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\"" - elif use lmdb; then - mycc="${mycc} -DDEF_DB_TYPE=\\\"lmdb\\\"" - fi - fi - - if use cdb; then - mycc="${mycc} -DHAS_CDB -I/usr/include/cdb" - # Tinycdb is preferred. - if has_version dev-db/tinycdb ; then - AUXLIBS_CDB="-lcdb" - else - CDB_PATH="/usr/$(get_libdir)" - for i in cdb.a alloc.a buffer.a unix.a byte.a ; do - AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}" - done - fi - fi - - sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs - sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs - - emake makefiles shared=yes dynamicmaps=no pie=yes \ - shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \ - DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \ - AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \ - AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \ - AUXLIBS_SQLITE="${AUXLIBS_SQLITE}" -} - -src_install() { - LD_LIBRARY_PATH="${S}/lib" \ - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/etc/postfix" \ - manpage_directory="/usr/share/man" \ - command_directory="/usr/sbin" \ - mailq_path="/usr/bin/mailq" \ - newaliases_path="/usr/bin/newaliases" \ - sendmail_path="/usr/sbin/sendmail" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade - rm -Rf "${D}"/var - keepdir /var/spool/postfix - - # Install rmail for UUCP, closes bug #19127 - dobin auxiliary/rmail/rmail - - # Provide another link for legacy FSH - dosym ../sbin/sendmail /usr/$(get_libdir)/sendmail - - # Install qshape, posttls-finger, collate and tlstype - dobin auxiliary/qshape/qshape.pl - doman man/man1/qshape.1 - dobin bin/posttls-finger - doman man/man1/posttls-finger.1 - dobin auxiliary/collate/collate.pl - newdoc auxiliary/collate/README README.collate - dobin auxiliary/collate/tlstype.pl - dodoc auxiliary/collate/README.tlstype - - # Performance tuning tools and their manuals - dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink} - doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1 - - # Set proper permissions on required files/directories - keepdir /var/lib/postfix - fowners -R postfix:postfix /var/lib/postfix - fperms 0750 /var/lib/postfix - fowners root:postdrop /usr/sbin/post{drop,queue,log} - fperms 02755 /usr/sbin/post{drop,queue,log} - - keepdir /etc/postfix - keepdir /etc/postfix/postfix-files.d - if use mbox; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - LD_LIBRARY_PATH="${S}/lib" \ - "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \ - -e ${mypostconf} || die "postconf failed" - - insinto /etc/postfix - newins "${FILESDIR}"/smtp.pass saslpass - fperms 600 /etc/postfix/saslpass - - newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix - # do not start mysql/postgres unnecessarily - bug #359913 - use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" - use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" - - dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES* - dodoc -r README_FILES/ examples/ - # postfix set-permissions expects uncompressed man files - docompress -x /usr/share/man - - if use pam; then - pamd_mimic_system smtp auth account - fi - - if use sasl; then - insinto /etc/sasl2 - newins "${FILESDIR}"/smtp.sasl smtpd.conf - fi - - # header files - insinto /usr/include/postfix - doins include/*.h - - if has_version mail-mta/postfix; then - # let the sysadmin decide when to change the compatibility_level - sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die - fi - - systemd_dounit "${FILESDIR}/${PN}.service" -} - -pkg_postinst() { - if [[ ! -e /etc/mail/aliases.db ]] ; then - ewarn - ewarn "You must edit /etc/mail/aliases to suit your needs" - ewarn "and then run /usr/bin/newaliases. Postfix will not" - ewarn "work correctly without it." - ewarn - fi - - # check and fix file permissions - "${EROOT}"/usr/sbin/postfix set-permissions - - # configure tls - if use ssl ; then - if "${EROOT}"/usr/sbin/postfix tls all-default-client; then - elog "To configure client side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-client - fi - if "${EROOT}"/usr/sbin/postfix tls all-default-server; then - elog "To configure server side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-server - fi - fi -} diff --git a/mail-mta/postfix/postfix-3.8_pre20220220-r1.ebuild b/mail-mta/postfix/postfix-3.8_pre20220220-r1.ebuild new file mode 100644 index 000000000000..8c42346cf6f5 --- /dev/null +++ b/mail-mta/postfix/postfix-3.8_pre20220220-r1.ebuild @@ -0,0 +1,294 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit pam systemd toolchain-funcs + +MY_PV="${PV/_pre/-}" +MY_SRC="${PN}-${MY_PV}" +MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/experimental" +RC_VER="2.7" + +DESCRIPTION="A fast and secure drop-in replacement for sendmail" +HOMEPAGE="http://www.postfix.org/" +SRC_URI="${MY_URI}/${MY_SRC}.tar.gz" + +LICENSE="|| ( IBM EPL-2.0 )" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86" +IUSE="+berkdb cdb dovecot-sasl +eai ldap ldap-bind lmdb mbox memcached mysql nis pam postgres sasl selinux sqlite ssl" + +DEPEND=" + acct-group/postfix + acct-group/postdrop + acct-user/postfix + || ( dev-libs/libpcre2:0 dev-libs/libpcre ) + dev-lang/perl + berkdb? ( >=sys-libs/db-3.2:* ) + cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) ) + eai? ( dev-libs/icu:= ) + ldap? ( net-nds/openldap:= ) + ldap-bind? ( net-nds/openldap:=[sasl] ) + lmdb? ( >=dev-db/lmdb-0.9.11:= ) + mysql? ( dev-db/mysql-connector-c:0= ) + nis? ( net-libs/libnsl:= ) + pam? ( sys-libs/pam ) + postgres? ( dev-db/postgresql:* ) + sasl? ( >=dev-libs/cyrus-sasl-2 ) + sqlite? ( dev-db/sqlite:3 ) + ssl? ( >=dev-libs/openssl-1.1.1:0= ) + " + +RDEPEND="${DEPEND} + memcached? ( net-misc/memcached ) + net-mail/mailbase + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/exim + !mail-mta/msmtp[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/sendmail + !mail-mta/opensmtpd + !mail-mta/ssmtp[mta] + selinux? ( sec-policy/selinux-postfix )" + +REQUIRED_USE="ldap-bind? ( ldap sasl )" + +S="${WORKDIR}/${MY_SRC}" + +src_prepare() { + default + sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ + src/util/sys_defs.h || die "sed failed" + # change default paths to better comply with portage standard paths + sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" +} + +src_configure() { + for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE + do + local AUXLIBS_${name}="" + done + + # Make sure LDFLAGS get passed down to the executables. + local mycc="" mylibs="${LDFLAGS} -ldl" + + # libpcre is EOL. prefer libpcre2 + if has_version dev-libs/libpcre2; then + mycc="-DHAS_PCRE=2" + AUXLIBS_PCRE="$(pcre2-config --libs8)" + else + mycc="-DHAS_PCRE=1" + AUXLIBS_PCRE="$(pcre-config --libs)" + fi + + use pam && mylibs="${mylibs} -lpam" + + if use ldap; then + mycc="${mycc} -DHAS_LDAP" + AUXLIBS_LDAP="-lldap -llber" + fi + + if use mysql; then + mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)" + AUXLIBS_MYSQL="$(mysql_config --libs)" + fi + + if use postgres; then + mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" + AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq" + fi + + if use sqlite; then + mycc="${mycc} -DHAS_SQLITE" + AUXLIBS_SQLITE="-lsqlite3 -lpthread" + fi + + if use ssl; then + mycc="${mycc} -DUSE_TLS" + mylibs="${mylibs} -lssl -lcrypto" + fi + + if use lmdb; then + mycc="${mycc} -DHAS_LMDB" + AUXLIBS_LMDB="-llmdb -lpthread" + fi + + if ! use eai; then + mycc="${mycc} -DNO_EAI" + fi + + # broken. and "in other words, not supported" by upstream. + # Use inet_protocols setting in main.cf + #if ! use ipv6; then + # mycc="${mycc} -DNO_IPV6" + #fi + + if use sasl; then + if use dovecot-sasl; then + # Set dovecot as default. + mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" + fi + if use ldap-bind; then + mycc="${mycc} -DUSE_LDAP_SASL" + fi + mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" + mylibs="${mylibs} -lsasl2" + elif use dovecot-sasl; then + mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" + fi + + if ! use nis; then + mycc="${mycc} -DNO_NIS" + fi + + if ! use berkdb; then + mycc="${mycc} -DNO_DB" + # change default database type + if use cdb; then + mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\"" + elif use lmdb; then + mycc="${mycc} -DDEF_DB_TYPE=\\\"lmdb\\\"" + fi + fi + + if use cdb; then + mycc="${mycc} -DHAS_CDB -I/usr/include/cdb" + # Tinycdb is preferred. + if has_version dev-db/tinycdb ; then + AUXLIBS_CDB="-lcdb" + else + CDB_PATH="/usr/$(get_libdir)" + for i in cdb.a alloc.a buffer.a unix.a byte.a ; do + AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}" + done + fi + fi + + sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs + sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs + + emake makefiles shared=yes dynamicmaps=no pie=yes \ + shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \ + DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ + AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \ + AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \ + AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \ + AUXLIBS_SQLITE="${AUXLIBS_SQLITE}" +} + +src_install() { + LD_LIBRARY_PATH="${S}/lib" \ + /bin/sh postfix-install \ + -non-interactive \ + install_root="${D}" \ + config_directory="/etc/postfix" \ + manpage_directory="/usr/share/man" \ + command_directory="/usr/sbin" \ + mailq_path="/usr/bin/mailq" \ + newaliases_path="/usr/bin/newaliases" \ + sendmail_path="/usr/sbin/sendmail" \ + || die "postfix-install failed" + + # Fix spool removal on upgrade + rm -Rf "${D}"/var + keepdir /var/spool/postfix + + # Install rmail for UUCP, closes bug #19127 + dobin auxiliary/rmail/rmail + + # Provide another link for legacy FSH + dosym ../sbin/sendmail /usr/$(get_libdir)/sendmail + + # Install qshape, posttls-finger, collate and tlstype + dobin auxiliary/qshape/qshape.pl + doman man/man1/qshape.1 + dobin bin/posttls-finger + doman man/man1/posttls-finger.1 + dobin auxiliary/collate/collate.pl + newdoc auxiliary/collate/README README.collate + dobin auxiliary/collate/tlstype.pl + dodoc auxiliary/collate/README.tlstype + + # Performance tuning tools and their manuals + dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink} + doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1 + + # Set proper permissions on required files/directories + keepdir /var/lib/postfix + fowners -R postfix:postfix /var/lib/postfix + fperms 0750 /var/lib/postfix + fowners root:postdrop /usr/sbin/post{drop,queue,log} + fperms 02755 /usr/sbin/post{drop,queue,log} + + keepdir /etc/postfix + keepdir /etc/postfix/postfix-files.d + if use mbox; then + mypostconf="mail_spool_directory=/var/spool/mail" + else + mypostconf="home_mailbox=.maildir/" + fi + LD_LIBRARY_PATH="${S}/lib" \ + "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \ + -e ${mypostconf} || die "postconf failed" + + insinto /etc/postfix + newins "${FILESDIR}"/smtp.pass saslpass + fperms 600 /etc/postfix/saslpass + + newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix + # do not start mysql/postgres unnecessarily - bug #359913 + use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" + use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" + + dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES* + dodoc -r README_FILES/ examples/ + # postfix set-permissions expects uncompressed man files + docompress -x /usr/share/man + + if use pam; then + pamd_mimic_system smtp auth account + fi + + if use sasl; then + insinto /etc/sasl2 + newins "${FILESDIR}"/smtp.sasl smtpd.conf + fi + + # header files + insinto /usr/include/postfix + doins include/*.h + + if has_version mail-mta/postfix; then + # let the sysadmin decide when to change the compatibility_level + sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die + fi + + systemd_dounit "${FILESDIR}/${PN}.service" +} + +pkg_postinst() { + if [[ ! -e /etc/mail/aliases.db ]] ; then + ewarn + ewarn "You must edit /etc/mail/aliases to suit your needs" + ewarn "and then run /usr/bin/newaliases. Postfix will not" + ewarn "work correctly without it." + ewarn + fi + + # check and fix file permissions + "${EROOT}"/usr/sbin/postfix set-permissions + + # configure tls + if use ssl ; then + if "${EROOT}"/usr/sbin/postfix tls all-default-client; then + elog "To configure client side TLS settings:" + elog "${EROOT}"/usr/sbin/postfix tls enable-client + fi + if "${EROOT}"/usr/sbin/postfix tls all-default-server; then + elog "To configure server side TLS settings:" + elog "${EROOT}"/usr/sbin/postfix tls enable-server + fi + fi +} diff --git a/mail-mta/postfix/postfix-3.8_pre20220220.ebuild b/mail-mta/postfix/postfix-3.8_pre20220220.ebuild deleted file mode 100644 index 27dc0dccf2ae..000000000000 --- a/mail-mta/postfix/postfix-3.8_pre20220220.ebuild +++ /dev/null @@ -1,294 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 -inherit pam systemd toolchain-funcs - -MY_PV="${PV/_pre/-}" -MY_SRC="${PN}-${MY_PV}" -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/experimental" -RC_VER="2.7" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail" -HOMEPAGE="http://www.postfix.org/" -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz" - -LICENSE="|| ( IBM EPL-2.0 )" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86" -IUSE="+berkdb cdb dovecot-sasl +eai ldap ldap-bind lmdb mbox memcached mysql nis pam postgres sasl selinux sqlite ssl" - -DEPEND=" - acct-group/postfix - acct-group/postdrop - acct-user/postfix - || ( dev-libs/libpcre2:0 dev-libs/libpcre ) - dev-lang/perl - berkdb? ( >=sys-libs/db-3.2:* ) - cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) ) - eai? ( dev-libs/icu:= ) - ldap? ( net-nds/openldap ) - ldap-bind? ( net-nds/openldap[sasl] ) - lmdb? ( >=dev-db/lmdb-0.9.11:= ) - mysql? ( dev-db/mysql-connector-c:0= ) - nis? ( net-libs/libnsl:= ) - pam? ( sys-libs/pam ) - postgres? ( dev-db/postgresql:* ) - sasl? ( >=dev-libs/cyrus-sasl-2 ) - sqlite? ( dev-db/sqlite:3 ) - ssl? ( >=dev-libs/openssl-1.1.1:0= ) - " - -RDEPEND="${DEPEND} - memcached? ( net-misc/memcached ) - net-mail/mailbase - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/msmtp[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/sendmail - !mail-mta/opensmtpd - !mail-mta/ssmtp[mta] - selinux? ( sec-policy/selinux-postfix )" - -REQUIRED_USE="ldap-bind? ( ldap sasl )" - -S="${WORKDIR}/${MY_SRC}" - -src_prepare() { - default - sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - # change default paths to better comply with portage standard paths - sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" -} - -src_configure() { - for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE - do - local AUXLIBS_${name}="" - done - - # Make sure LDFLAGS get passed down to the executables. - local mycc="" mylibs="${LDFLAGS} -ldl" - - # libpcre is EOL. prefer libpcre2 - if has_version dev-libs/libpcre2; then - mycc="-DHAS_PCRE=2" - AUXLIBS_PCRE="$(pcre2-config --libs8)" - else - mycc="-DHAS_PCRE=1" - AUXLIBS_PCRE="$(pcre-config --libs)" - fi - - use pam && mylibs="${mylibs} -lpam" - - if use ldap; then - mycc="${mycc} -DHAS_LDAP" - AUXLIBS_LDAP="-lldap -llber" - fi - - if use mysql; then - mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)" - AUXLIBS_MYSQL="$(mysql_config --libs)" - fi - - if use postgres; then - mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" - AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq" - fi - - if use sqlite; then - mycc="${mycc} -DHAS_SQLITE" - AUXLIBS_SQLITE="-lsqlite3 -lpthread" - fi - - if use ssl; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use lmdb; then - mycc="${mycc} -DHAS_LMDB" - AUXLIBS_LMDB="-llmdb -lpthread" - fi - - if ! use eai; then - mycc="${mycc} -DNO_EAI" - fi - - # broken. and "in other words, not supported" by upstream. - # Use inet_protocols setting in main.cf - #if ! use ipv6; then - # mycc="${mycc} -DNO_IPV6" - #fi - - if use sasl; then - if use dovecot-sasl; then - # Set dovecot as default. - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" - fi - if use ldap-bind; then - mycc="${mycc} -DUSE_LDAP_SASL" - fi - mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - elif use dovecot-sasl; then - mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" - fi - - if ! use nis; then - mycc="${mycc} -DNO_NIS" - fi - - if ! use berkdb; then - mycc="${mycc} -DNO_DB" - # change default database type - if use cdb; then - mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\"" - elif use lmdb; then - mycc="${mycc} -DDEF_DB_TYPE=\\\"lmdb\\\"" - fi - fi - - if use cdb; then - mycc="${mycc} -DHAS_CDB -I/usr/include/cdb" - # Tinycdb is preferred. - if has_version dev-db/tinycdb ; then - AUXLIBS_CDB="-lcdb" - else - CDB_PATH="/usr/$(get_libdir)" - for i in cdb.a alloc.a buffer.a unix.a byte.a ; do - AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}" - done - fi - fi - - sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs - sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs - - emake makefiles shared=yes dynamicmaps=no pie=yes \ - shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \ - DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \ - AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \ - AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \ - AUXLIBS_SQLITE="${AUXLIBS_SQLITE}" -} - -src_install() { - LD_LIBRARY_PATH="${S}/lib" \ - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/etc/postfix" \ - manpage_directory="/usr/share/man" \ - command_directory="/usr/sbin" \ - mailq_path="/usr/bin/mailq" \ - newaliases_path="/usr/bin/newaliases" \ - sendmail_path="/usr/sbin/sendmail" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade - rm -Rf "${D}"/var - keepdir /var/spool/postfix - - # Install rmail for UUCP, closes bug #19127 - dobin auxiliary/rmail/rmail - - # Provide another link for legacy FSH - dosym ../sbin/sendmail /usr/$(get_libdir)/sendmail - - # Install qshape, posttls-finger, collate and tlstype - dobin auxiliary/qshape/qshape.pl - doman man/man1/qshape.1 - dobin bin/posttls-finger - doman man/man1/posttls-finger.1 - dobin auxiliary/collate/collate.pl - newdoc auxiliary/collate/README README.collate - dobin auxiliary/collate/tlstype.pl - dodoc auxiliary/collate/README.tlstype - - # Performance tuning tools and their manuals - dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink} - doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1 - - # Set proper permissions on required files/directories - keepdir /var/lib/postfix - fowners -R postfix:postfix /var/lib/postfix - fperms 0750 /var/lib/postfix - fowners root:postdrop /usr/sbin/post{drop,queue,log} - fperms 02755 /usr/sbin/post{drop,queue,log} - - keepdir /etc/postfix - keepdir /etc/postfix/postfix-files.d - if use mbox; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - LD_LIBRARY_PATH="${S}/lib" \ - "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \ - -e ${mypostconf} || die "postconf failed" - - insinto /etc/postfix - newins "${FILESDIR}"/smtp.pass saslpass - fperms 600 /etc/postfix/saslpass - - newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix - # do not start mysql/postgres unnecessarily - bug #359913 - use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" - use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" - - dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES* - dodoc -r README_FILES/ examples/ - # postfix set-permissions expects uncompressed man files - docompress -x /usr/share/man - - if use pam; then - pamd_mimic_system smtp auth account - fi - - if use sasl; then - insinto /etc/sasl2 - newins "${FILESDIR}"/smtp.sasl smtpd.conf - fi - - # header files - insinto /usr/include/postfix - doins include/*.h - - if has_version mail-mta/postfix; then - # let the sysadmin decide when to change the compatibility_level - sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die - fi - - systemd_dounit "${FILESDIR}/${PN}.service" -} - -pkg_postinst() { - if [[ ! -e /etc/mail/aliases.db ]] ; then - ewarn - ewarn "You must edit /etc/mail/aliases to suit your needs" - ewarn "and then run /usr/bin/newaliases. Postfix will not" - ewarn "work correctly without it." - ewarn - fi - - # check and fix file permissions - "${EROOT}"/usr/sbin/postfix set-permissions - - # configure tls - if use ssl ; then - if "${EROOT}"/usr/sbin/postfix tls all-default-client; then - elog "To configure client side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-client - fi - if "${EROOT}"/usr/sbin/postfix tls all-default-server; then - elog "To configure server side TLS settings:" - elog "${EROOT}"/usr/sbin/postfix tls enable-server - fi - fi -} diff --git a/mail-mta/sendmail/Manifest b/mail-mta/sendmail/Manifest index c2c719ef7d80..c115baa8229c 100644 --- a/mail-mta/sendmail/Manifest +++ b/mail-mta/sendmail/Manifest @@ -8,6 +8,6 @@ AUX site.config.m4 564 BLAKE2B 85bcbe7b9a26071aedf0d1b530c1276d93de21d82972add09 AUX sm-client.service 418 BLAKE2B a9057cac008c11d3cfd5a4b662cf3fc71a33be79e8890a54e556a258b098ceccc2e9941f62dce868498751bd22f23f45289bc84a8250020b140acbd2b6508b58 SHA512 26e5a64790fd7106e45de0f4dfafb3b648094953bd1831a223ca7c60b7cb75b673fb554b426a6aa0e7dc200a134fd042b4ecc6795641cfddd82bd04e4c7ea324 DIST sendmail.8.16.1.tar.gz 2236402 BLAKE2B 80a9c2f1d04719099703e55f0a0c54fd638cf69b72839d358ae6863c95c9e0965d1b7fdd5b1807bec1ffdf87bca0c7c9ba91060962e6de5da5bf14422f6279ea SHA512 d7d4aac3c6d7505782abdb166204901b8b51cac000d610dfe40eda9eef7441a073af9e8e0b14c8719b07b445f55a1e2c28ac63d663d0daa7f1eafc5a101788b2 DIST sendmail.8.17.1.tar.gz 2284027 BLAKE2B 4cbbc2bb536a48ea27994721e9dfefff7739ef1c825bbc0397202e600d8dad8f9a2572a777204693cf9630f767865d50566f0827be6b52be41c1e25532cb394c SHA512 ae42343fb06c09f2db5d919d602afc4241914387dfdae0f15e0967dda3be25bf1d3a4637b57266763679646a3cea6aa07e6453266fd9b7358c1a09ec2b627a15 -EBUILD sendmail-8.16.1-r1.ebuild 6145 BLAKE2B 2658a8af147a832ad5c557b014211a75acff24c13b6053490435e5694284feedd6850bf8072eb381b69e042967ae09349e1d96cb08cbecbcabf9b5102d4e4c7a SHA512 5d6dd7fd32b0d5b3959d6e0addae86e7c06095b01af83ddebb09b93e28fc23f514697efc9056cc940bd0b62876b48ce64fe4d025f1911f878c1e6c90d3f157c9 -EBUILD sendmail-8.17.1-r1.ebuild 6190 BLAKE2B 4654ba36348d78bafb25c88d027945646412b48e8faba237e53de448a33d3b69691d3dd8da9e9c84f37b1f2511a7c5387f4b0cc1908945dc89a196f3df067ac7 SHA512 61b94e61b609a8c8e6e324960bb06adf69fa4e7f34c6001c909420994ca694dc92e3cf9bb33a507121ea7c7345c7eb75d3500114a7c57134d39e21a5b84d84ec +EBUILD sendmail-8.16.1-r2.ebuild 6147 BLAKE2B 2d54d5e075b359e16272e18e26ac54fd958af557b4df9d60fd2d9ce1c0b54d8f36d53dcfecb81937dc3aa81f03e1403f5e7ec47040c89d0b9fb085b172eb2ecb SHA512 1ab1a5df00df381269c669439b00843e363e1566bc19667a9467711a3cda90c5e7b57873aa4369e06de37447763d205b98741df3fb125b85867a6786c24d0bda +EBUILD sendmail-8.17.1-r2.ebuild 6192 BLAKE2B 3b2f1e24ab16b21147c4156fdd4c34401fd7e40f7ea970da24ed6eba367263cc0982e56a2272b33b0e88047fdcd6e01f667c7cd6f157606e03304ce29c26502c SHA512 57741cf33a4a61b843ec8a180ff4391881392f66be0138110b23cc3e0f42cf40cbd0e09b568b02f5a3d7f093677f502ca9ebdd49eb65d317ad864514ffd20633 MISC metadata.xml 168 BLAKE2B 2e0e000b4c3b6ca04c12903fdbe278415c05a822623c52e9aa95cbbf3d50bcb1246b7edbda7d2f6b559af8950c6374e6e0a69b76319964cfe686bf50b0604a57 SHA512 4dcf45d1809e8390a2d8155c8ebfe0dd610203e392aeab0ccd8a10f42cc8532a4925eff32b35e7a6c35598a4efd288229034ec0732299dbd8cfa0acff705fed3 diff --git a/mail-mta/sendmail/sendmail-8.16.1-r1.ebuild b/mail-mta/sendmail/sendmail-8.16.1-r1.ebuild deleted file mode 100644 index 6b50939abeb1..000000000000 --- a/mail-mta/sendmail/sendmail-8.16.1-r1.ebuild +++ /dev/null @@ -1,206 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -# Note: please bump this together with mail-filter/libmilter - -inherit systemd toolchain-funcs - -DESCRIPTION="Widely-used Mail Transport Agent (MTA)" -HOMEPAGE="https://www.sendmail.org/" -SRC_URI="ftp://ftp.sendmail.org/pub/${PN}/${PN}.${PV}.tar.gz" - -LICENSE="Sendmail GPL-2" # GPL-2 is here for initscript -SLOT="0" -KEYWORDS="~alpha amd64 arm hppa ~ia64 ppc ppc64 ~riscv sparc x86" -IUSE="ipv6 ldap mbox nis sasl sockets ssl tcpd" - -BDEPEND=" - sys-devel/m4 - virtual/pkgconfig" -DEPEND=" - acct-group/smmsp - >=acct-user/smmsp-0-r2 - net-mail/mailbase - >=sys-libs/db-3.2:= - ldap? ( net-nds/openldap ) - nis? ( net-libs/libnsl:= ) - sasl? ( >=dev-libs/cyrus-sasl-2.1.10 ) - ssl? ( dev-libs/openssl:0= ) - tcpd? ( sys-apps/tcp-wrappers )" -RDEPEND=" - ${DEPEND} - >=mail-filter/libmilter-1.0.2_p1-r1 - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/mini-qmail - !mail-mta/msmtp[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/opensmtpd - !mail-mta/postfix - !mail-mta/qmail-ldap - !>=mail-mta/ssmtp-2.64-r2[mta] - !net-mail/vacation" -PDEPEND="!mbox? ( mail-filter/procmail )" - -src_prepare() { - eapply "${FILESDIR}"/${PN}-8.16.1-build-system.patch - eapply -p0 "${FILESDIR}"/${PN}-delivered_hdr.patch - eapply_user - - local confCCOPTS="${CFLAGS}" - local confENVDEF="-DMAXDAEMONS=64 -DHAS_GETHOSTBYNAME2=1" - local confLDOPTS="${LDFLAGS}" - local confLIBS= - local confMAPDEF="-DMAP_REGEX" - local conf_sendmail_LIBS= - - if use ldap; then - confMAPDEF+=" -DLDAPMAP" - confLIBS+=" -lldap -llber" - fi - - if use sasl; then - confCCOPTS+=" $($(tc-getPKG_CONFIG) --cflags libsasl2)" - confENVDEF+=" -DSASL=2" - conf_sendmail_LIBS+=" $($(tc-getPKG_CONFIG) --libs libsasl2)" - fi - - if use ssl; then - # Bug #542370 - lets add support for modern crypto (PFS) - confCCOPTS+=" $($(tc-getPKG_CONFIG) --cflags openssl)" - confENVDEF+=" -DSTARTTLS -D_FFR_DEAL_WITH_ERROR_SSL" - confENVDEF+=" -D_FFR_TLS_1 -D_FFR_TLS_EC" - conf_sendmail_LIBS+=" $($(tc-getPKG_CONFIG) --libs openssl)" - fi - - if use tcpd; then - confENVDEF+=" -DTCPWRAPPERS" - confLIBS+=" -lwrap" - fi - - use ipv6 && confENVDEF+=" -DNETINET6" - use nis && confENVDEF+=" -DNIS" - use sockets && confENVDEF+=" -DSOCKETMAP" - - sed -e "s|@@confCC@@|$(tc-getCC)|" \ - -e "s|@@confCCOPTS@@|${confCCOPTS}|" \ - -e "s|@@confENVDEF@@|${confENVDEF}|" \ - -e "s|@@confLDOPTS@@|${confLDOPTS}|" \ - -e "s|@@confLIBS@@|${confLIBS}|" \ - -e "s|@@confMAPDEF@@|${confMAPDEF}|" \ - -e "s|@@conf_sendmail_LIBS@@|${conf_sendmail_LIBS}|" \ - "${FILESDIR}"/site.config.m4 > devtools/Site/site.config.m4 \ - || die "failed to generate site.config.m4" - - echo "APPENDDEF(\`confLIBDIRS', \`-L${EPREFIX}/usr/$(get_libdir)')" \ - >> devtools/Site/site.config.m4 || die "failed adding to site.config.m4" -} - -src_compile() { - sh Build AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" || die "compilation failed in main build script" -} - -src_install() { - dodir /usr/{bin,$(get_libdir)} - dodir /usr/share/man/man{1,5,8} /usr/sbin /usr/share/sendmail-cf - dodir /var/spool/{mqueue,clientmqueue} /etc/conf.d - - keepdir /var/spool/{clientmqueue,mqueue} - - local emakeargs=( - DESTDIR="${D}" LIBDIR="/usr/$(get_libdir)" - MANROOT=/usr/share/man/man - SBINOWN=root SBINGRP=root UBINOWN=root UBINGRP=root - MANOWN=root MANGRP=root INCOWN=root INCGRP=root - LIBOWN=root LIBGRP=root GBINOWN=root GBINGRP=root - MSPQOWN=root CFOWN=root CFGRP=root - ) - - local dir - for dir in libsmutil sendmail mailstats praliases smrsh makemap vacation editmap; do - emake -j1 -C obj.*/${dir} "${emakeargs[@]}" install - done - for dir in rmail mail.local; do - emake -j1 -C obj.*/${dir} "${emakeargs[@]}" force-install - done - - fowners root:smmsp /usr/sbin/sendmail - fperms 2555 /usr/sbin/sendmail - fowners smmsp:smmsp /var/spool/clientmqueue - fperms 770 /var/spool/clientmqueue - fperms 700 /var/spool/mqueue - dosym ../sbin/makemap /usr/bin/makemap - dodoc FAQ KNOWNBUGS README RELEASE_NOTES doc/op/op.ps - - dodoc sendmail/{SECURITY,TUNING} - newdoc sendmail/README README.sendmail - newdoc smrsh/README README.smrsh - - newdoc cf/README README.cf - newdoc cf/cf/README README.install-cf - - dodoc -r contrib - - cp -pPR cf/. "${ED}"/usr/share/sendmail-cf || die - - insinto /etc/mail - if use mbox; then - newins "${FILESDIR}"/sendmail.mc-r1 sendmail.mc - else - newins "${FILESDIR}"/sendmail-procmail.mc sendmail.mc - fi - - # See discussion on bug #730890 - m4 "${ED}"/usr/share/sendmail-cf/m4/cf.m4 \ - <(grep -v "${EPREFIX}"/usr/share/sendmail-cf/m4/cf.m4 "${ED}"/etc/mail/sendmail.mc) \ - > "${ED}"/etc/mail/sendmail.cf || die "cf.m4 failed" - - echo "include(\`/usr/share/sendmail-cf/m4/cf.m4')dnl" \ - > "${ED}"/etc/mail/submit.mc || die "submit.mc echo failed" - - cat "${ED}"/usr/share/sendmail-cf/cf/submit.mc \ - >> "${ED}"/etc/mail/submit.mc || die "submit.mc cat failed" - - echo "# local-host-names - include all aliases for your machine here" \ - > "${ED}"/etc/mail/local-host-names || die "local-host-names echo failed" - - cat <<- EOF > "${ED}"/etc/mail/trusted-users || die "trusted-users cat failed" - # trusted-users - users that can send mail as others without a warning - # apache, mailman, majordomo, uucp are good candidates - EOF - - cat <<- EOF > "${ED}"/etc/mail/access || die "access cat failed" - # Check the /usr/share/doc/sendmail/README.cf file for a description - # of the format of this file. (search for access_db in that file) - # The /usr/share/doc/sendmail/README.cf is part of the sendmail-doc - # package. - # - - EOF - - cat <<- EOF > "${ED}"/etc/conf.d/sendmail || die "sendmail cat failed" - # Config file for /etc/init.d/sendmail - # add start-up options here - SENDMAIL_OPTS="-bd -q30m -L sm-mta" # default daemon mode - CLIENTMQUEUE_OPTS="-Ac -q30m -L sm-cm" # clientmqueue - KILL_OPTS="" # add -9/-15/your favorite evil SIG level here - - EOF - - if use sasl; then - dodir /etc/sasl2 - cat <<- EOF > "${ED}"/etc/sasl2/Sendmail.conf || die "Sendmail.conf cat ailed" - pwcheck_method: saslauthd - mech_list: PLAIN LOGIN - - EOF - fi - - doinitd "${FILESDIR}"/sendmail - systemd_dounit "${FILESDIR}"/sendmail.service - systemd_dounit "${FILESDIR}"/sm-client.service -} diff --git a/mail-mta/sendmail/sendmail-8.16.1-r2.ebuild b/mail-mta/sendmail/sendmail-8.16.1-r2.ebuild new file mode 100644 index 000000000000..1dee86100cb7 --- /dev/null +++ b/mail-mta/sendmail/sendmail-8.16.1-r2.ebuild @@ -0,0 +1,206 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +# Note: please bump this together with mail-filter/libmilter + +inherit systemd toolchain-funcs + +DESCRIPTION="Widely-used Mail Transport Agent (MTA)" +HOMEPAGE="https://www.sendmail.org/" +SRC_URI="ftp://ftp.sendmail.org/pub/${PN}/${PN}.${PV}.tar.gz" + +LICENSE="Sendmail GPL-2" # GPL-2 is here for initscript +SLOT="0" +KEYWORDS="~alpha amd64 arm hppa ~ia64 ppc ppc64 ~riscv sparc x86" +IUSE="ipv6 ldap mbox nis sasl sockets ssl tcpd" + +BDEPEND=" + sys-devel/m4 + virtual/pkgconfig" +DEPEND=" + acct-group/smmsp + >=acct-user/smmsp-0-r2 + net-mail/mailbase + >=sys-libs/db-3.2:= + ldap? ( net-nds/openldap:= ) + nis? ( net-libs/libnsl:= ) + sasl? ( >=dev-libs/cyrus-sasl-2.1.10 ) + ssl? ( dev-libs/openssl:0= ) + tcpd? ( sys-apps/tcp-wrappers )" +RDEPEND=" + ${DEPEND} + >=mail-filter/libmilter-1.0.2_p1-r1 + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/exim + !mail-mta/mini-qmail + !mail-mta/msmtp[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/opensmtpd + !mail-mta/postfix + !mail-mta/qmail-ldap + !>=mail-mta/ssmtp-2.64-r2[mta] + !net-mail/vacation" +PDEPEND="!mbox? ( mail-filter/procmail )" + +src_prepare() { + eapply "${FILESDIR}"/${PN}-8.16.1-build-system.patch + eapply -p0 "${FILESDIR}"/${PN}-delivered_hdr.patch + eapply_user + + local confCCOPTS="${CFLAGS}" + local confENVDEF="-DMAXDAEMONS=64 -DHAS_GETHOSTBYNAME2=1" + local confLDOPTS="${LDFLAGS}" + local confLIBS= + local confMAPDEF="-DMAP_REGEX" + local conf_sendmail_LIBS= + + if use ldap; then + confMAPDEF+=" -DLDAPMAP" + confLIBS+=" -lldap -llber" + fi + + if use sasl; then + confCCOPTS+=" $($(tc-getPKG_CONFIG) --cflags libsasl2)" + confENVDEF+=" -DSASL=2" + conf_sendmail_LIBS+=" $($(tc-getPKG_CONFIG) --libs libsasl2)" + fi + + if use ssl; then + # Bug #542370 - lets add support for modern crypto (PFS) + confCCOPTS+=" $($(tc-getPKG_CONFIG) --cflags openssl)" + confENVDEF+=" -DSTARTTLS -D_FFR_DEAL_WITH_ERROR_SSL" + confENVDEF+=" -D_FFR_TLS_1 -D_FFR_TLS_EC" + conf_sendmail_LIBS+=" $($(tc-getPKG_CONFIG) --libs openssl)" + fi + + if use tcpd; then + confENVDEF+=" -DTCPWRAPPERS" + confLIBS+=" -lwrap" + fi + + use ipv6 && confENVDEF+=" -DNETINET6" + use nis && confENVDEF+=" -DNIS" + use sockets && confENVDEF+=" -DSOCKETMAP" + + sed -e "s|@@confCC@@|$(tc-getCC)|" \ + -e "s|@@confCCOPTS@@|${confCCOPTS}|" \ + -e "s|@@confENVDEF@@|${confENVDEF}|" \ + -e "s|@@confLDOPTS@@|${confLDOPTS}|" \ + -e "s|@@confLIBS@@|${confLIBS}|" \ + -e "s|@@confMAPDEF@@|${confMAPDEF}|" \ + -e "s|@@conf_sendmail_LIBS@@|${conf_sendmail_LIBS}|" \ + "${FILESDIR}"/site.config.m4 > devtools/Site/site.config.m4 \ + || die "failed to generate site.config.m4" + + echo "APPENDDEF(\`confLIBDIRS', \`-L${EPREFIX}/usr/$(get_libdir)')" \ + >> devtools/Site/site.config.m4 || die "failed adding to site.config.m4" +} + +src_compile() { + sh Build AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" || die "compilation failed in main build script" +} + +src_install() { + dodir /usr/{bin,$(get_libdir)} + dodir /usr/share/man/man{1,5,8} /usr/sbin /usr/share/sendmail-cf + dodir /var/spool/{mqueue,clientmqueue} /etc/conf.d + + keepdir /var/spool/{clientmqueue,mqueue} + + local emakeargs=( + DESTDIR="${D}" LIBDIR="/usr/$(get_libdir)" + MANROOT=/usr/share/man/man + SBINOWN=root SBINGRP=root UBINOWN=root UBINGRP=root + MANOWN=root MANGRP=root INCOWN=root INCGRP=root + LIBOWN=root LIBGRP=root GBINOWN=root GBINGRP=root + MSPQOWN=root CFOWN=root CFGRP=root + ) + + local dir + for dir in libsmutil sendmail mailstats praliases smrsh makemap vacation editmap; do + emake -j1 -C obj.*/${dir} "${emakeargs[@]}" install + done + for dir in rmail mail.local; do + emake -j1 -C obj.*/${dir} "${emakeargs[@]}" force-install + done + + fowners root:smmsp /usr/sbin/sendmail + fperms 2555 /usr/sbin/sendmail + fowners smmsp:smmsp /var/spool/clientmqueue + fperms 770 /var/spool/clientmqueue + fperms 700 /var/spool/mqueue + dosym ../sbin/makemap /usr/bin/makemap + dodoc FAQ KNOWNBUGS README RELEASE_NOTES doc/op/op.ps + + dodoc sendmail/{SECURITY,TUNING} + newdoc sendmail/README README.sendmail + newdoc smrsh/README README.smrsh + + newdoc cf/README README.cf + newdoc cf/cf/README README.install-cf + + dodoc -r contrib + + cp -pPR cf/. "${ED}"/usr/share/sendmail-cf || die + + insinto /etc/mail + if use mbox; then + newins "${FILESDIR}"/sendmail.mc-r1 sendmail.mc + else + newins "${FILESDIR}"/sendmail-procmail.mc sendmail.mc + fi + + # See discussion on bug #730890 + m4 "${ED}"/usr/share/sendmail-cf/m4/cf.m4 \ + <(grep -v "${EPREFIX}"/usr/share/sendmail-cf/m4/cf.m4 "${ED}"/etc/mail/sendmail.mc) \ + > "${ED}"/etc/mail/sendmail.cf || die "cf.m4 failed" + + echo "include(\`/usr/share/sendmail-cf/m4/cf.m4')dnl" \ + > "${ED}"/etc/mail/submit.mc || die "submit.mc echo failed" + + cat "${ED}"/usr/share/sendmail-cf/cf/submit.mc \ + >> "${ED}"/etc/mail/submit.mc || die "submit.mc cat failed" + + echo "# local-host-names - include all aliases for your machine here" \ + > "${ED}"/etc/mail/local-host-names || die "local-host-names echo failed" + + cat <<- EOF > "${ED}"/etc/mail/trusted-users || die "trusted-users cat failed" + # trusted-users - users that can send mail as others without a warning + # apache, mailman, majordomo, uucp are good candidates + EOF + + cat <<- EOF > "${ED}"/etc/mail/access || die "access cat failed" + # Check the /usr/share/doc/sendmail/README.cf file for a description + # of the format of this file. (search for access_db in that file) + # The /usr/share/doc/sendmail/README.cf is part of the sendmail-doc + # package. + # + + EOF + + cat <<- EOF > "${ED}"/etc/conf.d/sendmail || die "sendmail cat failed" + # Config file for /etc/init.d/sendmail + # add start-up options here + SENDMAIL_OPTS="-bd -q30m -L sm-mta" # default daemon mode + CLIENTMQUEUE_OPTS="-Ac -q30m -L sm-cm" # clientmqueue + KILL_OPTS="" # add -9/-15/your favorite evil SIG level here + + EOF + + if use sasl; then + dodir /etc/sasl2 + cat <<- EOF > "${ED}"/etc/sasl2/Sendmail.conf || die "Sendmail.conf cat ailed" + pwcheck_method: saslauthd + mech_list: PLAIN LOGIN + + EOF + fi + + doinitd "${FILESDIR}"/sendmail + systemd_dounit "${FILESDIR}"/sendmail.service + systemd_dounit "${FILESDIR}"/sm-client.service +} diff --git a/mail-mta/sendmail/sendmail-8.17.1-r1.ebuild b/mail-mta/sendmail/sendmail-8.17.1-r1.ebuild deleted file mode 100644 index 2b63f6088fdf..000000000000 --- a/mail-mta/sendmail/sendmail-8.17.1-r1.ebuild +++ /dev/null @@ -1,207 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -# Note: please bump this together with mail-filter/libmilter - -inherit systemd toolchain-funcs - -DESCRIPTION="Widely-used Mail Transport Agent (MTA)" -HOMEPAGE="https://www.sendmail.org/" -SRC_URI="ftp://ftp.sendmail.org/pub/${PN}/${PN}.${PV}.tar.gz" - -LICENSE="Sendmail GPL-2" # GPL-2 is here for initscript -SLOT="0" -KEYWORDS="~alpha amd64 arm hppa ~ia64 ppc ppc64 ~riscv ~s390 sparc x86" -IUSE="ipv6 ldap mbox nis sasl sockets ssl tcpd" - -BDEPEND=" - sys-devel/m4 - virtual/pkgconfig" -DEPEND=" - acct-group/smmsp - >=acct-user/smmsp-0-r2 - net-mail/mailbase - >=sys-libs/db-3.2:= - ldap? ( net-nds/openldap ) - nis? ( net-libs/libnsl:= ) - sasl? ( >=dev-libs/cyrus-sasl-2.1.10 ) - ssl? ( dev-libs/openssl:0= ) - tcpd? ( sys-apps/tcp-wrappers )" -RDEPEND=" - ${DEPEND} - >=mail-filter/libmilter-1.0.2_p2 - !mail-mta/courier - !mail-mta/esmtp - !mail-mta/exim - !mail-mta/mini-qmail - !mail-mta/msmtp[mta] - !mail-mta/netqmail - !mail-mta/nullmailer - !mail-mta/opensmtpd - !mail-mta/postfix - !mail-mta/qmail-ldap - !>=mail-mta/ssmtp-2.64-r2[mta] - !net-mail/vacation" -PDEPEND="!mbox? ( mail-filter/procmail )" - -src_prepare() { - eapply "${FILESDIR}"/${PN}-8.16.1-build-system.patch - eapply -p0 "${FILESDIR}"/${PN}-delivered_hdr.patch - eapply_user - - local confCCOPTS="${CFLAGS}" - # See bug #808954 for FLOCK - local confENVDEF="-DMAXDAEMONS=64 -DHAS_GETHOSTBYNAME2=1 -DHASFLOCK=1" - local confLDOPTS="${LDFLAGS}" - local confLIBS= - local confMAPDEF="-DMAP_REGEX" - local conf_sendmail_LIBS= - - if use ldap; then - confMAPDEF+=" -DLDAPMAP" - confLIBS+=" -lldap -llber" - fi - - if use sasl; then - confCCOPTS+=" $($(tc-getPKG_CONFIG) --cflags libsasl2)" - confENVDEF+=" -DSASL=2" - conf_sendmail_LIBS+=" $($(tc-getPKG_CONFIG) --libs libsasl2)" - fi - - if use ssl; then - # Bug #542370 - lets add support for modern crypto (PFS) - confCCOPTS+=" $($(tc-getPKG_CONFIG) --cflags openssl)" - confENVDEF+=" -DSTARTTLS -D_FFR_DEAL_WITH_ERROR_SSL" - confENVDEF+=" -D_FFR_TLS_1 -D_FFR_TLS_EC" - conf_sendmail_LIBS+=" $($(tc-getPKG_CONFIG) --libs openssl)" - fi - - if use tcpd; then - confENVDEF+=" -DTCPWRAPPERS" - confLIBS+=" -lwrap" - fi - - use ipv6 && confENVDEF+=" -DNETINET6" - use nis && confENVDEF+=" -DNIS" - use sockets && confENVDEF+=" -DSOCKETMAP" - - sed -e "s|@@confCC@@|$(tc-getCC)|" \ - -e "s|@@confCCOPTS@@|${confCCOPTS}|" \ - -e "s|@@confENVDEF@@|${confENVDEF}|" \ - -e "s|@@confLDOPTS@@|${confLDOPTS}|" \ - -e "s|@@confLIBS@@|${confLIBS}|" \ - -e "s|@@confMAPDEF@@|${confMAPDEF}|" \ - -e "s|@@conf_sendmail_LIBS@@|${conf_sendmail_LIBS}|" \ - "${FILESDIR}"/site.config.m4 > devtools/Site/site.config.m4 \ - || die "failed to generate site.config.m4" - - echo "APPENDDEF(\`confLIBDIRS', \`-L${EPREFIX}/usr/$(get_libdir)')" \ - >> devtools/Site/site.config.m4 || die "failed adding to site.config.m4" -} - -src_compile() { - sh Build AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" || die "compilation failed in main build script" -} - -src_install() { - dodir /usr/{bin,$(get_libdir)} - dodir /usr/share/man/man{1,5,8} /usr/sbin /usr/share/sendmail-cf - dodir /var/spool/{mqueue,clientmqueue} /etc/conf.d - - keepdir /var/spool/{clientmqueue,mqueue} - - local emakeargs=( - DESTDIR="${D}" LIBDIR="/usr/$(get_libdir)" - MANROOT=/usr/share/man/man - SBINOWN=root SBINGRP=root UBINOWN=root UBINGRP=root - MANOWN=root MANGRP=root INCOWN=root INCGRP=root - LIBOWN=root LIBGRP=root GBINOWN=root GBINGRP=root - MSPQOWN=root CFOWN=root CFGRP=root - ) - - local dir - for dir in libsmutil sendmail mailstats praliases smrsh makemap vacation editmap; do - emake -j1 -C obj.*/${dir} "${emakeargs[@]}" install - done - for dir in rmail mail.local; do - emake -j1 -C obj.*/${dir} "${emakeargs[@]}" force-install - done - - fowners root:smmsp /usr/sbin/sendmail - fperms 2555 /usr/sbin/sendmail - fowners smmsp:smmsp /var/spool/clientmqueue - fperms 770 /var/spool/clientmqueue - fperms 700 /var/spool/mqueue - dosym ../sbin/makemap /usr/bin/makemap - dodoc FAQ KNOWNBUGS README RELEASE_NOTES doc/op/op.ps - - dodoc sendmail/{SECURITY,TUNING} - newdoc sendmail/README README.sendmail - newdoc smrsh/README README.smrsh - - newdoc cf/README README.cf - newdoc cf/cf/README README.install-cf - - dodoc -r contrib - - cp -pPR cf/. "${ED}"/usr/share/sendmail-cf || die - - insinto /etc/mail - if use mbox; then - newins "${FILESDIR}"/sendmail.mc-r1 sendmail.mc - else - newins "${FILESDIR}"/sendmail-procmail.mc sendmail.mc - fi - - # See discussion on bug #730890 - m4 "${ED}"/usr/share/sendmail-cf/m4/cf.m4 \ - <(grep -v "${EPREFIX}"/usr/share/sendmail-cf/m4/cf.m4 "${ED}"/etc/mail/sendmail.mc) \ - > "${ED}"/etc/mail/sendmail.cf || die "cf.m4 failed" - - echo "include(\`/usr/share/sendmail-cf/m4/cf.m4')dnl" \ - > "${ED}"/etc/mail/submit.mc || die "submit.mc echo failed" - - cat "${ED}"/usr/share/sendmail-cf/cf/submit.mc \ - >> "${ED}"/etc/mail/submit.mc || die "submit.mc cat failed" - - echo "# local-host-names - include all aliases for your machine here" \ - > "${ED}"/etc/mail/local-host-names || die "local-host-names echo failed" - - cat <<- EOF > "${ED}"/etc/mail/trusted-users || die "trusted-users cat failed" - # trusted-users - users that can send mail as others without a warning - # apache, mailman, majordomo, uucp are good candidates - EOF - - cat <<- EOF > "${ED}"/etc/mail/access || die "access cat failed" - # Check the /usr/share/doc/sendmail/README.cf file for a description - # of the format of this file. (search for access_db in that file) - # The /usr/share/doc/sendmail/README.cf is part of the sendmail-doc - # package. - # - - EOF - - cat <<- EOF > "${ED}"/etc/conf.d/sendmail || die "sendmail cat failed" - # Config file for /etc/init.d/sendmail - # add start-up options here - SENDMAIL_OPTS="-bd -q30m -L sm-mta" # default daemon mode - CLIENTMQUEUE_OPTS="-Ac -q30m -L sm-cm" # clientmqueue - KILL_OPTS="" # add -9/-15/your favorite evil SIG level here - - EOF - - if use sasl; then - dodir /etc/sasl2 - cat <<- EOF > "${ED}"/etc/sasl2/Sendmail.conf || die "Sendmail.conf cat ailed" - pwcheck_method: saslauthd - mech_list: PLAIN LOGIN - - EOF - fi - - doinitd "${FILESDIR}"/sendmail - systemd_dounit "${FILESDIR}"/sendmail.service - systemd_dounit "${FILESDIR}"/sm-client.service -} diff --git a/mail-mta/sendmail/sendmail-8.17.1-r2.ebuild b/mail-mta/sendmail/sendmail-8.17.1-r2.ebuild new file mode 100644 index 000000000000..28381d79fb26 --- /dev/null +++ b/mail-mta/sendmail/sendmail-8.17.1-r2.ebuild @@ -0,0 +1,207 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +# Note: please bump this together with mail-filter/libmilter + +inherit systemd toolchain-funcs + +DESCRIPTION="Widely-used Mail Transport Agent (MTA)" +HOMEPAGE="https://www.sendmail.org/" +SRC_URI="ftp://ftp.sendmail.org/pub/${PN}/${PN}.${PV}.tar.gz" + +LICENSE="Sendmail GPL-2" # GPL-2 is here for initscript +SLOT="0" +KEYWORDS="~alpha amd64 arm hppa ~ia64 ppc ppc64 ~riscv ~s390 sparc x86" +IUSE="ipv6 ldap mbox nis sasl sockets ssl tcpd" + +BDEPEND=" + sys-devel/m4 + virtual/pkgconfig" +DEPEND=" + acct-group/smmsp + >=acct-user/smmsp-0-r2 + net-mail/mailbase + >=sys-libs/db-3.2:= + ldap? ( net-nds/openldap:= ) + nis? ( net-libs/libnsl:= ) + sasl? ( >=dev-libs/cyrus-sasl-2.1.10 ) + ssl? ( dev-libs/openssl:0= ) + tcpd? ( sys-apps/tcp-wrappers )" +RDEPEND=" + ${DEPEND} + >=mail-filter/libmilter-1.0.2_p2 + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/exim + !mail-mta/mini-qmail + !mail-mta/msmtp[mta] + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/opensmtpd + !mail-mta/postfix + !mail-mta/qmail-ldap + !>=mail-mta/ssmtp-2.64-r2[mta] + !net-mail/vacation" +PDEPEND="!mbox? ( mail-filter/procmail )" + +src_prepare() { + eapply "${FILESDIR}"/${PN}-8.16.1-build-system.patch + eapply -p0 "${FILESDIR}"/${PN}-delivered_hdr.patch + eapply_user + + local confCCOPTS="${CFLAGS}" + # See bug #808954 for FLOCK + local confENVDEF="-DMAXDAEMONS=64 -DHAS_GETHOSTBYNAME2=1 -DHASFLOCK=1" + local confLDOPTS="${LDFLAGS}" + local confLIBS= + local confMAPDEF="-DMAP_REGEX" + local conf_sendmail_LIBS= + + if use ldap; then + confMAPDEF+=" -DLDAPMAP" + confLIBS+=" -lldap -llber" + fi + + if use sasl; then + confCCOPTS+=" $($(tc-getPKG_CONFIG) --cflags libsasl2)" + confENVDEF+=" -DSASL=2" + conf_sendmail_LIBS+=" $($(tc-getPKG_CONFIG) --libs libsasl2)" + fi + + if use ssl; then + # Bug #542370 - lets add support for modern crypto (PFS) + confCCOPTS+=" $($(tc-getPKG_CONFIG) --cflags openssl)" + confENVDEF+=" -DSTARTTLS -D_FFR_DEAL_WITH_ERROR_SSL" + confENVDEF+=" -D_FFR_TLS_1 -D_FFR_TLS_EC" + conf_sendmail_LIBS+=" $($(tc-getPKG_CONFIG) --libs openssl)" + fi + + if use tcpd; then + confENVDEF+=" -DTCPWRAPPERS" + confLIBS+=" -lwrap" + fi + + use ipv6 && confENVDEF+=" -DNETINET6" + use nis && confENVDEF+=" -DNIS" + use sockets && confENVDEF+=" -DSOCKETMAP" + + sed -e "s|@@confCC@@|$(tc-getCC)|" \ + -e "s|@@confCCOPTS@@|${confCCOPTS}|" \ + -e "s|@@confENVDEF@@|${confENVDEF}|" \ + -e "s|@@confLDOPTS@@|${confLDOPTS}|" \ + -e "s|@@confLIBS@@|${confLIBS}|" \ + -e "s|@@confMAPDEF@@|${confMAPDEF}|" \ + -e "s|@@conf_sendmail_LIBS@@|${conf_sendmail_LIBS}|" \ + "${FILESDIR}"/site.config.m4 > devtools/Site/site.config.m4 \ + || die "failed to generate site.config.m4" + + echo "APPENDDEF(\`confLIBDIRS', \`-L${EPREFIX}/usr/$(get_libdir)')" \ + >> devtools/Site/site.config.m4 || die "failed adding to site.config.m4" +} + +src_compile() { + sh Build AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" || die "compilation failed in main build script" +} + +src_install() { + dodir /usr/{bin,$(get_libdir)} + dodir /usr/share/man/man{1,5,8} /usr/sbin /usr/share/sendmail-cf + dodir /var/spool/{mqueue,clientmqueue} /etc/conf.d + + keepdir /var/spool/{clientmqueue,mqueue} + + local emakeargs=( + DESTDIR="${D}" LIBDIR="/usr/$(get_libdir)" + MANROOT=/usr/share/man/man + SBINOWN=root SBINGRP=root UBINOWN=root UBINGRP=root + MANOWN=root MANGRP=root INCOWN=root INCGRP=root + LIBOWN=root LIBGRP=root GBINOWN=root GBINGRP=root + MSPQOWN=root CFOWN=root CFGRP=root + ) + + local dir + for dir in libsmutil sendmail mailstats praliases smrsh makemap vacation editmap; do + emake -j1 -C obj.*/${dir} "${emakeargs[@]}" install + done + for dir in rmail mail.local; do + emake -j1 -C obj.*/${dir} "${emakeargs[@]}" force-install + done + + fowners root:smmsp /usr/sbin/sendmail + fperms 2555 /usr/sbin/sendmail + fowners smmsp:smmsp /var/spool/clientmqueue + fperms 770 /var/spool/clientmqueue + fperms 700 /var/spool/mqueue + dosym ../sbin/makemap /usr/bin/makemap + dodoc FAQ KNOWNBUGS README RELEASE_NOTES doc/op/op.ps + + dodoc sendmail/{SECURITY,TUNING} + newdoc sendmail/README README.sendmail + newdoc smrsh/README README.smrsh + + newdoc cf/README README.cf + newdoc cf/cf/README README.install-cf + + dodoc -r contrib + + cp -pPR cf/. "${ED}"/usr/share/sendmail-cf || die + + insinto /etc/mail + if use mbox; then + newins "${FILESDIR}"/sendmail.mc-r1 sendmail.mc + else + newins "${FILESDIR}"/sendmail-procmail.mc sendmail.mc + fi + + # See discussion on bug #730890 + m4 "${ED}"/usr/share/sendmail-cf/m4/cf.m4 \ + <(grep -v "${EPREFIX}"/usr/share/sendmail-cf/m4/cf.m4 "${ED}"/etc/mail/sendmail.mc) \ + > "${ED}"/etc/mail/sendmail.cf || die "cf.m4 failed" + + echo "include(\`/usr/share/sendmail-cf/m4/cf.m4')dnl" \ + > "${ED}"/etc/mail/submit.mc || die "submit.mc echo failed" + + cat "${ED}"/usr/share/sendmail-cf/cf/submit.mc \ + >> "${ED}"/etc/mail/submit.mc || die "submit.mc cat failed" + + echo "# local-host-names - include all aliases for your machine here" \ + > "${ED}"/etc/mail/local-host-names || die "local-host-names echo failed" + + cat <<- EOF > "${ED}"/etc/mail/trusted-users || die "trusted-users cat failed" + # trusted-users - users that can send mail as others without a warning + # apache, mailman, majordomo, uucp are good candidates + EOF + + cat <<- EOF > "${ED}"/etc/mail/access || die "access cat failed" + # Check the /usr/share/doc/sendmail/README.cf file for a description + # of the format of this file. (search for access_db in that file) + # The /usr/share/doc/sendmail/README.cf is part of the sendmail-doc + # package. + # + + EOF + + cat <<- EOF > "${ED}"/etc/conf.d/sendmail || die "sendmail cat failed" + # Config file for /etc/init.d/sendmail + # add start-up options here + SENDMAIL_OPTS="-bd -q30m -L sm-mta" # default daemon mode + CLIENTMQUEUE_OPTS="-Ac -q30m -L sm-cm" # clientmqueue + KILL_OPTS="" # add -9/-15/your favorite evil SIG level here + + EOF + + if use sasl; then + dodir /etc/sasl2 + cat <<- EOF > "${ED}"/etc/sasl2/Sendmail.conf || die "Sendmail.conf cat ailed" + pwcheck_method: saslauthd + mech_list: PLAIN LOGIN + + EOF + fi + + doinitd "${FILESDIR}"/sendmail + systemd_dounit "${FILESDIR}"/sendmail.service + systemd_dounit "${FILESDIR}"/sm-client.service +} -- cgit v1.2.3