mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-01 10:45:49 +00:00
docs: kernel_include.py: add sphinx build dependencies
The files included by kernel-include should be added as build dependencies, in order for sphinx-build to rebuild the corresponding docs if any changes at the included file happens. Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org> Link: https://lore.kernel.org/r/d30fc4fa422a13b7e1623d690945c46b58a55e79.1648290305.git.mchehab@kernel.org Signed-off-by: Jonathan Corbet <corbet@lwn.net>
This commit is contained in:
parent
b4541803d8
commit
bcf0a536bf
@ -59,6 +59,7 @@ class KernelInclude(Include):
|
|||||||
u"""KernelInclude (``kernel-include``) directive"""
|
u"""KernelInclude (``kernel-include``) directive"""
|
||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
|
env = self.state.document.settings.env
|
||||||
path = os.path.realpath(
|
path = os.path.realpath(
|
||||||
os.path.expandvars(self.arguments[0]))
|
os.path.expandvars(self.arguments[0]))
|
||||||
|
|
||||||
@ -70,6 +71,8 @@ class KernelInclude(Include):
|
|||||||
|
|
||||||
self.arguments[0] = path
|
self.arguments[0] = path
|
||||||
|
|
||||||
|
env.note_dependency(os.path.abspath(path))
|
||||||
|
|
||||||
#return super(KernelInclude, self).run() # won't work, see HINTs in _run()
|
#return super(KernelInclude, self).run() # won't work, see HINTs in _run()
|
||||||
return self._run()
|
return self._run()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user