Gentoo Archives: gentoo-commits

From: Fabian Groffen <grobian@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: mail-client/mutt/
Date: Sun, 06 Sep 2020 07:50:45
Message-Id: 1599378636.cfc29b9c39314c562e2e6b9f69a2cda2590731d4.grobian@gentoo
1 commit: cfc29b9c39314c562e2e6b9f69a2cda2590731d4
2 Author: Fabian Groffen <grobian <AT> gentoo <DOT> org>
3 AuthorDate: Sun Sep 6 07:50:27 2020 +0000
4 Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org>
5 CommitDate: Sun Sep 6 07:50:36 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cfc29b9c
7
8 mail-client/mutt-1.14.7: version bump, bug #739750
9
10 Closes: https://bugs.gentoo.org/739750
11 Package-Manager: Portage-2.3.103, Repoman-2.3.23
12 Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org>
13
14 mail-client/mutt/Manifest | 2 +
15 mail-client/mutt/mutt-1.14.7.ebuild | 265 ++++++++++++++++++++++++++++++++++++
16 2 files changed, 267 insertions(+)
17
18 diff --git a/mail-client/mutt/Manifest b/mail-client/mutt/Manifest
19 index f0d5f1686c0..c35860c6471 100644
20 --- a/mail-client/mutt/Manifest
21 +++ b/mail-client/mutt/Manifest
22 @@ -1,4 +1,6 @@
23 DIST mutt-1.14.4.tar.gz 5007437 BLAKE2B 89d4327ddd86ec320c63db6ee9d3c07b7540a74aba7efdcb9605e5c5c242dec99fb5137d1cfc62fd4401e2af7589f03ebce78dfa2deae262aef408b804544656 SHA512 86484f009ca8bd1e26206694e03609a16f8a4e8c83620a07a4376fe160535a838e8c918a8a30799fb3d9cf46c059d67124f7425c42093fb5e5bf8ea4ac310daa
24 DIST mutt-1.14.5.tar.gz 5008208 BLAKE2B a7c2f7f63d2ee23e743114315cbb40903db720de7f2836f551739edb0b78857c525c40ebde083064dd2430b89b21d7a17745dfc1185672f86b15a9a082c3778e SHA512 950c8df3bdc552b41ba6209aed8d5ade6fff80fe4018a75856d0fdbcd6389bd995a6dee69e7badd05a9b40d2e2293ada9a9f9a96632e88af36b61162f226e2b9
25 +DIST mutt-1.14.7.tar.gz 5009968 BLAKE2B f729412d3da97fe9bd76733705317660edfa3858a9eb1012179fb289b03da58d79b6e261dbdc4ab8b001e89ca455e9972bab8f270bac28e887afc7e0bd9fc8c1 SHA512 dc9739b5f0a99ca70fcbd495c71fbead23e3481f9c9e426feb827997c9c42e5f28355084f54788820c96a079dedb649fcc20e69436fb3c4df7e46f372b533e7c
26 DIST mutt-gentoo-1.14.4-patches-r0.tar.xz 31124 BLAKE2B a9774a5bb5af18a275f7ea171cb08a12a98d63cbff57320d5d3fb4f995aac16f409689ac0015f3b5d37cfc20004c9fca72a3f63663aaa679a129d5f3886bc5cc SHA512 05506399a471c262479db88ef11d2a95d79598fd696fe50de5f5c1c3cae5adf30a2806a1500ba94a62bcbf7deed99acc59a8afb903f50169e41b77010e0ad8cc
27 DIST mutt-gentoo-1.14.5-patches-r0.tar.xz 31100 BLAKE2B 14525b54afa1414667ebe2dc0c58b9b5d5ad4dcc5dbae3c5db13cc23d33dbd9434fa929ad297625c891b2d690e34729a4f61c526fb94857e271ac85f5a07488e SHA512 fd8e473efa02e412aeaba258afee6dc02f9ca24f9edff643e4ef53c759a091e54c6a544e39cd7faa94cd680546bfcf845e282638045ae65a88d140ebb03a4631
28 +DIST mutt-gentoo-1.14.7-patches-r0.tar.xz 31144 BLAKE2B 5a9806dec79f8a991e39464afde1faf2ba988e67ffd85ec16943432a83ee1d05ddcb839095a475ab56aa80a4bbe25de58835d6bde84c0c95e4487df139e16e82 SHA512 ca57af137bc5a2663724cb97a7ea04e4d62b2fe8a3864489f15552ef361c1fb8c881ebc783a4f3a6d82c5e9bb45e83fbe6cad59158c831c54361729ada24b458
29
30 diff --git a/mail-client/mutt/mutt-1.14.7.ebuild b/mail-client/mutt/mutt-1.14.7.ebuild
31 new file mode 100644
32 index 00000000000..773c3c90952
33 --- /dev/null
34 +++ b/mail-client/mutt/mutt-1.14.7.ebuild
35 @@ -0,0 +1,265 @@
36 +# Copyright 1999-2020 Gentoo Authors
37 +# Distributed under the terms of the GNU General Public License v2
38 +
39 +EAPI="6"
40 +
41 +inherit eutils flag-o-matic autotools
42 +
43 +PATCHREV="r0"
44 +PATCHSET="gentoo-${PVR}/${PATCHREV}"
45 +
46 +DESCRIPTION="A small but very powerful text-based mail client"
47 +HOMEPAGE="http://www.mutt.org/"
48 +MUTT_G_PATCHES="mutt-gentoo-${PV}-patches-${PATCHREV}.tar.xz"
49 +SRC_URI="ftp://ftp.mutt.org/pub/mutt/${P}.tar.gz
50 + https://bitbucket.org/${PN}/${PN}/downloads/${P}.tar.gz
51 + https://dev.gentoo.org/~grobian/distfiles/${MUTT_G_PATCHES}"
52 +IUSE="autocrypt berkdb debug doc gdbm gnutls gpgme +hcache idn +imap kerberos libressl +lmdb mbox nls pgp-classic pop qdbm +sasl selinux slang smime-classic +smtp +ssl tokyocabinet vanilla prefix"
53 +# hcache: allow multiple, bug #607360
54 +REQUIRED_USE="
55 + hcache? ( || ( berkdb gdbm lmdb qdbm tokyocabinet ) )
56 + imap? ( ssl )
57 + pop? ( ssl )
58 + smime-classic? ( ssl !gnutls )
59 + smtp? ( ssl sasl )
60 + sasl? ( || ( imap pop smtp ) )
61 + kerberos? ( || ( imap pop smtp ) )
62 + autocrypt? ( gpgme )"
63 +SLOT="0"
64 +LICENSE="GPL-2"
65 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
66 +# yes, we overdepend on the backend impls here, hopefully one day we can
67 +# have REQUIRED_USE do what it is made for again. bug #607360
68 +CDEPEND="
69 + app-misc/mime-types
70 + virtual/libiconv
71 +
72 + berkdb? ( >=sys-libs/db-4:= )
73 + gdbm? ( sys-libs/gdbm )
74 + lmdb? ( dev-db/lmdb:= )
75 + qdbm? ( dev-db/qdbm )
76 + tokyocabinet? ( dev-db/tokyocabinet )
77 +
78 + ssl? (
79 + gnutls? ( >=net-libs/gnutls-1.0.17:= )
80 + !gnutls? (
81 + libressl? ( dev-libs/libressl:= )
82 + !libressl? ( >=dev-libs/openssl-0.9.6:0= )
83 + )
84 + )
85 +
86 + nls? ( virtual/libintl )
87 + sasl? ( >=dev-libs/cyrus-sasl-2 )
88 + kerberos? ( virtual/krb5 )
89 + idn? ( net-dns/libidn2 )
90 + gpgme? ( >=app-crypt/gpgme-0.9.0:= )
91 + autocrypt? ( >=dev-db/sqlite-3 )
92 + slang? ( sys-libs/slang )
93 + !slang? ( >=sys-libs/ncurses-5.2:0= )
94 +"
95 +DEPEND="${CDEPEND}
96 + net-mail/mailbase
97 + doc? (
98 + dev-libs/libxml2
99 + dev-libs/libxslt
100 + app-text/docbook-xsl-stylesheets
101 + || ( www-client/lynx www-client/w3m www-client/elinks )
102 + )"
103 +RDEPEND="${CDEPEND}
104 + selinux? ( sec-policy/selinux-mutt )
105 + smime-classic? ( || ( dev-libs/libressl >=dev-libs/openssl-0.9.6:0 ) )
106 + pgp-classic? ( app-crypt/gnupg )
107 +"
108 +
109 +src_prepare() {
110 + local PATCHDIR="${WORKDIR}"/mutt-gentoo-${PV}-patches-${PATCHREV}
111 +
112 + if use !vanilla ; then
113 + # apply patches
114 + export EPATCH_FORCE="yes"
115 + export EPATCH_SUFFIX="patch"
116 + # http://hg.code.sf.net/p/gentoomuttpatches/code/file/mutt-1.10
117 + local patches=(
118 + patches-mutt
119 + bugs-gentoo
120 + features-common
121 + features-extra
122 + gentoo
123 + )
124 + local patchset
125 + for patchset in "${patches[@]}" ; do
126 + [[ -d "${PATCHDIR}/${patchset}" ]] || continue
127 + einfo "Patches for ${PATCHSET} patchset ${patchset}"
128 + EPATCH_SOURCE="${PATCHDIR}"/${patchset} epatch \
129 + || die "patchset ${patchset} failed"
130 + done
131 + # add some explanation as to why not to go upstream
132 + sed -i \
133 + -e '/ReachingUs = N_(/aThis release of Mutt is heavily enriched with patches.\\nFor this reason, any bugs are better reported at https://bugs.gentoo.org/\\nor re-emerge with USE=vanilla and try to reproduce your problem.\\n\\' \
134 + main.c || die "Failed to add bug instructions"
135 + fi
136 +
137 + local upatches=
138 + # allow user patches
139 + eapply_user && upatches=" with user patches"
140 +
141 + # patch version string for bug reports
142 + local patchset=
143 + use vanilla || patchset=", ${PATCHSET}"
144 + sed -i -e 's|"Mutt %s (%s)"|"Mutt %s (%s'"${patchset}${upatches}"')"|' \
145 + muttlib.c || die "failed patching in Gentoo version"
146 +
147 + # many patches touch the buildsystem, we always need this
148 + AT_M4DIR="m4" eautoreconf
149 +
150 + # the configure script contains some "cleverness" whether or not to setgid
151 + # the dotlock program, resulting in bugs like #278332
152 + sed -i -e 's/@DOTLOCK_GROUP@//' Makefile.in || die "sed failed"
153 +}
154 +
155 +src_configure() {
156 + local myconf=(
157 + # signing and encryption
158 + $(use_enable autocrypt) $(use_with autocrypt sqlite3)
159 + $(use_enable pgp-classic pgp)
160 + $(use_enable smime-classic smime)
161 + $(use_enable gpgme)
162 +
163 + # features
164 + $(use_enable debug)
165 + $(use_enable doc)
166 + $(use_enable nls)
167 +
168 + # protocols
169 + $(use_enable imap)
170 + $(use_enable pop)
171 + $(use_enable smtp)
172 +
173 + $(use ssl && use gnutls && echo --with-gnutls --without-ssl)
174 + $(use ssl && use !gnutls && echo --without-gnutls --with-ssl )
175 + $(use !ssl && echo --without-gnutls --without-ssl)
176 +
177 + $(use_with sasl)
178 + $(use_with idn idn2) --without-idn # avoid automagic libidn dep
179 + $(use_with kerberos gss)
180 + "$(use slang && echo --with-slang="${EPREFIX}"/usr || echo a=b)"
181 + "$(use_with !slang curses "${EPREFIX}"/usr)"
182 +
183 + "--enable-compressed"
184 + "--enable-external-dotlock"
185 + "--enable-iconv"
186 + "--enable-nfs-fix"
187 + "--enable-sidebar"
188 + "--sysconfdir=${EPREFIX}/etc/${PN}"
189 + "--with-docdir=${EPREFIX}/usr/share/doc/${PN}-${PVR}"
190 + "--without-bundled-regex" # use the implementation from libc
191 + "--with-exec-shell=${EPREFIX}/bin/sh"
192 + )
193 +
194 + if [[ ${CHOST} == *-solaris2.* && ${CHOST#*-solaris2.} -le 10 ]] ; then
195 + # arrows in index view do not show when using wchar_t
196 + # or misalign due to wrong computations
197 + myconf+=( "--without-wc-funcs" )
198 + fi
199 +
200 + # note: REQUIRED_USE should have selected only one of these, but for
201 + # bug #607360 we're forced to allow multiple. For that reason, this
202 + # list is ordered to preference, and only the first is taken.
203 + local hcaches=(
204 + "lmdb"
205 + "qdbm"
206 + "tokyocabinet"
207 + "gdbm"
208 + "berkdb:bdb"
209 + )
210 + local ucache hcache lcache
211 + for hcache in "${hcaches[@]}" ; do
212 + if use ${hcache%%:*} ; then
213 + ucache=${hcache}
214 + break
215 + fi
216 + done
217 + if [[ -n ${ucache} ]] ; then
218 + myconf+=( "--enable-hcache" )
219 + else
220 + myconf+=( "--disable-hcache" )
221 + fi
222 + for hcache in "${hcaches[@]}" ; do
223 + [[ ${hcache} == ${ucache} ]] \
224 + && myconf+=( "--with-${hcache#*:}" ) \
225 + || myconf+=( "--without-${hcache#*:}" )
226 + done
227 +
228 + if use mbox; then
229 + myconf+=( "--with-mailpath=${EPREFIX}/var/spool/mail" )
230 + else
231 + myconf+=( "--with-homespool=Maildir" )
232 + fi
233 +
234 + econf "${myconf[@]}"
235 +}
236 +
237 +src_install() {
238 + emake DESTDIR="${D}" install
239 + insinto /etc/${PN}
240 + if use mbox; then
241 + newins "${FILESDIR}"/Muttrc.mbox Muttrc
242 + else
243 + doins "${FILESDIR}"/Muttrc
244 + fi
245 +
246 + # include attachment settings, it's mandatory and shouldn't harm
247 + # when not being referenced (index_format using %X)
248 + {
249 + echo
250 + echo "# mandatory attachments settings, not setting these is a BUG!"
251 + echo "# see https://marc.info/?l=mutt-dev&m=158347284923517&w=2"
252 + grep '^attachments' "${ED}"/etc/${PN}/Muttrc.dist
253 + } >> "${ED}"/etc/${PN}/Muttrc
254 +
255 + # add setting to actually enable gpgme usage
256 + if use gpgme || use autocrypt ; then
257 + {
258 + echo
259 + echo "# this setting enables the gpgme backend (via USE=gpgme)"
260 + # https is broken due to a certificate mismatch :(
261 + echo "# see http://www.mutt.org/doc/manual/#crypt-use-gpgme"
262 + echo "set crypt_use_gpgme = yes"
263 + } >> "${ED}"/etc/${PN}/Muttrc
264 + fi
265 +
266 + # similar for autocrypt
267 + if use autocrypt ; then
268 + {
269 + echo
270 + echo "# enables autocrypt (via USE=autocrypt)"
271 + echo "# see http://www.mutt.org/doc/manual/#autocryptdoc"
272 + echo "set autocrypt = yes"
273 + } >> "${ED}"/etc/${PN}/Muttrc
274 + fi
275 +
276 + # A newer file is provided by app-misc/mime-types. So we link it.
277 + rm "${ED}"/etc/${PN}/mime.types
278 + dosym ../mime.types /etc/${PN}/mime.types
279 +
280 + # nuke manpages that should be provided by an MTA, bug #177605
281 + rm "${ED}"/usr/share/man/man5/{mbox,mmdf}.5 \
282 + || ewarn "failed to remove files, please file a bug"
283 +
284 + if use !prefix ; then
285 + fowners root:mail /usr/bin/mutt_dotlock
286 + fperms g+s /usr/bin/mutt_dotlock
287 + fi
288 +
289 + dodoc BEWARE COPYRIGHT ChangeLog NEWS OPS* PATCHES README* TODO VERSION
290 +}
291 +
292 +pkg_postinst() {
293 + if [[ -z ${REPLACING_VERSIONS} ]] ; then
294 + echo
295 + elog "If you are new to mutt you may want to take a look at"
296 + elog "the Gentoo QuickStart Guide to Mutt E-Mail:"
297 + elog " https://wiki.gentoo.org/wiki/Mutt"
298 + echo
299 + fi
300 +}