Path: csiph.com!aioe.org!bofh.it!news.nic.it!robomod From: Andrey Rahmatullin Newsgroups: linux.debian.maint.python Subject: Re: PYTHONPATH with cmake build Date: Tue, 30 Aug 2022 16:40:02 +0200 Message-ID: References: X-Mailbox-Line: From debian-python-request@lists.debian.org Tue Aug 30 14:33:43 2022 Old-Return-Path: X-Amavis-Spam-Status: No, score=-11.99 tagged_above=-10000 required=5.3 tests=[BAYES_00=-2, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, FVGT_m_MULTI_ODD=0.02, LDO_WHITELIST=-5, PGPSIGNATURE=-5, T_SCC_BODY_TEXT_LINE=-0.01] autolearn=ham autolearn_force=no X-Policyd-Weight: using cached result; rate: -3.5 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="tGfEWZZ071cz/gQ8" Content-Disposition: inline X-Mailing-List: archive/latest/20243 List-ID: List-URL: List-Archive: https://lists.debian.org/msgid-search/Yw4fsZMTSHE9Bhpq@belkar.wrar.name Approved: robomod@news.nic.it Lines: 73 Organization: linux.* mail to news gateway Sender: robomod@news.nic.it X-Original-Date: Tue, 30 Aug 2022 19:33:21 +0500 X-Original-Message-ID: X-Original-References: <185024340.2308857.1661867906140.JavaMail.zimbra@synchrotron-soleil.fr> Xref: csiph.com linux.debian.maint.python:14405 --tGfEWZZ071cz/gQ8 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Aug 30, 2022 at 03:58:26PM +0200, PICCA Frederic-Emmanuel wrote: > Hello, I am packaging a python extension which use cmake as build system >=20 > here the repo >=20 > https://salsa.debian.org/science-team/dxtbx >=20 > I try to activate the test but this cause this kind of trouble >=20 > During handling of the above exception, another exception occurred: > /usr/lib/python3.10/importlib/__init__.py:126: in import_module > return _bootstrap._gcd_import(name[level:], package, level) > tests/serialize/test_xds.py:8: in > from dxtbx.imageset import ImageSetFactory > dxtbx/imageset.py:5: in > import dxtbx.format.image # noqa: F401, import dependency for unpick= ling > dxtbx/format/image.py:8: in > from dxtbx_format_image_ext import * # type: ignore # isort:skip # n= oqa: F403 > E ModuleNotFoundError: No module named 'dxtbx_format_image_ext' >=20 > Indeed the extension are build here. >=20 > cd /<>/obj-x86_64-linux-gnu/src/dxtbx && /usr/bin/cmake -E c= make_link_script CMakeFiles/dxtbx_flumpy.dir/link.txt --verbose=3D1 > /usr/bin/c++ -fPIC -g -O2 -ffile-prefix-map=3D/<>=3D. -fstac= k-protector-strong -Wformat -Werror=3Dformat-security -Wdate-time -D_FORTIF= Y_SOURCE=3D2 -flto -Wl,-z,relro -shared -o ../../lib/dxtbx_flumpy.cpython-= 310-x86_64-linux-gnu.so CMakeFiles/dxtbx_flumpy.dir/boost_python/flumpy.cc.= o /usr/lib/x86_64-linux-gnu/libboost_python310.so.1.74.0=20 > lto-wrapper: warning: using serial compilation of 4 LTRANS jobs > lto-wrapper: note: see the =E2=80=98-flto=E2=80=99 option documentation f= or more information > [ 90%] Linking CXX shared module ../../lib/dxtbx_format_image_ext.so >=20 > so I need to add the /<>/obj-x86_64-linux-gnu/lib directory = to the PYTHONPATH. >=20 > do you know how to do this ? Does the same happen when you run the test in the source tree manually? --=20 WBR, wRAR --tGfEWZZ071cz/gQ8 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJhBAABCgBLFiEEolIP6gqGcKZh3YxVM2L3AxpJkuEFAmMOH7EtFIAAAAAAFQAP cGthLWFkZHJlc3NAZ251cGcub3Jnd3JhckBkZWJpYW4ub3JnAAoJEDNi9wMaSZLh 5rEQAJy57PNbqGyiV5LwxyY7joDyJvpgvHwZU4plNyt10kob7Fj7hvSE97nePEoH TqgoFpC0+ca+VwDq9ApI/Z+dWpKyufx5zG6kGGqEG57Znue5U6Wve79mBVeMu8zh eau0VLU/BNWcF7bd5vua1rSyLcZ4D9G//e4Rp1Z+8/1Xm9Q0O+fYHcw7nl7FxapB bczkZ35akeSqMqVCOGXAzbxrhOBTzwRRhdQx98Z5+3AeGoqRML/jWLPackAX5Emp Av/r2zaJ+JOQcxXFigK7gusukk3Z+ldu3ZGxK1eq9hPoHVKDhzg2ht9rUbxchlOp WmbA1v2K/ULC+/SH18q5aoCG2/JOGp4Zx0KsABx6I91g8aB/reif3bjTaHd29azX XvAp7e10QLPNS3W7SJl4fd84OZrvh28iml+yNhd9jaFOEfHrBPk/NUngWTAGKwYR tbjo+1sag77E1aDc1vbnQ7q88534Xi/CG462CqBrtAY4Ox7yshnY5nwTJYzEJxky dKbScWW60ENXcWuVNq8VS2+HatP/z2ejDsYRBTB8wBcWSaXCtr3oRpg+LSArtdy2 iCjTK87uUcpRen2modvj47i3N3dwA587YGxv/2koZIR3agYXnsY+kLlpV6rhwb1i xqxxuV5QsooX/c0L+++4CRT1SVi/id9yYDRQCx/zXaIexRqN =SC3w -----END PGP SIGNATURE----- --tGfEWZZ071cz/gQ8--