Gentoo Archives: gentoo-commits

From: "Anthony G. Basile" <blueness@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: mail-mta/netqmail/
Date: Sun, 11 Oct 2015 01:00:30
Message-Id: 1444525558.df698a2d043800932ce06a74cd75ec75fcc2787b.blueness@gentoo
1 commit: df698a2d043800932ce06a74cd75ec75fcc2787b
2 Author: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
3 AuthorDate: Sun Oct 11 01:05:58 2015 +0000
4 Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
5 CommitDate: Sun Oct 11 01:05:58 2015 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=df698a2d
7
8 mail-mta/netqmail: add libressl support
9
10 Package-Manager: portage-2.2.20.1
11
12 mail-mta/netqmail/netqmail-1.06-r3.ebuild | 173 ++++++++++++++++++++++++++++++
13 1 file changed, 173 insertions(+)
14
15 diff --git a/mail-mta/netqmail/netqmail-1.06-r3.ebuild b/mail-mta/netqmail/netqmail-1.06-r3.ebuild
16 new file mode 100644
17 index 0000000..08dd2eb
18 --- /dev/null
19 +++ b/mail-mta/netqmail/netqmail-1.06-r3.ebuild
20 @@ -0,0 +1,173 @@
21 +# Copyright 1999-2015 Gentoo Foundation
22 +# Distributed under the terms of the GNU General Public License v2
23 +# $Id$
24 +
25 +EAPI=5
26 +
27 +GENQMAIL_PV=20080406
28 +QMAIL_SPP_PV=0.42
29 +
30 +QMAIL_TLS_PV=20070417
31 +QMAIL_TLS_F=${PN}-1.05-tls-smtpauth-${QMAIL_TLS_PV}.patch
32 +QMAIL_TLS_CVE=vu555316.patch
33 +
34 +QMAIL_BIGTODO_PV=103
35 +QMAIL_BIGTODO_F=big-todo.${QMAIL_BIGTODO_PV}.patch
36 +
37 +QMAIL_LARGE_DNS='qmail-103.patch'
38 +
39 +inherit eutils qmail
40 +
41 +DESCRIPTION="qmail -- a secure, reliable, efficient, simple message transfer agent"
42 +HOMEPAGE="
43 + http://netqmail.org
44 + http://cr.yp.to/qmail.html
45 + http://qmail.org
46 +"
47 +SRC_URI="mirror://qmail/${P}.tar.gz
48 + https://dev.gentoo.org/~hollow/distfiles/${GENQMAIL_F}
49 + http://www.ckdhr.com/ckd/${QMAIL_LARGE_DNS}
50 + http://inoa.net/qmail-tls/${QMAIL_TLS_CVE}
51 + !vanilla? (
52 + highvolume? ( mirror://qmail/${QMAIL_BIGTODO_F} )
53 + qmail-spp? ( mirror://sourceforge/qmail-spp/${QMAIL_SPP_F} )
54 + ssl? ( http://shupp.org/patches/${QMAIL_TLS_F} )
55 + )
56 +"
57 +
58 +LICENSE="public-domain"
59 +SLOT="0"
60 +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
61 +IUSE="authcram gencertdaily highvolume libressl qmail-spp ssl vanilla"
62 +REQUIRED_USE='vanilla? ( !ssl !qmail-spp !highvolume )'
63 +RESTRICT="test"
64 +
65 +DEPEND="
66 + !mail-mta/qmail
67 + net-mail/queue-repair
68 + ssl? (
69 + !libressl? ( dev-libs/openssl:0 )
70 + libressl? ( dev-libs/libressl )
71 + )
72 + sys-apps/groff
73 +"
74 +RDEPEND="
75 + !mail-mta/courier
76 + !mail-mta/esmtp
77 + !mail-mta/exim
78 + !mail-mta/mini-qmail
79 + !mail-mta/msmtp[mta]
80 + !mail-mta/nullmailer
81 + !mail-mta/postfix
82 + !mail-mta/qmail-ldap
83 + !mail-mta/sendmail
84 + !<mail-mta/ssmtp-2.64-r2
85 + !>=mail-mta/ssmtp-2.64-r2[mta]
86 + >=sys-apps/ucspi-tcp-0.88-r17
87 + ssl? ( >=sys-apps/ucspi-ssl-0.70-r1 )
88 + virtual/daemontools
89 + >=net-mail/dot-forward-0.71-r3
90 + virtual/checkpassword
91 + authcram? ( >=net-mail/cmd5checkpw-0.30 )
92 + ${DEPEND}
93 +"
94 +
95 +pkg_setup() {
96 + if [[ -n "${QMAIL_PATCH_DIR}" ]]; then
97 + eerror
98 + eerror "The QMAIL_PATCH_DIR variable for custom patches"
99 + eerror "has been removed from ${PN}. If you need custom patches"
100 + eerror "you should create a copy of this ebuild in an overlay."
101 + eerror
102 + die "QMAIL_PATCH_DIR is not supported anymore"
103 + fi
104 +
105 + qmail_create_users
106 +}
107 +
108 +src_unpack() {
109 + genqmail_src_unpack
110 + use qmail-spp && qmail_spp_src_unpack
111 +
112 + unpack ${P}.tar.gz
113 +}
114 +
115 +src_prepare() {
116 + epatch "${FILESDIR}"/${PV}-exit.patch
117 + epatch "${FILESDIR}"/${PV}-readwrite.patch
118 + epatch "${DISTDIR}"/${QMAIL_LARGE_DNS}
119 + epatch "${FILESDIR}"/${PV}-fbsd-utmpx.patch
120 +
121 + ht_fix_file Makefile*
122 +
123 + if ! use vanilla; then
124 + # This patch contains relative paths and needs to be cleaned up.
125 + sed 's~^--- ../../~--- ~g' \
126 + <"${DISTDIR}"/${QMAIL_TLS_F} \
127 + >"${T}"/${QMAIL_TLS_F}
128 + use ssl && epatch "${T}"/${QMAIL_TLS_F}
129 + use ssl && epatch "${DISTDIR}"/${QMAIL_TLS_CVE}
130 + use highvolume && epatch "${DISTDIR}"/${QMAIL_BIGTODO_F}
131 +
132 + if use qmail-spp; then
133 + if use ssl; then
134 + epatch "${QMAIL_SPP_S}"/qmail-spp-smtpauth-tls-20060105.diff
135 + else
136 + epatch "${QMAIL_SPP_S}"/netqmail-spp.diff
137 + fi
138 + cd "${WORKDIR}"
139 + epatch "${FILESDIR}"/genqmail-20080406-ldflags.patch
140 + cd -
141 + fi
142 + fi
143 +
144 + qmail_src_postunpack
145 +
146 + # Fix bug #33818 but for netqmail (Bug 137015)
147 + if ! use authcram; then
148 + einfo "Disabled CRAM_MD5 support"
149 + sed -e 's,^#define CRAM_MD5$,/*&*/,' -i "${S}"/qmail-smtpd.c
150 + else
151 + einfo "Enabled CRAM_MD5 support"
152 + fi
153 +}
154 +
155 +src_compile() {
156 + qmail_src_compile
157 + use qmail-spp && qmail_spp_src_compile
158 +}
159 +
160 +src_install() {
161 + qmail_src_install
162 +}
163 +
164 +pkg_postinst() {
165 + qmail_queue_setup
166 + qmail_rootmail_fixup
167 + qmail_tcprules_build
168 +
169 + qmail_config_notice
170 + qmail_supervise_config_notice
171 + elog
172 + elog "If you are looking for documentation, check those links:"
173 + elog "https://www.gentoo.org/doc/en/qmail-howto.xml"
174 + elog " -- qmail/vpopmail Virtual Mail Hosting System Guide"
175 + elog "http://www.lifewithqmail.com/"
176 + elog " -- Life with qmail"
177 + elog
178 +}
179 +
180 +pkg_preinst() {
181 + qmail_tcprules_fixup
182 +}
183 +
184 +pkg_config() {
185 + # avoid some weird locale problems
186 + export LC_ALL=C
187 +
188 + qmail_config_fast
189 + qmail_tcprules_config
190 + qmail_tcprules_build
191 +
192 + use ssl && qmail_ssl_generate
193 +}