1 |
commit: 5733d9ff6292b3c93ad7a7c17a041f692c08fcd1 |
2 |
Author: Eray Aslan <eras <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Oct 10 10:51:52 2016 +0000 |
4 |
Commit: Eray Aslan <eras <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Oct 10 10:51:52 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5733d9ff |
7 |
|
8 |
mail-mta/postfix: version bump to 3.1.3 |
9 |
|
10 |
Package-Manager: portage-2.3.1 |
11 |
|
12 |
mail-mta/postfix/Manifest | 1 + |
13 |
mail-mta/postfix/postfix-3.1.3.ebuild | 309 ++++++++++++++++++++++++++++++++++ |
14 |
2 files changed, 310 insertions(+) |
15 |
|
16 |
diff --git a/mail-mta/postfix/Manifest b/mail-mta/postfix/Manifest |
17 |
index a3c489e..8a0ad03 100644 |
18 |
--- a/mail-mta/postfix/Manifest |
19 |
+++ b/mail-mta/postfix/Manifest |
20 |
@@ -7,5 +7,6 @@ DIST postfix-3.0.6.tar.gz 4241733 SHA256 8d85480e3728773c70c427090c943516dfbd5ce |
21 |
DIST postfix-3.1.0.tar.gz 4336709 SHA256 88ac3e92755629077d9363319b1fa0db406efb10c2f22cdbb941bd8ab36fd733 SHA512 06cf4c827de8d613cab6a57a8e76198d293660a263f60d17dd189f511da4b1e12eb98bbcf75695697a62959e26ca204bf2a53eb6657e8bd756a816977e717783 WHIRLPOOL 5fe4350d47051cfda00505012493f5c6f70598be901cd94a598a7e3332bc022b41050935c5263f140f0df573e3a3e00f6b97dd1d90c01a4e3d78a039f47a16a8 |
22 |
DIST postfix-3.1.1.tar.gz 4337295 SHA256 3deda4c34631970490b1b5fbb559905f93531bf1c7eb00e38b0d0deb1dba9982 SHA512 e094dae3c3aaf6be23edefb7863d2f9fb57cd4e705464f17799fa4f71f9877efdf3f59ceb1970457a0dc6e6f3237ee06131f4ce1b21a5db9a61fe0c5f95a219d WHIRLPOOL 4dbf26e498cb48ebf5d5721aa69447deed4db25dd2a9159514826eb7d4986dd7fef40980281f0872f565750ed5d316f831856b87eaaabfed3df8b23f982592cd |
23 |
DIST postfix-3.1.2.tar.gz 4337569 SHA256 1ab9b4ee6bf9eb37d2467a63244132aab22ac23b91a72f327334e236b0d30f6b SHA512 58493d1890c3235d74a18365294ca764bd3b3f278b9825da931005165af60250342c6cf477c3b3575e50858d99cd3ee40f22bece094eb61e9be6c3cf0313d571 WHIRLPOOL 37e90ef6275a7f2dc8f712bb05348861098697438f274a5c5b69f50b31d55574af262a658657863c93f77fdeba2d37bf7b30dc43bf1629615f496ede19a89c00 |
24 |
+DIST postfix-3.1.3.tar.gz 4338730 SHA256 52f8127e6797e2617a36d0afb9473c55e95c3a777b6280df3f106168fd814979 SHA512 00e2b0974e59420cabfddc92597a99b42c8a8c9cd9a0c279c63ba6be9f40b15400f37dc16d0b1312130e72b5ba82b56fc7d579ee9ef975a957c0931b0401213c WHIRLPOOL 7274501921349e1f99344adb500638e91b92f3a3a87ec2171add18d58b926478459d4540a15f421c52175efb61d220c98438a9727adf5473d609d1b94480b663 |
25 |
DIST postfix-3.2-20161008.tar.gz 4350036 SHA256 9abd0e09767d19ac03d8eb44c806d865cdbe83e9881e17d7c60f8fc9be34a14c SHA512 c7eda9a28c2c4b873af8a6f86cff479bd99877ef4a55fa709ca5441f2da97ea92994334e858211cd7c2803a3a77650b7e4f919a28fa04258e24e77747f5bcd3a WHIRLPOOL e82e5052221749131badb4bb3aaea3aa98d4438b69dfd6d50680355fce6bde5f58630dbf13f324d67914536b2e264811f0fe6521a60defb2a61b8ab8e4a66a14 |
26 |
DIST postfix-vda-v13-2.10.0.patch 55701 SHA256 6208021eb0b37ac6482e334e538ed5700cc22c4d4dd66ed9e975ae5f20bf935f SHA512 0b4b53a8cd28abf56eee3b2ed63ca1814251b60816e6ca1143249d25fd6ef7f905bec3134125ac6e851af685db8aae878012113693261529ae2ddbcf1bd93e62 WHIRLPOOL d98b7d2177b8b69738086880fd08c336fa60b99ff7413624e628fd5f17be2064f2ccaa37c047d3013ed41c0ff1bcb76e7962f8390c4179f28ab11733dd3b59d3 |
27 |
|
28 |
diff --git a/mail-mta/postfix/postfix-3.1.3.ebuild b/mail-mta/postfix/postfix-3.1.3.ebuild |
29 |
new file mode 100644 |
30 |
index 00000000..15f8e1d |
31 |
--- /dev/null |
32 |
+++ b/mail-mta/postfix/postfix-3.1.3.ebuild |
33 |
@@ -0,0 +1,309 @@ |
34 |
+# Copyright 1999-2016 Gentoo Foundation |
35 |
+# Distributed under the terms of the GNU General Public License v2 |
36 |
+# $Id$ |
37 |
+ |
38 |
+EAPI=6 |
39 |
+inherit flag-o-matic pam systemd toolchain-funcs user |
40 |
+ |
41 |
+MY_PV="${PV/_rc/-RC}" |
42 |
+MY_SRC="${PN}-${MY_PV}" |
43 |
+MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official" |
44 |
+RC_VER="2.7" |
45 |
+ |
46 |
+DESCRIPTION="A fast and secure drop-in replacement for sendmail" |
47 |
+HOMEPAGE="http://www.postfix.org/" |
48 |
+SRC_URI="${MY_URI}/${MY_SRC}.tar.gz" |
49 |
+ |
50 |
+LICENSE="IBM" |
51 |
+SLOT="0" |
52 |
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd" |
53 |
+IUSE="+berkdb cdb doc dovecot-sasl +eai hardened ldap ldap-bind libressl lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl" |
54 |
+ |
55 |
+DEPEND=">=dev-libs/libpcre-3.4 |
56 |
+ dev-lang/perl |
57 |
+ berkdb? ( >=sys-libs/db-3.2:* ) |
58 |
+ cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r4 ) ) |
59 |
+ eai? ( dev-libs/icu:= ) |
60 |
+ ldap? ( net-nds/openldap ) |
61 |
+ ldap-bind? ( net-nds/openldap[sasl] ) |
62 |
+ lmdb? ( >=dev-db/lmdb-0.9.11 ) |
63 |
+ mysql? ( virtual/mysql ) |
64 |
+ pam? ( virtual/pam ) |
65 |
+ postgres? ( dev-db/postgresql:* ) |
66 |
+ sasl? ( >=dev-libs/cyrus-sasl-2 ) |
67 |
+ sqlite? ( dev-db/sqlite:3 ) |
68 |
+ ssl? ( |
69 |
+ !libressl? ( dev-libs/openssl:0 ) |
70 |
+ libressl? ( dev-libs/libressl ) |
71 |
+ )" |
72 |
+ |
73 |
+RDEPEND="${DEPEND} |
74 |
+ dovecot-sasl? ( net-mail/dovecot ) |
75 |
+ memcached? ( net-misc/memcached ) |
76 |
+ net-mail/mailbase |
77 |
+ !mail-mta/courier |
78 |
+ !mail-mta/esmtp |
79 |
+ !mail-mta/exim |
80 |
+ !mail-mta/mini-qmail |
81 |
+ !mail-mta/msmtp[mta] |
82 |
+ !mail-mta/netqmail |
83 |
+ !mail-mta/nullmailer |
84 |
+ !mail-mta/qmail-ldap |
85 |
+ !mail-mta/sendmail |
86 |
+ !mail-mta/opensmtpd |
87 |
+ !<mail-mta/ssmtp-2.64-r2 |
88 |
+ !>=mail-mta/ssmtp-2.64-r2[mta] |
89 |
+ !net-mail/fastforward |
90 |
+ selinux? ( sec-policy/selinux-postfix )" |
91 |
+ |
92 |
+REQUIRED_USE="ldap-bind? ( ldap sasl )" |
93 |
+ |
94 |
+S="${WORKDIR}/${MY_SRC}" |
95 |
+ |
96 |
+pkg_setup() { |
97 |
+ # Add postfix, postdrop user/group (bug #77565) |
98 |
+ enewgroup postfix 207 |
99 |
+ enewgroup postdrop 208 |
100 |
+ enewuser postfix 207 -1 /var/spool/postfix postfix,mail |
101 |
+} |
102 |
+ |
103 |
+src_prepare() { |
104 |
+ default |
105 |
+ sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \ |
106 |
+ src/util/sys_defs.h || die "sed failed" |
107 |
+ # change default paths to better comply with portage standard paths |
108 |
+ sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed" |
109 |
+ eapply -p0 "${FILESDIR}/${PN}-libressl.patch" |
110 |
+ eapply -p0 "${FILESDIR}/${PN}-libressl-runtime.patch" |
111 |
+} |
112 |
+ |
113 |
+src_configure() { |
114 |
+ for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE |
115 |
+ do |
116 |
+ local AUXLIBS_${name}="" |
117 |
+ done |
118 |
+ |
119 |
+ # Make sure LDFLAGS get passed down to the executables. |
120 |
+ local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl" |
121 |
+ AUXLIBS_PCRE="$(pcre-config --libs)" |
122 |
+ |
123 |
+ use pam && mylibs="${mylibs} -lpam" |
124 |
+ |
125 |
+ if use ldap; then |
126 |
+ mycc="${mycc} -DHAS_LDAP" |
127 |
+ AUXLIBS_LDAP="-lldap -llber" |
128 |
+ fi |
129 |
+ |
130 |
+ if use mysql; then |
131 |
+ mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)" |
132 |
+ AUXLIBS_MYSQL="$(mysql_config --libs)" |
133 |
+ fi |
134 |
+ |
135 |
+ if use postgres; then |
136 |
+ mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)" |
137 |
+ AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq" |
138 |
+ fi |
139 |
+ |
140 |
+ if use sqlite; then |
141 |
+ mycc="${mycc} -DHAS_SQLITE" |
142 |
+ AUXLIBS_SQLITE="-lsqlite3 -lpthread" |
143 |
+ fi |
144 |
+ |
145 |
+ if use ssl; then |
146 |
+ mycc="${mycc} -DUSE_TLS" |
147 |
+ mylibs="${mylibs} -lssl -lcrypto" |
148 |
+ fi |
149 |
+ |
150 |
+ if use lmdb; then |
151 |
+ mycc="${mycc} -DHAS_LMDB" |
152 |
+ AUXLIBS_LMDB="-llmdb -lpthread" |
153 |
+ fi |
154 |
+ |
155 |
+ if ! use eai; then |
156 |
+ mycc="${mycc} -DNO_EAI" |
157 |
+ fi |
158 |
+ |
159 |
+ # broken. and "in other words, not supported" by upstream. |
160 |
+ # Use inet_protocols setting in main.cf |
161 |
+ #if ! use ipv6; then |
162 |
+ # mycc="${mycc} -DNO_IPV6" |
163 |
+ #fi |
164 |
+ |
165 |
+ if use sasl; then |
166 |
+ if use dovecot-sasl; then |
167 |
+ # Set dovecot as default. |
168 |
+ mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\"" |
169 |
+ fi |
170 |
+ if use ldap-bind; then |
171 |
+ mycc="${mycc} -DUSE_LDAP_SASL" |
172 |
+ fi |
173 |
+ mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl" |
174 |
+ mylibs="${mylibs} -lsasl2" |
175 |
+ elif use dovecot-sasl; then |
176 |
+ mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"" |
177 |
+ fi |
178 |
+ |
179 |
+ if ! use nis; then |
180 |
+ mycc="${mycc} -DNO_NIS" |
181 |
+ fi |
182 |
+ |
183 |
+ if ! use berkdb; then |
184 |
+ mycc="${mycc} -DNO_DB" |
185 |
+ if use cdb; then |
186 |
+ # change default hash format from Berkeley DB to cdb |
187 |
+ mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\"" |
188 |
+ fi |
189 |
+ fi |
190 |
+ |
191 |
+ if use cdb; then |
192 |
+ mycc="${mycc} -DHAS_CDB -I/usr/include/cdb" |
193 |
+ # Tinycdb is preferred. |
194 |
+ if has_version dev-db/tinycdb ; then |
195 |
+ einfo "Building with dev-db/tinycdb" |
196 |
+ AUXLIBS_CDB="-lcdb" |
197 |
+ else |
198 |
+ einfo "Building with dev-db/cdb" |
199 |
+ CDB_PATH="/usr/$(get_libdir)" |
200 |
+ for i in cdb.a alloc.a buffer.a unix.a byte.a ; do |
201 |
+ AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}" |
202 |
+ done |
203 |
+ fi |
204 |
+ fi |
205 |
+ |
206 |
+ # Robin H. Johnson <robbat2@g.o> 17/Nov/2006 |
207 |
+ # Fix because infra boxes hit 2Gb .db files that fail a 32-bit fstat signed check. |
208 |
+ mycc="${mycc} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE" |
209 |
+ filter-lfs-flags |
210 |
+ |
211 |
+ # Workaround for bug #76512 |
212 |
+ if use hardened; then |
213 |
+ [[ "$(gcc-version)" == "3.4" ]] && replace-flags -O? -Os |
214 |
+ fi |
215 |
+ |
216 |
+ # Remove annoying C++ comment style warnings - bug #378099 |
217 |
+ append-flags -Wno-comment |
218 |
+ |
219 |
+ sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs |
220 |
+ sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs |
221 |
+ |
222 |
+ emake makefiles shared=yes dynamicmaps=no pie=yes \ |
223 |
+ shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \ |
224 |
+ DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \ |
225 |
+ AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \ |
226 |
+ AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \ |
227 |
+ AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \ |
228 |
+ AUXLIBS_SQLITE="${AUXLIBS_SQLITE}" |
229 |
+} |
230 |
+ |
231 |
+src_install () { |
232 |
+ local myconf |
233 |
+ use doc && myconf="readme_directory=\"/usr/share/doc/${PF}/readme\" \ |
234 |
+ html_directory=\"/usr/share/doc/${PF}/html\"" |
235 |
+ |
236 |
+ LD_LIBRARY_PATH="${S}/lib" \ |
237 |
+ /bin/sh postfix-install \ |
238 |
+ -non-interactive \ |
239 |
+ install_root="${D}" \ |
240 |
+ config_directory="/etc/postfix" \ |
241 |
+ manpage_directory="/usr/share/man" \ |
242 |
+ command_directory="/usr/sbin" \ |
243 |
+ mailq_path="/usr/bin/mailq" \ |
244 |
+ newaliases_path="/usr/bin/newaliases" \ |
245 |
+ sendmail_path="/usr/sbin/sendmail" \ |
246 |
+ ${myconf} \ |
247 |
+ || die "postfix-install failed" |
248 |
+ |
249 |
+ # Fix spool removal on upgrade |
250 |
+ rm -Rf "${D}"/var |
251 |
+ keepdir /var/spool/postfix |
252 |
+ |
253 |
+ # Install rmail for UUCP, closes bug #19127 |
254 |
+ dobin auxiliary/rmail/rmail |
255 |
+ |
256 |
+ # Provide another link for legacy FSH |
257 |
+ dosym /usr/sbin/sendmail /usr/$(get_libdir)/sendmail |
258 |
+ |
259 |
+ # Install qshape and posttls-finger |
260 |
+ dobin auxiliary/qshape/qshape.pl |
261 |
+ doman man/man1/qshape.1 |
262 |
+ dobin bin/posttls-finger |
263 |
+ doman man/man1/posttls-finger.1 |
264 |
+ |
265 |
+ # Performance tuning tools and their manuals |
266 |
+ dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink} |
267 |
+ doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1 |
268 |
+ |
269 |
+ # Set proper permissions on required files/directories |
270 |
+ dodir /var/lib/postfix |
271 |
+ keepdir /var/lib/postfix |
272 |
+ fowners -R postfix:postfix /var/lib/postfix |
273 |
+ fperms 0750 /var/lib/postfix |
274 |
+ fowners root:postdrop /usr/sbin/post{drop,queue} |
275 |
+ fperms 02711 /usr/sbin/post{drop,queue} |
276 |
+ |
277 |
+ keepdir /etc/postfix |
278 |
+ if use mbox; then |
279 |
+ mypostconf="mail_spool_directory=/var/spool/mail" |
280 |
+ else |
281 |
+ mypostconf="home_mailbox=.maildir/" |
282 |
+ fi |
283 |
+ LD_LIBRARY_PATH="${S}/lib" \ |
284 |
+ "${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \ |
285 |
+ -e ${mypostconf} || die "postconf failed" |
286 |
+ |
287 |
+ insinto /etc/postfix |
288 |
+ newins "${FILESDIR}"/smtp.pass saslpass |
289 |
+ fperms 600 /etc/postfix/saslpass |
290 |
+ |
291 |
+ newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix |
292 |
+ # do not start mysql/postgres unnecessarily - bug #359913 |
293 |
+ use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix" |
294 |
+ use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix" |
295 |
+ |
296 |
+ dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES* |
297 |
+ use doc && mv "${S}"/examples "${D}"/usr/share/doc/${PF}/ |
298 |
+ |
299 |
+ pamd_mimic_system smtp auth account |
300 |
+ |
301 |
+ if use sasl; then |
302 |
+ insinto /etc/sasl2 |
303 |
+ newins "${FILESDIR}"/smtp.sasl smtpd.conf |
304 |
+ fi |
305 |
+ |
306 |
+ # header files |
307 |
+ insinto /usr/include/postfix |
308 |
+ doins include/*.h |
309 |
+ |
310 |
+ # Keep config_dir clean |
311 |
+ rm -f "${D}"/etc/postfix/{*LICENSE,access,aliases,canonical,generic} |
312 |
+ rm -f "${D}"/etc/postfix/{header_checks,relocated,transport,virtual} |
313 |
+ |
314 |
+ if has_version mail-mta/postfix; then |
315 |
+ # let the sysadmin decide when to change the compatibility_level |
316 |
+ sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die |
317 |
+ fi |
318 |
+ |
319 |
+ systemd_dounit "${FILESDIR}/${PN}.service" |
320 |
+} |
321 |
+ |
322 |
+pkg_postinst() { |
323 |
+ if [[ ! -e /etc/mail/aliases.db ]] ; then |
324 |
+ ewarn |
325 |
+ ewarn "You must edit /etc/mail/aliases to suit your needs" |
326 |
+ ewarn "and then run /usr/bin/newaliases. Postfix will not" |
327 |
+ ewarn "work correctly without it." |
328 |
+ ewarn |
329 |
+ fi |
330 |
+ |
331 |
+ # configure tls |
332 |
+ if use ssl ; then |
333 |
+ if "${EROOT}"/usr/sbin/postfix tls all-default-client; then |
334 |
+ elog "To configure client side TLS settings:" |
335 |
+ elog "${EROOT}"usr/sbin/postfix tls enable-client |
336 |
+ fi |
337 |
+ if "${EROOT}"/usr/sbin/postfix tls all-default-server; then |
338 |
+ elog "To configure server side TLS settings:" |
339 |
+ elog "${EROOT}"usr/sbin/postfix tls enable-server |
340 |
+ fi |
341 |
+ fi |
342 |
+} |