You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The logic of installation of Python bindings for some subprojects is inherently fragile. The superbuild computes the installation location of python bindings in
), however for some others we just rely on the fact that the subprojets also compute their python installation directory via from distutils import sysconfig; print(sysconfig.get_python_lib(1,0,prefix='')). However, this is fragile as the, for example, the directory returned by this code is different depending on whater we are running the code in the system python environment or in a virtual environment. We already had users realllllly confused by this.
A better alternative is to use a strategy similar to the one that we used for casadi.
The text was updated successfully, but these errors were encountered:
traversaro
changed the title
Python bindings installation logic is fragile
Handling of the installation directory of some python subprojects fragile
Mar 17, 2023
The logic of installation of Python bindings for some subprojects is inherently fragile. The superbuild computes the installation location of python bindings in
robotology-superbuild/CMakeLists.txt
Line 39 in 3d587be
Then, for some subprojects we explicitly set that the python installation should be the one that we set (for example casadi
robotology-superbuild/cmake/Buildcasadi.cmake
Line 33 in 3d587be
from distutils import sysconfig; print(sysconfig.get_python_lib(1,0,prefix=''))
. However, this is fragile as the, for example, the directory returned by this code is different depending on whater we are running the code in the system python environment or in a virtual environment. We already had users realllllly confused by this.A better alternative is to use a strategy similar to the one that we used for casadi.
fyi @LoreMoretti
The text was updated successfully, but these errors were encountered: