The current nltk ebuilds (=dev-python/nltk-2.0.4 especially) have unneeded hard depends on numpy and pyyaml (and in the case of 2.0.4) on python built with the tk use flag. nltk works just fine without any of these depends as they are only optional depends required for some, but not all, features. Below is an ebuild excerpt that I use locally for nltk-3.0.0 which should only need an adjustement of PYTHON_COMPAT for it to be used with nltk-2.0.4. ``` EAPI="5" PYTHON_COMPAT=( python2_{6,7} ) PYTHON_REQ_USE="tk(+),xml(+)" inherit distutils-r1 DESCRIPTION="Natural Language Toolkit" SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" HOMEPAGE="http://nltk.org/" LICENSE="Apache-2.0" SLOT="0" KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x86-solaris" RDEPEND="${RDEPEND} dev-python/numpy[${PYTHON_USEDEP}] dev-python/pyyaml[${PYTHON_USEDEP}]" DEPEND="${RDEPEND} app-arch/unzip" ``` Reproducible: Always Steps to Reproduce: 1. Install nltk. 2. See that numpy, pyyaml, and tk are optional. Actual Results: nltk has hard depends on numpy, python with tk, and pyyaml Expected Results: nltk does not hard depend on numpy, python with tk, or pyyaml but instead allows the user to disable or enable these dependencies with use flags The ebuilds also restrict PYTHON_COMPAT to python2, whereas nltk 3.0.0 (which isn't in the tree yet) works with both python2 and python3. As python3 currently isn't in tree, this isn't really a bug. Just wanted to mention it because I added it to PYTHON_COMPAT in the ebuild I attached.
Created attachment 391750 [details] Updated nltk ebuild. I accidentally pasted the wrong ebuild. This is the correct one.
I confirm the optionality of numpy and tk. But the setup.py is clear, pyyaml is mandatory.