[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87ms80crfi.fsf@trenco.lwn.net>
Date: Fri, 15 Aug 2025 13:31:45 -0600
From: Jonathan Corbet <corbet@....net>
To: Mauro Carvalho Chehab <mchehab+huawei@...nel.org>
Cc: linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org, Akira Yokosawa
<akiyks@...il.com>, Randy Dunlap <rdunlap@...radead.org>
Subject: Re: [PATCH 07/13] docs: move sphinx-pre-install to tools/doc
Mauro Carvalho Chehab <mchehab+huawei@...nel.org> writes:
>> I'm not sure we need the common/docs intermediate directory.
>>
>> Meanwhile, I had a related, possibly unpopular idea... Start with
>> .../tools/python/kernel and put a basic __init__.py file there;
>> everything else would go into that directory or before. The imports
>> would then read something like:
>>
>> from kernel import abi_parser
>
> Not against something similar to it, but IMO "kernel" is a bad
> name as it sounds something that runs in kernel stace or for Kernel
> build. It could be, instead:
>
> from lib import abi_parser
Part of my purpose was to make it clear that the import was coming from
our own library - to distinguish it from all of the other imports that
these programs have. "Kernel" seems good to me, but we could call it
"kernel_lib" or some such if we really want. "lib" seems too generic.
> Yet, I guess it may still need to add something at PATH, depending from
> where current working dir the script was called (but tests required).
That seems hard to avoid, yes.
Of course, we could require that all kernel tools run in a special
virtualenv :)
> Btw, nothing prevents moving extensions from Documentation/sphinx
> into tools/sphinx_extensions. We just need to add the path insert
> at conf.py.
I feel less of a need to do that; it seems that the Sphinx-specific
stuff can stay where it is. Though I guess I wouldn't scream too loud
if people really wanted to do that move.
Thanks,
jon
Powered by blists - more mailing lists