diff options
author | Luca Longinotti <chtekk@gentoo.org> | 2007-05-12 17:27:46 +0000 |
---|---|---|
committer | Luca Longinotti <chtekk@gentoo.org> | 2007-05-12 17:27:46 +0000 |
commit | 6666c98e7f78f6c98291c92f51b53fecca4ca7b1 (patch) | |
tree | e0ac41db31adc08d711a2ab26e4c643449b9e88b /mail-mta/postfix | |
parent | x86 stable wrt #178218 (diff) | |
download | gentoo-2-6666c98e7f78f6c98291c92f51b53fecca4ca7b1.tar.gz gentoo-2-6666c98e7f78f6c98291c92f51b53fecca4ca7b1.tar.bz2 gentoo-2-6666c98e7f78f6c98291c92f51b53fecca4ca7b1.zip |
Cleanup, remove old ebuild versions and files.
(Portage version: 2.1.2.7)
Diffstat (limited to 'mail-mta/postfix')
24 files changed, 9 insertions, 3620 deletions
diff --git a/mail-mta/postfix/ChangeLog b/mail-mta/postfix/ChangeLog index 6923ebd96ca9..b0e26a200e59 100644 --- a/mail-mta/postfix/ChangeLog +++ b/mail-mta/postfix/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for mail-mta/postfix # Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/ChangeLog,v 1.127 2007/05/01 16:00:34 chtekk Exp $ +# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/ChangeLog,v 1.128 2007/05/12 17:27:45 chtekk Exp $ + + 12 May 2007; Luca Longinotti <chtekk@gentoo.org> + -files/postfix-2.3.0-SASL_README.patch, -files/postfix.rc6.2.2.4, + -files/postfix.rc6.2.2.5, -postfix-2.2.4.ebuild, -postfix-2.2.5.ebuild, + -postfix-2.2.5-r1.ebuild, -postfix-2.2.8.ebuild, -postfix-2.2.8-r1.ebuild, + -postfix-2.2.9.ebuild, -postfix-2.2.9-r1.ebuild, -postfix-2.3.7.ebuild, + -postfix-2.4.0.ebuild, -postfix-2.4.0-r1.ebuild: + Cleanup, remove old ebuild versions and files. *postfix-2.4.1 (01 May 2007) diff --git a/mail-mta/postfix/files/digest-postfix-2.2.4 b/mail-mta/postfix/files/digest-postfix-2.2.4 deleted file mode 100644 index 7ff18f15e3a5..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.2.4 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 7049364c6476edf80d6ff861ca37936f postfix-2.2.4-vda.patch.gz 7712 -RMD160 281fc48b132a5057c65b19161c98f469bd5fff49 postfix-2.2.4-vda.patch.gz 7712 -SHA256 dfa408f62769ca4d748c085556806e3e73e14b81c51559212e3db9e03021261c postfix-2.2.4-vda.patch.gz 7712 -MD5 77394db3a4ebe578fa453502040698ac postfix-2.2.4.tar.gz 2427281 -RMD160 00757574a0dc7e26ff52449d689853c9d7a338a8 postfix-2.2.4.tar.gz 2427281 -SHA256 ef6fbd3d5f9b30381efa4c089bf8e9ce99b8156e1e5bdd2cc37a38d0a97ba5e4 postfix-2.2.4.tar.gz 2427281 diff --git a/mail-mta/postfix/files/digest-postfix-2.2.5 b/mail-mta/postfix/files/digest-postfix-2.2.5 deleted file mode 100644 index 7244ac70e7ed..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.2.5 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 22c12038d355e104856a02cfcf8a31d9 postfix-2.2.5-vda.patch.gz 7744 -RMD160 ac262dabc7da4d51ed2857e37ffb9f09903d2ae5 postfix-2.2.5-vda.patch.gz 7744 -SHA256 338347da4da49f820f4fecaaf2a9f757eedfa047b2286e34ceaa380707a4846c postfix-2.2.5-vda.patch.gz 7744 -MD5 9c13d58494c64012bfd8ab0d6967305c postfix-2.2.5.tar.gz 2428594 -RMD160 5508f9662319e655daf8ec8b70fb508f0bb15bb0 postfix-2.2.5.tar.gz 2428594 -SHA256 c413000f2a99ebb8b1f5f37b2d2cc525990bef861c461f27e71bfb88ccd654c7 postfix-2.2.5.tar.gz 2428594 diff --git a/mail-mta/postfix/files/digest-postfix-2.2.5-r1 b/mail-mta/postfix/files/digest-postfix-2.2.5-r1 deleted file mode 100644 index 7244ac70e7ed..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.2.5-r1 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 22c12038d355e104856a02cfcf8a31d9 postfix-2.2.5-vda.patch.gz 7744 -RMD160 ac262dabc7da4d51ed2857e37ffb9f09903d2ae5 postfix-2.2.5-vda.patch.gz 7744 -SHA256 338347da4da49f820f4fecaaf2a9f757eedfa047b2286e34ceaa380707a4846c postfix-2.2.5-vda.patch.gz 7744 -MD5 9c13d58494c64012bfd8ab0d6967305c postfix-2.2.5.tar.gz 2428594 -RMD160 5508f9662319e655daf8ec8b70fb508f0bb15bb0 postfix-2.2.5.tar.gz 2428594 -SHA256 c413000f2a99ebb8b1f5f37b2d2cc525990bef861c461f27e71bfb88ccd654c7 postfix-2.2.5.tar.gz 2428594 diff --git a/mail-mta/postfix/files/digest-postfix-2.2.8 b/mail-mta/postfix/files/digest-postfix-2.2.8 deleted file mode 100644 index c2fad50c3ca5..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.2.8 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 50a7768db7bf7374b6e3fa24b99c19b9 postfix-2.2.8-vda.patch.gz 7741 -RMD160 c74969b300232900d816df5f5dad7e3178db43ed postfix-2.2.8-vda.patch.gz 7741 -SHA256 b325514aa1bb3f90dcc749be16f7c74d18d8ab75cee6f9b20d740dd0ce5c07ac postfix-2.2.8-vda.patch.gz 7741 -MD5 971bf94de3e8433c8965c27b42d56b9a postfix-2.2.8.tar.gz 2434615 -RMD160 449a6b417bafbcd598a96979b5de5af40b3f663e postfix-2.2.8.tar.gz 2434615 -SHA256 eb6c5aebafe873b0a9b27fc6abc38ee3fb3b51465c5d5b73318ab15bebfd216b postfix-2.2.8.tar.gz 2434615 diff --git a/mail-mta/postfix/files/digest-postfix-2.2.8-r1 b/mail-mta/postfix/files/digest-postfix-2.2.8-r1 deleted file mode 100644 index c2fad50c3ca5..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.2.8-r1 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 50a7768db7bf7374b6e3fa24b99c19b9 postfix-2.2.8-vda.patch.gz 7741 -RMD160 c74969b300232900d816df5f5dad7e3178db43ed postfix-2.2.8-vda.patch.gz 7741 -SHA256 b325514aa1bb3f90dcc749be16f7c74d18d8ab75cee6f9b20d740dd0ce5c07ac postfix-2.2.8-vda.patch.gz 7741 -MD5 971bf94de3e8433c8965c27b42d56b9a postfix-2.2.8.tar.gz 2434615 -RMD160 449a6b417bafbcd598a96979b5de5af40b3f663e postfix-2.2.8.tar.gz 2434615 -SHA256 eb6c5aebafe873b0a9b27fc6abc38ee3fb3b51465c5d5b73318ab15bebfd216b postfix-2.2.8.tar.gz 2434615 diff --git a/mail-mta/postfix/files/digest-postfix-2.2.9 b/mail-mta/postfix/files/digest-postfix-2.2.9 deleted file mode 100644 index 9a59cae3725b..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.2.9 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 50a7768db7bf7374b6e3fa24b99c19b9 postfix-2.2.8-vda.patch.gz 7741 -RMD160 c74969b300232900d816df5f5dad7e3178db43ed postfix-2.2.8-vda.patch.gz 7741 -SHA256 b325514aa1bb3f90dcc749be16f7c74d18d8ab75cee6f9b20d740dd0ce5c07ac postfix-2.2.8-vda.patch.gz 7741 -MD5 be78631bd9b6bf7735e43abfa54d69f6 postfix-2.2.9.tar.gz 2442158 -RMD160 d8da9d83156f4d26e94723398f19570121c62b23 postfix-2.2.9.tar.gz 2442158 -SHA256 47cacebab97f2659f83c4aeff5b9660505684bd7f8fb2f41628997673eb94f69 postfix-2.2.9.tar.gz 2442158 diff --git a/mail-mta/postfix/files/digest-postfix-2.2.9-r1 b/mail-mta/postfix/files/digest-postfix-2.2.9-r1 deleted file mode 100644 index 9a59cae3725b..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.2.9-r1 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 50a7768db7bf7374b6e3fa24b99c19b9 postfix-2.2.8-vda.patch.gz 7741 -RMD160 c74969b300232900d816df5f5dad7e3178db43ed postfix-2.2.8-vda.patch.gz 7741 -SHA256 b325514aa1bb3f90dcc749be16f7c74d18d8ab75cee6f9b20d740dd0ce5c07ac postfix-2.2.8-vda.patch.gz 7741 -MD5 be78631bd9b6bf7735e43abfa54d69f6 postfix-2.2.9.tar.gz 2442158 -RMD160 d8da9d83156f4d26e94723398f19570121c62b23 postfix-2.2.9.tar.gz 2442158 -SHA256 47cacebab97f2659f83c4aeff5b9660505684bd7f8fb2f41628997673eb94f69 postfix-2.2.9.tar.gz 2442158 diff --git a/mail-mta/postfix/files/digest-postfix-2.3.7 b/mail-mta/postfix/files/digest-postfix-2.3.7 deleted file mode 100644 index b809c838eb5a..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.3.7 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 3506ab432360766b6a2708042b29943a postfix-2.3.3-vda.patch.gz 7944 -RMD160 bdbd0798ca4d23c6e8443b26b957b8d0d252da1d postfix-2.3.3-vda.patch.gz 7944 -SHA256 4fdff601e0b2653025c9b9ca8875e995b8052e2e362c3a5e035c3d2859bd4fa2 postfix-2.3.3-vda.patch.gz 7944 -MD5 a3ce7f2e5d8a6f688571bb55b792b848 postfix-2.3.7.tar.gz 2785739 -RMD160 5d3c1074f2ab02fba60cc5d7251af45bb15c9068 postfix-2.3.7.tar.gz 2785739 -SHA256 5ea8f9f9b205145b23764b226eea0e4cdfd6489cd5fbacadd61580982e46538d postfix-2.3.7.tar.gz 2785739 diff --git a/mail-mta/postfix/files/digest-postfix-2.4.0 b/mail-mta/postfix/files/digest-postfix-2.4.0 deleted file mode 100644 index 6c54bb759a11..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.4.0 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 e7e1fc00b29f0d7b2d16c93626b416e9 postfix-2.4.0-vda.patch.gz 7830 -RMD160 0cfc1765b32bc894888517f6d210d2baf1615d56 postfix-2.4.0-vda.patch.gz 7830 -SHA256 ff8c79db9128be5f2347259ea46606338d3808cc5120ce45d6ef9453e04cd7e7 postfix-2.4.0-vda.patch.gz 7830 -MD5 45c56b112a6cd9ba08ac99dfd734ea9d postfix-2.4.0.tar.gz 2931537 -RMD160 00eb9e4510da1f6a0a0238417d147774deac50ce postfix-2.4.0.tar.gz 2931537 -SHA256 7cbc4d8904512ac1792193c54a2989b481e6402447b82988b6a88b8091af6bbd postfix-2.4.0.tar.gz 2931537 diff --git a/mail-mta/postfix/files/digest-postfix-2.4.0-r1 b/mail-mta/postfix/files/digest-postfix-2.4.0-r1 deleted file mode 100644 index c8e96a876133..000000000000 --- a/mail-mta/postfix/files/digest-postfix-2.4.0-r1 +++ /dev/null @@ -1,6 +0,0 @@ -MD5 48bab5796d79130e9d850ed713b3b4e1 postfix-2.4.0-vda-ng-r1.patch.gz 12015 -RMD160 8ef868bccd69e1c57c67eac524f617ca6eaffb94 postfix-2.4.0-vda-ng-r1.patch.gz 12015 -SHA256 d905ad2084d7f6e7eb831cd3d5b95386c3d78ed389e104dd8a4abc3ecb954496 postfix-2.4.0-vda-ng-r1.patch.gz 12015 -MD5 45c56b112a6cd9ba08ac99dfd734ea9d postfix-2.4.0.tar.gz 2931537 -RMD160 00eb9e4510da1f6a0a0238417d147774deac50ce postfix-2.4.0.tar.gz 2931537 -SHA256 7cbc4d8904512ac1792193c54a2989b481e6402447b82988b6a88b8091af6bbd postfix-2.4.0.tar.gz 2931537 diff --git a/mail-mta/postfix/files/postfix-2.3.0-SASL_README.patch b/mail-mta/postfix/files/postfix-2.3.0-SASL_README.patch deleted file mode 100644 index bad5a295c5f9..000000000000 --- a/mail-mta/postfix/files/postfix-2.3.0-SASL_README.patch +++ /dev/null @@ -1,61 +0,0 @@ -diff -uNr postfix-2.3.0.orig/README_FILES/SASL_README postfix-2.3.0/README_FILES/SASL_README ---- postfix-2.3.0.orig/README_FILES/SASL_README 2006-07-13 15:25:55.000000000 -0700 -+++ postfix-2.3.0/README_FILES/SASL_README 2006-07-13 16:07:33.000000000 -0700 -@@ -71,13 +71,13 @@ - To generate the necessary Makefiles, execute the following in the Postfix top- - level directory: - -- % make makefiles CCARGS='-DUSE_SASL_AUTH -DDEF_SASL_SERVER=\"dovecot\"' -+ % make makefiles CCARGS='-DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\"dovecot\"' - - After this, proceed with "make" as described in the INSTALL document. - - Notes: - -- * The "-DDEF_SASL_SERVER" stuff is not necessary; it just makes Postfix -+ * The "-DDEF_SERVER_SASL_TYPE" stuff is not necessary; it just makes Postfix - configuration a little more convenient because you don't have to specify - the SASL plug-in type in the Postfix main.cf file. - -diff -uNr postfix-2.3.0.orig/html/SASL_README.html postfix-2.3.0/html/SASL_README.html ---- postfix-2.3.0.orig/html/SASL_README.html 2006-07-13 15:25:55.000000000 -0700 -+++ postfix-2.3.0/html/SASL_README.html 2006-07-13 16:08:22.000000000 -0700 -@@ -127,7 +127,7 @@ - - <blockquote> - <pre> --% make makefiles CCARGS='-DUSE_SASL_AUTH -DDEF_SASL_SERVER=\"dovecot\"' -+% make makefiles CCARGS='-DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\"dovecot\"' - </pre> - </blockquote> - -@@ -138,7 +138,7 @@ - - <ul> - --<li> <p> The "-DDEF_SASL_SERVER" stuff is not necessary; it just -+<li> <p> The "-DDEF_SERVER_SASL_TYPE" stuff is not necessary; it just - makes Postfix configuration a little more convenient because you - don't have to specify the SASL plug-in type in the Postfix <a href="postconf.5.html">main.cf</a> - file. </p> -diff -uNr postfix-2.3.0.orig/proto/SASL_README.html postfix-2.3.0/proto/SASL_README.html ---- postfix-2.3.0.orig/proto/SASL_README.html 2006-07-13 15:25:55.000000000 -0700 -+++ postfix-2.3.0/proto/SASL_README.html 2006-07-13 16:09:11.000000000 -0700 -@@ -127,7 +127,7 @@ - - <blockquote> - <pre> --% make makefiles CCARGS='-DUSE_SASL_AUTH -DDEF_SASL_SERVER=\"dovecot\"' -+% make makefiles CCARGS='-DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\"dovecot\"' - </pre> - </blockquote> - -@@ -138,7 +138,7 @@ - - <ul> - --<li> <p> The "-DDEF_SASL_SERVER" stuff is not necessary; it just -+<li> <p> The "-DDEF_SERVER_SASL_TYPE" stuff is not necessary; it just - makes Postfix configuration a little more convenient because you - don't have to specify the SASL plug-in type in the Postfix main.cf - file. </p> diff --git a/mail-mta/postfix/files/postfix.rc6.2.2.4 b/mail-mta/postfix/files/postfix.rc6.2.2.4 deleted file mode 100644 index 06c8f6023276..000000000000 --- a/mail-mta/postfix/files/postfix.rc6.2.2.4 +++ /dev/null @@ -1,30 +0,0 @@ -#!/sbin/runscript -# Copyright 1999-2004 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/files/postfix.rc6.2.2.4,v 1.1 2005/06/29 15:12:13 langthang Exp $ - -opts="${opts} reload" - -depend() { - need net - use logger dns ypbind amavisd mysql postgresql antivirus postfix_greylist - provide mta -} - -start() { - ebegin "Starting postfix" - /usr/sbin/postfix start &>/dev/null - eend $? -} - -stop() { - ebegin "Stopping postfix" - /usr/sbin/postfix stop &>/dev/null - eend $? -} - -reload() { - ebegin "Reloading postfix" - /usr/sbin/postfix reload &>/dev/null - eend $? -} diff --git a/mail-mta/postfix/files/postfix.rc6.2.2.5 b/mail-mta/postfix/files/postfix.rc6.2.2.5 deleted file mode 100644 index 48787907becb..000000000000 --- a/mail-mta/postfix/files/postfix.rc6.2.2.5 +++ /dev/null @@ -1,29 +0,0 @@ -#!/sbin/runscript -# Copyright 1999-2004 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/files/postfix.rc6.2.2.5,v 1.1 2005/10/11 02:16:31 langthang Exp $ - -opts="${opts} reload" - -depend() { - use logger dns ypbind amavisd mysql postgresql antivirus postfix_greylist net - provide mta -} - -start() { - ebegin "Starting postfix" - /usr/sbin/postfix start &>/dev/null - eend $? -} - -stop() { - ebegin "Stopping postfix" - /usr/sbin/postfix stop &>/dev/null - eend $? -} - -reload() { - ebegin "Reloading postfix" - /usr/sbin/postfix reload &>/dev/null - eend $? -} diff --git a/mail-mta/postfix/postfix-2.2.4.ebuild b/mail-mta/postfix/postfix-2.2.4.ebuild deleted file mode 100644 index d64f096d2a76..000000000000 --- a/mail-mta/postfix/postfix-2.2.4.ebuild +++ /dev/null @@ -1,305 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.2.4.ebuild,v 1.6 2006/11/23 20:28:34 vivo Exp $ - -inherit eutils ssl-cert toolchain-funcs flag-o-matic mailer pam -IUSE="ipv6 pam ldap mysql postgres ssl sasl mbox nis vda selinux hardened" -#IUSE="ipv6 pam ldap mysql postgres ssl sasl mbox nis vda selinux hardened devel" - -MY_PV=${PV} -MY_SRC=${PN}-${MY_PV} -#DEV_SRC=${MY_SRC}-newdb-nonprod -VDA_P="${PN}-${MY_PV}-vda" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.tar.gz - vda? ( http://web.onda.com.br/nadal/postfix/VDA/${VDA_P}.patch.gz ) " -# devel? ( ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/${DEV_SRC}.tar.gz ) " - -LICENSE="IPL-1" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" - -PROVIDE="${PROVIDE} virtual/mda" -DEPEND=">=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - pam? ( virtual/pam ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - postgres? ( >=dev-db/postgresql-7.1 ) - ssl? ( >=dev-libs/openssl-0.9.6g ) - sasl? ( >=dev-libs/cyrus-sasl-2 )" -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - selinux? ( sec-policy/selinux-postfix )" - -#if use devel; then -# MY_SRC=${DEV_SRC} -#fi - -S=${WORKDIR}/${MY_SRC} - -group_user_check() { - einfo "checking for postfix group... create if missing." - enewgroup postfix 207 - einfo "checking for postdrop group... create if missing." - enewgroup postdrop 208 - einfo "checking for postfix user... create if missing." - enewuser postfix 207 -1 /var/spool/postfix postfix -} - -pkg_setup() { - # do not upgrade from postfix-2.1. logic to fix bug #53324 - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.2' ; then - if [ "${FORCE_UPGRADE}" ]; then - echo - ewarn "You are upgrading from a incompatible version and" - ewarn "you have FORCE_UPGRADE set, will build this package with postfix running." - ewarn "You MUST stop postfix BEFORE install it to your system." - echo - else - echo - eerror "You are upgrading from a incompatible version." - eerror "You MUST stop postfix BEFORE install it to your system." - eerror "If you want a minimal downtime, emerge postfix with:" - eerror "\`FORCE_UPGRADE=1 emerge --buildpkgonly postfix\`; then" - eerror "\`/etc/init.d/postfix stop && emerge --usepkgonly postfix\`" - eerror "run etc-update or dispatch-conf and merge the configuration files." - eerror "Next /etc/init.d/postfix start" - die "upgrade from an incompatible version!" - echo - fi - - else - echo - ewarn "It is safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance; please hit Ctrl+C now;" - ewarn "stop Postfix then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continue." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org\"" - ewarn "assign to \"net-mail@gentoo.org\"." - echo - #epause 5 - - # put out warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18'; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, one of the empty queue" - ewarn "directory get deleted during unmerge the older version (#45764). Please run" - ewarn "\`etc/postfix/post-install upgrade-source\` to recreate them." - echo - #epause 5 - fi - - #TLS non-prod warn - if use ssl; then - echo - ewarn "you have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service entry is incompatible with previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - #epause 5 - fi - - # IPV6 non-prod warn - if use ipv6; then - echo - ewarn "you have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - -} - -src_unpack() { - unpack ${A} && cd "${S}" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" || die "failed to patch VDA" - fi - - # Postfix does not get the FQDN if no hostname is configured. - epatch "${FILESDIR}/${PN}-2.0.9-get-FQDN.patch" || die "patch failed." - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - -} - -src_compile() { - cd ${S} - # added -Wl,-z,now wrt 62674. - local mycc="-DHAS_PCRE" mylibs="-Wl,-z,now -L/usr/lib -lpcre -ldl -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - mycc="${mycc} -DUSE_SASL_AUTH -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - fi - - if ! use nis; then - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" src/util/sys_defs.h || \ - die "sed failed" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/lib/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - ebegin "Starting make makefiles..." - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # workaround for bug #76512 - [ "$(gcc-version)" == "3.4" ] && use hardened && replace-flags -O? -Os - - make CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade. - rm -rf "${D}/var" - keepdir /var/spool/postfix - - # Install an rmail for UUCP, closing bug #19127. - dobin auxiliary/rmail/rmail - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - rm "${D}/usr/bin/mailq" "${D}/usr/bin/newaliases" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - mailer_install_conf - else - # Provide another link for legacy FSH. - dosym /usr/sbin/sendmail /usr/lib/sendmail - fi - - # Install qshape tool. - dobin auxiliary/qshape/qshape.pl - - # Set proper permissions on required files/directories. - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv ${D}/usr/share/doc/${PF}/defaults/{*.cf,post*-*} ${D}/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - - "${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.${PV}" postfix || \ - die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # do not install server.{key,pem) if they are exist. - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]]; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [ ! -e /etc/mail/aliases.db ] ; then - echo - 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." - fi - - mailer_pkg_postinst -} diff --git a/mail-mta/postfix/postfix-2.2.5-r1.ebuild b/mail-mta/postfix/postfix-2.2.5-r1.ebuild deleted file mode 100644 index 450ecb4d2962..000000000000 --- a/mail-mta/postfix/postfix-2.2.5-r1.ebuild +++ /dev/null @@ -1,306 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.2.5-r1.ebuild,v 1.4 2006/11/23 20:28:34 vivo Exp $ - -inherit eutils ssl-cert toolchain-funcs flag-o-matic mailer pam -IUSE="ipv6 pam ldap mysql postgres ssl sasl mbox nis vda selinux hardened" -#IUSE="ipv6 pam ldap mysql postgres ssl sasl mbox nis vda selinux hardened devel" - -MY_PV=${PV} -MY_SRC=${PN}-${MY_PV} -#DEV_SRC=${MY_SRC}-newdb-nonprod -VDA_P="${PN}-${MY_PV}-vda" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.tar.gz - vda? ( http://web.onda.com.br/nadal/postfix/VDA/${VDA_P}.patch.gz ) " -# devel? ( ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/${DEV_SRC}.tar.gz ) " - -LICENSE="IPL-1" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" - -PROVIDE="${PROVIDE} virtual/mda" -DEPEND=">=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - pam? ( virtual/pam ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - postgres? ( >=dev-db/postgresql-7.1 ) - ssl? ( >=dev-libs/openssl-0.9.6g ) - sasl? ( >=dev-libs/cyrus-sasl-2 )" -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - selinux? ( sec-policy/selinux-postfix )" - -#if use devel; then -# MY_SRC=${DEV_SRC} -#fi - -S=${WORKDIR}/${MY_SRC} - -group_user_check() { - einfo "checking for postfix group... create if missing." - enewgroup postfix 207 - einfo "checking for postdrop group... create if missing." - enewgroup postdrop 208 - einfo "checking for postfix user... create if missing." - enewuser postfix 207 -1 /var/spool/postfix postfix -} - -pkg_setup() { - # do not upgrade from postfix-2.1. logic to fix bug #53324 - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.2' ; then - if [ "${FORCE_UPGRADE}" ]; then - echo - ewarn "You are upgrading from a incompatible version and" - ewarn "you have FORCE_UPGRADE set, will build this package with postfix running." - ewarn "You MUST stop postfix BEFORE install it to your system." - echo - else - echo - eerror "You are upgrading from a incompatible version." - eerror "You MUST stop postfix BEFORE install it to your system." - eerror "If you want a minimal downtime, emerge postfix with:" - eerror "\`FORCE_UPGRADE=1 emerge --buildpkgonly postfix\`; then" - eerror "\`/etc/init.d/postfix stop && emerge --usepkgonly postfix\`" - eerror "run etc-update or dispatch-conf and merge the configuration files." - eerror "Next /etc/init.d/postfix start" - die "upgrade from an incompatible version!" - echo - fi - - else - echo - ewarn "It is safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance; please hit Ctrl+C now;" - ewarn "stop Postfix then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continue." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org\"" - ewarn "assign to \"net-mail@gentoo.org\"." - echo - #epause 5 - - # put out warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18'; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, one of the empty queue" - ewarn "directory get deleted during unmerge the older version (#45764). Please run" - ewarn "\`etc/postfix/post-install upgrade-source\` to recreate them." - echo - #epause 5 - fi - - #TLS non-prod warn - if use ssl; then - echo - ewarn "you have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service entry is incompatible with previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - #epause 5 - fi - - # IPV6 non-prod warn - if use ipv6; then - echo - ewarn "you have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - -} - -src_unpack() { - unpack ${A} && cd "${S}" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" - fi - - # Postfix does not get the FQDN if no hostname is configured. - epatch "${FILESDIR}/${PN}-2.0.9-get-FQDN.patch" - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - -} - -src_compile() { - cd ${S} - # added -Wl,-z,now wrt 62674. - # remove -ldl as it is not necessary, resolve bug #106446. - local mycc="-DHAS_PCRE" mylibs="-Wl,-z,now -L/usr/lib -lpcre -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - mycc="${mycc} -DUSE_SASL_AUTH -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - fi - - if ! use nis; then - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" src/util/sys_defs.h || \ - die "sed failed" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/lib/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - ebegin "Starting make makefiles..." - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # workaround for bug #76512 - [ "$(gcc-version)" == "3.4" ] && use hardened && replace-flags -O? -Os - - make CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade. - rm -rf "${D}/var" - keepdir /var/spool/postfix - - # Install an rmail for UUCP, closing bug #19127. - dobin auxiliary/rmail/rmail - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - rm "${D}/usr/bin/mailq" "${D}/usr/bin/newaliases" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - mailer_install_conf - else - # Provide another link for legacy FSH. - dosym /usr/sbin/sendmail /usr/lib/sendmail - fi - - # Install qshape tool. - dobin auxiliary/qshape/qshape.pl - - # Set proper permissions on required files/directories. - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv ${D}/usr/share/doc/${PF}/defaults/{*.cf,post*-*} ${D}/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - - "${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.${PV}" postfix || \ - die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # do not install server.{key,pem) if they are exist. - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]]; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [ ! -e /etc/mail/aliases.db ] ; then - echo - 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." - fi - - mailer_pkg_postinst -} diff --git a/mail-mta/postfix/postfix-2.2.5.ebuild b/mail-mta/postfix/postfix-2.2.5.ebuild deleted file mode 100644 index 8c1a516c7aa0..000000000000 --- a/mail-mta/postfix/postfix-2.2.5.ebuild +++ /dev/null @@ -1,316 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.2.5.ebuild,v 1.12 2006/11/23 20:28:34 vivo Exp $ - -inherit eutils ssl-cert toolchain-funcs flag-o-matic pam -IUSE="ipv6 pam ldap mysql postgres ssl sasl mailwrapper mbox nis vda selinux hardened" -#IUSE="ipv6 pam ldap mysql postgres ssl sasl mailwrapper mbox nis vda selinux hardened devel" - -MY_PV=${PV} -MY_SRC=${PN}-${MY_PV} -#DEV_SRC=${MY_SRC}-newdb-nonprod -VDA_P="${PN}-${MY_PV}-vda" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.tar.gz - vda? ( http://web.onda.com.br/nadal/postfix/VDA/${VDA_P}.patch.gz ) " -# devel? ( ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/${DEV_SRC}.tar.gz ) " - -LICENSE="IPL-1" -SLOT="0" -KEYWORDS="alpha amd64 arm hppa ia64 mips ppc ppc64 s390 sh sparc x86" - -PROVIDE="virtual/mta virtual/mda" -DEPEND=">=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - pam? ( virtual/pam ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - postgres? ( >=dev-db/postgresql-7.1 ) - ssl? ( >=dev-libs/openssl-0.9.6g ) - sasl? ( >=dev-libs/cyrus-sasl-2 )" -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - !mailwrapper? ( !virtual/mta ) - mailwrapper? ( >=net-mail/mailwrapper-0.2 ) - selinux? ( sec-policy/selinux-postfix )" - -#if use devel; then -# MY_SRC=${DEV_SRC} -#fi - -S=${WORKDIR}/${MY_SRC} - -group_user_check() { - einfo "checking for postfix group... create if missing." - enewgroup postfix 207 - einfo "checking for postdrop group... create if missing." - enewgroup postdrop 208 - einfo "checking for postfix user... create if missing." - enewuser postfix 207 -1 /var/spool/postfix postfix -} - -pkg_setup() { - # do not upgrade from postfix-2.1. logic to fix bug #53324 - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.2' ; then - if [ "${FORCE_UPGRADE}" ]; then - echo - ewarn "You are upgrading from a incompatible version and" - ewarn "you have FORCE_UPGRADE set, will build this package with postfix running." - ewarn "You MUST stop postfix BEFORE install it to your system." - echo - else - echo - eerror "You are upgrading from a incompatible version." - eerror "You MUST stop postfix BEFORE install it to your system." - eerror "If you want a minimal downtime, emerge postfix with:" - eerror "\`FORCE_UPGRADE=1 emerge --buildpkgonly postfix\`; then" - eerror "\`/etc/init.d/postfix stop && emerge --usepkgonly postfix\`" - eerror "run etc-update or dispatch-conf and merge the configuration files." - eerror "Next /etc/init.d/postfix start" - die "upgrade from an incompatible version!" - echo - fi - - else - echo - ewarn "It is safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance; please hit Ctrl+C now;" - ewarn "stop Postfix then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continue." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org\"" - ewarn "assign to \"net-mail@gentoo.org\"." - echo - #epause 5 - - # put out warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18'; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, one of the empty queue" - ewarn "directory get deleted during unmerge the older version (#45764). Please run" - ewarn "\`etc/postfix/post-install upgrade-source\` to recreate them." - echo - #epause 5 - fi - - #TLS non-prod warn - if use ssl; then - echo - ewarn "you have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service entry is incompatible with previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - #epause 5 - fi - - # IPV6 non-prod warn - if use ipv6; then - echo - ewarn "you have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - -} - -src_unpack() { - unpack ${A} && cd "${S}" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" - fi - - # Postfix does not get the FQDN if no hostname is configured. - epatch "${FILESDIR}/${PN}-2.0.9-get-FQDN.patch" - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - -} - -src_compile() { - cd ${S} - # added -Wl,-z,now wrt 62674. - # remove -ldl as it is not necessary, resolve bug #106446. - local mycc="-DHAS_PCRE" mylibs="-Wl,-z,now -L/usr/lib -lpcre -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - mycc="${mycc} -DUSE_SASL_AUTH -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - fi - - if ! use nis; then - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" src/util/sys_defs.h || \ - die "sed failed" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/lib/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - ebegin "Starting make makefiles..." - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # workaround for bug #76512 - [ "$(gcc-version)" == "3.4" ] && use hardened && replace-flags -O? -Os - - make CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade. - rm -rf "${D}/var" - keepdir /var/spool/postfix - - # Install an rmail for UUCP, closing bug #19127. - dobin auxiliary/rmail/rmail - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - rm "${D}/usr/bin/mailq" "${D}/usr/bin/newaliases" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - insinto /etc/mail - doins "${FILESDIR}/mailer.conf" - else - # Provide another link for legacy FSH. - dosym /usr/sbin/sendmail /usr/lib/sendmail - fi - - # Install qshape tool. - dobin auxiliary/qshape/qshape.pl - - # Set proper permissions on required files/directories. - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv ${D}/usr/share/doc/${PF}/defaults/{*.cf,post*-*} ${D}/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - - "${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.${PV}" postfix || \ - die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # do not install server.{key,pem) if they are exist. - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]]; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [ ! -e /etc/mail/aliases.db ] ; then - echo - 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." - fi - - if ! use mailwrapper && [[ -e /etc/mailer.conf ]] - then - einfo - einfo "Since you emerged $PN without mailwrapper in USE," - einfo "you probably want to 'emerge -C mailwrapper' now." - einfo - fi - -} diff --git a/mail-mta/postfix/postfix-2.2.8-r1.ebuild b/mail-mta/postfix/postfix-2.2.8-r1.ebuild deleted file mode 100644 index dc12f8882327..000000000000 --- a/mail-mta/postfix/postfix-2.2.8-r1.ebuild +++ /dev/null @@ -1,337 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.2.8-r1.ebuild,v 1.2 2006/11/23 20:28:34 vivo Exp $ - -inherit eutils ssl-cert toolchain-funcs flag-o-matic mailer pam -IUSE="ipv6 pam ldap mysql postgres ssl sasl mbox nis vda selinux hardened cdb" -#IUSE="ipv6 pam ldap mysql postgres ssl sasl mbox nis vda selinux hardened devel" - -MY_PV=${PV} -MY_SRC=${PN}-${MY_PV} -#DEV_SRC=${MY_SRC}-newdb-nonprod -VDA_VER=2.2.8 -VDA_P="${PN}-${VDA_VER}-vda" -RC_VER="2.2.5" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.tar.gz - vda? ( http://web.onda.com.br/nadal/postfix/VDA/${VDA_P}.patch.gz ) " -# devel? ( ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/${DEV_SRC}.tar.gz ) " - -LICENSE="IPL-1" -SLOT="0" -#KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" - -PROVIDE="${PROVIDE} virtual/mda" -DEPEND="cdb? ( || ( >=dev-db/cdb-0.75-r1 >=dev-db/tinycdb-0.74 ) ) - >=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - pam? ( virtual/pam ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - postgres? ( >=dev-db/postgresql-7.1 ) - ssl? ( >=dev-libs/openssl-0.9.6g ) - sasl? ( >=dev-libs/cyrus-sasl-2 )" -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - selinux? ( sec-policy/selinux-postfix )" - -#if use devel; then -# MY_SRC=${DEV_SRC} -#fi - -S=${WORKDIR}/${MY_SRC} - -group_user_check() { - einfo "checking for postfix group... create if missing." - enewgroup postfix 207 - einfo "checking for postdrop group... create if missing." - enewgroup postdrop 208 - einfo "checking for postfix user... create if missing." - enewuser postfix 207 -1 /var/spool/postfix postfix -} - -pkg_setup() { - # do not upgrade from postfix-2.1. logic to fix bug #53324 - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.2' ; then - if [ "${FORCE_UPGRADE}" ]; then - echo - ewarn "You are upgrading from a incompatible version and" - ewarn "you have FORCE_UPGRADE set, will build this package with postfix running." - ewarn "You MUST stop postfix BEFORE install it to your system." - echo - else - echo - eerror "You are upgrading from a incompatible version." - eerror "You MUST stop postfix BEFORE install it to your system." - eerror "If you want a minimal downtime, emerge postfix with:" - eerror "\`FORCE_UPGRADE=1 emerge --buildpkgonly postfix\`; then" - eerror "\`/etc/init.d/postfix stop && emerge --usepkgonly postfix\`" - eerror "run etc-update or dispatch-conf and merge the configuration files." - eerror "Next /etc/init.d/postfix start" - die "upgrade from an incompatible version!" - echo - fi - - else - echo - ewarn "It is safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance; please hit Ctrl+C now;" - ewarn "stop Postfix then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continue." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org\"" - ewarn "assign to \"net-mail@gentoo.org\"." - echo - #epause 5 - - # put out warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18'; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, one of the empty queue" - ewarn "directory get deleted during unmerge the older version (#45764). Please run" - ewarn "\`etc/postfix/post-install upgrade-source\` to recreate them." - echo - #epause 5 - fi - - #TLS non-prod warn - if use ssl; then - echo - ewarn "you have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service entry is incompatible with previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - #epause 5 - fi - - # IPV6 non-prod warn - if use ipv6; then - echo - ewarn "you have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - -} - -src_unpack() { - unpack ${A} && cd "${S}" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" - fi - - # Postfix does not get the FQDN if no hostname is configured. - epatch "${FILESDIR}/${PN}-2.0.9-get-FQDN.patch" - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - -} - -src_compile() { - cd ${S} - # added -Wl,-z,now wrt 62674. - # remove -ldl as it is not necessary, resolve bug #106446. - # -Wl,-z,now replaced by $(bindnow-flags) - local mycc="-DHAS_PCRE" mylibs="$(bindnow-flags) -L/usr/lib -lpcre -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - mycc="${mycc} -DUSE_SASL_AUTH -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - fi - - if ! use nis; then - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" src/util/sys_defs.h || \ - die "sed failed" - fi - - # CDB support, bug #112293 - if use cdb; then - mycc="${mycc} -DHAS_CDB" - CDB_LIBS="" - - # tinycdb is preferred. - if has_version dev-db/tinycdb; then - einfo "build with dev-db/tinycdb" - # ugly hack because gentoo doesn't install cdb.h - cp /usr/include/tinycdb.h ${S}/src/util/cdb.h || die \ - "failed to cp /usr/include/tinycdb.h to ${S}/util/cdb.h" - CDB_LIBS="-ltinycdb" - else - CDB_PATH="/usr/lib" - for i in cdb.a alloc.a buffer.a unix.a byte.a - do CDB_LIBS="${CDB_LIBS} ${CDB_PATH}/${i}" - done - fi - - mylibs="${mylibs} ${CDB_LIBS}" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/lib/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - ebegin "Starting make makefiles..." - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # workaround for bug #76512 - [ "$(gcc-version)" == "3.4" ] && use hardened && replace-flags -O? -Os - - make CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade. - rm -rf "${D}/var" - keepdir /var/spool/postfix - - # Install an rmail for UUCP, closing bug #19127. - dobin auxiliary/rmail/rmail - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - rm "${D}/usr/bin/mailq" "${D}/usr/bin/newaliases" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - mailer_install_conf - else - # Provide another link for legacy FSH. - dosym /usr/sbin/sendmail /usr/lib/sendmail - fi - - # Install qshape tool. - dobin auxiliary/qshape/qshape.pl - - # performance tuning tools. - 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. - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv ${D}/usr/share/doc/${PF}/defaults/{*.cf,post*-*} ${D}/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - - "${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 || \ - die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # do not install server.{key,pem) if they are exist. - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]]; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [ ! -e /etc/mail/aliases.db ] ; then - echo - 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." - fi - - mailer_pkg_postinst -} diff --git a/mail-mta/postfix/postfix-2.2.8.ebuild b/mail-mta/postfix/postfix-2.2.8.ebuild deleted file mode 100644 index 4de37d4b5356..000000000000 --- a/mail-mta/postfix/postfix-2.2.8.ebuild +++ /dev/null @@ -1,345 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.2.8.ebuild,v 1.2 2006/11/23 20:28:34 vivo Exp $ - -inherit eutils ssl-cert toolchain-funcs flag-o-matic pam -IUSE="ipv6 pam ldap mysql postgres ssl sasl mailwrapper mbox nis vda selinux hardened cdb" -#IUSE="ipv6 pam ldap mysql postgres ssl sasl mailwrapper mbox nis vda selinux hardened devel" - -MY_PV=${PV} -MY_SRC=${PN}-${MY_PV} -#DEV_SRC=${MY_SRC}-newdb-nonprod -VDA_VER=2.2.8 -VDA_P="${PN}-${VDA_VER}-vda" -RC_VER="2.2.5" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.tar.gz - vda? ( http://web.onda.com.br/nadal/postfix/VDA/${VDA_P}.patch.gz ) " -# devel? ( ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/${DEV_SRC}.tar.gz ) " - -LICENSE="IPL-1" -SLOT="0" -#KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" - -PROVIDE="virtual/mta virtual/mda" -DEPEND="cdb? ( || ( >=dev-db/cdb-0.75-r1 >=dev-db/tinycdb-0.74 ) ) - >=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - pam? ( virtual/pam ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - postgres? ( >=dev-db/postgresql-7.1 ) - ssl? ( >=dev-libs/openssl-0.9.6g ) - sasl? ( >=dev-libs/cyrus-sasl-2 )" -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - !mailwrapper? ( !virtual/mta ) - mailwrapper? ( >=net-mail/mailwrapper-0.2 ) - selinux? ( sec-policy/selinux-postfix )" - -#if use devel; then -# MY_SRC=${DEV_SRC} -#fi - -S=${WORKDIR}/${MY_SRC} - -group_user_check() { - einfo "checking for postfix group... create if missing." - enewgroup postfix 207 - einfo "checking for postdrop group... create if missing." - enewgroup postdrop 208 - einfo "checking for postfix user... create if missing." - enewuser postfix 207 -1 /var/spool/postfix postfix -} - -pkg_setup() { - # do not upgrade from postfix-2.1. logic to fix bug #53324 - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.2' ; then - if [ "${FORCE_UPGRADE}" ]; then - echo - ewarn "You are upgrading from a incompatible version and" - ewarn "you have FORCE_UPGRADE set, will build this package with postfix running." - ewarn "You MUST stop postfix BEFORE install it to your system." - echo - else - echo - eerror "You are upgrading from a incompatible version." - eerror "You MUST stop postfix BEFORE install it to your system." - eerror "If you want a minimal downtime, emerge postfix with:" - eerror "\`FORCE_UPGRADE=1 emerge --buildpkgonly postfix\`; then" - eerror "\`/etc/init.d/postfix stop && emerge --usepkgonly postfix\`" - eerror "run etc-update or dispatch-conf and merge the configuration files." - eerror "Next /etc/init.d/postfix start" - die "upgrade from an incompatible version!" - echo - fi - - else - echo - ewarn "It is safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance; please hit Ctrl+C now;" - ewarn "stop Postfix then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continue." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org\"" - ewarn "assign to \"net-mail@gentoo.org\"." - echo - #epause 5 - - # put out warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18'; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, one of the empty queue" - ewarn "directory get deleted during unmerge the older version (#45764). Please run" - ewarn "\`etc/postfix/post-install upgrade-source\` to recreate them." - echo - #epause 5 - fi - - #TLS non-prod warn - if use ssl; then - echo - ewarn "you have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service entry is incompatible with previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - #epause 5 - fi - - # IPV6 non-prod warn - if use ipv6; then - echo - ewarn "you have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - -} - -src_unpack() { - unpack ${A} && cd "${S}" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" - fi - - # Postfix does not get the FQDN if no hostname is configured. - epatch "${FILESDIR}/${PN}-2.0.9-get-FQDN.patch" - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - -} - -src_compile() { - cd ${S} - # added -Wl,-z,now wrt 62674. - # remove -ldl as it is not necessary, resolve bug #106446. - # -Wl,-z,now replaced by $(bindnow-flags) - local mycc="-DHAS_PCRE" mylibs="$(bindnow-flags) -L/usr/lib -lpcre -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - mycc="${mycc} -DUSE_SASL_AUTH -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - fi - - if ! use nis; then - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" src/util/sys_defs.h || \ - die "sed failed" - fi - - if use cdb; then - mycc="${mycc} -DHAS_CDB" - CDB_LIBS="" - - # tinycdb is preferred. - if has_version dev-db/tinycdb; then - einfo "build with dev-db/tinycdb" - # ugly hack because gentoo doesn't install cdb.h - cp /usr/include/tinycdb.h ${S}/src/util/cdb.h || die \ - "failed to cp /usr/include/tinycdb.h to ${S}/util/cdb.h" - CDB_LIBS="-ltinycdb" - else - CDB_PATH="/usr/lib" - for i in cdb.a alloc.a buffer.a unix.a byte.a - do CDB_LIBS="${CDB_LIBS} ${CDB_PATH}/${i}" - done - fi - - mylibs="${mylibs} ${CDB_LIBS}" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/lib/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - ebegin "Starting make makefiles..." - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # workaround for bug #76512 - [ "$(gcc-version)" == "3.4" ] && use hardened && replace-flags -O? -Os - - make CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade. - rm -rf "${D}/var" - keepdir /var/spool/postfix - - # Install an rmail for UUCP, closing bug #19127. - dobin auxiliary/rmail/rmail - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - insinto /etc/mail - doins "${FILESDIR}/mailer.conf" - else - # Provide another link for legacy FSH. - dosym /usr/sbin/sendmail /usr/lib/sendmail - fi - - # Install qshape tool. - dobin auxiliary/qshape/qshape.pl - - # performance tuning tools. - 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. - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv ${D}/usr/share/doc/${PF}/defaults/{*.cf,post*-*} ${D}/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - - "${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 || \ - die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # do not install server.{key,pem) if they are exist. - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]]; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [ ! -e /etc/mail/aliases.db ] ; then - echo - 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." - fi - - if ! use mailwrapper && [[ -e /etc/mailer.conf ]] - then - einfo - einfo "Since you emerged $PN without mailwrapper in USE," - einfo "you probably want to 'emerge -C mailwrapper' now." - einfo - fi - -} diff --git a/mail-mta/postfix/postfix-2.2.9-r1.ebuild b/mail-mta/postfix/postfix-2.2.9-r1.ebuild deleted file mode 100644 index 0995f377d309..000000000000 --- a/mail-mta/postfix/postfix-2.2.9-r1.ebuild +++ /dev/null @@ -1,337 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.2.9-r1.ebuild,v 1.3 2006/11/23 20:28:34 vivo Exp $ - -inherit eutils ssl-cert toolchain-funcs flag-o-matic mailer pam -IUSE="ipv6 pam ldap mysql postgres ssl sasl mbox nis vda selinux hardened cdb" -#IUSE="ipv6 pam ldap mysql postgres ssl sasl mbox nis vda selinux hardened devel" - -MY_PV=${PV} -MY_SRC=${PN}-${MY_PV} -#DEV_SRC=${MY_SRC}-newdb-nonprod -VDA_VER=2.2.8 -VDA_P="${PN}-${VDA_VER}-vda" -RC_VER="2.2.9" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.tar.gz - vda? ( http://web.onda.com.br/nadal/postfix/VDA/${VDA_P}.patch.gz ) " -# devel? ( ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/${DEV_SRC}.tar.gz ) " - -LICENSE="IPL-1" -SLOT="0" -#KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" - -PROVIDE="${PROVIDE} virtual/mda" -DEPEND="cdb? ( || ( >=dev-db/cdb-0.75-r1 >=dev-db/tinycdb-0.74 ) ) - >=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - pam? ( virtual/pam ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - postgres? ( >=dev-db/postgresql-7.1 ) - ssl? ( >=dev-libs/openssl-0.9.6g ) - sasl? ( >=dev-libs/cyrus-sasl-2 )" -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - selinux? ( sec-policy/selinux-postfix )" - -#if use devel; then -# MY_SRC=${DEV_SRC} -#fi - -S=${WORKDIR}/${MY_SRC} - -group_user_check() { - einfo "checking for postfix group... create if missing." - enewgroup postfix 207 - einfo "checking for postdrop group... create if missing." - enewgroup postdrop 208 - einfo "checking for postfix user... create if missing." - enewuser postfix 207 -1 /var/spool/postfix postfix -} - -pkg_setup() { - # do not upgrade from postfix-2.1. logic to fix bug #53324 - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.2' ; then - if [ "${FORCE_UPGRADE}" ]; then - echo - ewarn "You are upgrading from a incompatible version and" - ewarn "you have FORCE_UPGRADE set, will build this package with postfix running." - ewarn "You MUST stop postfix BEFORE install it to your system." - echo - else - echo - eerror "You are upgrading from a incompatible version." - eerror "You MUST stop postfix BEFORE install it to your system." - eerror "If you want a minimal downtime, emerge postfix with:" - eerror "\`FORCE_UPGRADE=1 emerge --buildpkgonly postfix\`; then" - eerror "\`/etc/init.d/postfix stop && emerge --usepkgonly postfix\`" - eerror "run etc-update or dispatch-conf and merge the configuration files." - eerror "Next /etc/init.d/postfix start" - die "upgrade from an incompatible version!" - echo - fi - - else - echo - ewarn "It is safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance; please hit Ctrl+C now;" - ewarn "stop Postfix then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continue." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org\"" - ewarn "assign to \"net-mail@gentoo.org\"." - echo - #epause 5 - - # put out warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18'; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, one of the empty queue" - ewarn "directory get deleted during unmerge the older version (#45764). Please run" - ewarn "\`etc/postfix/post-install upgrade-source\` to recreate them." - echo - #epause 5 - fi - - #TLS non-prod warn - if use ssl; then - echo - ewarn "you have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service entry is incompatible with previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - #epause 5 - fi - - # IPV6 non-prod warn - if use ipv6; then - echo - ewarn "you have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - -} - -src_unpack() { - unpack ${A} && cd "${S}" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" - fi - - # Postfix does not get the FQDN if no hostname is configured. - epatch "${FILESDIR}/${PN}-2.0.9-get-FQDN.patch" - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - -} - -src_compile() { - cd ${S} - # added -Wl,-z,now wrt 62674. - # remove -ldl as it is not necessary, resolve bug #106446. - # -Wl,-z,now replaced by $(bindnow-flags) - local mycc="-DHAS_PCRE" mylibs="$(bindnow-flags) -L/usr/lib -lpcre -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - mycc="${mycc} -DUSE_SASL_AUTH -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - fi - - if ! use nis; then - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" src/util/sys_defs.h || \ - die "sed failed" - fi - - # CDB support, bug #112293 - if use cdb; then - mycc="${mycc} -DHAS_CDB" - CDB_LIBS="" - - # tinycdb is preferred. - if has_version dev-db/tinycdb; then - einfo "build with dev-db/tinycdb" - # ugly hack because gentoo doesn't install cdb.h - cp /usr/include/tinycdb.h ${S}/src/util/cdb.h || die \ - "failed to cp /usr/include/tinycdb.h to ${S}/util/cdb.h" - CDB_LIBS="-ltinycdb" - else - CDB_PATH="/usr/lib" - for i in cdb.a alloc.a buffer.a unix.a byte.a - do CDB_LIBS="${CDB_LIBS} ${CDB_PATH}/${i}" - done - fi - - mylibs="${mylibs} ${CDB_LIBS}" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/lib/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - ebegin "Starting make makefiles..." - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # workaround for bug #76512 - [ "$(gcc-version)" == "3.4" ] && use hardened && replace-flags -O? -Os - - make CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade. - rm -rf "${D}/var" - keepdir /var/spool/postfix - - # Install an rmail for UUCP, closing bug #19127. - dobin auxiliary/rmail/rmail - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - rm "${D}/usr/bin/mailq" "${D}/usr/bin/newaliases" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - mailer_install_conf - else - # Provide another link for legacy FSH. - dosym /usr/sbin/sendmail /usr/lib/sendmail - fi - - # Install qshape tool. - dobin auxiliary/qshape/qshape.pl - - # performance tuning tools. - 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. - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv ${D}/usr/share/doc/${PF}/defaults/{*.cf,post*-*} ${D}/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - - "${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 || \ - die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # do not install server.{key,pem) if they are exist. - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]]; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [ ! -e /etc/mail/aliases.db ] ; then - echo - 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." - fi - - mailer_pkg_postinst -} diff --git a/mail-mta/postfix/postfix-2.2.9.ebuild b/mail-mta/postfix/postfix-2.2.9.ebuild deleted file mode 100644 index f97207ac87e0..000000000000 --- a/mail-mta/postfix/postfix-2.2.9.ebuild +++ /dev/null @@ -1,345 +0,0 @@ -# Copyright 1999-2006 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.2.9.ebuild,v 1.3 2006/11/23 20:28:34 vivo Exp $ - -inherit eutils ssl-cert toolchain-funcs flag-o-matic pam -IUSE="ipv6 pam ldap mysql postgres ssl sasl mailwrapper mbox nis vda selinux hardened cdb" -#IUSE="ipv6 pam ldap mysql postgres ssl sasl mailwrapper mbox nis vda selinux hardened devel" - -MY_PV=${PV} -MY_SRC=${PN}-${MY_PV} -#DEV_SRC=${MY_SRC}-newdb-nonprod -VDA_VER=2.2.8 -VDA_P="${PN}-${VDA_VER}-vda" -RC_VER="2.2.9" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.tar.gz - vda? ( http://web.onda.com.br/nadal/postfix/VDA/${VDA_P}.patch.gz ) " -# devel? ( ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/${DEV_SRC}.tar.gz ) " - -LICENSE="IPL-1" -SLOT="0" -#KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" - -PROVIDE="virtual/mta virtual/mda" -DEPEND="cdb? ( || ( >=dev-db/cdb-0.75-r1 >=dev-db/tinycdb-0.74 ) ) - >=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - pam? ( virtual/pam ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - postgres? ( >=dev-db/postgresql-7.1 ) - ssl? ( >=dev-libs/openssl-0.9.6g ) - sasl? ( >=dev-libs/cyrus-sasl-2 )" -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - !mailwrapper? ( !virtual/mta ) - mailwrapper? ( >=net-mail/mailwrapper-0.2 ) - selinux? ( sec-policy/selinux-postfix )" - -#if use devel; then -# MY_SRC=${DEV_SRC} -#fi - -S=${WORKDIR}/${MY_SRC} - -group_user_check() { - einfo "checking for postfix group... create if missing." - enewgroup postfix 207 - einfo "checking for postdrop group... create if missing." - enewgroup postdrop 208 - einfo "checking for postfix user... create if missing." - enewuser postfix 207 -1 /var/spool/postfix postfix -} - -pkg_setup() { - # do not upgrade from postfix-2.1. logic to fix bug #53324 - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.2' ; then - if [ "${FORCE_UPGRADE}" ]; then - echo - ewarn "You are upgrading from a incompatible version and" - ewarn "you have FORCE_UPGRADE set, will build this package with postfix running." - ewarn "You MUST stop postfix BEFORE install it to your system." - echo - else - echo - eerror "You are upgrading from a incompatible version." - eerror "You MUST stop postfix BEFORE install it to your system." - eerror "If you want a minimal downtime, emerge postfix with:" - eerror "\`FORCE_UPGRADE=1 emerge --buildpkgonly postfix\`; then" - eerror "\`/etc/init.d/postfix stop && emerge --usepkgonly postfix\`" - eerror "run etc-update or dispatch-conf and merge the configuration files." - eerror "Next /etc/init.d/postfix start" - die "upgrade from an incompatible version!" - echo - fi - - else - echo - ewarn "It is safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance; please hit Ctrl+C now;" - ewarn "stop Postfix then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continue." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org\"" - ewarn "assign to \"net-mail@gentoo.org\"." - echo - #epause 5 - - # put out warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18'; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, one of the empty queue" - ewarn "directory get deleted during unmerge the older version (#45764). Please run" - ewarn "\`etc/postfix/post-install upgrade-source\` to recreate them." - echo - #epause 5 - fi - - #TLS non-prod warn - if use ssl; then - echo - ewarn "you have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service entry is incompatible with previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - #epause 5 - fi - - # IPV6 non-prod warn - if use ipv6; then - echo - ewarn "you have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - -} - -src_unpack() { - unpack ${A} && cd "${S}" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" - fi - - # Postfix does not get the FQDN if no hostname is configured. - epatch "${FILESDIR}/${PN}-2.0.9-get-FQDN.patch" - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - -} - -src_compile() { - cd ${S} - # added -Wl,-z,now wrt 62674. - # remove -ldl as it is not necessary, resolve bug #106446. - # -Wl,-z,now replaced by $(bindnow-flags) - local mycc="-DHAS_PCRE" mylibs="$(bindnow-flags) -L/usr/lib -lpcre -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - mycc="${mycc} -DUSE_SASL_AUTH -I/usr/include/sasl" - mylibs="${mylibs} -lsasl2" - fi - - if ! use nis; then - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" src/util/sys_defs.h || \ - die "sed failed" - fi - - if use cdb; then - mycc="${mycc} -DHAS_CDB" - CDB_LIBS="" - - # tinycdb is preferred. - if has_version dev-db/tinycdb; then - einfo "build with dev-db/tinycdb" - # ugly hack because gentoo doesn't install cdb.h - cp /usr/include/tinycdb.h ${S}/src/util/cdb.h || die \ - "failed to cp /usr/include/tinycdb.h to ${S}/util/cdb.h" - CDB_LIBS="-ltinycdb" - else - CDB_PATH="/usr/lib" - for i in cdb.a alloc.a buffer.a unix.a byte.a - do CDB_LIBS="${CDB_LIBS} ${CDB_PATH}/${i}" - done - fi - - mylibs="${mylibs} ${CDB_LIBS}" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/lib/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - ebegin "Starting make makefiles..." - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # workaround for bug #76512 - [ "$(gcc-version)" == "3.4" ] && use hardened && replace-flags -O? -Os - - make CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade. - rm -rf "${D}/var" - keepdir /var/spool/postfix - - # Install an rmail for UUCP, closing bug #19127. - dobin auxiliary/rmail/rmail - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - insinto /etc/mail - doins "${FILESDIR}/mailer.conf" - else - # Provide another link for legacy FSH. - dosym /usr/sbin/sendmail /usr/lib/sendmail - fi - - # Install qshape tool. - dobin auxiliary/qshape/qshape.pl - - # performance tuning tools. - 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. - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv ${D}/usr/share/doc/${PF}/defaults/{*.cf,post*-*} ${D}/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - - "${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 || \ - die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # do not install server.{key,pem) if they are exist. - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]]; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [ ! -e /etc/mail/aliases.db ] ; then - echo - 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." - fi - - if ! use mailwrapper && [[ -e /etc/mailer.conf ]] - then - einfo - einfo "Since you emerged $PN without mailwrapper in USE," - einfo "you probably want to 'emerge -C mailwrapper' now." - einfo - fi - -} diff --git a/mail-mta/postfix/postfix-2.3.7.ebuild b/mail-mta/postfix/postfix-2.3.7.ebuild deleted file mode 100644 index 0927e28cf4e9..000000000000 --- a/mail-mta/postfix/postfix-2.3.7.ebuild +++ /dev/null @@ -1,386 +0,0 @@ -# Copyright 1999-2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.3.7.ebuild,v 1.1 2007/02/04 04:20:29 ticho Exp $ - -# NOTE: this ebuild is regular ebuild without mailer-config support -# comment lines below "regular ebuild" and uncomment lines below "mailer-config support" -# to turn this ebuild to mailer-config supported ebuild. - -# regular ebuild -inherit eutils ssl-cert toolchain-funcs flag-o-matic pam -# mailer-config support. -#inherit eutils ssl-cert toolchain-funcs flag-o-matic mailer pam - -# regular ebuild. -IUSE="ipv6 pam ldap mysql postgres ssl sasl dovecot-sasl mailwrapper mbox nis selinux hardened cdb vda" -# mailer-config support. -#IUSE="ipv6 pam ldap mysql postgres ssl sasl dovecot-sasl mbox nis selinux hardened cdb" - -MY_PV=${PV/_rc/-RC} -MY_SRC=${PN}-${MY_PV} -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" -VDA_VER=2.3.3 -VDA_P="${PN}-${VDA_VER}-vda" -RC_VER="2.2.9" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz - vda? ( http://web.onda.com.br/nadal/postfix/VDA/${VDA_P}.patch.gz ) " -# devel? ( ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/${DEV_SRC}.tar.gz ) " - -LICENSE="IPL-1" -SLOT="0" -#KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" - -# regular ebuild. -PROVIDE="virtual/mta virtual/mda" -# mailer-config support. -#PROVIDE="${PROVIDE} virtual/mda" - -DEPEND="cdb? ( || ( >=dev-db/cdb-0.75-r1 >=dev-db/tinycdb-0.74 ) ) - >=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - pam? ( virtual/pam ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - postgres? ( >=dev-db/postgresql-7.1 ) - ssl? ( >=dev-libs/openssl-0.9.6g ) - sasl? ( >=dev-libs/cyrus-sasl-2 )" - -# regular ebuild. -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - !mailwrapper? ( !virtual/mta ) - mailwrapper? ( >=net-mail/mailwrapper-0.2 ) - selinux? ( sec-policy/selinux-postfix )" - -# mailer-config support. -#RDEPEND="${DEPEND} -# >=net-mail/mailbase-0.00 -# selinux? ( sec-policy/selinux-postfix )" - -#if use devel; then -# MY_SRC=${DEV_SRC} -#fi - -S=${WORKDIR}/${MY_SRC} - -group_user_check() { - einfo "checking for postfix group... create if missing." - enewgroup postfix 207 - einfo "checking for postdrop group... create if missing." - enewgroup postdrop 208 - einfo "checking for postfix user... create if missing." - enewuser postfix 207 -1 /var/spool/postfix postfix,mail -} - -pkg_setup() { - # do not upgrade live from postfix <2.3. - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.3.0' ; then - if [ "${FORCE_UPGRADE}" ]; then - echo - ewarn "You are upgrading from a incompatible version and" - ewarn "you have FORCE_UPGRADE set, will build this package with postfix running." - ewarn "You MUST stop postfix BEFORE install it to your system." - echo - else - echo - eerror "You are upgrading from a incompatible version." - eerror "You MUST stop postfix BEFORE install it to your system." - eerror "If you want a minimal downtime, emerge postfix with:" - eerror "\`FORCE_UPGRADE=1 emerge --buildpkgonly postfix\`; then" - eerror "\`/etc/init.d/postfix stop && emerge --usepkgonly postfix\`" - eerror "run etc-update or dispatch-conf and merge the configuration files." - eerror "Next /etc/init.d/postfix start" - die "upgrade from an incompatible version!" - echo - fi - - else - echo - ewarn "It is safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance; please hit Ctrl+C now;" - ewarn "stop Postfix then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continue." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org\"" - ewarn "assign to \"net-mail@gentoo.org\"." - echo - #epause 5 - - # put out warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18'; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, one of the empty queue" - ewarn "directory get deleted during unmerge the older version (#45764). Please run" - ewarn "\`etc/postfix/post-install upgrade-source\` to recreate them." - echo - #epause 5 - fi - - #TLS non-prod warn - if use ssl; then - echo - ewarn "you have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service entry is incompatible with previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - #epause 5 - fi - - # IPV6 non-prod warn - if use ipv6; then - echo - ewarn "you have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - if use sasl ; then - echo - elog "postfix 2.3 supports two SASL implementations." - elog "Cyrus SASL and Dovecot protocol version 1 (server only)" - elog "detail at http://www.postfix.org/SASL_README.html" - echo - fi - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" -} - -src_unpack() { - unpack ${A} && cd "${S}" - - epatch "${FILESDIR}/${PN}-master.cf.patch" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" - fi - - # Postfix does not get the FQDN if no hostname is configured. - epatch "${FILESDIR}/${PN}-2.0.9-get-FQDN.patch" - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - -} - -src_compile() { - cd ${S} - # added -Wl,-z,now wrt 62674. - # remove -ldl as it is not necessary, resolve bug #106446. - # -Wl,-z,now replaced by $(bindnow-flags) - local mycc="-DHAS_PCRE" mylibs="$(bindnow-flags) -L/usr/lib -lpcre -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - if use dovecot-sasl ; then - # set dovecot as default. - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" - 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 - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" src/util/sys_defs.h || \ - die "sed failed" - fi - - if use cdb; then - mycc="${mycc} -DHAS_CDB" - CDB_LIBS="" - - # tinycdb is preferred. - if has_version dev-db/tinycdb; then - einfo "build with dev-db/tinycdb" - # ugly hack because gentoo doesn't install cdb.h - cp /usr/include/tinycdb.h ${S}/src/util/cdb.h || die \ - "failed to cp /usr/include/tinycdb.h to ${S}/util/cdb.h" - CDB_LIBS="-ltinycdb" - else - CDB_PATH="/usr/lib" - for i in cdb.a alloc.a buffer.a unix.a byte.a - do CDB_LIBS="${CDB_LIBS} ${CDB_PATH}/${i}" - done - fi - - mylibs="${mylibs} ${CDB_LIBS}" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/lib/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - ebegin "Starting make makefiles..." - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # workaround for bug #76512 - [ "$(gcc-version)" == "3.4" ] && use hardened && replace-flags -O? -Os - - make DEBUG="" CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade. - rm -rf "${D}/var" - keepdir /var/spool/postfix - - # Install an rmail for UUCP, closing bug #19127. - dobin auxiliary/rmail/rmail - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - # mailer-config support - #rm "${D}/usr/bin/mailq" "${D}/usr/bin/newaliases" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - # regular ebuild. - insinto /etc/mail - doins "${FILESDIR}/mailer.conf" - # mailer-config support - #mailer_install_conf - else - # Provide another link for legacy FSH. - dosym /usr/sbin/sendmail /usr/lib/sendmail - fi - - # Install qshape tool. - dobin auxiliary/qshape/qshape.pl - - # performance tuning tools. - 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. - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv ${D}/usr/share/doc/${PF}/defaults/{*.cf,post*-*} ${D}/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - "${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 || \ - die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # do not install server.{key,pem) if they are exist. - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]]; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [ ! -e /etc/mail/aliases.db ] ; then - echo - 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." - fi - - # regular ebuild - if ! use mailwrapper && [[ -e /etc/mailer.conf ]] - then - einfo - einfo "Since you emerged $PN without mailwrapper in USE," - einfo "you probably want to 'emerge -C mailwrapper' now." - einfo - fi - # mailer-config support - #mailer_pkg_postinst -} diff --git a/mail-mta/postfix/postfix-2.4.0-r1.ebuild b/mail-mta/postfix/postfix-2.4.0-r1.ebuild deleted file mode 100644 index 45e33aea5299..000000000000 --- a/mail-mta/postfix/postfix-2.4.0-r1.ebuild +++ /dev/null @@ -1,373 +0,0 @@ -# Copyright 1999-2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.4.0-r1.ebuild,v 1.1 2007/04/24 19:26:43 chtekk Exp $ - -# NOTE: this ebuild is a regular ebuild without mailer-config support! -# Comment lines below "regular ebuild" and uncomment lines below "mailer-config support" -# to turn this ebuild to a mailer-config enabled ebuild. - -# regular ebuild -inherit eutils multilib ssl-cert toolchain-funcs flag-o-matic pam -# mailer-config support -#inherit eutils multilib ssl-cert toolchain-funcs flag-o-matic mailer pam - -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd" - -# regular ebuild -IUSE="cdb dovecot-sasl hardened ipv6 ldap mailwrapper mbox mysql nis pam postgres sasl selinux ssl vda" -# mailer-config support -#IUSE="cdb dovecot-sasl hardened ipv6 ldap mbox mysql nis pam postgres sasl selinux ssl vda" - -MY_PV="${PV/_rc/-RC}" -MY_SRC="${PN}-${MY_PV}" -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" -VDA_P="${P}-vda-ng-r1" -RC_VER="2.2.9" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz - vda? ( http://gentoo.longitekk.com/${VDA_P}.patch.gz ) " - -LICENSE="IPL-1" -SLOT="0" - -# regular ebuild -PROVIDE="virtual/mta virtual/mda" -# mailer-config support -#PROVIDE="${PROVIDE} virtual/mda" - -DEPEND=">=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - cdb? ( || ( >=dev-db/cdb-0.75-r1 >=dev-db/tinycdb-0.76 ) ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - pam? ( virtual/pam ) - postgres? ( >=dev-db/postgresql-7.1 ) - sasl? ( >=dev-libs/cyrus-sasl-2 ) - ssl? ( >=dev-libs/openssl-0.9.6g )" - -# regular ebuild -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - !mailwrapper? ( !virtual/mta ) - mailwrapper? ( >=net-mail/mailwrapper-0.2 ) - selinux? ( sec-policy/selinux-postfix )" - -# mailer-config support -#RDEPEND="${DEPEND} -# >=net-mail/mailbase-0.00 -# selinux? ( sec-policy/selinux-postfix )" - -S="${WORKDIR}/${MY_SRC}" - -group_user_check() { - einfo "Checking for postfix group ..." - enewgroup postfix 207 - einfo "Checking for postdrop group ..." - enewgroup postdrop 208 - einfo "Checking for postfix user ..." - enewuser postfix 207 -1 /var/spool/postfix postfix,mail -} - -pkg_setup() { - # Do not upgrade live from Postfix <2.4 - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.4.0' ; then - if [[ "${FORCE_UPGRADE}" ]] ; then - echo - ewarn "You are upgrading from an incompatible version and you have" - ewarn "FORCE_UPGRADE set, will build this package while Postfix is running." - ewarn "You MUST stop Postfix BEFORE installing this version to your system." - echo - else - echo - eerror "You are upgrading from an incompatible version." - eerror "You MUST stop Postfix BEFORE installing this version to your system." - eerror "If you want minimal downtime, emerge postfix with:" - eerror " FORCE_UPGRADE=1 emerge --buildpkgonly postfix" - eerror " /etc/init.d/postfix stop" - eerror " emerge --usepkgonly postfix" - eerror "Then run etc-update or dispatch-conf and merge the configuration files." - eerror "Then restart Postfix with: /etc/init.d/postfix start" - die "Upgrade from an incompatible version!" - echo - fi - else - echo - ewarn "It's safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance, please hit Ctrl+C now," - ewarn "stop Postfix, then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing ..." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continueing." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org/\" and" - ewarn "assigned to \"net-mail@gentoo.org\"." - echo - - # Warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18' ; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, some of the empty queue" - ewarn "directories get deleted while unmerging the older version (see bug #45764)." - ewarn "Please run '/etc/postfix/post-install upgrade-source' to recreate them." - echo - fi - - # TLS non-prod warning - if use ssl ; then - echo - ewarn "You have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service is incompatible with the previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - fi - - # IPV6 non-prod warn - if use ipv6 ; then - echo - ewarn "You have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - # SASL non-prod warning - if use sasl ; then - echo - elog "Postfix 2.3 and newer supports two SASL implementations." - elog "Cyrus SASL and Dovecot protocol version 1 (server only)" - elog "Visit http://www.postfix.org/SASL_README.html for more info." - echo - fi - - # Add postfix, postdrop user/group (bug #77565) - group_user_check || die "Failed to check/add needed user/group" -} - -src_unpack() { - unpack ${A} - cd "${S}" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" - fi - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" -} - -src_compile() { - cd "${S}" - - # Added -Wl,-z,now wrt bug #62674 - # Remove -ldl as it is not necessary, solves bug #106446 - # -Wl,-z,now replaced by $(bindnow-flags) - local mycc="-DHAS_PCRE" mylibs="$(bindnow-flags) -L/usr/$(get_libdir) -lpcre -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - if use dovecot-sasl ; then - # Set dovecot as default. - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" - 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 - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" \ - src/util/sys_defs.h || die "sed failed" - fi - - if use cdb ; then - mycc="${mycc} -DHAS_CDB" - CDB_LIBS="" - - # Tinycdb is preferred. - if has_version dev-db/tinycdb ; then - einfo "Building with dev-db/tinycdb" - CDB_LIBS="-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 - CDB_LIBS="${CDB_LIBS} ${CDB_PATH}/${i}" - done - fi - - mylibs="${mylibs} ${CDB_LIBS}" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/$(get_libdir)/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - # Robin H. Johnson <robbat2@gentoo.org> 17/Nov/2006 - # Fix because infra boxes hit 2Gb .db files that fail a 32-bit fstat signed check. - mycc="${mycc} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE" - filter-lfs-flags - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # Workaround for bug #76512 - [[ "$(gcc-version)" == "3.4" ]] && use hardened && replace-flags -O? -Os - - make DEBUG="" CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || 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 - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - # mailer-config support - #rm "${D}/usr/bin/mailq" "${D}/usr/bin/newaliases" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - # regular ebuild - insinto /etc/mail - doins "${FILESDIR}/mailer.conf" - # mailer-config support - #mailer_install_conf - else - # Provide another link for legacy FSH - dosym /usr/sbin/sendmail /usr/$(get_libdir)/sendmail - fi - - # Install qshape tool - dobin auxiliary/qshape/qshape.pl - - # 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 - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv "${D}"/usr/share/doc/${PF}/defaults/{*.cf,post*-*} "${D}"/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - "${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 || die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # Do not install server.{key,pem) SSL certificates if they already exist - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]] ; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - # Add postfix, postdrop user/group (bug #77565) - group_user_check || die "Failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from Postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [[ ! -e /etc/mail/aliases.db ]] ; then - echo - 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." - fi - - # regular ebuild - if ! use mailwrapper && [[ -e /etc/mailer.conf ]] ; then - einfo - einfo "Since you emerged Postfix without mailwrapper in USE," - einfo "you may want to 'emerge -C mailwrapper' now." - einfo - fi - # mailer-config support - #mailer_pkg_postinst -} diff --git a/mail-mta/postfix/postfix-2.4.0.ebuild b/mail-mta/postfix/postfix-2.4.0.ebuild deleted file mode 100644 index 5a495cf752fe..000000000000 --- a/mail-mta/postfix/postfix-2.4.0.ebuild +++ /dev/null @@ -1,389 +0,0 @@ -# Copyright 1999-2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.4.0.ebuild,v 1.1 2007/04/08 01:44:13 falco Exp $ - -# NOTE: this ebuild is regular ebuild without mailer-config support -# comment lines below "regular ebuild" and uncomment lines below "mailer-config support" -# to turn this ebuild to mailer-config supported ebuild. - -# regular ebuild -inherit eutils ssl-cert toolchain-funcs flag-o-matic pam -# mailer-config support. -#inherit eutils ssl-cert toolchain-funcs flag-o-matic mailer pam - -# regular ebuild. -IUSE="ipv6 pam ldap mysql postgres ssl sasl dovecot-sasl mailwrapper mbox nis selinux hardened cdb vda" -# mailer-config support. -#IUSE="ipv6 pam ldap mysql postgres ssl sasl dovecot-sasl mbox nis selinux hardened cdb" - -MY_PV=${PV/_rc/-RC} -MY_SRC=${PN}-${MY_PV} -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" -VDA_P="${P}-vda" -RC_VER="2.2.9" - -DESCRIPTION="A fast and secure drop-in replacement for sendmail." -HOMEPAGE="http://www.postfix.org/" -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz - vda? ( http://vda.sourceforge.net/VDA/${VDA_P}.patch.gz ) " -# devel? ( ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/${DEV_SRC}.tar.gz ) " - -LICENSE="IPL-1" -SLOT="0" -#KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd" - -# regular ebuild. -PROVIDE="virtual/mta virtual/mda" -# mailer-config support. -#PROVIDE="${PROVIDE} virtual/mda" - -DEPEND="cdb? ( || ( >=dev-db/cdb-0.75-r1 >=dev-db/tinycdb-0.74 ) ) - >=sys-libs/db-3.2 - >=dev-libs/libpcre-3.4 - pam? ( virtual/pam ) - ldap? ( >=net-nds/openldap-1.2 ) - mysql? ( virtual/mysql ) - postgres? ( >=dev-db/postgresql-7.1 ) - ssl? ( >=dev-libs/openssl-0.9.6g ) - sasl? ( >=dev-libs/cyrus-sasl-2 )" - -# regular ebuild. -RDEPEND="${DEPEND} - >=net-mail/mailbase-0.00 - !mailwrapper? ( !virtual/mta ) - mailwrapper? ( >=net-mail/mailwrapper-0.2 ) - selinux? ( sec-policy/selinux-postfix )" - -# mailer-config support. -#RDEPEND="${DEPEND} -# >=net-mail/mailbase-0.00 -# selinux? ( sec-policy/selinux-postfix )" - -#if use devel; then -# MY_SRC=${DEV_SRC} -#fi - -S=${WORKDIR}/${MY_SRC} - -group_user_check() { - einfo "checking for postfix group... create if missing." - enewgroup postfix 207 - einfo "checking for postdrop group... create if missing." - enewgroup postdrop 208 - einfo "checking for postfix user... create if missing." - enewuser postfix 207 -1 /var/spool/postfix postfix,mail -} - -pkg_setup() { - # do not upgrade live from postfix <2.4. - if [[ -f /var/lib/init.d/started/postfix ]] ; then - if has_version '<mail-mta/postfix-2.4.0' ; then - if [ "${FORCE_UPGRADE}" ]; then - echo - ewarn "You are upgrading from a incompatible version and" - ewarn "you have FORCE_UPGRADE set, will build this package with postfix running." - ewarn "You MUST stop postfix BEFORE install it to your system." - echo - else - echo - eerror "You are upgrading from a incompatible version." - eerror "You MUST stop postfix BEFORE install it to your system." - eerror "If you want a minimal downtime, emerge postfix with:" - eerror "\`FORCE_UPGRADE=1 emerge --buildpkgonly postfix\`; then" - eerror "\`/etc/init.d/postfix stop && emerge --usepkgonly postfix\`" - eerror "run etc-update or dispatch-conf and merge the configuration files." - eerror "Next /etc/init.d/postfix start" - die "upgrade from an incompatible version!" - echo - fi - - else - echo - ewarn "It is safe to upgrade your current version while it's running." - ewarn "If you don't want to take any chance; please hit Ctrl+C now;" - ewarn "stop Postfix then emerge again." - ewarn "You have been warned!" - ewarn "Waiting 5 seconds before continuing." - echo - epause 5 - fi - fi - - echo - ewarn "Read \"ftp://ftp.porcupine.org/mirrors/postfix-release/official/${MY_SRC}.RELEASE_NOTES\"" - ewarn "for incompatible changes before continue." - ewarn "Bugs should be filed at \"http://bugs.gentoo.org\"" - ewarn "assign to \"net-mail@gentoo.org\"." - echo - #epause 5 - - # put out warnings to work around bug #45764 - if has_version '<=mail-mta/postfix-2.0.18'; then - echo - ewarn "You are upgrading from postfix-2.0.18 or earlier, one of the empty queue" - ewarn "directory get deleted during unmerge the older version (#45764). Please run" - ewarn "\`etc/postfix/post-install upgrade-source\` to recreate them." - echo - #epause 5 - fi - - #TLS non-prod warn - if use ssl; then - echo - ewarn "you have \"ssl\" in your USE flags, TLS will be enabled." - ewarn "This service entry is incompatible with previous TLS patch." - ewarn "Visit http://www.postfix.org/TLS_README.html for more info." - echo - #epause 5 - fi - - # IPV6 non-prod warn - if use ipv6; then - echo - ewarn "you have \"ipv6\" in your USE flags, IPV6 will be enabled." - ewarn "Visit http://www.postfix.org/IPV6_README.html for more info." - echo - fi - - if use sasl ; then - echo - elog "postfix 2.3 and newer supports two SASL implementations." - elog "Cyrus SASL and Dovecot protocol version 1 (server only)" - elog "detail at http://www.postfix.org/SASL_README.html" - echo - fi - - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" -} - -src_unpack() { - unpack ${A} && cd "${S}" - - # Cyrus support is now commented out in upstream master.cf - # epatch "${FILESDIR}/${PN}-master.cf.patch" - - if use vda ; then - epatch "${WORKDIR}/${VDA_P}.patch" - fi - - # Postfix does not get the FQDN if no hostname is configured. - # Postfix 2.4 no longer requires a domain name, it uses "localdomain" - # by default which will not be resolved, so let's drop that patch. - # epatch "${FILESDIR}/${PN}-2.0.9-get-FQDN.patch" - - sed -i -e "/^#define ALIAS_DB_MAP/s|hash:/etc/aliases|hash:/etc/mail/aliases|" \ - src/util/sys_defs.h || die "sed failed" - -} - -src_compile() { - cd ${S} - # added -Wl,-z,now wrt 62674. - # remove -ldl as it is not necessary, resolve bug #106446. - # -Wl,-z,now replaced by $(bindnow-flags) - local mycc="-DHAS_PCRE" mylibs="$(bindnow-flags) -L/usr/lib -lpcre -lcrypt -lpthread" - - use pam && mylibs="${mylibs} -lpam" - - if use ldap ; then - mycc="${mycc} -DHAS_LDAP" - mylibs="${mylibs} -lldap -llber" - fi - - if use mysql ; then - mycc="${mycc} -DHAS_MYSQL -I/usr/include/mysql" - mylibs="${mylibs} -lmysqlclient -lm -lz" - fi - - if use postgres ; then - if best_version '=dev-db/postgresql-7.3*' ; then - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql" - else - mycc="${mycc} -DHAS_PGSQL -I/usr/include/postgresql/pgsql" - fi - mylibs="${mylibs} -lpq" - fi - - if use ssl ; then - mycc="${mycc} -DUSE_TLS" - mylibs="${mylibs} -lssl -lcrypto" - fi - - if use sasl ; then - if use dovecot-sasl ; then - # set dovecot as default. - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" - 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 - sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" src/util/sys_defs.h || \ - die "sed failed" - fi - - if use cdb; then - mycc="${mycc} -DHAS_CDB" - CDB_LIBS="" - - # tinycdb is preferred. - if has_version dev-db/tinycdb; then - einfo "build with dev-db/tinycdb" - # ugly hack because gentoo doesn't install cdb.h - cp /usr/include/tinycdb.h ${S}/src/util/cdb.h || die \ - "failed to cp /usr/include/tinycdb.h to ${S}/util/cdb.h" - CDB_LIBS="-ltinycdb" - else - CDB_PATH="/usr/lib" - for i in cdb.a alloc.a buffer.a unix.a byte.a - do CDB_LIBS="${CDB_LIBS} ${CDB_PATH}/${i}" - done - fi - - mylibs="${mylibs} ${CDB_LIBS}" - fi - - mycc="${mycc} -DDEF_DAEMON_DIR=\\\"/usr/lib/postfix\\\"" - mycc="${mycc} -DDEF_MANPAGE_DIR=\\\"/usr/share/man\\\"" - mycc="${mycc} -DDEF_README_DIR=\\\"/usr/share/doc/${PF}/readme\\\"" - mycc="${mycc} -DDEF_HTML_DIR=\\\"/usr/share/doc/${PF}/html\\\"" - - ebegin "Starting make makefiles..." - - local my_cc=$(tc-getCC) - einfo "CC=${my_cc:=gcc}" - - # workaround for bug #76512 - [ "$(gcc-version)" == "3.4" ] && use hardened && replace-flags -O? -Os - - make DEBUG="" CC="${my_cc:=gcc}" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ - makefiles || die "configure problem" - - emake || die "compile problem" -} - -src_install () { - /bin/sh postfix-install \ - -non-interactive \ - install_root="${D}" \ - config_directory="/usr/share/doc/${PF}/defaults" \ - readme_directory="/usr/share/doc/${PF}/readme" \ - || die "postfix-install failed" - - # Fix spool removal on upgrade. - rm -rf "${D}/var" - keepdir /var/spool/postfix - - # Install an rmail for UUCP, closing bug #19127. - dobin auxiliary/rmail/rmail - - # mailwrapper stuff - if use mailwrapper ; then - mv "${D}/usr/sbin/sendmail" "${D}/usr/sbin/sendmail.postfix" - mv "${D}/usr/bin/rmail" "${D}/usr/bin/rmail.postfix" - # mailer-config support - #rm "${D}/usr/bin/mailq" "${D}/usr/bin/newaliases" - - mv "${D}/usr/share/man/man1/sendmail.1" \ - "${D}/usr/share/man/man1/sendmail-postfix.1" - mv "${D}/usr/share/man/man1/newaliases.1" \ - "${D}/usr/share/man/man1/newaliases-postfix.1" - mv "${D}/usr/share/man/man1/mailq.1" \ - "${D}/usr/share/man/man1/mailq-postfix.1" - mv "${D}/usr/share/man/man5/aliases.5" \ - "${D}/usr/share/man/man5/aliases-postfix.5" - - # regular ebuild. - insinto /etc/mail - doins "${FILESDIR}/mailer.conf" - # mailer-config support - #mailer_install_conf - else - # Provide another link for legacy FSH. - dosym /usr/sbin/sendmail /usr/lib/sendmail - fi - - # Install qshape tool. - dobin auxiliary/qshape/qshape.pl - - # performance tuning tools. - 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. - fowners root:postdrop /usr/sbin/post{drop,queue} - fperms 02711 /usr/sbin/post{drop,queue} - - keepdir /etc/postfix - mv ${D}/usr/share/doc/${PF}/defaults/{*.cf,post*-*} ${D}/etc/postfix - if use mbox ; then - mypostconf="mail_spool_directory=/var/spool/mail" - else - mypostconf="home_mailbox=.maildir/" - fi - "${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 || \ - die "newinitd failed" - - mv "${S}/examples" "${D}/usr/share/doc/${PF}/" - dodoc *README COMPATIBILITY HISTORY INSTALL LICENSE PORTING RELEASE_NOTES* - dohtml html/* - - pamd_mimic_system smtp auth account - - # do not install server.{key,pem) if they are exist. - if use ssl && [[ ! -f /etc/ssl/postfix/server.key && ! -f /etc/ssl/postfix/server.pem ]]; then - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" - insinto /etc/ssl/postfix - docert server - fowners postfix:mail /etc/ssl/postfix/server.{key,pem} - fi - - if use sasl ; then - insinto /etc/sasl2 - newins "${FILESDIR}/smtp.sasl" smtpd.conf - fi -} - -pkg_postinst() { - # add postfix, postdrop user/group. Bug #77565. - group_user_check || die "failed to check/add needed user/group" - - ebegin "Fixing queue directories and permissions" - "${ROOT}/etc/postfix/post-install" upgrade-permissions - echo - ewarn "If you upgraded from postfix-1.x, you must revisit" - ewarn "your configuration files. See" - ewarn " /usr/share/doc/${PF}/RELEASE_NOTES" - ewarn "for a list of changes." - - if [ ! -e /etc/mail/aliases.db ] ; then - echo - 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." - fi - - # regular ebuild - if ! use mailwrapper && [[ -e /etc/mailer.conf ]] - then - einfo - einfo "Since you emerged $PN without mailwrapper in USE," - einfo "you probably want to 'emerge -C mailwrapper' now." - einfo - fi - # mailer-config support - #mailer_pkg_postinst -} - |