Description: use Debian packages for external documentation
 Do not fetch external Sphinx inventory but use one from Debian packages.
 .
 Documentation tries to download MathJax from the network. This might be
 a privacy breach and makes it hard to use documentation in offline mode.
 This patch forces Sphinx to use MathJax from (other) package.
Forwarded: not-needed
Author: Tomasz Rybak <tomasz.rybak@post.pl>
Last-Update: 2022-07-01

--- a/doc/conf.py
+++ b/doc/conf.py
@@ -6,6 +6,9 @@ _conf_url = \
 with open("sphinxconfig.py") as _inf:
     exec(compile(_inf.read(), _conf_url, "exec"), globals())
 
+project = "PyCUDA"
+html_theme = "alabaster"
+
 copyright = "2008-21, Andreas Kloeckner"
 
 ver_dic = {}
@@ -20,7 +23,11 @@ version = ".".join(str(x) for x in ver_d
 release = ver_dic["VERSION_TEXT"]
 
 intersphinx_mapping = {
-    "https://docs.python.org/3": None,
+        'file:///usr/share/doc/python3-doc/html/':
+           '/usr/share/doc/python3-doc/html/objects.inv',
     "https://numpy.org/doc/stable/": None,
-    "https://documen.tician.de/codepy/": None,
+        'file:///usr/share/doc/python-mako-doc/html/':
+            '/usr/share/doc/python-mako-doc/html/objects.inv'
 }
+
+mathjax_path = "file:///usr/share/javascript/mathjax/mathjax/MathJax.js"
