1 |
commit: 5c1968d993330fcd3d593e014de4d7eccfd05872 |
2 |
Author: Thomas Deutschmann <whissi <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Sep 6 13:16:23 2019 +0000 |
4 |
Commit: Thomas Deutschmann <whissi <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Sep 6 13:17:49 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5c1968d9 |
7 |
|
8 |
mail-mta/exim: bump to v4.92.2 (CVE-2019-15846) |
9 |
|
10 |
Ebuild changes: |
11 |
- EAPI bumped to EAPI=7 |
12 |
|
13 |
Bug: https://bugs.gentoo.org/693494 |
14 |
Package-Manager: Portage-2.3.75, Repoman-2.3.17 |
15 |
Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org> |
16 |
|
17 |
mail-mta/exim/Manifest | 2 + |
18 |
mail-mta/exim/exim-4.92.2.ebuild | 582 +++++++++++++++++++++++++++++++++++++++ |
19 |
2 files changed, 584 insertions(+) |
20 |
|
21 |
diff --git a/mail-mta/exim/Manifest b/mail-mta/exim/Manifest |
22 |
index 92f89a8e4ee..e94787221cc 100644 |
23 |
--- a/mail-mta/exim/Manifest |
24 |
+++ b/mail-mta/exim/Manifest |
25 |
@@ -1,5 +1,7 @@ |
26 |
DIST exim-4.92.1.tar.xz 1767976 BLAKE2B fb5bdb8762f16e30c43c7899e5fb5b459bb5e910458f970d20a5cb26cdde842d87a1f8150e4c0f9e931fa277e2f33a0fb8a6d478b5bf871d03a12ebd06c36d67 SHA512 fd43448db0aa5139f8b459322b95e258f232ac8a4bf21a19099c7768329ec20c344c4e0d8dd2e98c33a192a5f97d7666a746de2c87bdfb8da42c625c985d7e05 |
27 |
+DIST exim-4.92.2.tar.xz 1772688 BLAKE2B 618c70e26811d0e6d453a4b88ab1cdb9e337a9ca8ceec50aee665b1493c75157001483cf9721e3d57313a90910d2605717b2c4be4174c2897b3f992af01c1c26 SHA512 d27aca4d4e9df267b0afcbe7b3f74c9ca6e96e7e6eb4d2f86ff00b0e2234eaec90271405eb387a36a2e0d4ec5597b2920753f85318a5618ddbc8af475a7d81cd |
28 |
DIST exim-4.92.tar.xz 1767136 BLAKE2B 6c97578807073a782112218c65de460cc94f046d807eddc7330f2f67266c0ef341ded61050a16aca13c88e606a923a9e08033c8bfb618a7ef34b3d2ea6db32ca SHA512 62c327e6184a358ba7f0dbc38b44d2537234be91727a5bfac97e74af64a8d77e376b3221dcfdd8f6eca7d812f9233595503dc6e50e2972bed40a1b74eb209c31 |
29 |
DIST exim-pdf-4.92.1.tar.xz 2038948 BLAKE2B 6624fb8930944f79e0c7e52a001727cfcff508ac69cb4107247201b8598d6e223cac7c7eda14c3102d0eabc151a547b6cc5ef11a6c4a830f31dfd88e24907c1d SHA512 437b868cd7dedae59e32b9245c8c1ca3375605eb4911846bc3508b627acf32c99bda644b3c3e84eb539a39b3c2cc4f83314eebe55160b3da617ccaec2f1623a2 |
30 |
+DIST exim-pdf-4.92.2.tar.xz 2039468 BLAKE2B 3542bb5d38267bb06728ada72cfa89f06027b917799e743a1764cb7568cf0ba4cdbc5b40738c3ae41c9540d348810b388d74ad315a201f2740a5a0b79e83f904 SHA512 da90354cd8133103f08b978dd0422fd1a00e5866cd3f40e523d06875fb8b31163d7fe9791f1cf81d15bc63b16fc7f6bb98cf28c3036d054464336c07245b3c91 |
31 |
DIST exim-pdf-4.92.tar.xz 2038812 BLAKE2B d5966a27f980a2ceb31293d92049a6691a08262bd20ae7315f41929f0d7a45b5d66c7000f9596b193e74d0c17f91c56a3262602047673c49649f1cad6b216547 SHA512 3a40818025fceaa7ac17f8e7ce06a61e3cf65267c821aea93e1a1a659782b047ab177b88a38c9b2271c0a296e1dc7939e23fe0f89415a11cd45693cb8af10c15 |
32 |
DIST system_filter.exim.gz 3075 BLAKE2B d05e872b5cef377d29126cda03fc0a74c8777b2119b76ff43da6e8de808035eb9bfcb034a85d81824f135d484e864bfc0629fc1af2c228a7277d5ee7cf9cde79 SHA512 cb358d3ce2499a0bb5920d962a06f2af8486e55ec90c8c928bd8e3aefb279aa57f5f960d5adfcef68bd94110b405eaa144e9629cfe6014a529c79c544600bbf3 |
33 |
|
34 |
diff --git a/mail-mta/exim/exim-4.92.2.ebuild b/mail-mta/exim/exim-4.92.2.ebuild |
35 |
new file mode 100644 |
36 |
index 00000000000..1217a52cf51 |
37 |
--- /dev/null |
38 |
+++ b/mail-mta/exim/exim-4.92.2.ebuild |
39 |
@@ -0,0 +1,582 @@ |
40 |
+# Copyright 1999-2019 Gentoo Authors |
41 |
+# Distributed under the terms of the GNU General Public License v2 |
42 |
+ |
43 |
+EAPI="7" |
44 |
+ |
45 |
+inherit db-use toolchain-funcs multilib pam systemd |
46 |
+ |
47 |
+IUSE="arc dane dcc +dkim dlfunc dmarc +dnsdb doc dovecot-sasl dsn elibc_glibc exiscan-acl gnutls idn ipv6 ldap libressl lmtp maildir mbx mysql nis pam perl pkcs11 postgres +prdr proxy radius redis sasl selinux spf sqlite srs ssl syslog tcpd +tpda X" |
48 |
+REQUIRED_USE=" |
49 |
+ arc? ( dkim spf ) |
50 |
+ dane? ( ssl !gnutls ) |
51 |
+ dmarc? ( dkim spf ) |
52 |
+ gnutls? ( ssl ) |
53 |
+ pkcs11? ( ssl ) |
54 |
+ spf? ( exiscan-acl ) |
55 |
+ srs? ( exiscan-acl ) |
56 |
+ !ssl? ( !dkim ) |
57 |
+" |
58 |
+# NOTE on USE="gnutls dane", gnutls[dane] is masked in base, unmasked |
59 |
+# for x86 and amd64 only, due to this, repoman won't allow depending on |
60 |
+# gnutls[dane] for all else. Because we cannot express USE=dane when |
61 |
+# USE=gnutls is in effect only in package.use.mask, the only option we |
62 |
+# have left is to a) ignore the dependency (but that results in bug |
63 |
+# #661164) or b) mask the usage of USE=dane with USE=gnutls. Both are |
64 |
+# incorrect, but b) is the only "correct" view from repoman. |
65 |
+ |
66 |
+COMM_URI="https://downloads.exim.org/exim4$([[ ${PV} == *_rc* ]] && echo /test)" |
67 |
+ |
68 |
+DESCRIPTION="A highly configurable, drop-in replacement for sendmail" |
69 |
+SRC_URI="${COMM_URI}/${P//rc/RC}.tar.xz |
70 |
+ mirror://gentoo/system_filter.exim.gz |
71 |
+ doc? ( ${COMM_URI}/${PN}-pdf-${PV//rc/RC}.tar.xz )" |
72 |
+HOMEPAGE="https://www.exim.org/" |
73 |
+ |
74 |
+SLOT="0" |
75 |
+LICENSE="GPL-2" |
76 |
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~x86-solaris" |
77 |
+ |
78 |
+COMMON_DEPEND=">=sys-apps/sed-4.0.5 |
79 |
+ ( >=sys-libs/db-3.2:= <sys-libs/db-6:= ) |
80 |
+ dev-libs/libpcre |
81 |
+ idn? ( net-dns/libidn:= net-dns/libidn2:= ) |
82 |
+ perl? ( dev-lang/perl:= ) |
83 |
+ pam? ( virtual/pam ) |
84 |
+ tcpd? ( sys-apps/tcp-wrappers ) |
85 |
+ ssl? ( |
86 |
+ !libressl? ( dev-libs/openssl:0= ) |
87 |
+ libressl? ( dev-libs/libressl:= ) |
88 |
+ ) |
89 |
+ gnutls? ( |
90 |
+ net-libs/gnutls:0=[pkcs11?] |
91 |
+ dev-libs/libtasn1 |
92 |
+ ) |
93 |
+ ldap? ( >=net-nds/openldap-2.0.7 ) |
94 |
+ nis? ( |
95 |
+ elibc_glibc? ( |
96 |
+ net-libs/libtirpc |
97 |
+ >=net-libs/libnsl-1:= |
98 |
+ ) |
99 |
+ ) |
100 |
+ mysql? ( dev-db/mysql-connector-c:= ) |
101 |
+ postgres? ( dev-db/postgresql:= ) |
102 |
+ sasl? ( >=dev-libs/cyrus-sasl-2.1.26-r2 ) |
103 |
+ redis? ( dev-libs/hiredis ) |
104 |
+ spf? ( >=mail-filter/libspf2-1.2.5-r1 ) |
105 |
+ dmarc? ( mail-filter/opendmarc ) |
106 |
+ srs? ( mail-filter/libsrs_alt ) |
107 |
+ X? ( |
108 |
+ x11-libs/libX11 |
109 |
+ x11-libs/libXmu |
110 |
+ x11-libs/libXt |
111 |
+ x11-libs/libXaw |
112 |
+ ) |
113 |
+ sqlite? ( dev-db/sqlite ) |
114 |
+ radius? ( net-dialup/freeradius-client ) |
115 |
+ virtual/libiconv |
116 |
+ elibc_glibc? ( net-libs/libnsl ) |
117 |
+ " |
118 |
+ # added X check for #57206 |
119 |
+BDEPEND="virtual/pkgconfig" |
120 |
+DEPEND="${COMMON_DEPEND}" |
121 |
+RDEPEND="${COMMON_DEPEND} |
122 |
+ !mail-mta/courier |
123 |
+ !mail-mta/esmtp |
124 |
+ !mail-mta/mini-qmail |
125 |
+ !<mail-mta/msmtp-1.4.19-r1 |
126 |
+ !>=mail-mta/msmtp-1.4.19-r1[mta] |
127 |
+ !mail-mta/netqmail |
128 |
+ !mail-mta/nullmailer |
129 |
+ !mail-mta/postfix |
130 |
+ !mail-mta/qmail-ldap |
131 |
+ !mail-mta/sendmail |
132 |
+ !mail-mta/opensmtpd |
133 |
+ !<mail-mta/ssmtp-2.64-r2 |
134 |
+ !>=mail-mta/ssmtp-2.64-r2[mta] |
135 |
+ !net-mail/mailwrapper |
136 |
+ >=net-mail/mailbase-0.00-r5 |
137 |
+ virtual/logger |
138 |
+ dcc? ( mail-filter/dcc ) |
139 |
+ selinux? ( sec-policy/selinux-exim ) |
140 |
+ " |
141 |
+ |
142 |
+PATCHES=( |
143 |
+ "${FILESDIR}"/exim-4.69-r1.27021.patch |
144 |
+ "${FILESDIR}"/exim-4.92-localscan_dlopen.patch |
145 |
+) |
146 |
+ |
147 |
+S=${WORKDIR}/${P//rc/RC} |
148 |
+ |
149 |
+src_prepare() { |
150 |
+ # Legacy patches which need a respin for -p1 |
151 |
+ eapply -p0 "${FILESDIR}"/exim-4.14-tail.patch |
152 |
+ eapply -p0 "${FILESDIR}"/exim-4.74-radius-db-ENV-clash.patch # 287426 |
153 |
+ eapply -p0 "${FILESDIR}"/exim-4.82-makefile-freebsd.patch # 235785 |
154 |
+ eapply -p0 "${FILESDIR}"/exim-4.89-as-needed-ldflags.patch # 352265, 391279 |
155 |
+ eapply -p0 "${FILESDIR}"/exim-4.76-crosscompile.patch # 266591 |
156 |
+ eapply -p2 "${FILESDIR}"/exim-4.92-fix-eval-expansion-32bit.patch #687554 |
157 |
+ |
158 |
+ if use maildir ; then |
159 |
+ eapply "${FILESDIR}"/exim-4.20-maildir.patch |
160 |
+ else |
161 |
+ eapply -p0 "${FILESDIR}"/exim-4.80-spool-mail-group.patch # 438606 |
162 |
+ fi |
163 |
+ |
164 |
+ default |
165 |
+ |
166 |
+ # user Exim believes it should be |
167 |
+ MAILUSER=mail |
168 |
+ MAILGROUP=mail |
169 |
+ if use prefix && [[ ${EUID} != 0 ]] ; then |
170 |
+ MAILUSER=$(id -un) |
171 |
+ MAILGROUP=$(id -gn) |
172 |
+ fi |
173 |
+} |
174 |
+ |
175 |
+src_configure() { |
176 |
+ # general config and paths |
177 |
+ |
178 |
+ local aliases="${EPREFIX}/etc/mail/aliases" |
179 |
+ sed -i \ |
180 |
+ -e "/SYSTEM_ALIASES_FILE/s'SYSTEM_ALIASES_FILE'${aliases}'" \ |
181 |
+ src/configure.default || die |
182 |
+ |
183 |
+ sed -i -e 's/^buildname=.*/buildname=exim-gentoo/' Makefile || die |
184 |
+ |
185 |
+ if use elibc_musl; then |
186 |
+ sed -i -e 's/^LIBS = -lnsl/LIBS =/g' OS/Makefile-Linux || die |
187 |
+ fi |
188 |
+ |
189 |
+ local conffile="${EPREFIX}/etc/exim/exim.conf" |
190 |
+ sed -e "48i\CFLAGS=${CFLAGS}" \ |
191 |
+ -e "s:BIN_DIRECTORY=/usr/exim/bin:BIN_DIRECTORY=${EPREFIX}/usr/sbin:" \ |
192 |
+ -e "s:EXIM_USER=:EXIM_USER=${MAILUSER}:" \ |
193 |
+ -e "s:CONFIGURE_FILE=.*$:CONFIGURE_FILE=${conffile}:" \ |
194 |
+ -e "s:ZCAT_COMMAND=.*$:ZCAT_COMMAND=${EPREFIX}/bin/zcat:" \ |
195 |
+ -e "s:COMPRESS_COMMAND=.*$:COMPRESS_COMMAND=${EPREFIX}/bin/gzip:" \ |
196 |
+ src/EDITME > Local/Makefile || die |
197 |
+ |
198 |
+ # work on Local/Makefile from now on |
199 |
+ cd Local |
200 |
+ |
201 |
+ cat >> Makefile <<- EOC |
202 |
+ INFO_DIRECTORY=${EPREFIX}/usr/share/info |
203 |
+ PID_FILE_PATH=${EPREFIX}/run/exim.pid |
204 |
+ SPOOL_DIRECTORY=${EPREFIX}/var/spool/exim |
205 |
+ HAVE_ICONV=yes |
206 |
+ EOC |
207 |
+ |
208 |
+ # if we use libiconv, now is the time to tell so |
209 |
+ use !elibc_glibc && use !elibc_musl && \ |
210 |
+ echo "EXTRALIBS_EXIM=-liconv" >> Makefile |
211 |
+ |
212 |
+ # support for IPv6 |
213 |
+ if use ipv6; then |
214 |
+ cat >> Makefile <<- EOC |
215 |
+ HAVE_IPV6=YES |
216 |
+ EOC |
217 |
+ fi |
218 |
+ |
219 |
+ # support i18n/IDNA |
220 |
+ if use idn; then |
221 |
+ cat >> Makefile <<- EOC |
222 |
+ SUPPORT_I18N=yes |
223 |
+ SUPPORT_I18N_2008=yes |
224 |
+ EXTRALIBS_EXIM += -lidn -lidn2 |
225 |
+ EOC |
226 |
+ fi |
227 |
+ |
228 |
+ # |
229 |
+ # mail storage formats |
230 |
+ # |
231 |
+ |
232 |
+ # mailstore is Exim's traditional storage format |
233 |
+ cat >> Makefile <<- EOC |
234 |
+ SUPPORT_MAILSTORE=yes |
235 |
+ EOC |
236 |
+ |
237 |
+ # mbox |
238 |
+ if use mbx; then |
239 |
+ cat >> Makefile <<- EOC |
240 |
+ SUPPORT_MBX=yes |
241 |
+ EOC |
242 |
+ fi |
243 |
+ |
244 |
+ # maildir |
245 |
+ if use maildir; then |
246 |
+ cat >> Makefile <<- EOC |
247 |
+ SUPPORT_MAILDIR=yes |
248 |
+ EOC |
249 |
+ fi |
250 |
+ |
251 |
+ # |
252 |
+ # lookup methods |
253 |
+ |
254 |
+ # use the "native" interfaces to the DBM and CDB libraries, support |
255 |
+ # passwd and directory lookups by default |
256 |
+ local DB_VERS="5.3 5.1 4.8 4.7 4.6 4.5 4.4 4.3 4.2 3.2" |
257 |
+ cat >> Makefile <<- EOC |
258 |
+ USE_DB=yes |
259 |
+ CFLAGS+=-I$(db_includedir ${DB_VERS}) |
260 |
+ DBMLIB=-l$(db_libname ${DB_VERS}) |
261 |
+ LOOKUP_CDB=yes |
262 |
+ LOOKUP_PASSWD=yes |
263 |
+ LOOKUP_DSEARCH=yes |
264 |
+ EOC |
265 |
+ |
266 |
+ if ! use dnsdb; then |
267 |
+ # DNSDB lookup is enabled by default |
268 |
+ sed -i -e 's:^LOOKUP_DNSDB=yes:# LOOKUP_DNSDB=yes:' Makefile || die |
269 |
+ fi |
270 |
+ |
271 |
+ if use ldap; then |
272 |
+ cat >> Makefile <<- EOC |
273 |
+ LOOKUP_LDAP=yes |
274 |
+ LDAP_LIB_TYPE=OPENLDAP2 |
275 |
+ LOOKUP_INCLUDE += -I"${EPREFIX}"/usr/include/ldap |
276 |
+ LOOKUP_LIBS += -lldap -llber |
277 |
+ EOC |
278 |
+ fi |
279 |
+ |
280 |
+ if use mysql; then |
281 |
+ cat >> Makefile <<- EOC |
282 |
+ LOOKUP_MYSQL=yes |
283 |
+ LOOKUP_INCLUDE += $(mysql_config --include) |
284 |
+ LOOKUP_LIBS += $(mysql_config --libs) |
285 |
+ EOC |
286 |
+ fi |
287 |
+ |
288 |
+ if use nis; then |
289 |
+ cat >> Makefile <<- EOC |
290 |
+ LOOKUP_NIS=yes |
291 |
+ LOOKUP_NISPLUS=yes |
292 |
+ EOC |
293 |
+ if use elibc_glibc ; then |
294 |
+ cat >> Makefile <<- EOC |
295 |
+ CFLAGS += -I"${EPREFIX}"/usr/include/tirpc |
296 |
+ EOC |
297 |
+ fi |
298 |
+ fi |
299 |
+ |
300 |
+ if use postgres; then |
301 |
+ cat >> Makefile <<- EOC |
302 |
+ LOOKUP_PGSQL=yes |
303 |
+ LOOKUP_INCLUDE += -I$(pg_config --includedir) |
304 |
+ LOOKUP_LIBS += -L$(pg_config --libdir) -lpq |
305 |
+ EOC |
306 |
+ fi |
307 |
+ |
308 |
+ if use sqlite; then |
309 |
+ cat >> Makefile <<- EOC |
310 |
+ LOOKUP_SQLITE=yes |
311 |
+ LOOKUP_SQLITE_PC=sqlite3 |
312 |
+ EOC |
313 |
+ fi |
314 |
+ |
315 |
+ if use redis; then |
316 |
+ cat >> Makefile <<- EOC |
317 |
+ LOOKUP_REDIS=yes |
318 |
+ LOOKUP_LIBS += -lhiredis |
319 |
+ EOC |
320 |
+ fi |
321 |
+ |
322 |
+ # Exim monitor, enabled by default, controlled via X USE-flag, |
323 |
+ # disable if not requested, bug #46778 |
324 |
+ if use X; then |
325 |
+ cp ../exim_monitor/EDITME eximon.conf || die |
326 |
+ else |
327 |
+ sed -i -e '/^EXIM_MONITOR=/s/^/# /' Makefile || die |
328 |
+ fi |
329 |
+ |
330 |
+ # |
331 |
+ # features |
332 |
+ # |
333 |
+ |
334 |
+ # content scanning support |
335 |
+ if use exiscan-acl; then |
336 |
+ cat >> Makefile <<- EOC |
337 |
+ WITH_CONTENT_SCAN=yes |
338 |
+ EOC |
339 |
+ fi |
340 |
+ |
341 |
+ # DomainKeys Identified Mail, RFC4871 |
342 |
+ if ! use dkim; then |
343 |
+ # DKIM is enabled by default |
344 |
+ cat >> Makefile <<- EOC |
345 |
+ DISABLE_DKIM=yes |
346 |
+ EOC |
347 |
+ fi |
348 |
+ |
349 |
+ # Per-Recipient-Data-Response |
350 |
+ if ! use prdr; then |
351 |
+ # PRDR is enabled by default |
352 |
+ cat >> Makefile <<- EOC |
353 |
+ DISABLE_PRDR=yes |
354 |
+ EOC |
355 |
+ fi |
356 |
+ |
357 |
+ # Transport post-delivery actions |
358 |
+ if use !tpda && use !dane; then |
359 |
+ # EVENT is enabled by default |
360 |
+ cat >> Makefile <<- EOC |
361 |
+ DISABLE_EVENT=yes |
362 |
+ EOC |
363 |
+ fi |
364 |
+ |
365 |
+ # log to syslog |
366 |
+ if use syslog; then |
367 |
+ local eximlog="${EPREFIX}/var/log/exim/exim_%s.log" |
368 |
+ sed -i \ |
369 |
+ -e "s:LOG_FILE_PATH=${eximlog}:LOG_FILE_PATH=syslog:" \ |
370 |
+ Makefile || die |
371 |
+ cat >> Makefile <<- EOC |
372 |
+ LOG_FILE_PATH=syslog |
373 |
+ EOC |
374 |
+ else |
375 |
+ cat >> Makefile <<- EOC |
376 |
+ LOG_FILE_PATH=${EPREFIX}/var/log/exim/exim_%s.log |
377 |
+ EOC |
378 |
+ fi |
379 |
+ |
380 |
+ # starttls support (ssl) |
381 |
+ if use ssl; then |
382 |
+ echo "SUPPORT_TLS=yes" >> Makefile |
383 |
+ if use gnutls; then |
384 |
+ echo "USE_GNUTLS=yes" >> Makefile |
385 |
+ echo "USE_GNUTLS_PC=gnutls" >> Makefile |
386 |
+ use pkcs11 || echo "AVOID_GNUTLS_PKCS11=yes" >> Makefile |
387 |
+ else |
388 |
+ echo "USE_OPENSSL_PC=openssl" >> Makefile |
389 |
+ fi |
390 |
+ fi |
391 |
+ |
392 |
+ # TCP wrappers |
393 |
+ if use tcpd; then |
394 |
+ cat >> Makefile <<- EOC |
395 |
+ USE_TCP_WRAPPERS=yes |
396 |
+ EXTRALIBS_EXIM += -lwrap |
397 |
+ EOC |
398 |
+ fi |
399 |
+ |
400 |
+ # Light Mail Transport Protocol |
401 |
+ if use lmtp; then |
402 |
+ cat >> Makefile <<- EOC |
403 |
+ TRANSPORT_LMTP=yes |
404 |
+ EOC |
405 |
+ fi |
406 |
+ |
407 |
+ # embedded Perl |
408 |
+ if use perl; then |
409 |
+ cat >> Makefile <<- EOC |
410 |
+ EXIM_PERL=perl.o |
411 |
+ EOC |
412 |
+ fi |
413 |
+ |
414 |
+ # dlfunc |
415 |
+ if use dlfunc; then |
416 |
+ cat >> Makefile <<- EOC |
417 |
+ EXPAND_DLFUNC=yes |
418 |
+ HAVE_LOCAL_SCAN=yes |
419 |
+ DLOPEN_LOCAL_SCAN=yes |
420 |
+ EOC |
421 |
+ fi |
422 |
+ |
423 |
+ # Proxy Protocol |
424 |
+ if use proxy; then |
425 |
+ cat >> Makefile <<- EOC |
426 |
+ SUPPORT_PROXY=yes |
427 |
+ EOC |
428 |
+ fi |
429 |
+ |
430 |
+ # DANE |
431 |
+ if use dane; then |
432 |
+ cat >> Makefile <<- EOC |
433 |
+ SUPPORT_DANE=yes |
434 |
+ EOC |
435 |
+ fi |
436 |
+ |
437 |
+ # Sender Policy Framework |
438 |
+ if use spf; then |
439 |
+ cat >> Makefile <<- EOC |
440 |
+ SUPPORT_SPF=yes |
441 |
+ EXTRALIBS_EXIM += -lspf2 |
442 |
+ EOC |
443 |
+ fi |
444 |
+ |
445 |
+ # |
446 |
+ # experimental features |
447 |
+ # |
448 |
+ |
449 |
+ # Authenticated Receive Chain |
450 |
+ if use arc; then |
451 |
+ echo "EXPERIMENTAL_ARC=yes">> Makefile |
452 |
+ fi |
453 |
+ |
454 |
+ # Distributed Checksum Clearinghouse |
455 |
+ if use dcc; then |
456 |
+ echo "EXPERIMENTAL_DCC=yes">> Makefile |
457 |
+ fi |
458 |
+ |
459 |
+ # Sender Rewriting Scheme |
460 |
+ if use srs; then |
461 |
+ cat >> Makefile <<- EOC |
462 |
+ EXPERIMENTAL_SRS=yes |
463 |
+ EXTRALIBS_EXIM += -lsrs_alt |
464 |
+ EOC |
465 |
+ fi |
466 |
+ |
467 |
+ # DMARC |
468 |
+ if use dmarc; then |
469 |
+ cat >> Makefile <<- EOC |
470 |
+ EXPERIMENTAL_DMARC=yes |
471 |
+ EXTRALIBS_EXIM += -lopendmarc |
472 |
+ EOC |
473 |
+ fi |
474 |
+ |
475 |
+ # Delivery Sender Notifications extra information in fail message |
476 |
+ if use dsn; then |
477 |
+ cat >> Makefile <<- EOC |
478 |
+ EXPERIMENTAL_DSN_INFO=yes |
479 |
+ EOC |
480 |
+ fi |
481 |
+ |
482 |
+ # |
483 |
+ # authentication (SMTP AUTH) |
484 |
+ # |
485 |
+ |
486 |
+ # standard bits |
487 |
+ cat >> Makefile <<- EOC |
488 |
+ AUTH_SPA=yes |
489 |
+ AUTH_CRAM_MD5=yes |
490 |
+ AUTH_PLAINTEXT=yes |
491 |
+ EOC |
492 |
+ |
493 |
+ # Cyrus SASL |
494 |
+ if use sasl; then |
495 |
+ cat >> Makefile <<- EOC |
496 |
+ CYRUS_SASLAUTHD_SOCKET=${EPREFIX}/run/saslauthd/mux |
497 |
+ AUTH_CYRUS_SASL=yes |
498 |
+ AUTH_LIBS += -lsasl2 |
499 |
+ EOC |
500 |
+ fi |
501 |
+ |
502 |
+ # Dovecot |
503 |
+ if use dovecot-sasl; then |
504 |
+ cat >> Makefile <<- EOC |
505 |
+ AUTH_DOVECOT=yes |
506 |
+ EOC |
507 |
+ fi |
508 |
+ |
509 |
+ # Pluggable Authentication Modules |
510 |
+ if use pam; then |
511 |
+ cat >> Makefile <<- EOC |
512 |
+ SUPPORT_PAM=yes |
513 |
+ AUTH_LIBS += -lpam |
514 |
+ EOC |
515 |
+ fi |
516 |
+ |
517 |
+ # Radius |
518 |
+ if use radius; then |
519 |
+ cat >> Makefile <<- EOC |
520 |
+ RADIUS_CONFIG_FILE=${EPREFIX}/etc/radiusclient/radiusclient.conf |
521 |
+ RADIUS_LIB_TYPE=RADIUSCLIENTNEW |
522 |
+ AUTH_LIBS += -lfreeradius-client |
523 |
+ EOC |
524 |
+ fi |
525 |
+} |
526 |
+ |
527 |
+src_compile() { |
528 |
+ emake CC="$(tc-getCC)" HOSTCC="$(tc-getBUILD_CC)" \ |
529 |
+ AR="$(tc-getAR) cq" RANLIB="$(tc-getRANLIB)" FULLECHO='' \ |
530 |
+ || die "make failed" |
531 |
+} |
532 |
+ |
533 |
+src_install () { |
534 |
+ cd "${S}"/build-exim-gentoo || die |
535 |
+ dosbin exim |
536 |
+ if use X; then |
537 |
+ dosbin eximon.bin |
538 |
+ dosbin eximon |
539 |
+ fi |
540 |
+ fperms 4755 /usr/sbin/exim |
541 |
+ |
542 |
+ dosym exim /usr/sbin/sendmail |
543 |
+ dosym exim /usr/sbin/rsmtp |
544 |
+ dosym exim /usr/sbin/rmail |
545 |
+ dosym ../sbin/exim /usr/bin/mailq |
546 |
+ dosym ../sbin/exim /usr/bin/newaliases |
547 |
+ dosym ../sbin/sendmail /usr/lib/sendmail |
548 |
+ |
549 |
+ for i in exicyclog exim_dbmbuild exim_dumpdb exim_fixdb exim_lock \ |
550 |
+ exim_tidydb exinext exiwhat exigrep eximstats exiqsumm exiqgrep \ |
551 |
+ convert4r3 convert4r4 exipick |
552 |
+ do |
553 |
+ dosbin $i |
554 |
+ done |
555 |
+ |
556 |
+ dodoc -r "${S}"/doc/. |
557 |
+ doman "${S}"/doc/exim.8 |
558 |
+ use dsn && dodoc "${S}"/README.DSN |
559 |
+ use doc && dodoc "${WORKDIR}"/${PN}-pdf-${PV//rc/RC}/doc/*.pdf |
560 |
+ |
561 |
+ # conf files |
562 |
+ insinto /etc/exim |
563 |
+ newins "${S}"/src/configure.default exim.conf.dist |
564 |
+ if use exiscan-acl; then |
565 |
+ newins "${S}"/src/configure.default exim.conf.exiscan-acl |
566 |
+ fi |
567 |
+ doins "${WORKDIR}"/system_filter.exim |
568 |
+ doins "${FILESDIR}"/auth_conf.sub |
569 |
+ |
570 |
+ pamd_mimic system-auth exim auth account |
571 |
+ |
572 |
+ # headers, #436406 |
573 |
+ if use dlfunc ; then |
574 |
+ # fixup includes so they actually can be found when including |
575 |
+ sed -i \ |
576 |
+ -e '/#include "\(config\|store\|mytypes\).h"/s:"\(.\+\)":<exim/\1>:' \ |
577 |
+ local_scan.h || die |
578 |
+ insinto /usr/include/exim |
579 |
+ doins {config,local_scan}.h ../src/{mytypes,store}.h |
580 |
+ fi |
581 |
+ |
582 |
+ insinto /etc/logrotate.d |
583 |
+ newins "${FILESDIR}/exim.logrotate" exim |
584 |
+ |
585 |
+ newinitd "${FILESDIR}"/exim.rc10 exim |
586 |
+ newconfd "${FILESDIR}"/exim.confd exim |
587 |
+ |
588 |
+ systemd_dounit \ |
589 |
+ "${FILESDIR}"/{exim.service,exim.socket,exim-submission.socket} |
590 |
+ systemd_newunit \ |
591 |
+ "${FILESDIR}"/exim_at.service 'exim@.service' |
592 |
+ systemd_newunit \ |
593 |
+ "${FILESDIR}"/exim-submission_at.service 'exim-submission@.service' |
594 |
+ |
595 |
+ diropts -m 0750 -o ${MAILUSER} -g ${MAILGROUP} |
596 |
+ keepdir /var/log/${PN} |
597 |
+} |
598 |
+ |
599 |
+pkg_postinst() { |
600 |
+ if [[ ! -f ${EROOT}/etc/exim/exim.conf ]] ; then |
601 |
+ einfo "${EROOT}/etc/exim/system_filter.exim is a sample system_filter." |
602 |
+ einfo "${EROOT}/etc/exim/auth_conf.sub contains the configuration sub" |
603 |
+ einfo "for using smtp auth." |
604 |
+ einfo "Please create ${EROOT}/etc/exim/exim.conf from" |
605 |
+ einfo " ${EROOT}/etc/exim/exim.conf.dist." |
606 |
+ fi |
607 |
+ if use dcc ; then |
608 |
+ einfo "DCC support is experimental, you can find some limited" |
609 |
+ einfo "documentation at the bottom of this prerelease message:" |
610 |
+ einfo "http://article.gmane.org/gmane.mail.exim.devel/3579" |
611 |
+ fi |
612 |
+ use srs && einfo "SRS support is experimental" |
613 |
+ if use dmarc ; then |
614 |
+ einfo "DMARC support is experimental. See global settings to" |
615 |
+ einfo "configure DMARC, for usage see the documentation at " |
616 |
+ einfo "experimental-spec.txt." |
617 |
+ fi |
618 |
+ use dsn && einfo "extra information in fail DSN message is experimental" |
619 |
+ elog "The obsolete acl condition 'demime' is removed, the replacements" |
620 |
+ elog "are the ACLs acl_smtp_mime and acl_not_smtp_mime" |
621 |
+} |