On Tue, Oct 24, 2023 at 5:18 PM Sandro Mani <manisan...@gmail.com> wrote:
>
> Hi
>
> Since some time, Fedora's cmake FindPython will return 
> Python_SITEARCH=/usr/local/lib64/pythonX.Y/site-packages, which results in 
> possible failure to find python libraries below the system site packages dir 
> (aka shipped by RPMs). A workaround(?) is to call
>
> EXECUTE_PROCESS(COMMAND ${Python_EXECUTABLE} -c "import 
> sysconfig;print(sysconfig.get_path(\"platlib\", \"rpm_prefix\"), end=\"\")" 
> OUTPUT_VARIABLE Python_SITEARCH)
>
> and such workarounds are starting to appear in applications [1]. Any opinions 
> on whether this is indeed the best way to handle the issue, whether Fedoras 
> FindPython needs fixing, or whether there already is a cleaner solution?
>

This needs to be fixed in FindPython.cmake to detect whether cmake is
running in a package build environment to get the correct path.



-- 
真実はいつも一つ!/ Always, there's only one truth!
_______________________________________________
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to