1 |
commit: 68ee1bf682140f439186c5e6bdcaedcbf19f7444 |
2 |
Author: Amadeusz Piotr Żołnowski <aidecoe <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Mar 4 22:15:12 2020 +0000 |
4 |
Commit: Amadeusz Piotr Żołnowski <aidecoe <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Mar 4 22:17:22 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=68ee1bf6 |
7 |
|
8 |
net-mail/notmuch: Fix error on configure with 'crypt' flag disabled |
9 |
|
10 |
Bug: https://bugs.gentoo.org/707656 |
11 |
Package-Manager: Portage-2.3.76, Repoman-2.3.16 |
12 |
Signed-off-by: Amadeusz Piotr Żołnowski <aidecoe <AT> gentoo.org> |
13 |
|
14 |
net-mail/notmuch/notmuch-0.29.3-r1.ebuild | 232 ++++++++++++++++++++++++++++++ |
15 |
1 file changed, 232 insertions(+) |
16 |
|
17 |
diff --git a/net-mail/notmuch/notmuch-0.29.3-r1.ebuild b/net-mail/notmuch/notmuch-0.29.3-r1.ebuild |
18 |
new file mode 100644 |
19 |
index 00000000000..d43493b3fad |
20 |
--- /dev/null |
21 |
+++ b/net-mail/notmuch/notmuch-0.29.3-r1.ebuild |
22 |
@@ -0,0 +1,232 @@ |
23 |
+# Copyright 1999-2020 Gentoo Authors |
24 |
+# Distributed under the terms of the GNU General Public License v2 |
25 |
+ |
26 |
+EAPI=6 |
27 |
+ |
28 |
+DISTUTILS_OPTIONAL=1 |
29 |
+PYTHON_COMPAT=( python{2_7,3_6,3_7} ) |
30 |
+ |
31 |
+inherit bash-completion-r1 elisp-common eutils flag-o-matic pax-utils \ |
32 |
+ distutils-r1 toolchain-funcs |
33 |
+ |
34 |
+DESCRIPTION="Thread-based e-mail indexer, supporting quick search and tagging" |
35 |
+HOMEPAGE="https://notmuchmail.org/" |
36 |
+SRC_URI="https://notmuchmail.org/releases/${P}.tar.xz |
37 |
+ test? ( https://notmuchmail.org/releases/test-databases/database-v1.tar.xz )" |
38 |
+ |
39 |
+LICENSE="GPL-3" |
40 |
+# Sub-slot corresponds to major wersion of libnotmuch.so.X.Y. Bump of Y is |
41 |
+# meant to be binary backward compatible. |
42 |
+SLOT="0/5" |
43 |
+KEYWORDS="~alpha ~amd64 ~x86 ~x64-solaris" |
44 |
+REQUIRED_USE=" |
45 |
+ nmbug? ( python ) |
46 |
+ python? ( ${PYTHON_REQUIRED_USE} ) |
47 |
+ test? ( crypt emacs python valgrind ) |
48 |
+ " |
49 |
+IUSE="crypt doc emacs mutt nmbug python test valgrind" |
50 |
+ |
51 |
+RESTRICT="!test? ( test )" |
52 |
+ |
53 |
+CDEPEND=" |
54 |
+ !!<app-shells/bash-completion-1.9 |
55 |
+ >=dev-libs/glib-2.22:2 |
56 |
+ >=dev-libs/gmime-3.0.3:3.0[crypt] |
57 |
+ >=dev-libs/xapian-1.4.8:= |
58 |
+ dev-python/sphinx |
59 |
+ sys-apps/texinfo |
60 |
+ >=sys-libs/zlib-1.2.5.2 |
61 |
+ sys-libs/talloc |
62 |
+ emacs? ( >=app-editors/emacs-24.1:* ) |
63 |
+ python? ( ${PYTHON_DEPS} ) |
64 |
+ " |
65 |
+DEPEND="${CDEPEND} |
66 |
+ virtual/pkgconfig |
67 |
+ doc? ( |
68 |
+ app-doc/doxygen |
69 |
+ dev-python/mock[${PYTHON_USEDEP}] |
70 |
+ ) |
71 |
+ test? ( |
72 |
+ app-misc/dtach |
73 |
+ >=app-editors/emacs-24.1:*[libxml2] |
74 |
+ sys-devel/gdb |
75 |
+ crypt? ( app-crypt/gnupg dev-libs/openssl ) |
76 |
+ ) |
77 |
+ valgrind? ( dev-util/valgrind ) |
78 |
+ " |
79 |
+RDEPEND="${CDEPEND} |
80 |
+ crypt? ( app-crypt/gnupg ) |
81 |
+ nmbug? ( dev-vcs/git ) |
82 |
+ mutt? ( |
83 |
+ dev-perl/File-Which |
84 |
+ dev-perl/Mail-Box |
85 |
+ dev-perl/MailTools |
86 |
+ dev-perl/String-ShellQuote |
87 |
+ dev-perl/Term-ReadLine-Gnu |
88 |
+ virtual/perl-Digest-SHA |
89 |
+ virtual/perl-File-Path |
90 |
+ virtual/perl-Getopt-Long |
91 |
+ virtual/perl-Pod-Parser |
92 |
+ ) |
93 |
+ " |
94 |
+ |
95 |
+DOCS=( AUTHORS NEWS README ) |
96 |
+NEED_EMACS="24.1" |
97 |
+SITEFILE="50${PN}-gentoo.el" |
98 |
+MY_LD_LIBRARY_PATH="${WORKDIR}/${P}/lib" |
99 |
+PATCHES=( |
100 |
+ "${FILESDIR}"/${PV}-0001-Use-loopback-IP-address-rather-than-name.patch |
101 |
+) |
102 |
+ |
103 |
+bindings() { |
104 |
+ local ret=0 |
105 |
+ |
106 |
+ if use $1; then |
107 |
+ pushd bindings/$1 || die |
108 |
+ shift |
109 |
+ "$@" |
110 |
+ ret=$? |
111 |
+ popd || die |
112 |
+ fi |
113 |
+ |
114 |
+ return $ret |
115 |
+} |
116 |
+ |
117 |
+pkg_pretend() { |
118 |
+ if has_version '<net-mail/notmuch-0.18'; then |
119 |
+ ewarn |
120 |
+ ewarn "There are few not backward compatible changes between" |
121 |
+ ewarn "<notmuch-0.18 and >=notmuch-0.18. See NEWS file" |
122 |
+ ewarn "(0.18 section) for details before first use!" |
123 |
+ ewarn |
124 |
+ fi |
125 |
+} |
126 |
+ |
127 |
+pkg_setup() { |
128 |
+ use emacs && elisp-check-emacs-version |
129 |
+} |
130 |
+ |
131 |
+src_unpack() { |
132 |
+ unpack "${P}".tar.xz |
133 |
+ if use test; then |
134 |
+ mkdir -p "${S}"/test/test-databases || die |
135 |
+ cp "${DISTDIR}"/database-v1.tar.xz "${S}"/test/test-databases/ || die |
136 |
+ fi |
137 |
+} |
138 |
+ |
139 |
+src_prepare() { |
140 |
+ default |
141 |
+ |
142 |
+ bindings python distutils-r1_src_prepare |
143 |
+ bindings python mv README README-python || die |
144 |
+ mv contrib/notmuch-mutt/README contrib/notmuch-mutt/README-mutt || die |
145 |
+ |
146 |
+ # assure that new Makefile.config will be generated |
147 |
+ rm -f Makefile.config || die |
148 |
+ |
149 |
+ sed -e 's@^install: all install-man install-info$@install: all install-info@' -i Makefile.local |
150 |
+ |
151 |
+ if use test; then |
152 |
+ append-cflags -g |
153 |
+ append-cxxflags -g |
154 |
+ fi |
155 |
+ |
156 |
+ if [[ ${CHOST} == *-solaris* ]] ; then |
157 |
+ append-ldflags -lnsl -lsocket # non-autoconf configure |
158 |
+ fi |
159 |
+} |
160 |
+ |
161 |
+src_configure() { |
162 |
+ python_setup # for sphinx |
163 |
+ |
164 |
+ local myeconfargs=( |
165 |
+ --bashcompletiondir="$(get_bashcompdir)" |
166 |
+ --emacslispdir="${EPREFIX}/${SITELISP}/${PN}" |
167 |
+ --emacsetcdir="${EPREFIX}/${SITEETC}/${PN}" |
168 |
+ --without-desktop |
169 |
+ --without-ruby |
170 |
+ --zshcompletiondir="${EPREFIX}/usr/share/zsh/site-functions" |
171 |
+ $(use_with emacs) |
172 |
+ $(use_with doc api-docs) |
173 |
+ ) |
174 |
+ tc-export CC CXX |
175 |
+ econf "${myeconfargs[@]}" |
176 |
+} |
177 |
+ |
178 |
+src_compile() { |
179 |
+ python_setup # for sphinx |
180 |
+ |
181 |
+ V=1 default |
182 |
+ bindings python distutils-r1_src_compile |
183 |
+ |
184 |
+ if use mutt; then |
185 |
+ pushd contrib/notmuch-mutt || die |
186 |
+ emake notmuch-mutt.1 |
187 |
+ popd || die |
188 |
+ fi |
189 |
+ |
190 |
+ if use doc; then |
191 |
+ pydocs() { |
192 |
+ pushd docs || die |
193 |
+ emake html |
194 |
+ rm -r html/_sources || die |
195 |
+ rm html/{objects.inv,.buildinfo} || die |
196 |
+ mkdir -p ../html && mv html ../html/python || die |
197 |
+ popd || die |
198 |
+ } |
199 |
+ LD_LIBRARY_PATH="${MY_LD_LIBRARY_PATH}" bindings python pydocs |
200 |
+ fi |
201 |
+} |
202 |
+ |
203 |
+src_test() { |
204 |
+ pax-mark -m notmuch |
205 |
+ LD_LIBRARY_PATH="${MY_LD_LIBRARY_PATH}" V=1 default |
206 |
+ pax-mark -ze notmuch |
207 |
+} |
208 |
+ |
209 |
+src_install() { |
210 |
+ default |
211 |
+ |
212 |
+ if use doc; then |
213 |
+ doman doc/_build/man/man?/*.? |
214 |
+ fi |
215 |
+ |
216 |
+ if use emacs; then |
217 |
+ elisp-site-file-install "${FILESDIR}/${SITEFILE}" || die |
218 |
+ fi |
219 |
+ |
220 |
+ if use nmbug; then |
221 |
+ dobin devel/nmbug/nmbug |
222 |
+ dobin devel/nmbug/notmuch-report |
223 |
+ fi |
224 |
+ |
225 |
+ if use mutt; then |
226 |
+ pushd contrib/notmuch-mutt || die |
227 |
+ dobin notmuch-mutt |
228 |
+ doman notmuch-mutt.1 |
229 |
+ insinto /etc/mutt |
230 |
+ doins notmuch-mutt.rc |
231 |
+ dodoc README-mutt |
232 |
+ popd || die |
233 |
+ fi |
234 |
+ |
235 |
+ DOCS="" bindings python distutils-r1_src_install |
236 |
+ use doc && bindings python dodoc -r html |
237 |
+} |
238 |
+ |
239 |
+pkg_preinst() { |
240 |
+ if use mutt && ! [[ -e ${ROOT}/etc/mutt/notmuch-mutt.rc ]]; then |
241 |
+ elog "To enable notmuch support in mutt, add the following line into" |
242 |
+ elog "your mutt config file, please:" |
243 |
+ elog "" |
244 |
+ elog " source /etc/mutt/notmuch-mutt.rc" |
245 |
+ fi |
246 |
+} |
247 |
+ |
248 |
+pkg_postinst() { |
249 |
+ use emacs && elisp-site-regen |
250 |
+} |
251 |
+ |
252 |
+pkg_postrm() { |
253 |
+ use emacs && elisp-site-regen |
254 |
+} |