]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
cmake,debian: install pure python module to deb_system path
authorKefu Chai <tchaikov@gmail.com>
Thu, 4 Aug 2022 13:52:43 +0000 (21:52 +0800)
committerKefu Chai <tchaikov@gmail.com>
Wed, 31 Aug 2022 12:36:53 +0000 (20:36 +0800)
commitbcfe4fb8dc1fc0210ea261f7410e7092fe560f48
tree7eee18c0b991dcdfd7cdb6502982a2afb28133d7
parentbfa86c88cd6b9c0ba0e042feb9764383245c8a49
cmake,debian: install pure python module to deb_system path

in ubuntu 22.04 and debian unstable, the layout (scheme) for system
python module is named "deb_system", the default one is 'posix_local'.
and 'posix_local' installs python modules into paths like
usr/local/lib/python3.10/dist-packages/. hence dh_install fails
when it tries to find the files to be packaged under directory of
usr/lib/python3*/site-packages/.

in this change, the "deb_system" scheme is used if it is available,
and fall back to "posix_prefix" to be backward compatible with older
debian (derivative) distros.

also, update the source directories of pure python's installation
from `site-packages` to `*-packages`, to be compatible with ubuntu focal
and ubuntu jammy. as we are now using the specified scheme instead of
the default one.

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
(cherry picked from commit 04967404ed682835f81c1a5e51f94d09805d38b3)
Conflicts:
    apply the same change to debian/python3-cephfs.install, which
    was remove in main branch, but we need to preserve it in pacific.
debian/python3-ceph-argparse.install
debian/python3-cephfs.install [changed mode: 0644->0755]
src/pybind/CMakeLists.txt