Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   1) # -*- coding: utf-8 -*-
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   2) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   3) # The Linux Kernel documentation build configuration file, created by
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   4) # sphinx-quickstart on Fri Feb 12 13:51:46 2016.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   5) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   6) # This file is execfile()d with the current directory set to its
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   7) # containing dir.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   8) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   9) # Note that not all possible configuration values are present in this
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  10) # autogenerated file.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  11) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  12) # All configuration values have a default; values that are commented out
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  13) # serve to show the default.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  14) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  15) import sys
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  16) import os
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  17) import sphinx
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  18) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  19) from subprocess import check_output
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  20) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  21) # Get Sphinx version
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  22) major, minor, patch = sphinx.version_info[:3]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  23) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  24) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  25) # If extensions (or modules to document with autodoc) are in another directory,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  26) # add these directories to sys.path here. If the directory is relative to the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  27) # documentation root, use os.path.abspath to make it absolute, like shown here.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  28) sys.path.insert(0, os.path.abspath('sphinx'))
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  29) from load_config import loadConfig
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  30) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  31) # -- General configuration ------------------------------------------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  32) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  33) # If your documentation needs a minimal Sphinx version, state it here.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  34) needs_sphinx = '1.3'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  35) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  36) # Add any Sphinx extension module names here, as strings. They can be
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  37) # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  38) # ones.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  39) extensions = ['kerneldoc', 'rstFlatTable', 'kernel_include',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  40)               'kfigure', 'sphinx.ext.ifconfig', 'automarkup',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  41)               'maintainers_include', 'sphinx.ext.autosectionlabel',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  42)               'kernel_abi']
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  43) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  44) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  45) # cdomain is badly broken in Sphinx 3+.  Leaving it out generates *most*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  46) # of the docs correctly, but not all.  Scream bloody murder but allow
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  47) # the process to proceed; hopefully somebody will fix this properly soon.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  48) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  49) if major >= 3:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  50)     sys.stderr.write('''WARNING: The kernel documentation build process
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  51)         support for Sphinx v3.0 and above is brand new. Be prepared for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  52)         possible issues in the generated output.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  53)         ''')
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  54)     if (major > 3) or (minor > 0 or patch >= 2):
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  55)         # Sphinx c function parser is more pedantic with regards to type
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  56)         # checking. Due to that, having macros at c:function cause problems.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  57)         # Those needed to be scaped by using c_id_attributes[] array
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  58)         c_id_attributes = [
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  59)             # GCC Compiler types not parsed by Sphinx:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  60)             "__restrict__",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  61) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  62)             # include/linux/compiler_types.h:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  63)             "__iomem",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  64)             "__kernel",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  65)             "noinstr",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  66)             "notrace",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  67)             "__percpu",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  68)             "__rcu",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  69)             "__user",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  70) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  71)             # include/linux/compiler_attributes.h:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  72)             "__alias",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  73)             "__aligned",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  74)             "__aligned_largest",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  75)             "__always_inline",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  76)             "__assume_aligned",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  77)             "__cold",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  78)             "__attribute_const__",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  79)             "__copy",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  80)             "__pure",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  81)             "__designated_init",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  82)             "__visible",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  83)             "__printf",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  84)             "__scanf",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  85)             "__gnu_inline",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  86)             "__malloc",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  87)             "__mode",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  88)             "__no_caller_saved_registers",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  89)             "__noclone",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  90)             "__nonstring",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  91)             "__noreturn",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  92)             "__packed",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  93)             "__pure",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  94)             "__section",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  95)             "__always_unused",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  96)             "__maybe_unused",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  97)             "__used",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  98)             "__weak",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  99)             "noinline",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 100) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 101)             # include/linux/memblock.h:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 102)             "__init_memblock",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 103)             "__meminit",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 104) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 105)             # include/linux/init.h:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 106)             "__init",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 107)             "__ref",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 108) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 109)             # include/linux/linkage.h:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 110)             "asmlinkage",
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 111)         ]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 112) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 113) else:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 114)     extensions.append('cdomain')
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 115) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 116) # Ensure that autosectionlabel will produce unique names
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 117) autosectionlabel_prefix_document = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 118) autosectionlabel_maxdepth = 2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 119) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 120) # The name of the math extension changed on Sphinx 1.4
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 121) if (major == 1 and minor > 3) or (major > 1):
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 122)     extensions.append("sphinx.ext.imgmath")
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 123) else:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 124)     extensions.append("sphinx.ext.pngmath")
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 125) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 126) # Add any paths that contain templates here, relative to this directory.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 127) templates_path = ['_templates']
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 128) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 129) # The suffix(es) of source filenames.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 130) # You can specify multiple suffix as a list of string:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 131) # source_suffix = ['.rst', '.md']
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 132) source_suffix = '.rst'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 133) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 134) # The encoding of source files.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 135) #source_encoding = 'utf-8-sig'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 136) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 137) # The master toctree document.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 138) master_doc = 'index'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 139) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 140) # General information about the project.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 141) project = 'The Linux Kernel'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 142) copyright = 'The kernel development community'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 143) author = 'The kernel development community'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 144) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 145) # The version info for the project you're documenting, acts as replacement for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 146) # |version| and |release|, also used in various other places throughout the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 147) # built documents.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 148) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 149) # In a normal build, version and release are are set to KERNELVERSION and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 150) # KERNELRELEASE, respectively, from the Makefile via Sphinx command line
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 151) # arguments.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 152) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 153) # The following code tries to extract the information by reading the Makefile,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 154) # when Sphinx is run directly (e.g. by Read the Docs).
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 155) try:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 156)     makefile_version = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 157)     makefile_patchlevel = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 158)     for line in open('../Makefile'):
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 159)         key, val = [x.strip() for x in line.split('=', 2)]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 160)         if key == 'VERSION':
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 161)             makefile_version = val
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 162)         elif key == 'PATCHLEVEL':
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 163)             makefile_patchlevel = val
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 164)         if makefile_version and makefile_patchlevel:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 165)             break
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 166) except:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 167)     pass
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 168) finally:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 169)     if makefile_version and makefile_patchlevel:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 170)         version = release = makefile_version + '.' + makefile_patchlevel
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 171)     else:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 172)         version = release = "unknown version"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 173) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 174) # The language for content autogenerated by Sphinx. Refer to documentation
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 175) # for a list of supported languages.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 176) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 177) # This is also used if you do content translation via gettext catalogs.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 178) # Usually you set "language" from the command line for these cases.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 179) language = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 180) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 181) # There are two options for replacing |today|: either, you set today to some
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 182) # non-false value, then it is used:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 183) #today = ''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 184) # Else, today_fmt is used as the format for a strftime call.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 185) #today_fmt = '%B %d, %Y'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 186) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 187) # List of patterns, relative to source directory, that match files and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 188) # directories to ignore when looking for source files.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 189) exclude_patterns = ['output']
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 190) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 191) # The reST default role (used for this markup: `text`) to use for all
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 192) # documents.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 193) #default_role = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 194) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 195) # If true, '()' will be appended to :func: etc. cross-reference text.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 196) #add_function_parentheses = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 197) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 198) # If true, the current module name will be prepended to all description
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 199) # unit titles (such as .. function::).
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 200) #add_module_names = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 201) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 202) # If true, sectionauthor and moduleauthor directives will be shown in the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 203) # output. They are ignored by default.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 204) #show_authors = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 205) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 206) # The name of the Pygments (syntax highlighting) style to use.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 207) pygments_style = 'sphinx'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 208) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 209) # A list of ignored prefixes for module index sorting.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 210) #modindex_common_prefix = []
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 211) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 212) # If true, keep warnings as "system message" paragraphs in the built documents.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 213) #keep_warnings = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 214) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 215) # If true, `todo` and `todoList` produce output, else they produce nothing.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 216) todo_include_todos = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 217) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 218) primary_domain = 'c'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 219) highlight_language = 'none'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 220) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 221) # -- Options for HTML output ----------------------------------------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 222) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 223) # The theme to use for HTML and HTML Help pages.  See the documentation for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 224) # a list of builtin themes.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 225) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 226) # The Read the Docs theme is available from
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 227) # - https://github.com/snide/sphinx_rtd_theme
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 228) # - https://pypi.python.org/pypi/sphinx_rtd_theme
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 229) # - python-sphinx-rtd-theme package (on Debian)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 230) try:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 231)     import sphinx_rtd_theme
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 232)     html_theme = 'sphinx_rtd_theme'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 233)     html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 234) except ImportError:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 235)     sys.stderr.write('Warning: The Sphinx \'sphinx_rtd_theme\' HTML theme was not found. Make sure you have the theme installed to produce pretty HTML output. Falling back to the default theme.\n')
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 236) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 237) # Theme options are theme-specific and customize the look and feel of a theme
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 238) # further.  For a list of options available for each theme, see the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 239) # documentation.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 240) #html_theme_options = {}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 241) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 242) # Add any paths that contain custom themes here, relative to this directory.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 243) #html_theme_path = []
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 244) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 245) # The name for this set of Sphinx documents.  If None, it defaults to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 246) # "<project> v<release> documentation".
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 247) #html_title = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 248) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 249) # A shorter title for the navigation bar.  Default is the same as html_title.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 250) #html_short_title = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 251) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 252) # The name of an image file (relative to this directory) to place at the top
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 253) # of the sidebar.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 254) #html_logo = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 255) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 256) # The name of an image file (within the static path) to use as favicon of the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 257) # docs.  This file should be a Windows icon file (.ico) being 16x16 or 32x32
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 258) # pixels large.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 259) #html_favicon = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 260) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 261) # Add any paths that contain custom static files (such as style sheets) here,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 262) # relative to this directory. They are copied after the builtin static files,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 263) # so a file named "default.css" will overwrite the builtin "default.css".
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 264) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 265) html_static_path = ['sphinx-static']
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 266) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 267) html_context = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 268)     'css_files': [
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 269)         '_static/theme_overrides.css',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 270)     ],
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 271) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 272) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 273) # Add any extra paths that contain custom files (such as robots.txt or
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 274) # .htaccess) here, relative to this directory. These files are copied
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 275) # directly to the root of the documentation.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 276) #html_extra_path = []
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 277) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 278) # If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 279) # using the given strftime format.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 280) #html_last_updated_fmt = '%b %d, %Y'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 281) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 282) # If true, SmartyPants will be used to convert quotes and dashes to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 283) # typographically correct entities.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 284) html_use_smartypants = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 285) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 286) # Custom sidebar templates, maps document names to template names.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 287) #html_sidebars = {}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 288) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 289) # Additional templates that should be rendered to pages, maps page names to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 290) # template names.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 291) #html_additional_pages = {}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 292) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 293) # If false, no module index is generated.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 294) #html_domain_indices = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 295) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 296) # If false, no index is generated.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 297) #html_use_index = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 298) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 299) # If true, the index is split into individual pages for each letter.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 300) #html_split_index = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 301) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 302) # If true, links to the reST sources are added to the pages.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 303) #html_show_sourcelink = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 304) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 305) # If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 306) #html_show_sphinx = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 307) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 308) # If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 309) #html_show_copyright = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 310) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 311) # If true, an OpenSearch description file will be output, and all pages will
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 312) # contain a <link> tag referring to it.  The value of this option must be the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 313) # base URL from which the finished HTML is served.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 314) #html_use_opensearch = ''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 315) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 316) # This is the file name suffix for HTML files (e.g. ".xhtml").
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 317) #html_file_suffix = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 318) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 319) # Language to be used for generating the HTML full-text search index.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 320) # Sphinx supports the following languages:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 321) #   'da', 'de', 'en', 'es', 'fi', 'fr', 'h', 'it', 'ja'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 322) #   'nl', 'no', 'pt', 'ro', 'r', 'sv', 'tr'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 323) #html_search_language = 'en'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 324) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 325) # A dictionary with options for the search language support, empty by default.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 326) # Now only 'ja' uses this config value
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 327) #html_search_options = {'type': 'default'}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 328) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 329) # The name of a javascript file (relative to the configuration directory) that
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 330) # implements a search results scorer. If empty, the default will be used.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 331) #html_search_scorer = 'scorer.js'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 332) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 333) # Output file base name for HTML help builder.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 334) htmlhelp_basename = 'TheLinuxKerneldoc'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 335) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 336) # -- Options for LaTeX output ---------------------------------------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 337) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 338) latex_elements = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 339) # The paper size ('letterpaper' or 'a4paper').
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 340) 'papersize': 'a4paper',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 341) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 342) # The font size ('10pt', '11pt' or '12pt').
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 343) 'pointsize': '11pt',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 344) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 345) # Latex figure (float) alignment
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 346) #'figure_align': 'htbp',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 347) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 348) # Don't mangle with UTF-8 chars
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 349) 'inputenc': '',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 350) 'utf8extra': '',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 351) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 352) # Additional stuff for the LaTeX preamble.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 353)     'preamble': '''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 354) 	% Use some font with UTF-8 support with XeLaTeX
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 355)         \\usepackage{fontspec}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 356)         \\setsansfont{DejaVu Sans}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 357)         \\setromanfont{DejaVu Serif}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 358)         \\setmonofont{DejaVu Sans Mono}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 359)      '''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 360) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 361) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 362) # At least one book (translations) may have Asian characters
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 363) # with are only displayed if xeCJK is used
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 364) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 365) cjk_cmd = check_output(['fc-list', '--format="%{family[0]}\n"']).decode('utf-8', 'ignore')
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 366) if cjk_cmd.find("Noto Sans CJK SC") >= 0:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 367)     print ("enabling CJK for LaTeX builder")
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 368)     latex_elements['preamble']  += '''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 369) 	% This is needed for translations
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 370)         \\usepackage{xeCJK}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 371)         \\setCJKmainfont{Noto Sans CJK SC}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 372)      '''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 373) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 374) # Fix reference escape troubles with Sphinx 1.4.x
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 375) if major == 1 and minor > 3:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 376)     latex_elements['preamble']  += '\\renewcommand*{\\DUrole}[2]{ #2 }\n'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 377) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 378) if major == 1 and minor <= 4:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 379)     latex_elements['preamble']  += '\\usepackage[margin=0.5in, top=1in, bottom=1in]{geometry}'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 380) elif major == 1 and (minor > 5 or (minor == 5 and patch >= 3)):
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 381)     latex_elements['sphinxsetup'] = 'hmargin=0.5in, vmargin=1in'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 382)     latex_elements['preamble']  += '\\fvset{fontsize=auto}\n'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 383) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 384) # Customize notice background colors on Sphinx < 1.6:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 385) if major == 1 and minor < 6:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 386)    latex_elements['preamble']  += '''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 387)         \\usepackage{ifthen}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 388) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 389)         % Put notes in color and let them be inside a table
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 390) 	\\definecolor{NoteColor}{RGB}{204,255,255}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 391) 	\\definecolor{WarningColor}{RGB}{255,204,204}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 392) 	\\definecolor{AttentionColor}{RGB}{255,255,204}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 393) 	\\definecolor{ImportantColor}{RGB}{192,255,204}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 394) 	\\definecolor{OtherColor}{RGB}{204,204,204}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 395)         \\newlength{\\mynoticelength}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 396)         \\makeatletter\\newenvironment{coloredbox}[1]{%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 397) 	   \\setlength{\\fboxrule}{1pt}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 398) 	   \\setlength{\\fboxsep}{7pt}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 399) 	   \\setlength{\\mynoticelength}{\\linewidth}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 400) 	   \\addtolength{\\mynoticelength}{-2\\fboxsep}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 401) 	   \\addtolength{\\mynoticelength}{-2\\fboxrule}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 402)            \\begin{lrbox}{\\@tempboxa}\\begin{minipage}{\\mynoticelength}}{\\end{minipage}\\end{lrbox}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 403) 	   \\ifthenelse%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 404) 	      {\\equal{\\py@noticetype}{note}}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 405) 	      {\\colorbox{NoteColor}{\\usebox{\\@tempboxa}}}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 406) 	      {%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 407) 	         \\ifthenelse%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 408) 	         {\\equal{\\py@noticetype}{warning}}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 409) 	         {\\colorbox{WarningColor}{\\usebox{\\@tempboxa}}}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 410) 		 {%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 411) 	            \\ifthenelse%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 412) 	            {\\equal{\\py@noticetype}{attention}}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 413) 	            {\\colorbox{AttentionColor}{\\usebox{\\@tempboxa}}}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 414) 		    {%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 415) 	               \\ifthenelse%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 416) 	               {\\equal{\\py@noticetype}{important}}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 417) 	               {\\colorbox{ImportantColor}{\\usebox{\\@tempboxa}}}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 418) 	               {\\colorbox{OtherColor}{\\usebox{\\@tempboxa}}}%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 419) 		    }%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 420) 		 }%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 421) 	      }%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 422)         }\\makeatother
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 423) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 424)         \\makeatletter
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 425)         \\renewenvironment{notice}[2]{%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 426)           \\def\\py@noticetype{#1}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 427)           \\begin{coloredbox}{#1}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 428)           \\bf\\it
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 429)           \\par\\strong{#2}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 430)           \\csname py@noticestart@#1\\endcsname
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 431)         }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 432) 	{
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 433)           \\csname py@noticeend@\\py@noticetype\\endcsname
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 434)           \\end{coloredbox}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 435)         }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 436) 	\\makeatother
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 437) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 438)      '''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 439) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 440) # With Sphinx 1.6, it is possible to change the Bg color directly
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 441) # by using:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 442) #	\definecolor{sphinxnoteBgColor}{RGB}{204,255,255}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 443) #	\definecolor{sphinxwarningBgColor}{RGB}{255,204,204}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 444) #	\definecolor{sphinxattentionBgColor}{RGB}{255,255,204}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 445) #	\definecolor{sphinximportantBgColor}{RGB}{192,255,204}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 446) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 447) # However, it require to use sphinx heavy box with:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 448) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 449) #	\renewenvironment{sphinxlightbox} {%
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 450) #		\\begin{sphinxheavybox}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 451) #	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 452) #		\\end{sphinxheavybox}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 453) #	}
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 454) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 455) # Unfortunately, the implementation is buggy: if a note is inside a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 456) # table, it isn't displayed well. So, for now, let's use boring
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 457) # black and white notes.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 458) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 459) # Grouping the document tree into LaTeX files. List of tuples
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 460) # (source start file, target name, title,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 461) #  author, documentclass [howto, manual, or own class]).
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 462) # Sorted in alphabetical order
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 463) latex_documents = [
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 464) ]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 465) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 466) # Add all other index files from Documentation/ subdirectories
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 467) for fn in os.listdir('.'):
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 468)     doc = os.path.join(fn, "index")
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 469)     if os.path.exists(doc + ".rst"):
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 470)         has = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 471)         for l in latex_documents:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 472)             if l[0] == doc:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 473)                 has = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 474)                 break
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 475)         if not has:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 476)             latex_documents.append((doc, fn + '.tex',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 477)                                     'Linux %s Documentation' % fn.capitalize(),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 478)                                     'The kernel development community',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 479)                                     'manual'))
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 480) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 481) # The name of an image file (relative to this directory) to place at the top of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 482) # the title page.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 483) #latex_logo = None
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 484) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 485) # For "manual" documents, if this is true, then toplevel headings are parts,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 486) # not chapters.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 487) #latex_use_parts = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 488) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 489) # If true, show page references after internal links.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 490) #latex_show_pagerefs = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 491) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 492) # If true, show URL addresses after external links.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 493) #latex_show_urls = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 494) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 495) # Documents to append as an appendix to all manuals.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 496) #latex_appendices = []
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 497) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 498) # If false, no module index is generated.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 499) #latex_domain_indices = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 500) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 501) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 502) # -- Options for manual page output ---------------------------------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 503) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 504) # One entry per manual page. List of tuples
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 505) # (source start file, name, description, authors, manual section).
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 506) man_pages = [
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 507)     (master_doc, 'thelinuxkernel', 'The Linux Kernel Documentation',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 508)      [author], 1)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 509) ]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 510) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 511) # If true, show URL addresses after external links.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 512) #man_show_urls = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 513) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 514) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 515) # -- Options for Texinfo output -------------------------------------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 516) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 517) # Grouping the document tree into Texinfo files. List of tuples
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 518) # (source start file, target name, title, author,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 519) #  dir menu entry, description, category)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 520) texinfo_documents = [
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 521)     (master_doc, 'TheLinuxKernel', 'The Linux Kernel Documentation',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 522)      author, 'TheLinuxKernel', 'One line description of project.',
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 523)      'Miscellaneous'),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 524) ]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 525) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 526) # Documents to append as an appendix to all manuals.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 527) #texinfo_appendices = []
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 528) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 529) # If false, no module index is generated.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 530) #texinfo_domain_indices = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 531) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 532) # How to display URL addresses: 'footnote', 'no', or 'inline'.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 533) #texinfo_show_urls = 'footnote'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 534) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 535) # If true, do not generate a @detailmenu in the "Top" node's menu.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 536) #texinfo_no_detailmenu = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 537) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 538) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 539) # -- Options for Epub output ----------------------------------------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 540) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 541) # Bibliographic Dublin Core info.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 542) epub_title = project
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 543) epub_author = author
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 544) epub_publisher = author
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 545) epub_copyright = copyright
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 546) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 547) # The basename for the epub file. It defaults to the project name.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 548) #epub_basename = project
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 549) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 550) # The HTML theme for the epub output. Since the default themes are not
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 551) # optimized for small screen space, using the same theme for HTML and epub
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 552) # output is usually not wise. This defaults to 'epub', a theme designed to save
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 553) # visual space.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 554) #epub_theme = 'epub'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 555) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 556) # The language of the text. It defaults to the language option
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 557) # or 'en' if the language is not set.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 558) #epub_language = ''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 559) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 560) # The scheme of the identifier. Typical schemes are ISBN or URL.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 561) #epub_scheme = ''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 562) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 563) # The unique identifier of the text. This can be a ISBN number
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 564) # or the project homepage.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 565) #epub_identifier = ''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 566) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 567) # A unique identification for the text.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 568) #epub_uid = ''
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 569) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 570) # A tuple containing the cover image and cover page html template filenames.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 571) #epub_cover = ()
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 572) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 573) # A sequence of (type, uri, title) tuples for the guide element of content.opf.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 574) #epub_guide = ()
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 575) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 576) # HTML files that should be inserted before the pages created by sphinx.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 577) # The format is a list of tuples containing the path and title.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 578) #epub_pre_files = []
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 579) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 580) # HTML files that should be inserted after the pages created by sphinx.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 581) # The format is a list of tuples containing the path and title.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 582) #epub_post_files = []
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 583) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 584) # A list of files that should not be packed into the epub file.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 585) epub_exclude_files = ['search.html']
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 586) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 587) # The depth of the table of contents in toc.ncx.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 588) #epub_tocdepth = 3
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 589) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 590) # Allow duplicate toc entries.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 591) #epub_tocdup = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 592) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 593) # Choose between 'default' and 'includehidden'.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 594) #epub_tocscope = 'default'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 595) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 596) # Fix unsupported image types using the Pillow.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 597) #epub_fix_images = False
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 598) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 599) # Scale large images.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 600) #epub_max_image_width = 0
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 601) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 602) # How to display URL addresses: 'footnote', 'no', or 'inline'.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 603) #epub_show_urls = 'inline'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 604) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 605) # If false, no index is generated.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 606) #epub_use_index = True
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 607) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 608) #=======
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 609) # rst2pdf
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 610) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 611) # Grouping the document tree into PDF files. List of tuples
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 612) # (source start file, target name, title, author, options).
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 613) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 614) # See the Sphinx chapter of https://ralsina.me/static/manual.pdf
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 615) #
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 616) # FIXME: Do not add the index file here; the result will be too big. Adding
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 617) # multiple PDF files here actually tries to get the cross-referencing right
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 618) # *between* PDF files.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 619) pdf_documents = [
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 620)     ('kernel-documentation', u'Kernel', u'Kernel', u'J. Random Bozo'),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 621) ]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 622) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 623) # kernel-doc extension configuration for running Sphinx directly (e.g. by Read
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 624) # the Docs). In a normal build, these are supplied from the Makefile via command
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 625) # line arguments.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 626) kerneldoc_bin = '../scripts/kernel-doc'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 627) kerneldoc_srctree = '..'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 628) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 629) # ------------------------------------------------------------------------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 630) # Since loadConfig overwrites settings from the global namespace, it has to be
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 631) # the last statement in the conf.py file
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 632) # ------------------------------------------------------------------------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 633) loadConfig(globals())