pkgsrc-Users archive

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

Python hier question



I'm currently working (when I have some time) upstream for Xorg
modules and I'm fixing things so that at least NetBSD (but should work
for other OSes, at least *BSD) can compile things without any patching.

While I'm at it, I'm adding, alongside the autotools files, meson
files (I'm neither a python nor a meson user, but a meson.build file
is far more readable than the autotools stuff and cross-compilation
seems in better shape with meson).

There are some python bindings, for example for xcb, and I want to
simplify installation by following https://peps.python.org/pep-3147/.

But I see that in pkgsrc, the repository where the py source files are
installed is prefixed with the version of the interpreter, defeating
the goal, exposed in the link above, of sharing .py source files
between different python versions, several different byte-compiled
versions being cached for the various interpreters in a __pycache__
subdir.

What is the purpose of prefixing the installation path with the
exact version of the interpreter? Is it "just" because it would be
awkward to have a, say, "python/" shared dir for modules and to
have to decide, at deinstallation time, if such and such modules, so
other pkgsrc packages, have to be cleaned from the byte-compile related
.pyc files for the deinstalled python interpreted version?

I'm trying to understand the rationale so that what I add in an Xorg
module does not end up being incompatible with the use downstream thus
requiring ad hoc handling.
-- 
        Thierry Laronde <tlaronde +AT+ kergis +dot+ com>
                     http://www.kergis.com/
                    http://kertex.kergis.com/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C


Home | Main Index | Thread Index | Old Index