diff options
author | Amadeusz Piotr Żołnowski <aidecoe@gentoo.org> | 2014-05-14 13:12:03 +0000 |
---|---|---|
committer | Amadeusz Piotr Żołnowski <aidecoe@gentoo.org> | 2014-05-14 13:12:03 +0000 |
commit | e3d34a392c0daa2843d3c8109ef2e955aa3ccfd6 (patch) | |
tree | d9a4c6a65f26ac0fc18bf19fad00857772413e39 /net-mail | |
parent | sci-libs/rosetta-fragments: Add additional dep on sci-biology/update-blast (diff) | |
download | gentoo-2-e3d34a392c0daa2843d3c8109ef2e955aa3ccfd6.tar.gz gentoo-2-e3d34a392c0daa2843d3c8109ef2e955aa3ccfd6.tar.bz2 gentoo-2-e3d34a392c0daa2843d3c8109ef2e955aa3ccfd6.zip |
Fixes compilation in case if emacs is not present and prevents infinite loops
on generating docs with newer Sphinx.
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key F0134531E1DBFAB5)
Diffstat (limited to 'net-mail')
5 files changed, 290 insertions, 1 deletions
diff --git a/net-mail/notmuch/ChangeLog b/net-mail/notmuch/ChangeLog index bf0459165015..733d08d75595 100644 --- a/net-mail/notmuch/ChangeLog +++ b/net-mail/notmuch/ChangeLog @@ -1,6 +1,16 @@ # ChangeLog for net-mail/notmuch # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-mail/notmuch/ChangeLog,v 1.91 2014/05/07 19:37:19 aidecoe Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-mail/notmuch/ChangeLog,v 1.92 2014/05/14 13:12:03 aidecoe Exp $ + +*notmuch-0.18-r1 (14 May 2014) + + 14 May 2014; Amadeusz Żołnowski <aidecoe@gentoo.org> + +notmuch-0.18-r1.ebuild, + +files/0.18-0001-emacs-install-make-sure-all-components.patch, + +files/0.18-0002-doc-conf.py-Remove-_static-from-html_s.patch, + +files/0.18-0003-Unset-html_static_path-in-Python-bindi.patch: + Fixes compilation in case if emacs is not present and prevents infinite loops + on generating docs with newer Sphinx. *notmuch-0.18 (07 May 2014) diff --git a/net-mail/notmuch/files/0.18-0001-emacs-install-make-sure-all-components.patch b/net-mail/notmuch/files/0.18-0001-emacs-install-make-sure-all-components.patch new file mode 100644 index 000000000000..e9582fdad8b7 --- /dev/null +++ b/net-mail/notmuch/files/0.18-0001-emacs-install-make-sure-all-components.patch @@ -0,0 +1,32 @@ +From 0211b37f150f35f8015e9455d84f0764bb1cf8b1 Mon Sep 17 00:00:00 2001 +From: Tomi Ollila <tomi.ollila@iki.fi> +Date: Sun, 11 May 2014 00:36:43 +0300 +Subject: [PATCH 1/3] emacs install: make sure all components to be installed + are there + +`make install-emacs` will copy $(emacs_sources), $(emacs_images) and +$(emacs_bytecode) to their target directories. $(emacs_bytecode) was +already a prerequisite of make install-emacs as these obviously needed +to be build. Until a while ago all of $(emacs_sources) was available +in the repository, but now it includes `notmuch-version.el` which +is generated. In the future we may have generated emacs images too. +--- + emacs/Makefile.local | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/emacs/Makefile.local b/emacs/Makefile.local +index dcb4995..c0d6b19 100644 +--- a/emacs/Makefile.local ++++ b/emacs/Makefile.local +@@ -69,7 +69,7 @@ install: install-emacs + endif + + .PHONY: install-emacs +-install-emacs: ++install-emacs: $(emacs_sources) $(emacs_images) + mkdir -p "$(DESTDIR)$(emacslispdir)" + install -m0644 $(emacs_sources) "$(DESTDIR)$(emacslispdir)" + ifeq ($(HAVE_EMACS),1) +-- +1.9.3 + diff --git a/net-mail/notmuch/files/0.18-0002-doc-conf.py-Remove-_static-from-html_s.patch b/net-mail/notmuch/files/0.18-0002-doc-conf.py-Remove-_static-from-html_s.patch new file mode 100644 index 000000000000..d9b48c0c5a17 --- /dev/null +++ b/net-mail/notmuch/files/0.18-0002-doc-conf.py-Remove-_static-from-html_s.patch @@ -0,0 +1,34 @@ +From 29712ff47411c950e1426e638a13975e6de8952f Mon Sep 17 00:00:00 2001 +From: "W. Trevor King" <wking@tremily.us> +Date: Sat, 10 May 2014 08:55:21 -0700 +Subject: [PATCH 2/3] doc/conf.py: Remove _static from html_static_path + +Avoid: + + $ make HAVE_SPHINX=1 sphinx-html + python ./doc/mkdocdeps.py ./doc doc/_build doc/docdeps.mk + sphinx-build -b html -d doc/_build/doctrees -q ./doc doc/_build/html + Making output directory... + WARNING: html_static_path entry '/home/wking/src/notmuch/notmuch/doc/_static' does not exist + +because we have no static source in doc/_static. +--- + doc/conf.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/doc/conf.py b/doc/conf.py +index a926fe4..70ba1b8 100644 +--- a/doc/conf.py ++++ b/doc/conf.py +@@ -42,7 +42,7 @@ html_theme = 'default' + # Add any paths that contain custom static files (such as style sheets) here, + # relative to this directory. They are copied after the builtin static files, + # so a file named "default.css" will overwrite the builtin "default.css". +-html_static_path = ['_static'] ++html_static_path = [] + + # Output file base name for HTML help builder. + htmlhelp_basename = 'notmuchdoc' +-- +1.9.3 + diff --git a/net-mail/notmuch/files/0.18-0003-Unset-html_static_path-in-Python-bindi.patch b/net-mail/notmuch/files/0.18-0003-Unset-html_static_path-in-Python-bindi.patch new file mode 100644 index 000000000000..7daf0554ebcb --- /dev/null +++ b/net-mail/notmuch/files/0.18-0003-Unset-html_static_path-in-Python-bindi.patch @@ -0,0 +1,28 @@ +From b2bbe0b0a30c11d307a29b23f0e22268bd8edcc1 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Amadeusz=20=C5=BBo=C5=82nowski?= <aidecoe@aidecoe.name> +Date: Mon, 12 May 2014 12:35:41 +0200 +Subject: [PATCH 3/3] Unset html_static_path in Python bindings docs + +html_static_path is a kind of source directory and it was set to +destination directory (../html) which caused infinite recursion with +Sphinx 1.2 and above. +--- + bindings/python/docs/source/conf.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/bindings/python/docs/source/conf.py b/bindings/python/docs/source/conf.py +index 9db377f..5107a96 100644 +--- a/bindings/python/docs/source/conf.py ++++ b/bindings/python/docs/source/conf.py +@@ -140,7 +140,7 @@ html_theme = 'default' + # Add any paths that contain custom static files (such as style sheets) here, + # relative to this directory. They are copied after the builtin static files, + # so a file named "default.css" will overwrite the builtin "default.css". +-html_static_path = ['../html'] ++html_static_path = [] + + # If not '', a 'Last updated on:' timestamp is inserted at every page bottom, + # using the given strftime format. +-- +1.9.3 + diff --git a/net-mail/notmuch/notmuch-0.18-r1.ebuild b/net-mail/notmuch/notmuch-0.18-r1.ebuild new file mode 100644 index 000000000000..1abd26d15087 --- /dev/null +++ b/net-mail/notmuch/notmuch-0.18-r1.ebuild @@ -0,0 +1,185 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-mail/notmuch/notmuch-0.18-r1.ebuild,v 1.1 2014/05/14 13:12:03 aidecoe Exp $ + +EAPI=5 + +DISTUTILS_OPTIONAL=1 +PYTHON_COMPAT=( python{2_6,2_7,3_2,3_3} ) + +inherit elisp-common eutils pax-utils distutils-r1 toolchain-funcs + +DESCRIPTION="Thread-based e-mail indexer, supporting quick search and tagging" +HOMEPAGE="http://notmuchmail.org/" +SRC_URI="${HOMEPAGE%/}/releases/${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~x86" +REQUIRED_USE=" + python? ( ${PYTHON_REQUIRED_USE} ) + test? ( crypt emacs python ) + " +IUSE="bash-completion crypt debug doc emacs mutt nmbug python test + zsh-completion" + +CDEPEND=" + >=dev-libs/glib-2.22 + >=dev-libs/gmime-2.6.7 + !=dev-libs/gmime-2.6.19 + <dev-libs/xapian-1.3 + >=sys-libs/zlib-1.2.5.2 + sys-libs/talloc + debug? ( dev-util/valgrind ) + emacs? ( >=virtual/emacs-23 ) + python? ( ${PYTHON_DEPS} ) + x86? ( >=dev-libs/xapian-1.2.7-r2 ) + " +DEPEND="${CDEPEND} + virtual/pkgconfig + doc? ( python? ( dev-python/sphinx[${PYTHON_USEDEP}] ) ) + test? ( app-misc/dtach || ( >=app-editors/emacs-23[libxml2] + >=app-editors/emacs-vcs-23[libxml2] ) sys-devel/gdb ) + " +RDEPEND="${CDEPEND} + bash-completion? ( >=app-shells/bash-completion-1.9 ) + crypt? ( app-crypt/gnupg ) + nmbug? ( dev-vcs/git virtual/perl-File-Temp virtual/perl-PodParser ) + mutt? ( dev-perl/File-Which dev-perl/Mail-Box dev-perl/MailTools + dev-perl/String-ShellQuote dev-perl/Term-ReadLine-Gnu + virtual/perl-Digest-SHA virtual/perl-File-Path virtual/perl-Getopt-Long + virtual/perl-PodParser + ) + zsh-completion? ( app-shells/zsh ) + " + +DOCS=( AUTHORS NEWS README ) +SITEFILE="50${PN}-gentoo.el" +MY_LD_LIBRARY_PATH="${WORKDIR}/${P}/lib" +MY_PATCHES=( + "${FILESDIR}/${PV}-0001-emacs-install-make-sure-all-components.patch" + "${FILESDIR}/${PV}-0002-doc-conf.py-Remove-_static-from-html_s.patch" + "${FILESDIR}/${PV}-0003-Unset-html_static_path-in-Python-bindi.patch" +) + +bindings() { + local ret=0 + + if use $1; then + pushd bindings/$1 || die + shift + "$@" + ret=$? + popd || die + fi + + return $ret +} + +pkg_pretend() { + if has_version '<net-mail/notmuch-0.18'; then + ewarn + ewarn "Notmuch 0.18 comes with few not backward compatible changes." + ewarn "See NEWS file for details before first use!" + ewarn + fi +} + +pkg_setup() { + if use emacs; then + elisp-need-emacs 23 || die "Emacs version too low" + fi +} + +src_prepare() { + [[ "${MY_PATCHES[@]}" ]] && epatch "${MY_PATCHES[@]}" + + default + bindings python distutils-r1_src_prepare + bindings python mv README README-python || die + mv contrib/notmuch-mutt/README contrib/notmuch-mutt/README-mutt || die +} + +src_configure() { + local myeconfargs=( + --bashcompletiondir="${ROOT}/usr/share/bash-completion" + --emacslispdir="${ROOT}/${SITELISP}/${PN}" + --emacsetcdir="${ROOT}/${SITEETC}/${PN}" + --with-gmime-version=2.6 + --zshcompletiondir="${ROOT}/usr/share/zsh/site-functions" + $(use_with bash-completion) + $(use_with emacs) + $(use_with zsh-completion) + ) + tc-export CC CXX + econf "${myeconfargs[@]}" +} + +src_compile() { + V=1 default + bindings python distutils-r1_src_compile + + if use mutt; then + pushd contrib/notmuch-mutt || die + emake notmuch-mutt.1 + popd || die + fi + + if use doc; then + pydocs() { + pushd docs || die + emake html + mv html ../python || die + popd || die + } + LD_LIBRARY_PATH="${MY_LD_LIBRARY_PATH}" bindings python pydocs + fi +} + +src_test() { + pax-mark -m notmuch + LD_LIBRARY_PATH="${MY_LD_LIBRARY_PATH}" default + pax-mark -ze notmuch +} + +src_install() { + default + + if use emacs; then + elisp-site-file-install "${FILESDIR}/${SITEFILE}" || die + fi + + if use nmbug; then + dobin devel/nmbug/nmbug + dobin devel/nmbug/nmbug-status + fi + + if use mutt; then + [[ -e /etc/mutt/notmuch-mutt.rc ]] && NOTMUCH_MUTT_RC_EXISTS=1 + pushd contrib/notmuch-mutt || die + dobin notmuch-mutt + doman notmuch-mutt.1 + insinto /etc/mutt + doins notmuch-mutt.rc + dodoc README-mutt + popd || die + fi + + DOCS="" bindings python distutils-r1_src_install + use doc && bindings python dohtml -r python +} + +pkg_postinst() { + use emacs && elisp-site-regen + + if use mutt && [[ ! ${NOTMUCH_MUTT_RC_EXISTS} ]]; then + elog "To enable notmuch support in mutt, add the following line into" + elog "your mutt config file, please:" + elog "" + elog " source /etc/mutt/notmuch-mutt.rc" + fi +} + +pkg_postrm() { + use emacs && elisp-site-regen +} |