[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Help with Lintian error in python3 (pybind11-wrapped) package



On Mon, Jul 10, 2023 at 11:22:05AM +0200, José Luis Blanco-Claraco wrote:
> On Mon, Jul 10, 2023 at 11:09 AM Andrey Rakhmatullin <wrar@wrar.name> wrote:
> > No, as it says "phyton3".
> > (I would also expect that using appropriate substvars here is better than
> > writing deps manually)
> 
> I know, and added ${python3:Depends} and ${shlibs:Depends}, but
> "dh-python" seems not to add any substvars, and "shlibs" does neither.
shlibs:Depends is indeed irrelevant here.
python3:Depends being empty is a problem that needs to be fixed. I've
built the package and it lacks postinst/prerm so I guess dh_python3 didn't
find any modules in the package. I also see that the package is named
python3-pymrpt while the top-level module is named myrpt, though I don't
know if this can cause any problems beside the autopkgtest not working.

> In fact, the "so" module built from the pybind11 wrapper seems not to
> list any python library in "ldd", which also puzzled me:
> 
> ldd mrpt/pymrpt.cpython-310-x86_64-linux-gnu.so  | grep py
>   libsnappy.so.1 => /lib/x86_64-linux-gnu/libsnappy.so.1 (0x00007facb732d000)
Python extensions indeed don't need to link libpython, which is (mostly?)
for embedding the interpreter, as extensions are loaded into an
interpreter themselves.

> I checked that other "*cpython.so" modules out there indeed list
> "libpython3.xxx.so" in their "ldd".
(I've checked two random extensiopns and they don't)

> I understand this is what is preventing "shlibs" to automatically list
> python3 as a substvar, but don't know how to fix it.
It's not, and shlibs:Depends won't list python3 anyway.


Reply to: