diff options
author | Eray Aslan <eras@gentoo.org> | 2012-02-18 19:40:32 +0000 |
---|---|---|
committer | Eray Aslan <eras@gentoo.org> | 2012-02-18 19:40:32 +0000 |
commit | 4ae62b1879cc6409ff76bedec4553e408e86c343 (patch) | |
tree | b3e5de9b15d45f614a6b0dffff12ca7b4d0a063d /mail-mta | |
parent | alpha/ia64/s390/sh/sparc stable wrt #400671 (diff) | |
download | historical-4ae62b1879cc6409ff76bedec4553e408e86c343.tar.gz historical-4ae62b1879cc6409ff76bedec4553e408e86c343.tar.bz2 historical-4ae62b1879cc6409ff76bedec4553e408e86c343.zip |
version bump. fown any and all .keep files - bug #404391
Package-Manager: portage-2.1.10.47/cvs/Linux x86_64
Diffstat (limited to 'mail-mta')
-rw-r--r-- | mail-mta/postfix/ChangeLog | 9 | ||||
-rw-r--r-- | mail-mta/postfix/Manifest | 34 | ||||
-rw-r--r-- | mail-mta/postfix/postfix-2.10_pre20120218.ebuild (renamed from mail-mta/postfix/postfix-2.10_pre20120202.ebuild) | 12 | ||||
-rw-r--r-- | mail-mta/postfix/postfix-2.9.1.ebuild | 315 |
4 files changed, 350 insertions, 20 deletions
diff --git a/mail-mta/postfix/ChangeLog b/mail-mta/postfix/ChangeLog index 212f64ed2a03..2815735159ab 100644 --- a/mail-mta/postfix/ChangeLog +++ b/mail-mta/postfix/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for mail-mta/postfix # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/ChangeLog,v 1.337 2012/02/13 07:36:20 eras Exp $ +# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/ChangeLog,v 1.338 2012/02/18 19:40:32 eras Exp $ + +*postfix-2.10_pre20120218 (18 Feb 2012) +*postfix-2.9.1 (18 Feb 2012) + + 18 Feb 2012; Eray Aslan <eras@gentoo.org> +postfix-2.9.1.ebuild, + -postfix-2.10_pre20120202.ebuild, +postfix-2.10_pre20120218.ebuild: + version bump. fown any and all .keep files - bug #404391 13 Feb 2012; Eray Aslan <eras@gentoo.org> postfix-2.9.0.ebuild, postfix-2.9.0-r1.ebuild: diff --git a/mail-mta/postfix/Manifest b/mail-mta/postfix/Manifest index 6b3d364aa492..1bdf198dee8a 100644 --- a/mail-mta/postfix/Manifest +++ b/mail-mta/postfix/Manifest @@ -6,7 +6,7 @@ AUX postfix.rc6.2.6 1996 RMD160 a7936897d1b8249e3fc0da2426afcbbe25bbe0ce SHA1 34 AUX postfix_no-berkdb.patch 2729 RMD160 2e80e5c446b58afe8cda35991ac3af5f3db3f7eb SHA1 8c6d8695bf347769f957a79f3320fcff8d844315 SHA256 c21e9582346c913b3033ec6d3567d0b0bd3576ad64052fed48a5cf78d7ad92fc AUX smtp.pass 141 RMD160 799433a4ee9e9e32f20aa2d31f85f33faa2bc7e6 SHA1 e1d75aa259fa07b257a617e056662aecfd19957f SHA256 c9b3b56a8df2367cc15bc43a70304fac7ebdd7697e1d450d1bcb4bfdd3e078e9 AUX smtp.sasl 147 RMD160 8565ca413ec1a9e369be227643d3610124b34566 SHA1 565035b230d4997a207d146609336dfe643c6ed3 SHA256 0ef6a2a7846498f56b9a8879f561a51c1e3a203ba90b2991d499afa69fd85629 -DIST postfix-2.10-20120202.tar.gz 3759818 RMD160 e24e8847e8970fedebe228d1731e43f3d1c01df6 SHA1 f52288557d6bd3b7fffd8c46dc63a927de381083 SHA256 a1b9e3feeaff7addd1df370d4931933135dcc41b151de9219b94e5fa688faa86 +DIST postfix-2.10-20120218.tar.gz 3760226 RMD160 d9935129ff9059b4216de0c4952447cc929f2fd8 SHA1 db0ee370224abb0be3b2e057788f739d606d46bf SHA256 4079af81f8ea6bfa02cad1f384a64714e3c84a2959317e06f13eb46b6c17a643 DIST postfix-2.7.4.tar.gz 3423968 RMD160 4f3e0db43c55cd50b3fb4493dbc698ff3f343294 SHA1 c755ceb3a5ee983f3b72f08e1fffb6384b1f1865 SHA256 9bad5851e8a7c97890ee9465e7f675f7826d56361369d3e792a79eaf98ed2b11 DIST postfix-2.7.5.tar.gz 3425071 RMD160 a900ff09c0a54382a4af62b609f6ddaba17963fc SHA1 066cc87f602f2daf1d3207de92ca08de9eb16bab SHA256 2fe408f49bc8540bc41b44f1b7ee7a27561f1baa4e25ef55645778ba96d15932 DIST postfix-2.7.6.tar.gz 3425286 RMD160 9961b959ae34a1fe1d3bf70acce1f16e5ada255d SHA1 9a2cd652abdc0d3cf29563261d5c0f407d8d7bf9 SHA256 4f7546d25463c5fc300eccd05c302a44458b1cc8dfda02c7205daa0038d5ab17 @@ -18,11 +18,12 @@ DIST postfix-2.8.6.tar.gz 3647498 RMD160 1f85ff0e9432109342436144f6963d39b79910e DIST postfix-2.8.7.tar.gz 3647643 RMD160 ab0700f8f340fad11bf2a294a36ff1d70a1a8783 SHA1 81c87aceff4d9af67a304354bab9c99ac98fc8a0 SHA256 5c13465ab47414e9aa2e857851eff1a3f020cebd056e0dde6094ece3552806e5 DIST postfix-2.8.8.tar.gz 3648317 RMD160 eb71b542af2a00da5f12220946731560ff20377d SHA1 b712b25a105c132b40b63aef49268ea117b86f03 SHA256 77dc98e21da48901d326e98f918ea50d6cad66ee5812033b5aab342c9578328c DIST postfix-2.9.0.tar.gz 3768091 RMD160 0454dce2e82edb11f7e61f8038154c32a47bc605 SHA1 a04a72a8b9436279a30b7d1b62197be63124a132 SHA256 aed9b360eb74f46bfd6c6efe4eb724ce013cb8c6d4ad43888dd940aa2d33e6ec +DIST postfix-2.9.1.tar.gz 3768329 RMD160 5a97bcfe16a5ed343e449e73cde99c62b47c4aeb SHA1 d4f6572ab1ac5fc15626ac2de6d18c340aae2cef SHA256 d1dbe901f76ab6fd51f9c8c61eb46bd6fe0bc8b13823330e397eb1b00e940cbe DIST postfix-vda-2.7.2.patch 59667 RMD160 ebec1fa4a4c6b3c0160407b09aacf8357c936148 SHA1 ac712922f45856965118fa7b8551ece1ccb524db SHA256 f9b12376983833ef9305f7696e9792b62058f242ff2630aeb0866cf686f0a14b DIST postfix-vda-v10-2.8.1.patch 56777 RMD160 42f6351d645cc7a211aea86cc35e1f3b10b50da1 SHA1 6b36480be036e7b7aa834fd904a2aa57c537cd40 SHA256 13ca7430b68dc19e21ee26c1c1109e1527a656777fa2f224cd3ce2d594435f12 DIST postfix-vda-v10-2.8.3.patch 56777 RMD160 ce30005d590d884c589612e65dbd34cbdbf84a31 SHA1 c27217b9af33c86a44bbb4469b7ebd4203210f7a SHA256 02599bdf16e7d77fe6043d1dac972daecdd40c4b2758579200d6ccb11e83acaa DIST postfix-vda-v10-2.8.5.patch 56777 RMD160 fc1622a91c88d6d91782b9d4e9dfecd3f603251b SHA1 b9f8480a738dccf0023698274c8d5f5cb4fb308f SHA256 0106e0bfdea8bb3888e8f33e7cb4b1530d171abbf2d3ac91567f91240e4b6b5a -EBUILD postfix-2.10_pre20120202.ebuild 9307 RMD160 ae51672a589398a8a4daa10ce7251c553710aa7a SHA1 ae757bf69ac3f53f9cb70827fd25992490acf173 SHA256 ade013e4e0a1f579446b0cf92ca71a9f35b880a3c951f8ad3bd62c8be6f4fcdc +EBUILD postfix-2.10_pre20120218.ebuild 9545 RMD160 da9cb1ef211b1814883a46db1f6194095c82cc42 SHA1 96ade120dd39405708f1784276fe6d211951e677 SHA256 dfb5d89f253f9c506c77440891acfb702073bf4186f830902eed37a93e8e289b EBUILD postfix-2.7.4.ebuild 7562 RMD160 7b1874aa1c5fb0357ab8bafd740e38ec00ecdb45 SHA1 db22462d85927f3afc7c172597842d1fc0ac5fb5 SHA256 aaa33b10ecc21d9dcd8256b12974912bf3481544c5f7cb5119da7b52fcefc9d9 EBUILD postfix-2.7.5.ebuild 7573 RMD160 767bf6a470af95a14e1e725fc77287d3f3907ffd SHA1 2f897791234a3c2bfbcb3fe39406c60e2f7e9b09 SHA256 b348d000438cae031fa48e04a938aa623dd722120699a9969cccc99d05842122 EBUILD postfix-2.7.6.ebuild 7573 RMD160 6e8c3b59101d7d4d19f20f0df24b5f53d2a23957 SHA1 f703ec9a31a1a6a2e3930fbd7660f998d1753c27 SHA256 7ade993dbeba99be1ab0f97d35227fbb0d208f70e4a718bf3d2a56bc4983f512 @@ -37,22 +38,23 @@ EBUILD postfix-2.8.7.ebuild 8422 RMD160 039622b906a8c3b62cda6780f213e042d2e06e9f EBUILD postfix-2.8.8.ebuild 8433 RMD160 a1670cca48ff09cb8ec6243bda4c14fe6c2baad8 SHA1 051e023f04cc06bb87448ce2307cc94ca0b79469 SHA256 bba214631e160d68020f83b1f8fbadffb45e5d2e1d097c2a6de75f3bf9de39e6 EBUILD postfix-2.9.0-r1.ebuild 9557 RMD160 97300e05fc507d1b90146f2c6cb1f45f2c7bc5db SHA1 df1669c2af777951a244dbb7f60f36f529ee169f SHA256 21b0fdad4a7a065e20dd39bd2b75bfc4da2c066bd76558a304fd2114ed4c81a7 EBUILD postfix-2.9.0.ebuild 9554 RMD160 6077663c5d24ee7b97069befd5e37833e8f10f9a SHA1 41777f9b4f2120c6f99ab0ea26866f65c1321e14 SHA256 a5f517184ac04843bf5c09fc4a76d8b8ecde981b6af463f598a48262bc86bced -MISC ChangeLog 77626 RMD160 6643ac6fb4c57365fd3fc65bad20b8112ddf557f SHA1 9debfe3017f580d81abe36f162ae17055543e190 SHA256 8350c53ce66072e839e64d77b9a39b04154a732578adbb507cff19ce989f2ba8 +EBUILD postfix-2.9.1.ebuild 9529 RMD160 9e9a56b93c6479db76aa82f0e8b011334c1030d8 SHA1 9ca3a88679b18be7d6e25e88dae7028483314577 SHA256 aa5f398f2ce0d9f215db7f87d0bea6cb0caaee4da845d42a85ce4120dd6a784f +MISC ChangeLog 77893 RMD160 daa724220d23b9fe15080aa45aca6d81688451c3 SHA1 ce02a6dc4ba086f30698ddcc6acd8e0efe97206e SHA256 22b61d0cceb5f801095475daa8f4dea6d4c288a50875f64f99e3d6fb78762e43 MISC metadata.xml 610 RMD160 095d8cd529350f58c64d6d2eb40e8534d3dddfae SHA1 d53048933e7490f3f342ccf8972c191ee8030ccd SHA256 00b7ef524664b20a9df7642573745b1d17b0b51f005ffd150ac6dccba38dee88 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.18 (GNU/Linux) -iQIcBAEBCAAGBQJPOL2DAAoJEHfx8XVYajsfc80P/j5B3P4OmNZO32VOK8sZyYQK -8c2qH/zna3K5oujCCJORhrBacDHNvWHgJIkCnzu9ryYed/Utvg+DwlVhCpyZg/wY -hu+Rz9WHK0lMYYQ+x2LY6h8hoB3OZLF3evbN68gqsNWz8T4Q9crjCYYdTIBYbM+C -r1b7d5k8LJXhmAXBQabTn1cA5l+WtB0yUzTAURwa4zUW/VO04msvIBTSOVxJnwgR -fcohG1jOXPD73LwAz3WZg1zPtnwmZZexzhi/FI6Awe+gF4z6j9gs7VeBm63itIlW -qi42XGKLfh9iFkcTASdvPbxVywLKLm9UyzRybTAs2bI9Gp6h/fu3/XPqhxN8MVk/ -OGj3W0TwVQvSb5wgqJIt/fiPC146Hk6z27sSpqzGR8rH1dvFaCwxPggi1qD32u0g -fUS3gok/0uD+kB2G0beTTqgDvqZrHSRsHpQIfz/E4FCX5XSIt4bxPSkFLJDdCJ+o -+JrTbaSG+EZmZT3/y8/MUOVQKpYxyU5PzM6oBSUAJh0p7mC4fw79PcN2kKv2P/rO -CdzE4zh6Vz4yXI+6AkBwg9xR5e4BTtNUIFDKU1aLgo/wwf113mzkcwjWfpiZPMZz -r6BTNFWScq2zylFMO9JMChGN68qVgfv58WTuuAHzEEWeh/8P9exRjerSl0df5G/H -QEjsqJl4WXen4NMiPkw8 -=lT9L +iQIcBAEBCAAGBQJPP/61AAoJEHfx8XVYajsfgUQP/2qJk82mTZPK8VPYAzyAK4ce +bfsjfOir4C5sJcqYDW64l4VrCmAwnWXtUGiIrvH86VjoE1x7tDu+kA3bRMaYBeOs +XUFG+rpwa61CrhTMJcQXG3uljKcFzLoZ1U50HsNtIL2m915gjmJAlkpNhzYIoIYV +E0noSijI3dhLyykDwLbgo48/KN0IbjaxEzTEQ/O2J4+ZNgDsjs9qCTdDOHMOR6TL +kRjS0oAyJK7d9lGkmeAsRKSGHrTgJdUz4wmh8PCsBaI7Kg35z6zi4VvVfB1FO+mp +uMJCwCPnj1uIJtTKqFCIRZL2guFNaHk4HBRBmxIsvb7fpw3vqtRPCuxiI7JpOu3v +CazC20QLQudB1f73ll7ax7C000OR4g1m8f6o0ws89ascmEa0K7/n2rZB5dmGqse7 +4GGJDPX8O52ep91L30TVo0UoMC6yB1ZMCm8wWfwBg9M41zSxZJqzSuSacTQXPgCU +8q+1lRTR/oop8YJddyo6W5jtTPB4FlAwwuQky39hgIPB4RHKyFzeLnZHetbKT2Tb +sosj9jUKPAjF3SPQ8W+mAvuFdWUB9bvO9d/scsd2XRssIip/wIrnZQndG4ibQcyy +XtmJ5IGtfA0/9DvPNXi9qPBWNPcYHwaeWHBkQKO0mLlaeWBLkOzSnsIXb576NnXN +3L4jUutfsUkcqOYjj2WD +=hfaL -----END PGP SIGNATURE----- diff --git a/mail-mta/postfix/postfix-2.10_pre20120202.ebuild b/mail-mta/postfix/postfix-2.10_pre20120218.ebuild index 86574c4af755..3d091976ab22 100644 --- a/mail-mta/postfix/postfix-2.10_pre20120202.ebuild +++ b/mail-mta/postfix/postfix-2.10_pre20120218.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2012 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.10_pre20120202.ebuild,v 1.2 2012/02/05 06:13:58 eras Exp $ +# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.10_pre20120218.ebuild,v 1.1 2012/02/18 19:40:32 eras Exp $ EAPI=4 @@ -55,7 +55,9 @@ RDEPEND="${DEPEND} !>=mail-mta/ssmtp-2.64-r2[mta] !net-mail/fastforward" -REQUIRED_USE="ldap-bind? ( ldap sasl )" +# vda patch is broken for 2.10 +REQUIRED_USE="ldap-bind? ( ldap sasl ) + !vda" S="${WORKDIR}/${MY_SRC}" @@ -215,7 +217,7 @@ src_install () { dodir /var/lib/postfix keepdir /var/lib/postfix fowners postfix:postfix /var/lib/postfix - fowners postfix:postfix /var/lib/postfix/.keep_${CATEGORY}_${PN}-${SLOT} + fowners postfix:postfix /var/lib/postfix/.keep* fperms 0750 /var/lib/postfix fowners root:postdrop /usr/sbin/post{drop,queue} fperms 02711 /usr/sbin/post{drop,queue} @@ -305,5 +307,9 @@ pkg_postinst() { ewarn "Please turn on berkdb USE flag for hash or btree table" ewarn "lookup support.\n" fi + ewarn "Postfix daemons now live under /usr/libexec/postfix" + ewarn "Please adjust your main.cf accordingly by running" + ewarn "etc-update/dispatch-conf or similar and accepting the new" + ewarn "daemon_directory setting." fi } diff --git a/mail-mta/postfix/postfix-2.9.1.ebuild b/mail-mta/postfix/postfix-2.9.1.ebuild new file mode 100644 index 000000000000..13f329853762 --- /dev/null +++ b/mail-mta/postfix/postfix-2.9.1.ebuild @@ -0,0 +1,315 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/postfix-2.9.1.ebuild,v 1.1 2012/02/18 19:40:32 eras Exp $ + +EAPI=4 + +inherit eutils multilib ssl-cert toolchain-funcs flag-o-matic pam versionator + +MY_PV="${PV/_rc/-RC}" +MY_SRC="${PN}-${MY_PV}" +MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" +VDA_PV="2.8.5" +VDA_P="${PN}-vda-v10-${VDA_PV}" +RC_VER="2.6" + +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 ) " + +LICENSE="IBM" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd" +IUSE="+berkdb cdb doc dovecot-sasl hardened ldap ldap-bind memcached mbox mysql nis pam postgres sasl selinux sqlite ssl vda" + +DEPEND=">=dev-libs/libpcre-3.4 + dev-lang/perl + berkdb? ( >=sys-libs/db-3.2 ) + cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r1 ) ) + ldap? ( net-nds/openldap ) + ldap-bind? ( net-nds/openldap[sasl] ) + mysql? ( virtual/mysql ) + pam? ( virtual/pam ) + postgres? ( dev-db/postgresql-base ) + sasl? ( >=dev-libs/cyrus-sasl-2 ) + sqlite? ( dev-db/sqlite:3 ) + ssl? ( >=dev-libs/openssl-0.9.6g )" + +RDEPEND="${DEPEND} + dovecot-sasl? ( net-mail/dovecot ) + memcached? ( net-misc/memcached ) + net-mail/mailbase + selinux? ( sec-policy/selinux-postfix ) + !mail-mta/courier + !mail-mta/esmtp + !mail-mta/exim + !mail-mta/mini-qmail + !mail-mta/msmtp[mta] + !mail-mta/nbsmtp + !mail-mta/netqmail + !mail-mta/nullmailer + !mail-mta/qmail-ldap + !mail-mta/sendmail + !<mail-mta/ssmtp-2.64-r2 + !>=mail-mta/ssmtp-2.64-r2[mta] + !net-mail/fastforward" + +# vda patch is broken in 2.9 +REQUIRED_USE="ldap-bind? ( ldap sasl ) + !vda" + +S="${WORKDIR}/${MY_SRC}" + +pkg_setup() { + # Add postfix, postdrop user/group (bug #77565) + enewgroup postfix 207 + enewgroup postdrop 208 + enewuser postfix 207 -1 /var/spool/postfix postfix,mail +} + +src_prepare() { + if use vda; then + epatch "${DISTDIR}"/${VDA_P}.patch + fi + + if ! use berkdb; then + epatch "${FILESDIR}/${PN}_no-berkdb.patch" + fi + + sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ + src/util/sys_defs.h || die "sed failed" + + # change default paths to better comply with portage standard paths + sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" +} + +src_configure() { + # Make sure LDFLAGS get passed down to the executables. + local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -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 $(mysql_config --include)" + mylibs="${mylibs} $(mysql_config --libs)" + fi + + if use postgres; then + mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" + mylibs="${mylibs} -lpq -L$(pg_config --libdir)" + fi + + if use sqlite; then + mycc="${mycc} -DHAS_SQLITE" + mylibs="${mylibs} -lsqlite3" + fi + + if use ssl; then + mycc="${mycc} -DUSE_TLS" + mylibs="${mylibs} -lssl -lcrypto" + fi + + # broken. and "in other words, not supported" by upstream. + # Use inet_protocols setting in main.cf + #if ! use ipv6; then + # mycc="${mycc} -DNO_IPV6" + #fi + + if use sasl; then + if use dovecot-sasl; then + # Set dovecot as default. + mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" + fi + if use ldap-bind; then + mycc="${mycc} -DUSE_LDAP_SASL" + fi + mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" + mylibs="${mylibs} -lsasl2" + elif use dovecot-sasl; then + mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" + fi + + if ! use nis; then + sed -i -e "s|#define HAS_NIS|//#define HAS_NIS|g" \ + src/util/sys_defs.h || die "sed failed" + fi + + if ! use berkdb; then + mycc="${mycc} -DNO_DB" + if use cdb; then + # change default hash format from Berkeley DB to cdb + sed -i -e "s/hash/cdb/" src/util/sys_defs.h || die + fi + fi + + if use cdb; then + mycc="${mycc} -DHAS_CDB -I/usr/include/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 + + # 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 + + # Workaround for bug #76512 + if use hardened; then + [[ "$(gcc-version)" == "3.4" ]] && replace-flags -O? -Os + fi + + # Remove annoying C++ comment style warnings - bug #378099 + append-flags -Wno-comment + + emake DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" makefiles +} + +src_install () { + /bin/sh postfix-install \ + -non-interactive \ + install_root="${D}" \ + config_directory="/etc/postfix" \ + manpage_directory="/usr/share/man" \ + readme_directory="/usr/share/doc/${PF}/readme" \ + html_directory="/usr/share/doc/${PF}/html" \ + command_directory="/usr/sbin" \ + mailq_path="/usr/bin/mailq" \ + newaliases_path="/usr/bin/newaliases" \ + sendmail_path="/usr/sbin/sendmail" \ + || die "postfix-install failed" + + # Fix spool removal on upgrade + rm -Rf "${D}"/var + keepdir /var/spool/postfix + + # Install rmail for UUCP, closes bug #19127 + dobin auxiliary/rmail/rmail + + # Provide another link for legacy FSH + dosym /usr/sbin/sendmail /usr/$(get_libdir)/sendmail + + # Install qshape tool + dobin auxiliary/qshape/qshape.pl + doman man/man1/qshape.1 + + # 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 + dodir /var/lib/postfix + keepdir /var/lib/postfix + fowners postfix:postfix /var/lib/postfix + fowners postfix:postfix /var/lib/postfix/.keep* + fperms 0750 /var/lib/postfix + fowners root:postdrop /usr/sbin/post{drop,queue} + fperms 02711 /usr/sbin/post{drop,queue} + + keepdir /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 + # do not start mysql/postgres unnecessarily - bug #359913 + use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" + use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" + + mv "${S}"/examples "${D}"/usr/share/doc/${PF}/ + mv "${D}"/etc/postfix/{*.default,makedefs.out} "${D}"/usr/share/doc/${PF}/ + + dodoc *README COMPATIBILITY HISTORY INSTALL PORTING RELEASE_NOTES* + + pamd_mimic_system smtp auth account + + if use sasl; then + insinto /etc/sasl2 + newins "${FILESDIR}"/smtp.sasl smtpd.conf + fi + + # header files + insinto /usr/include/postfix + doins include/*.h + + # Remove unnecessary files + rm -f "${D}"/etc/postfix/{*LICENSE,access,aliases,canonical,generic} + rm -f "${D}"/etc/postfix/{header_checks,relocated,transport,virtual} +} + +pkg_preinst() { + # default for inet_protocols changed from ipv4 to all in postfix-2.9. + # check inet_protocols setting in main.cf and modify if necessary to prevent + # performance loss with useless DNS lookups and useless connection attempts. + [[ -d ${ROOT}/etc/postfix ]] && { + if [[ "$(${D}/usr/sbin/postconf -dh inet_protocols)" != "ipv4" ]]; then + if [[ ! -n "$(${D}/usr/sbin/postconf -c ${ROOT}/etc/postfix -nh inet_protocols)" ]]; + then + ewarn "\nCOMPATIBILITY: adding inet_protocols=ipv4 to main.cf." + ewarn "That will keep the same behaviour as previous postfix versions." + ewarn "Specify inet_protocols explicitly if you want to enable IPv6.\n" + else + # delete inet_protocols setting. there is already one in /etc/postfix + sed -i -e /inet_protocols/d "${D}"/etc/postfix/main.cf || die + fi + fi + } +} + +pkg_postinst() { + # Do not install server.{key,pem) SSL certificates if they already exist + if use ssl && [[ ! -f "${ROOT}"/etc/ssl/postfix/server.key \ + && ! -f "${ROOT}"/etc/ssl/postfix/server.pem ]] ; then + SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}" + install_cert /etc/ssl/postfix/server + chown postfix:mail "${ROOT}"/etc/ssl/postfix/server.{key,pem} + fi + + if [[ ! -e /etc/mail/aliases.db ]] ; then + ewarn + ewarn "You must edit /etc/mail/aliases to suit your needs" + ewarn "and then run /usr/bin/newaliases. Postfix will not" + ewarn "work correctly without it." + ewarn + fi + + if [[ $(get_version_component_range 2 ${REPLACING_VERSIONS}) -lt 9 ]]; then + elog "If you are using old style postfix instances by symlinking" + elog "startup scripts in ${ROOT}etc/init.d, please consider" + elog "upgrading your config for postmulti support. For more info:" + elog "http://www.postfix.org/MULTI_INSTANCE_README.html" + if ! use berkdb; then + ewarn "\nPostfix is installed without BerkeleyDB support." + ewarn "Please turn on berkdb USE flag for hash or btree table" + ewarn "lookup support.\n" + fi + ewarn "Postfix daemons now live under /usr/libexec/postfix" + ewarn "Please adjust your main.cf accordingly by running" + ewarn "etc-update/dispatch-conf or similar and accepting the new" + ewarn "daemon_directory setting." + fi +} |