OSDN Git Service

scripts: kernel-doc: make it more compatible with Sphinx 3.x
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Tue, 17 Nov 2020 16:52:59 +0000 (17:52 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 10 Dec 2020 17:15:22 +0000 (12:15 -0500)
commit6d3a3cfc2f1ca323b671ecdb48f4b9ec73583ea4
treef570202c9bbf65554355c7bad5b43e06a3285731
parent46ae6e8f8225cc8e1aef13831e850154f3fd8ae6
scripts: kernel-doc: make it more compatible with Sphinx 3.x

With Sphinx 3.x, the ".. c:type:" tag was changed to accept either:

.. c:type:: typedef-like declaration
.. c:type:: name

Using it for other types (including functions) don't work anymore.

So, there are newer tags for macro, enum, struct, union, and others,
which doesn't exist on older versions.

Add a check for the Sphinx version and change the produced tags
accordingly.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Message-Id: <20201117165312.118257-17-pbonzini@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
scripts/kernel-doc