From 9d8c2c5b475d0bdbb054dd58c902c5a68fc187e9 Mon Sep 17 00:00:00 2001 From: Michel Alexandre Salim Date: Feb 14 2016 05:07:13 +0000 Subject: Patch the documentation generator config so it works offline --- diff --git a/hypothesis-2.0.0-offline.patch b/hypothesis-2.0.0-offline.patch new file mode 100644 index 0000000..57a95dc --- /dev/null +++ b/hypothesis-2.0.0-offline.patch @@ -0,0 +1,10 @@ +--- hypothesis-2.0.0/docs/conf.py.offline 2016-01-11 00:47:23.000000000 +0700 ++++ hypothesis-2.0.0/docs/conf.py 2016-02-14 10:50:58.790136352 +0700 +@@ -33,7 +33,6 @@ + extensions = [ + 'sphinx.ext.autodoc', + 'sphinx.ext.viewcode', +- 'sphinx.ext.intersphinx', + ] + + templates_path = ['_templates'] diff --git a/python-hypothesis.spec b/python-hypothesis.spec index 5e693e9..cceb98f 100644 --- a/python-hypothesis.spec +++ b/python-hypothesis.spec @@ -13,6 +13,8 @@ Summary: %{sum} License: MPLv2.0 URL: https://github.com/DRMacIver/hypothesis Source0: https://github.com/DRMacIver/hypothesis/archive/%{version}.tar.gz#/hypothesis-%{version}.tar.gz +# disable Sphinx extensions that require Internet access +Patch0: %{srcname}-2.0.0-offline.patch BuildArch: noarch BuildRequires: python2-devel @@ -87,7 +89,7 @@ flow. %prep -%autosetup -n %{srcname}-%{version} +%autosetup -n %{srcname}-%{version} -p1 # remove shebang, mergedbs gets installed in sitelib %{__sed} -i -e 1,2d src/hypothesis/tools/mergedbs.py @@ -104,7 +106,7 @@ rm -rf tests/nocover %if 0%{?with_python3} %py3_build #(cd docs && READTHEDOCS=True make man) -sphinx-build -W -b man -d docs/_build/doctrees docs docs/_build/man +sphinx-build -b man -d docs/_build/doctrees docs docs/_build/man %endif