File: docs.patch

package info (click to toggle)
pycuda 2025.1.1~dfsg-1
  • links: PTS, VCS
  • area: contrib
  • in suites: forky, sid, trixie
  • size: 1,676 kB
  • sloc: python: 13,445; cpp: 6,965; makefile: 70; sh: 1
file content (39 lines) | stat: -rw-r--r-- 1,477 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
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
@@ -9,6 +9,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 = {}
@@ -23,12 +26,14 @@ version = ".".join(str(x) for x in ver_d
 release = ver_dic["VERSION_TEXT"]
 
 intersphinx_mapping = {
-    "python": ("https://docs.python.org/3", None),
+    "python": ("file:///usr/share/doc/python3-doc/html/", "/usr/share/doc/python3-doc/html/objects.inv"),
     "numpy": ("https://numpy.org/doc/stable/", None),
-    "codepy": ("https://documen.tician.de/codepy/", None),
+    "codepy": ("file:///usr/share/doc/python-mako-doc/html/", "/usr/share/doc/python-mako-doc/html/objects.inv"),
     "pytest": ("https://docs.pytest.org/en/stable/", None),
 }
 
+mathjax_path = "file:///usr/share/javascript/mathjax/mathjax/MathJax.js"
+
 nitpick_ignore_regex = [
     ["py:class", r"numpy.(float32|u?int32)"],  # not sure why these don't work?
 ]