Gentoo Archives: gentoo-commits

From: Eray Aslan <eras@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-mail/mailutils/files/, net-mail/mailutils/
Date: Sat, 17 Apr 2021 09:05:14
Message-Id: 1618650298.b53245a868edbae2e47e15767cb7dddc73c36524.eras@gentoo
1 commit: b53245a868edbae2e47e15767cb7dddc73c36524
2 Author: Eray Aslan <eras <AT> gentoo <DOT> org>
3 AuthorDate: Sat Apr 17 09:04:39 2021 +0000
4 Commit: Eray Aslan <eras <AT> gentoo <DOT> org>
5 CommitDate: Sat Apr 17 09:04:58 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b53245a8
7
8 net-mail/mailutils: fix big endian archs
9
10 also
11 - fix HOMEPAGE
12 - add missing endif
13
14 thanks to ernsteiswuerfel and Rolf Eike Beer
15
16 Closes: https://bugs.gentoo.org/670924
17 Closes: https://bugs.gentoo.org/727998
18 Package-Manager: Portage-3.0.18, Repoman-3.0.3
19 Signed-off-by: Eray Aslan <eras <AT> gentoo.org>
20
21 .../files/mailutils-3.12-fix-big-endians.patch | 26 ++++
22 .../files/mailutils-3.12-misssing-endif.patch | 23 ++++
23 net-mail/mailutils/mailutils-3.12-r1.ebuild | 141 +++++++++++++++++++++
24 3 files changed, 190 insertions(+)
25
26 diff --git a/net-mail/mailutils/files/mailutils-3.12-fix-big-endians.patch b/net-mail/mailutils/files/mailutils-3.12-fix-big-endians.patch
27 new file mode 100644
28 index 00000000000..5dd2f8f035d
29 --- /dev/null
30 +++ b/net-mail/mailutils/files/mailutils-3.12-fix-big-endians.patch
31 @@ -0,0 +1,26 @@
32 +From c0af3be2fcee73c1a61f58572ecef1ef3f385015 Mon Sep 17 00:00:00 2001
33 +From: Sergey Poznyakoff <gray@×××.org>
34 +Date: Thu, 15 Apr 2021 08:37:29 +0300
35 +Subject: Bugfix in mimeview testsuite
36 +
37 +* mimeview/tests/bf.c (write_byte): Fix type of the character buffer.
38 +---
39 + mimeview/tests/bf.c | 2 +-
40 + 1 file changed, 1 insertion(+), 1 deletion(-)
41 +
42 +diff --git a/mimeview/tests/bf.c b/mimeview/tests/bf.c
43 +index 6ccce848c..2e6b37e4a 100644
44 +--- a/mimeview/tests/bf.c
45 ++++ b/mimeview/tests/bf.c
46 +@@ -68,7 +68,7 @@ write_string (FILE *fp, char *arg)
47 + int
48 + write_byte (FILE *fp, char *arg)
49 + {
50 +- int c;
51 ++ char c;
52 + if (strlen (arg) == 3
53 + && (arg[0] == '\'' || arg[0] == '"'))
54 + c = arg[1];
55 +--
56 +cgit v1.2.1
57 +
58
59 diff --git a/net-mail/mailutils/files/mailutils-3.12-misssing-endif.patch b/net-mail/mailutils/files/mailutils-3.12-misssing-endif.patch
60 new file mode 100644
61 index 00000000000..12d03af7b33
62 --- /dev/null
63 +++ b/net-mail/mailutils/files/mailutils-3.12-misssing-endif.patch
64 @@ -0,0 +1,23 @@
65 +From 4cc284cfb38306989694a7828e880f0cf6d0c4e0 Mon Sep 17 00:00:00 2001
66 +From: Sergey Poznyakoff <gray@×××.org>
67 +Date: Thu, 15 Apr 2021 08:36:56 +0300
68 +Subject: Minor fix
69 +
70 +* include/mailutils/sys/streamtrans.h: Add missing #endif
71 +---
72 + include/mailutils/sys/streamtrans.h | 2 ++
73 + 1 file changed, 2 insertions(+)
74 +
75 +diff --git a/include/mailutils/sys/streamtrans.h b/include/mailutils/sys/streamtrans.h
76 +index 8a4727cee..c9c866013 100644
77 +--- a/include/mailutils/sys/streamtrans.h
78 ++++ b/include/mailutils/sys/streamtrans.h
79 +@@ -25,3 +25,5 @@ struct _mu_streamtrans
80 + struct _mu_stream base; /* Superclass */
81 + mu_stream_t transport; /* Transport stream */
82 + };
83 ++
84 ++#endif
85 +--
86 +cgit v1.2.1
87 +
88
89 diff --git a/net-mail/mailutils/mailutils-3.12-r1.ebuild b/net-mail/mailutils/mailutils-3.12-r1.ebuild
90 new file mode 100644
91 index 00000000000..89bc57c915a
92 --- /dev/null
93 +++ b/net-mail/mailutils/mailutils-3.12-r1.ebuild
94 @@ -0,0 +1,141 @@
95 +# Copyright 1999-2021 Gentoo Authors
96 +# Distributed under the terms of the GNU General Public License v2
97 +
98 +EAPI=7
99 +PYTHON_COMPAT=( python3_{7,8,9} )
100 +
101 +inherit autotools elisp-common eutils flag-o-matic python-single-r1 toolchain-funcs
102 +
103 +DESCRIPTION="A useful collection of mail servers, clients, and filters"
104 +HOMEPAGE="https://mailutils.org/"
105 +SRC_URI="mirror://gnu/mailutils/${P}.tar.xz"
106 +
107 +LICENSE="GPL-2 LGPL-2.1"
108 +SLOT="0"
109 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~ppc-macos ~x64-macos"
110 +IUSE="berkdb bidi +clients emacs gdbm sasl guile ipv6 kerberos kyotocabinet \
111 + ldap mysql nls pam postgres python servers split-usr ssl static-libs +threads tcpd \
112 + tokyocabinet"
113 +
114 +RDEPEND="!mail-client/nmh
115 + !mail-filter/libsieve
116 + !mail-client/mailx
117 + !mail-client/nail
118 + sys-libs/ncurses:=
119 + sys-libs/readline:=
120 + dev-libs/libltdl:0
121 + virtual/mta
122 + berkdb? ( sys-libs/db:= )
123 + bidi? ( dev-libs/fribidi )
124 + emacs? ( >=app-editors/emacs-23.1:* )
125 + gdbm? ( sys-libs/gdbm:= )
126 + guile? ( dev-scheme/guile:12/2.2-1 )
127 + kerberos? ( virtual/krb5 )
128 + kyotocabinet? ( dev-db/kyotocabinet )
129 + ldap? ( net-nds/openldap )
130 + mysql? ( dev-db/mysql-connector-c )
131 + nls? ( sys-devel/gettext )
132 + pam? ( sys-libs/pam )
133 + postgres? ( dev-db/postgresql:= )
134 + python? ( ${PYTHON_DEPS} )
135 + sasl? ( virtual/gsasl )
136 + servers? ( virtual/libiconv dev-libs/libunistring )
137 + ssl? ( net-libs/gnutls:= )
138 + tcpd? ( sys-apps/tcp-wrappers )
139 + tokyocabinet? ( dev-db/tokyocabinet )"
140 +
141 +DEPEND="${RDEPEND}
142 + virtual/pkgconfig"
143 +
144 +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )
145 + servers? ( tcpd ldap )"
146 +
147 +DOCS=( ABOUT-NLS AUTHORS COPYING COPYING.LESSER ChangeLog INSTALL NEWS README THANKS TODO )
148 +PATCHES=(
149 + "${FILESDIR}"/${PN}-3.5-add-include.patch
150 + "${FILESDIR}"/${P}-misssing-endif.patch
151 + "${FILESDIR}"/${P}-fix-big-endians.patch
152 +)
153 +
154 +pkg_setup() {
155 + use python && python-single-r1_pkg_setup
156 +}
157 +
158 +src_prepare() {
159 + default
160 + if use mysql; then
161 + sed -i -e /^INCLUDES/"s:$:$(mysql_config --include):" \
162 + sql/Makefile.am || die
163 + fi
164 + eautoreconf
165 +}
166 +
167 +src_configure() {
168 + append-flags -fno-strict-aliasing
169 +
170 + # maildir is the Gentoo default
171 + econf \
172 + MU_DEFAULT_SCHEME=maildir \
173 + CURSES_LIBS="$($(tc-getPKG_CONFIG) --libs ncurses)" \
174 + $(use_with berkdb berkeley-db) \
175 + $(use_with bidi fribidi) \
176 + $(use_enable ipv6) \
177 + $(use_with gdbm) \
178 + $(use_with sasl gsasl) \
179 + $(use_with guile) \
180 + $(use_with kerberos gssapi) \
181 + $(use_with ldap) \
182 + $(use_with mysql) \
183 + $(use_enable nls) \
184 + $(use_enable pam) \
185 + $(use_with postgres) \
186 + $(use_enable python) \
187 + $(use_with ssl gnutls) \
188 + $(use_enable static-libs static) \
189 + $(use_enable threads pthread) \
190 + $(use_with tokyocabinet) \
191 + $(use_with kyotocabinet) \
192 + $(use_with tcpd tcp-wrappers) \
193 + $(use_enable servers build-servers) \
194 + $(use_with servers unistring ) \
195 + $(use_enable clients build-clients) \
196 + EMACS=$(usex emacs emacs no) \
197 + --with-lispdir="${EPREFIX}${SITELISP}/${PN}" \
198 + --with-mail-spool=/var/spool/mail \
199 + --with-readline \
200 + --enable-sendmail \
201 + --disable-debug
202 +}
203 +
204 +src_install() {
205 + default
206 +
207 + insinto /etc
208 + # bug 613112
209 + newins "${FILESDIR}/mailutils.rc" mailutils.conf
210 + keepdir /etc/mailutils.d/
211 + insinto /etc/mailutils.d
212 + doins "${FILESDIR}/mail"
213 +
214 + if use python; then
215 + python_optimize
216 + if use static-libs; then
217 + rm -r "${D}$(python_get_sitedir)/mailutils"/*.{a,la} || die
218 + fi
219 + fi
220 +
221 + if use servers; then
222 + newinitd "${FILESDIR}"/imap4d.initd imap4d
223 + newinitd "${FILESDIR}"/pop3d.initd pop3d
224 + newinitd "${FILESDIR}"/comsatd.initd comsatd
225 + fi
226 +
227 + # compatibility link
228 + if use clients && use split-usr; then
229 + dosym ../usr/bin/mail /bin/mail
230 + fi
231 +
232 + if ! use static-libs; then
233 + find "${D}" -name "*.la" -delete || die
234 + fi
235 +}