Gentoo Archives: gentoo-commits

From: Eray Aslan <eras@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: mail-mta/postfix/
Date: Mon, 10 Oct 2016 11:03:41
Message-Id: 1476097171.95ae52580b72518e1d93b8d8aadb8099cee21f3d.eras@gentoo
1 commit: 95ae52580b72518e1d93b8d8aadb8099cee21f3d
2 Author: Eray Aslan <eras <AT> gentoo <DOT> org>
3 AuthorDate: Mon Oct 10 10:59:31 2016 +0000
4 Commit: Eray Aslan <eras <AT> gentoo <DOT> org>
5 CommitDate: Mon Oct 10 10:59:31 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=95ae5258
7
8 mail-mta/postfix: remove old
9
10 Package-Manager: portage-2.3.1
11
12 mail-mta/postfix/Manifest | 3 -
13 mail-mta/postfix/postfix-3.0.4.ebuild | 314 ----------------------------------
14 mail-mta/postfix/postfix-3.0.5.ebuild | 314 ----------------------------------
15 mail-mta/postfix/postfix-3.0.6.ebuild | 314 ----------------------------------
16 4 files changed, 945 deletions(-)
17
18 diff --git a/mail-mta/postfix/Manifest b/mail-mta/postfix/Manifest
19 index 0415b9e..b97519a 100644
20 --- a/mail-mta/postfix/Manifest
21 +++ b/mail-mta/postfix/Manifest
22 @@ -1,9 +1,6 @@
23 DIST postfix-2.10.9.tar.gz 3820525 SHA256 e47eb56db2d238b9c5a5147a516fa406ab6afb102cedb4bd08273e979ae95d82 SHA512 c77df7ccc051bd72271dc5298da0ca4e45397b1ba96fc8be31e095f5b15cd30ebc0b29cf638e76efc65503cb241efd937f2d64aaa97243402c35e2927b7a7b91 WHIRLPOOL 3a7acb90ae03366e2ed24dfbd2e07619f0694abe098a621c6f9202e4d43a968376b5a52f2a65223634cf921af0a7156b0272ca15ad188a1b61fe4fb9cc97cab7
24 DIST postfix-3.0.2.tar.gz 4239235 SHA256 68256314202f5f0f24022d64f7ac664d28fa1394d07c84a37c3fc7a2d040be80 SHA512 b097ff5cb1707361af568bbcf8b9d264dfefe7a9fd5c2fb4ce731a2ff6a632c3341ace43afe7f1600f2096592535cf9a300322f78c92000e752e0df7d3c39021 WHIRLPOOL 3fd230321577c0226926701a17803b038a281b46abe884899ca38ea18c5fd9c13ef90900e5fdd17db20ecf8dc63b373cb9f378f1402660be2908192900cba47a
25 DIST postfix-3.0.3.tar.gz 4240588 SHA256 401e46ec3450569dcce60d1d8ca22a19ab1f7f817b0cc730cdf4875ba608ac02 SHA512 b6cd091a8cdda9678fa2979082e47a363dd086e4376effc0a427d1beb5eb35bd7dc28003ad28323c42318d7f630e0d8b105c56fd1a63bd5b5a20501db68ac524 WHIRLPOOL b013164f12e2adde464052f37584320687716f18c65cdd01344848bbcdd5a08be16c741234a063d717474a50be0d14d7b5574ccb69dc56e00f30b619d148c9f9
26 -DIST postfix-3.0.4.tar.gz 4240805 SHA256 b81ce81176b9df7183ad99b9c98000135f5e88e659493ab50db5d9fe5b8dba0e SHA512 ca1ad1b7a0c552825d820e1ea017bdd79cf31e6262c9d2b801fa11011be5e10549cfb57745cec4177046a178fab104f3b7f79bf08708bb7772b127970970949d WHIRLPOOL e1a00ba9733522109ebbefa902021abda3bed0316da98cfb98a305122e736f5889b8b5a6426f152d0c68a9f8cb675683fddb80fd12fa6b278f1ae8c024c5fc1c
27 -DIST postfix-3.0.5.tar.gz 4241656 SHA256 dbe20d011a6fe79d28b5f7e6e86681dafd30f7ed8ad663bec244fc4694c87d1c SHA512 73ae64d5d5a21a773934b1b334bb7c407a1e8f9652a2de7d4c0563d8b399fbd25b9fcc28d1d5ee724fc13c775ee9af2d5d56cb06d4947cd5a18bcf487c71c24e WHIRLPOOL 022110186e5c2e9a11bfe19bd2712d39f751a47a273f75a3aa61f99f34ce76e4f20552c3df87c3878d0c1b7a1bf5bff893191d94a4951e14ce3d6ff7bcfbf905
28 -DIST postfix-3.0.6.tar.gz 4241733 SHA256 8d85480e3728773c70c427090c943516dfbd5cedac5f09388fb1367b7a66f1b9 SHA512 10cef53bde1c479c16d8b06602c5ea4f07377ad32558e36055b20fc815f1ffc77d6bd7841a2aa4f8aac36ac337f09f0ab4329995e89c7ad274dd313e33e6368d WHIRLPOOL b2e40928a5e0129be231cbbb27d570eee16538ea66ee1f0e444cb10ac087f451a1b6b79923569f6315aa0090f260e6c99f2b162943a8e71be9912b09a10e1354
29 DIST postfix-3.0.7.tar.gz 4242726 SHA256 2cc47eec71f0dbbe990d1e0de5b2b5236eacce503e4c4eefe753366b80106ab8 SHA512 0663337c091ac9f8cadcb44d33f1cd4716f718fb0bc8f55c300e87cc96517d2b11cb71855f4ea1d8b88dc5a76d14718bbd22ad46e5ad15afaf43bd88fa850efc WHIRLPOOL 20078faba287247e49cffa630b911151323203659de5275c3ad6bbffdcd17dc09acac56b2631aabc9d1dd8e45d8a3b63baa3d1fe55ae94e6059f5951e8c9c9a2
30 DIST postfix-3.1.0.tar.gz 4336709 SHA256 88ac3e92755629077d9363319b1fa0db406efb10c2f22cdbb941bd8ab36fd733 SHA512 06cf4c827de8d613cab6a57a8e76198d293660a263f60d17dd189f511da4b1e12eb98bbcf75695697a62959e26ca204bf2a53eb6657e8bd756a816977e717783 WHIRLPOOL 5fe4350d47051cfda00505012493f5c6f70598be901cd94a598a7e3332bc022b41050935c5263f140f0df573e3a3e00f6b97dd1d90c01a4e3d78a039f47a16a8
31 DIST postfix-3.1.1.tar.gz 4337295 SHA256 3deda4c34631970490b1b5fbb559905f93531bf1c7eb00e38b0d0deb1dba9982 SHA512 e094dae3c3aaf6be23edefb7863d2f9fb57cd4e705464f17799fa4f71f9877efdf3f59ceb1970457a0dc6e6f3237ee06131f4ce1b21a5db9a61fe0c5f95a219d WHIRLPOOL 4dbf26e498cb48ebf5d5721aa69447deed4db25dd2a9159514826eb7d4986dd7fef40980281f0872f565750ed5d316f831856b87eaaabfed3df8b23f982592cd
32
33 diff --git a/mail-mta/postfix/postfix-3.0.4.ebuild b/mail-mta/postfix/postfix-3.0.4.ebuild
34 deleted file mode 100644
35 index 9cbe08f..00000000
36 --- a/mail-mta/postfix/postfix-3.0.4.ebuild
37 +++ /dev/null
38 @@ -1,314 +0,0 @@
39 -# Copyright 1999-2016 Gentoo Foundation
40 -# Distributed under the terms of the GNU General Public License v2
41 -# $Id$
42 -
43 -EAPI=5
44 -inherit eutils flag-o-matic multilib pam ssl-cert systemd toolchain-funcs user versionator
45 -
46 -MY_PV="${PV/_rc/-RC}"
47 -MY_SRC="${PN}-${MY_PV}"
48 -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official"
49 -VDA_PV="2.10.0"
50 -VDA_P="${PN}-vda-v13-${VDA_PV}"
51 -RC_VER="2.7"
52 -
53 -DESCRIPTION="A fast and secure drop-in replacement for sendmail"
54 -HOMEPAGE="http://www.postfix.org/"
55 -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz
56 - vda? ( http://vda.sourceforge.net/VDA/${VDA_P}.patch ) "
57 -
58 -LICENSE="IBM"
59 -SLOT="0"
60 -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd"
61 -IUSE="+berkdb cdb doc dovecot-sasl +eai hardened ldap ldap-bind libressl lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl vda"
62 -
63 -DEPEND=">=dev-libs/libpcre-3.4
64 - dev-lang/perl
65 - berkdb? ( >=sys-libs/db-3.2:* )
66 - cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) )
67 - eai? ( dev-libs/icu:= )
68 - ldap? ( net-nds/openldap )
69 - ldap-bind? ( net-nds/openldap[sasl] )
70 - lmdb? ( >=dev-db/lmdb-0.9.11 )
71 - mysql? ( virtual/mysql )
72 - pam? ( virtual/pam )
73 - postgres? ( dev-db/postgresql:* )
74 - sasl? ( >=dev-libs/cyrus-sasl-2 )
75 - sqlite? ( dev-db/sqlite:3 )
76 - ssl? (
77 - !libressl? ( dev-libs/openssl:0 )
78 - libressl? ( dev-libs/libressl )
79 - )"
80 -
81 -RDEPEND="${DEPEND}
82 - dovecot-sasl? ( net-mail/dovecot )
83 - memcached? ( net-misc/memcached )
84 - net-mail/mailbase
85 - !mail-mta/courier
86 - !mail-mta/esmtp
87 - !mail-mta/exim
88 - !mail-mta/mini-qmail
89 - !mail-mta/msmtp[mta]
90 - !mail-mta/netqmail
91 - !mail-mta/nullmailer
92 - !mail-mta/qmail-ldap
93 - !mail-mta/sendmail
94 - !mail-mta/opensmtpd
95 - !<mail-mta/ssmtp-2.64-r2
96 - !>=mail-mta/ssmtp-2.64-r2[mta]
97 - !net-mail/fastforward
98 - selinux? ( sec-policy/selinux-postfix )"
99 -
100 -# No vda support for postfix-3.0
101 -REQUIRED_USE="ldap-bind? ( ldap sasl )
102 - !vda"
103 -
104 -S="${WORKDIR}/${MY_SRC}"
105 -
106 -pkg_setup() {
107 - # Add postfix, postdrop user/group (bug #77565)
108 - enewgroup postfix 207
109 - enewgroup postdrop 208
110 - enewuser postfix 207 -1 /var/spool/postfix postfix,mail
111 -}
112 -
113 -src_prepare() {
114 - if use vda; then
115 - epatch "${DISTDIR}"/${VDA_P}.patch
116 - fi
117 -
118 - sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \
119 - src/util/sys_defs.h || die "sed failed"
120 -
121 - # change default paths to better comply with portage standard paths
122 - sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed"
123 -
124 - epatch_user
125 -}
126 -
127 -src_configure() {
128 - for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE
129 - do
130 - local AUXLIBS_${name}=""
131 - done
132 -
133 - # Make sure LDFLAGS get passed down to the executables.
134 - local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl"
135 - AUXLIBS_PCRE="$(pcre-config --libs)"
136 -
137 - use pam && mylibs="${mylibs} -lpam"
138 -
139 - if use ldap; then
140 - mycc="${mycc} -DHAS_LDAP"
141 - AUXLIBS_LDAP="-lldap -llber"
142 - fi
143 -
144 - if use mysql; then
145 - mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)"
146 - AUXLIBS_MYSQL="$(mysql_config --libs)"
147 - fi
148 -
149 - if use postgres; then
150 - mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)"
151 - AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq"
152 - fi
153 -
154 - if use sqlite; then
155 - mycc="${mycc} -DHAS_SQLITE"
156 - AUXLIBS_SQLITE="-lsqlite3 -lpthread"
157 - fi
158 -
159 - if use ssl; then
160 - mycc="${mycc} -DUSE_TLS"
161 - mylibs="${mylibs} -lssl -lcrypto"
162 - fi
163 -
164 - if use lmdb; then
165 - mycc="${mycc} -DHAS_LMDB"
166 - AUXLIBS_LMDB="-llmdb -lpthread"
167 - fi
168 -
169 - if ! use eai; then
170 - mycc="${mycc} -DNO_EAI"
171 - fi
172 -
173 - # broken. and "in other words, not supported" by upstream.
174 - # Use inet_protocols setting in main.cf
175 - #if ! use ipv6; then
176 - # mycc="${mycc} -DNO_IPV6"
177 - #fi
178 -
179 - if use sasl; then
180 - if use dovecot-sasl; then
181 - # Set dovecot as default.
182 - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\""
183 - fi
184 - if use ldap-bind; then
185 - mycc="${mycc} -DUSE_LDAP_SASL"
186 - fi
187 - mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl"
188 - mylibs="${mylibs} -lsasl2"
189 - elif use dovecot-sasl; then
190 - mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\""
191 - fi
192 -
193 - if ! use nis; then
194 - mycc="${mycc} -DNO_NIS"
195 - fi
196 -
197 - if ! use berkdb; then
198 - mycc="${mycc} -DNO_DB"
199 - if use cdb; then
200 - # change default hash format from Berkeley DB to cdb
201 - mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\""
202 - fi
203 - fi
204 -
205 - if use cdb; then
206 - mycc="${mycc} -DHAS_CDB -I/usr/include/cdb"
207 - # Tinycdb is preferred.
208 - if has_version dev-db/tinycdb ; then
209 - einfo "Building with dev-db/tinycdb"
210 - AUXLIBS_CDB="-lcdb"
211 - else
212 - einfo "Building with dev-db/cdb"
213 - CDB_PATH="/usr/$(get_libdir)"
214 - for i in cdb.a alloc.a buffer.a unix.a byte.a ; do
215 - AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}"
216 - done
217 - fi
218 - fi
219 -
220 - # Robin H. Johnson <robbat2@g.o> 17/Nov/2006
221 - # Fix because infra boxes hit 2Gb .db files that fail a 32-bit fstat signed check.
222 - mycc="${mycc} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE"
223 - filter-lfs-flags
224 -
225 - # Workaround for bug #76512
226 - if use hardened; then
227 - [[ "$(gcc-version)" == "3.4" ]] && replace-flags -O? -Os
228 - fi
229 -
230 - # Remove annoying C++ comment style warnings - bug #378099
231 - append-flags -Wno-comment
232 -
233 - sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs
234 - sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs
235 -
236 - emake makefiles shared=yes dynamicmaps=no pie=yes \
237 - shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \
238 - DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \
239 - AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \
240 - AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \
241 - AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \
242 - AUXLIBS_SQLITE="${AUXLIBS_SQLITE}"
243 -}
244 -
245 -src_install () {
246 - local myconf
247 - use doc && myconf="readme_directory=\"/usr/share/doc/${PF}/readme\" \
248 - html_directory=\"/usr/share/doc/${PF}/html\""
249 -
250 - LD_LIBRARY_PATH="${S}/lib" \
251 - /bin/sh postfix-install \
252 - -non-interactive \
253 - install_root="${D}" \
254 - config_directory="/etc/postfix" \
255 - manpage_directory="/usr/share/man" \
256 - command_directory="/usr/sbin" \
257 - mailq_path="/usr/bin/mailq" \
258 - newaliases_path="/usr/bin/newaliases" \
259 - sendmail_path="/usr/sbin/sendmail" \
260 - ${myconf} \
261 - || die "postfix-install failed"
262 -
263 - # Fix spool removal on upgrade
264 - rm -Rf "${D}"/var
265 - keepdir /var/spool/postfix
266 -
267 - # Install rmail for UUCP, closes bug #19127
268 - dobin auxiliary/rmail/rmail
269 -
270 - # Provide another link for legacy FSH
271 - dosym /usr/sbin/sendmail /usr/$(get_libdir)/sendmail
272 -
273 - # Install qshape tool and posttls-finger
274 - dobin auxiliary/qshape/qshape.pl
275 - doman man/man1/qshape.1
276 - dobin bin/posttls-finger
277 - doman man/man1/posttls-finger.1
278 -
279 - # Performance tuning tools and their manuals
280 - dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink}
281 - doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1
282 -
283 - # Set proper permissions on required files/directories
284 - dodir /var/lib/postfix
285 - keepdir /var/lib/postfix
286 - fowners -R postfix:postfix /var/lib/postfix
287 - fperms 0750 /var/lib/postfix
288 - fowners root:postdrop /usr/sbin/post{drop,queue}
289 - fperms 02711 /usr/sbin/post{drop,queue}
290 -
291 - keepdir /etc/postfix
292 - if use mbox; then
293 - mypostconf="mail_spool_directory=/var/spool/mail"
294 - else
295 - mypostconf="home_mailbox=.maildir/"
296 - fi
297 - LD_LIBRARY_PATH="${S}/lib" \
298 - "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \
299 - -e ${mypostconf} || die "postconf failed"
300 -
301 - insinto /etc/postfix
302 - newins "${FILESDIR}"/smtp.pass saslpass
303 - fperms 600 /etc/postfix/saslpass
304 -
305 - newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix
306 - # do not start mysql/postgres unnecessarily - bug #359913
307 - use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix"
308 - use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix"
309 -
310 - dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES*
311 - use doc && mv "${S}"/examples "${D}"/usr/share/doc/${PF}/
312 -
313 - pamd_mimic_system smtp auth account
314 -
315 - if use sasl; then
316 - insinto /etc/sasl2
317 - newins "${FILESDIR}"/smtp.sasl smtpd.conf
318 - fi
319 -
320 - # header files
321 - insinto /usr/include/postfix
322 - doins include/*.h
323 -
324 - # Remove unnecessary files
325 - rm -f "${D}"/etc/postfix/{*LICENSE,access,aliases,canonical,generic}
326 - rm -f "${D}"/etc/postfix/{header_checks,relocated,transport,virtual}
327 -
328 - if has_version mail-mta/postfix; then
329 - # let the sysadmin decide when to change the compatibility_level
330 - sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die
331 - fi
332 -
333 - systemd_dounit "${FILESDIR}/${PN}.service"
334 -}
335 -
336 -pkg_postinst() {
337 - # Do not install server.{key,pem) SSL certificates if they already exist
338 - if use ssl && [[ ! -f "${ROOT}"/etc/ssl/postfix/server.key \
339 - && ! -f "${ROOT}"/etc/ssl/postfix/server.pem ]] ; then
340 - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}"
341 - install_cert /etc/ssl/postfix/server
342 - chown postfix:mail "${ROOT}"/etc/ssl/postfix/server.{key,pem}
343 - fi
344 -
345 - if [[ ! -e /etc/mail/aliases.db ]] ; then
346 - ewarn
347 - ewarn "You must edit /etc/mail/aliases to suit your needs"
348 - ewarn "and then run /usr/bin/newaliases. Postfix will not"
349 - ewarn "work correctly without it."
350 - ewarn
351 - fi
352 -}
353
354 diff --git a/mail-mta/postfix/postfix-3.0.5.ebuild b/mail-mta/postfix/postfix-3.0.5.ebuild
355 deleted file mode 100644
356 index 9cbe08f..00000000
357 --- a/mail-mta/postfix/postfix-3.0.5.ebuild
358 +++ /dev/null
359 @@ -1,314 +0,0 @@
360 -# Copyright 1999-2016 Gentoo Foundation
361 -# Distributed under the terms of the GNU General Public License v2
362 -# $Id$
363 -
364 -EAPI=5
365 -inherit eutils flag-o-matic multilib pam ssl-cert systemd toolchain-funcs user versionator
366 -
367 -MY_PV="${PV/_rc/-RC}"
368 -MY_SRC="${PN}-${MY_PV}"
369 -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official"
370 -VDA_PV="2.10.0"
371 -VDA_P="${PN}-vda-v13-${VDA_PV}"
372 -RC_VER="2.7"
373 -
374 -DESCRIPTION="A fast and secure drop-in replacement for sendmail"
375 -HOMEPAGE="http://www.postfix.org/"
376 -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz
377 - vda? ( http://vda.sourceforge.net/VDA/${VDA_P}.patch ) "
378 -
379 -LICENSE="IBM"
380 -SLOT="0"
381 -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd"
382 -IUSE="+berkdb cdb doc dovecot-sasl +eai hardened ldap ldap-bind libressl lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl vda"
383 -
384 -DEPEND=">=dev-libs/libpcre-3.4
385 - dev-lang/perl
386 - berkdb? ( >=sys-libs/db-3.2:* )
387 - cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) )
388 - eai? ( dev-libs/icu:= )
389 - ldap? ( net-nds/openldap )
390 - ldap-bind? ( net-nds/openldap[sasl] )
391 - lmdb? ( >=dev-db/lmdb-0.9.11 )
392 - mysql? ( virtual/mysql )
393 - pam? ( virtual/pam )
394 - postgres? ( dev-db/postgresql:* )
395 - sasl? ( >=dev-libs/cyrus-sasl-2 )
396 - sqlite? ( dev-db/sqlite:3 )
397 - ssl? (
398 - !libressl? ( dev-libs/openssl:0 )
399 - libressl? ( dev-libs/libressl )
400 - )"
401 -
402 -RDEPEND="${DEPEND}
403 - dovecot-sasl? ( net-mail/dovecot )
404 - memcached? ( net-misc/memcached )
405 - net-mail/mailbase
406 - !mail-mta/courier
407 - !mail-mta/esmtp
408 - !mail-mta/exim
409 - !mail-mta/mini-qmail
410 - !mail-mta/msmtp[mta]
411 - !mail-mta/netqmail
412 - !mail-mta/nullmailer
413 - !mail-mta/qmail-ldap
414 - !mail-mta/sendmail
415 - !mail-mta/opensmtpd
416 - !<mail-mta/ssmtp-2.64-r2
417 - !>=mail-mta/ssmtp-2.64-r2[mta]
418 - !net-mail/fastforward
419 - selinux? ( sec-policy/selinux-postfix )"
420 -
421 -# No vda support for postfix-3.0
422 -REQUIRED_USE="ldap-bind? ( ldap sasl )
423 - !vda"
424 -
425 -S="${WORKDIR}/${MY_SRC}"
426 -
427 -pkg_setup() {
428 - # Add postfix, postdrop user/group (bug #77565)
429 - enewgroup postfix 207
430 - enewgroup postdrop 208
431 - enewuser postfix 207 -1 /var/spool/postfix postfix,mail
432 -}
433 -
434 -src_prepare() {
435 - if use vda; then
436 - epatch "${DISTDIR}"/${VDA_P}.patch
437 - fi
438 -
439 - sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \
440 - src/util/sys_defs.h || die "sed failed"
441 -
442 - # change default paths to better comply with portage standard paths
443 - sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed"
444 -
445 - epatch_user
446 -}
447 -
448 -src_configure() {
449 - for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE
450 - do
451 - local AUXLIBS_${name}=""
452 - done
453 -
454 - # Make sure LDFLAGS get passed down to the executables.
455 - local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl"
456 - AUXLIBS_PCRE="$(pcre-config --libs)"
457 -
458 - use pam && mylibs="${mylibs} -lpam"
459 -
460 - if use ldap; then
461 - mycc="${mycc} -DHAS_LDAP"
462 - AUXLIBS_LDAP="-lldap -llber"
463 - fi
464 -
465 - if use mysql; then
466 - mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)"
467 - AUXLIBS_MYSQL="$(mysql_config --libs)"
468 - fi
469 -
470 - if use postgres; then
471 - mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)"
472 - AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq"
473 - fi
474 -
475 - if use sqlite; then
476 - mycc="${mycc} -DHAS_SQLITE"
477 - AUXLIBS_SQLITE="-lsqlite3 -lpthread"
478 - fi
479 -
480 - if use ssl; then
481 - mycc="${mycc} -DUSE_TLS"
482 - mylibs="${mylibs} -lssl -lcrypto"
483 - fi
484 -
485 - if use lmdb; then
486 - mycc="${mycc} -DHAS_LMDB"
487 - AUXLIBS_LMDB="-llmdb -lpthread"
488 - fi
489 -
490 - if ! use eai; then
491 - mycc="${mycc} -DNO_EAI"
492 - fi
493 -
494 - # broken. and "in other words, not supported" by upstream.
495 - # Use inet_protocols setting in main.cf
496 - #if ! use ipv6; then
497 - # mycc="${mycc} -DNO_IPV6"
498 - #fi
499 -
500 - if use sasl; then
501 - if use dovecot-sasl; then
502 - # Set dovecot as default.
503 - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\""
504 - fi
505 - if use ldap-bind; then
506 - mycc="${mycc} -DUSE_LDAP_SASL"
507 - fi
508 - mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl"
509 - mylibs="${mylibs} -lsasl2"
510 - elif use dovecot-sasl; then
511 - mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\""
512 - fi
513 -
514 - if ! use nis; then
515 - mycc="${mycc} -DNO_NIS"
516 - fi
517 -
518 - if ! use berkdb; then
519 - mycc="${mycc} -DNO_DB"
520 - if use cdb; then
521 - # change default hash format from Berkeley DB to cdb
522 - mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\""
523 - fi
524 - fi
525 -
526 - if use cdb; then
527 - mycc="${mycc} -DHAS_CDB -I/usr/include/cdb"
528 - # Tinycdb is preferred.
529 - if has_version dev-db/tinycdb ; then
530 - einfo "Building with dev-db/tinycdb"
531 - AUXLIBS_CDB="-lcdb"
532 - else
533 - einfo "Building with dev-db/cdb"
534 - CDB_PATH="/usr/$(get_libdir)"
535 - for i in cdb.a alloc.a buffer.a unix.a byte.a ; do
536 - AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}"
537 - done
538 - fi
539 - fi
540 -
541 - # Robin H. Johnson <robbat2@g.o> 17/Nov/2006
542 - # Fix because infra boxes hit 2Gb .db files that fail a 32-bit fstat signed check.
543 - mycc="${mycc} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE"
544 - filter-lfs-flags
545 -
546 - # Workaround for bug #76512
547 - if use hardened; then
548 - [[ "$(gcc-version)" == "3.4" ]] && replace-flags -O? -Os
549 - fi
550 -
551 - # Remove annoying C++ comment style warnings - bug #378099
552 - append-flags -Wno-comment
553 -
554 - sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs
555 - sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs
556 -
557 - emake makefiles shared=yes dynamicmaps=no pie=yes \
558 - shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \
559 - DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \
560 - AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \
561 - AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \
562 - AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \
563 - AUXLIBS_SQLITE="${AUXLIBS_SQLITE}"
564 -}
565 -
566 -src_install () {
567 - local myconf
568 - use doc && myconf="readme_directory=\"/usr/share/doc/${PF}/readme\" \
569 - html_directory=\"/usr/share/doc/${PF}/html\""
570 -
571 - LD_LIBRARY_PATH="${S}/lib" \
572 - /bin/sh postfix-install \
573 - -non-interactive \
574 - install_root="${D}" \
575 - config_directory="/etc/postfix" \
576 - manpage_directory="/usr/share/man" \
577 - command_directory="/usr/sbin" \
578 - mailq_path="/usr/bin/mailq" \
579 - newaliases_path="/usr/bin/newaliases" \
580 - sendmail_path="/usr/sbin/sendmail" \
581 - ${myconf} \
582 - || die "postfix-install failed"
583 -
584 - # Fix spool removal on upgrade
585 - rm -Rf "${D}"/var
586 - keepdir /var/spool/postfix
587 -
588 - # Install rmail for UUCP, closes bug #19127
589 - dobin auxiliary/rmail/rmail
590 -
591 - # Provide another link for legacy FSH
592 - dosym /usr/sbin/sendmail /usr/$(get_libdir)/sendmail
593 -
594 - # Install qshape tool and posttls-finger
595 - dobin auxiliary/qshape/qshape.pl
596 - doman man/man1/qshape.1
597 - dobin bin/posttls-finger
598 - doman man/man1/posttls-finger.1
599 -
600 - # Performance tuning tools and their manuals
601 - dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink}
602 - doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1
603 -
604 - # Set proper permissions on required files/directories
605 - dodir /var/lib/postfix
606 - keepdir /var/lib/postfix
607 - fowners -R postfix:postfix /var/lib/postfix
608 - fperms 0750 /var/lib/postfix
609 - fowners root:postdrop /usr/sbin/post{drop,queue}
610 - fperms 02711 /usr/sbin/post{drop,queue}
611 -
612 - keepdir /etc/postfix
613 - if use mbox; then
614 - mypostconf="mail_spool_directory=/var/spool/mail"
615 - else
616 - mypostconf="home_mailbox=.maildir/"
617 - fi
618 - LD_LIBRARY_PATH="${S}/lib" \
619 - "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \
620 - -e ${mypostconf} || die "postconf failed"
621 -
622 - insinto /etc/postfix
623 - newins "${FILESDIR}"/smtp.pass saslpass
624 - fperms 600 /etc/postfix/saslpass
625 -
626 - newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix
627 - # do not start mysql/postgres unnecessarily - bug #359913
628 - use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix"
629 - use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix"
630 -
631 - dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES*
632 - use doc && mv "${S}"/examples "${D}"/usr/share/doc/${PF}/
633 -
634 - pamd_mimic_system smtp auth account
635 -
636 - if use sasl; then
637 - insinto /etc/sasl2
638 - newins "${FILESDIR}"/smtp.sasl smtpd.conf
639 - fi
640 -
641 - # header files
642 - insinto /usr/include/postfix
643 - doins include/*.h
644 -
645 - # Remove unnecessary files
646 - rm -f "${D}"/etc/postfix/{*LICENSE,access,aliases,canonical,generic}
647 - rm -f "${D}"/etc/postfix/{header_checks,relocated,transport,virtual}
648 -
649 - if has_version mail-mta/postfix; then
650 - # let the sysadmin decide when to change the compatibility_level
651 - sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die
652 - fi
653 -
654 - systemd_dounit "${FILESDIR}/${PN}.service"
655 -}
656 -
657 -pkg_postinst() {
658 - # Do not install server.{key,pem) SSL certificates if they already exist
659 - if use ssl && [[ ! -f "${ROOT}"/etc/ssl/postfix/server.key \
660 - && ! -f "${ROOT}"/etc/ssl/postfix/server.pem ]] ; then
661 - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}"
662 - install_cert /etc/ssl/postfix/server
663 - chown postfix:mail "${ROOT}"/etc/ssl/postfix/server.{key,pem}
664 - fi
665 -
666 - if [[ ! -e /etc/mail/aliases.db ]] ; then
667 - ewarn
668 - ewarn "You must edit /etc/mail/aliases to suit your needs"
669 - ewarn "and then run /usr/bin/newaliases. Postfix will not"
670 - ewarn "work correctly without it."
671 - ewarn
672 - fi
673 -}
674
675 diff --git a/mail-mta/postfix/postfix-3.0.6.ebuild b/mail-mta/postfix/postfix-3.0.6.ebuild
676 deleted file mode 100644
677 index 9cbe08f..00000000
678 --- a/mail-mta/postfix/postfix-3.0.6.ebuild
679 +++ /dev/null
680 @@ -1,314 +0,0 @@
681 -# Copyright 1999-2016 Gentoo Foundation
682 -# Distributed under the terms of the GNU General Public License v2
683 -# $Id$
684 -
685 -EAPI=5
686 -inherit eutils flag-o-matic multilib pam ssl-cert systemd toolchain-funcs user versionator
687 -
688 -MY_PV="${PV/_rc/-RC}"
689 -MY_SRC="${PN}-${MY_PV}"
690 -MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official"
691 -VDA_PV="2.10.0"
692 -VDA_P="${PN}-vda-v13-${VDA_PV}"
693 -RC_VER="2.7"
694 -
695 -DESCRIPTION="A fast and secure drop-in replacement for sendmail"
696 -HOMEPAGE="http://www.postfix.org/"
697 -SRC_URI="${MY_URI}/${MY_SRC}.tar.gz
698 - vda? ( http://vda.sourceforge.net/VDA/${VDA_P}.patch ) "
699 -
700 -LICENSE="IBM"
701 -SLOT="0"
702 -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd"
703 -IUSE="+berkdb cdb doc dovecot-sasl +eai hardened ldap ldap-bind libressl lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl vda"
704 -
705 -DEPEND=">=dev-libs/libpcre-3.4
706 - dev-lang/perl
707 - berkdb? ( >=sys-libs/db-3.2:* )
708 - cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) )
709 - eai? ( dev-libs/icu:= )
710 - ldap? ( net-nds/openldap )
711 - ldap-bind? ( net-nds/openldap[sasl] )
712 - lmdb? ( >=dev-db/lmdb-0.9.11 )
713 - mysql? ( virtual/mysql )
714 - pam? ( virtual/pam )
715 - postgres? ( dev-db/postgresql:* )
716 - sasl? ( >=dev-libs/cyrus-sasl-2 )
717 - sqlite? ( dev-db/sqlite:3 )
718 - ssl? (
719 - !libressl? ( dev-libs/openssl:0 )
720 - libressl? ( dev-libs/libressl )
721 - )"
722 -
723 -RDEPEND="${DEPEND}
724 - dovecot-sasl? ( net-mail/dovecot )
725 - memcached? ( net-misc/memcached )
726 - net-mail/mailbase
727 - !mail-mta/courier
728 - !mail-mta/esmtp
729 - !mail-mta/exim
730 - !mail-mta/mini-qmail
731 - !mail-mta/msmtp[mta]
732 - !mail-mta/netqmail
733 - !mail-mta/nullmailer
734 - !mail-mta/qmail-ldap
735 - !mail-mta/sendmail
736 - !mail-mta/opensmtpd
737 - !<mail-mta/ssmtp-2.64-r2
738 - !>=mail-mta/ssmtp-2.64-r2[mta]
739 - !net-mail/fastforward
740 - selinux? ( sec-policy/selinux-postfix )"
741 -
742 -# No vda support for postfix-3.0
743 -REQUIRED_USE="ldap-bind? ( ldap sasl )
744 - !vda"
745 -
746 -S="${WORKDIR}/${MY_SRC}"
747 -
748 -pkg_setup() {
749 - # Add postfix, postdrop user/group (bug #77565)
750 - enewgroup postfix 207
751 - enewgroup postdrop 208
752 - enewuser postfix 207 -1 /var/spool/postfix postfix,mail
753 -}
754 -
755 -src_prepare() {
756 - if use vda; then
757 - epatch "${DISTDIR}"/${VDA_P}.patch
758 - fi
759 -
760 - sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \
761 - src/util/sys_defs.h || die "sed failed"
762 -
763 - # change default paths to better comply with portage standard paths
764 - sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed"
765 -
766 - epatch_user
767 -}
768 -
769 -src_configure() {
770 - for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE
771 - do
772 - local AUXLIBS_${name}=""
773 - done
774 -
775 - # Make sure LDFLAGS get passed down to the executables.
776 - local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl"
777 - AUXLIBS_PCRE="$(pcre-config --libs)"
778 -
779 - use pam && mylibs="${mylibs} -lpam"
780 -
781 - if use ldap; then
782 - mycc="${mycc} -DHAS_LDAP"
783 - AUXLIBS_LDAP="-lldap -llber"
784 - fi
785 -
786 - if use mysql; then
787 - mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)"
788 - AUXLIBS_MYSQL="$(mysql_config --libs)"
789 - fi
790 -
791 - if use postgres; then
792 - mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)"
793 - AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq"
794 - fi
795 -
796 - if use sqlite; then
797 - mycc="${mycc} -DHAS_SQLITE"
798 - AUXLIBS_SQLITE="-lsqlite3 -lpthread"
799 - fi
800 -
801 - if use ssl; then
802 - mycc="${mycc} -DUSE_TLS"
803 - mylibs="${mylibs} -lssl -lcrypto"
804 - fi
805 -
806 - if use lmdb; then
807 - mycc="${mycc} -DHAS_LMDB"
808 - AUXLIBS_LMDB="-llmdb -lpthread"
809 - fi
810 -
811 - if ! use eai; then
812 - mycc="${mycc} -DNO_EAI"
813 - fi
814 -
815 - # broken. and "in other words, not supported" by upstream.
816 - # Use inet_protocols setting in main.cf
817 - #if ! use ipv6; then
818 - # mycc="${mycc} -DNO_IPV6"
819 - #fi
820 -
821 - if use sasl; then
822 - if use dovecot-sasl; then
823 - # Set dovecot as default.
824 - mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\""
825 - fi
826 - if use ldap-bind; then
827 - mycc="${mycc} -DUSE_LDAP_SASL"
828 - fi
829 - mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl"
830 - mylibs="${mylibs} -lsasl2"
831 - elif use dovecot-sasl; then
832 - mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\""
833 - fi
834 -
835 - if ! use nis; then
836 - mycc="${mycc} -DNO_NIS"
837 - fi
838 -
839 - if ! use berkdb; then
840 - mycc="${mycc} -DNO_DB"
841 - if use cdb; then
842 - # change default hash format from Berkeley DB to cdb
843 - mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\""
844 - fi
845 - fi
846 -
847 - if use cdb; then
848 - mycc="${mycc} -DHAS_CDB -I/usr/include/cdb"
849 - # Tinycdb is preferred.
850 - if has_version dev-db/tinycdb ; then
851 - einfo "Building with dev-db/tinycdb"
852 - AUXLIBS_CDB="-lcdb"
853 - else
854 - einfo "Building with dev-db/cdb"
855 - CDB_PATH="/usr/$(get_libdir)"
856 - for i in cdb.a alloc.a buffer.a unix.a byte.a ; do
857 - AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}"
858 - done
859 - fi
860 - fi
861 -
862 - # Robin H. Johnson <robbat2@g.o> 17/Nov/2006
863 - # Fix because infra boxes hit 2Gb .db files that fail a 32-bit fstat signed check.
864 - mycc="${mycc} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE"
865 - filter-lfs-flags
866 -
867 - # Workaround for bug #76512
868 - if use hardened; then
869 - [[ "$(gcc-version)" == "3.4" ]] && replace-flags -O? -Os
870 - fi
871 -
872 - # Remove annoying C++ comment style warnings - bug #378099
873 - append-flags -Wno-comment
874 -
875 - sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs
876 - sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs
877 -
878 - emake makefiles shared=yes dynamicmaps=no pie=yes \
879 - shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \
880 - DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \
881 - AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \
882 - AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \
883 - AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \
884 - AUXLIBS_SQLITE="${AUXLIBS_SQLITE}"
885 -}
886 -
887 -src_install () {
888 - local myconf
889 - use doc && myconf="readme_directory=\"/usr/share/doc/${PF}/readme\" \
890 - html_directory=\"/usr/share/doc/${PF}/html\""
891 -
892 - LD_LIBRARY_PATH="${S}/lib" \
893 - /bin/sh postfix-install \
894 - -non-interactive \
895 - install_root="${D}" \
896 - config_directory="/etc/postfix" \
897 - manpage_directory="/usr/share/man" \
898 - command_directory="/usr/sbin" \
899 - mailq_path="/usr/bin/mailq" \
900 - newaliases_path="/usr/bin/newaliases" \
901 - sendmail_path="/usr/sbin/sendmail" \
902 - ${myconf} \
903 - || die "postfix-install failed"
904 -
905 - # Fix spool removal on upgrade
906 - rm -Rf "${D}"/var
907 - keepdir /var/spool/postfix
908 -
909 - # Install rmail for UUCP, closes bug #19127
910 - dobin auxiliary/rmail/rmail
911 -
912 - # Provide another link for legacy FSH
913 - dosym /usr/sbin/sendmail /usr/$(get_libdir)/sendmail
914 -
915 - # Install qshape tool and posttls-finger
916 - dobin auxiliary/qshape/qshape.pl
917 - doman man/man1/qshape.1
918 - dobin bin/posttls-finger
919 - doman man/man1/posttls-finger.1
920 -
921 - # Performance tuning tools and their manuals
922 - dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink}
923 - doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1
924 -
925 - # Set proper permissions on required files/directories
926 - dodir /var/lib/postfix
927 - keepdir /var/lib/postfix
928 - fowners -R postfix:postfix /var/lib/postfix
929 - fperms 0750 /var/lib/postfix
930 - fowners root:postdrop /usr/sbin/post{drop,queue}
931 - fperms 02711 /usr/sbin/post{drop,queue}
932 -
933 - keepdir /etc/postfix
934 - if use mbox; then
935 - mypostconf="mail_spool_directory=/var/spool/mail"
936 - else
937 - mypostconf="home_mailbox=.maildir/"
938 - fi
939 - LD_LIBRARY_PATH="${S}/lib" \
940 - "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \
941 - -e ${mypostconf} || die "postconf failed"
942 -
943 - insinto /etc/postfix
944 - newins "${FILESDIR}"/smtp.pass saslpass
945 - fperms 600 /etc/postfix/saslpass
946 -
947 - newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix
948 - # do not start mysql/postgres unnecessarily - bug #359913
949 - use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix"
950 - use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix"
951 -
952 - dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES*
953 - use doc && mv "${S}"/examples "${D}"/usr/share/doc/${PF}/
954 -
955 - pamd_mimic_system smtp auth account
956 -
957 - if use sasl; then
958 - insinto /etc/sasl2
959 - newins "${FILESDIR}"/smtp.sasl smtpd.conf
960 - fi
961 -
962 - # header files
963 - insinto /usr/include/postfix
964 - doins include/*.h
965 -
966 - # Remove unnecessary files
967 - rm -f "${D}"/etc/postfix/{*LICENSE,access,aliases,canonical,generic}
968 - rm -f "${D}"/etc/postfix/{header_checks,relocated,transport,virtual}
969 -
970 - if has_version mail-mta/postfix; then
971 - # let the sysadmin decide when to change the compatibility_level
972 - sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die
973 - fi
974 -
975 - systemd_dounit "${FILESDIR}/${PN}.service"
976 -}
977 -
978 -pkg_postinst() {
979 - # Do not install server.{key,pem) SSL certificates if they already exist
980 - if use ssl && [[ ! -f "${ROOT}"/etc/ssl/postfix/server.key \
981 - && ! -f "${ROOT}"/etc/ssl/postfix/server.pem ]] ; then
982 - SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}"
983 - install_cert /etc/ssl/postfix/server
984 - chown postfix:mail "${ROOT}"/etc/ssl/postfix/server.{key,pem}
985 - fi
986 -
987 - if [[ ! -e /etc/mail/aliases.db ]] ; then
988 - ewarn
989 - ewarn "You must edit /etc/mail/aliases to suit your needs"
990 - ewarn "and then run /usr/bin/newaliases. Postfix will not"
991 - ewarn "work correctly without it."
992 - ewarn
993 - fi
994 -}