dev-python/flask-cors/flask-cors-9999.ebuild: Use local intersphinx
authorW. Trevor King <wking@tremily.us>
Tue, 2 Sep 2014 22:54:51 +0000 (15:54 -0700)
committerW. Trevor King <wking@tremily.us>
Tue, 2 Sep 2014 22:54:51 +0000 (15:54 -0700)
commit6bc40ba47d1f651a421e804295cfa1962edd228a
tree012af5d07cf8e0da51fd7fb5d9b0b20b99a93300
parent9ee702679f4872ea39215ad6eed8a96a6501faff
dev-python/flask-cors/flask-cors-9999.ebuild: Use local intersphinx

Gentoo's python-docs recently learned how to install objects.inv (with
the 2.7.6, 3.3.5, and 3.4.0 ebuilds, but without a revbump [1]).
Avoid the troublesome web access [2,3]:

  loading intersphinx inventory from http://docs.python.org/objects.inv...

Unfortunately, the approach to locating the local objects.inv is a bit
awkward.  Ideally there would be some sort of pkg-config approach to
listing a package's HTML doc directory :p, but until then the best I
can do is shell out to ls with an EROOT-based glob.  Using ROOT in
ebuild functions is illegal though [4] (and by extension, using it via
EROOT may be illegal as well).  Even if it was legal, you're going to
run into trouble if the python-docs dependency was installed with a
different ROOT, which is why I die if PYTHON_DOC is empty.

[1]: https://bugs.gentoo.org/show_bug.cgi?id=521768
     Summary: dev-python/python-docs-3.4.0 doesn't install objects.inv
       for intersphinx
[2]: https://bugs.gentoo.org/show_bug.cgi?id=522064
     Summary: should explicitly disallow network access from existing
       ebuild functions
[3]: https://github.com/gentoo/devmanual.gentoo.org/pull/21
     Summary: ebuild-writing/functions: Don't allow network access
[4]: http://devmanual.gentoo.org/ebuild-writing/common-mistakes/#invalid-use-of-root
flask-cors-9999.ebuild