-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
python: Fix python-install on windows
- Loading branch information
Showing
1 changed file
with
5 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
72db8e5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This extraneous quoting breaks install on Linux, it creates paths like:
/home/abuild/rpmbuild/BUILD/or-tools-9.9/build/python/'/home/abuild/rpmbuild/BUILDROOT/google-or-tools-9.9-0.x86_64'/"/usr"/lib64/python3.11/site-packages/ortools-9.9.9999-py3.11.egg-info/PKG-INFO
The correct path would be
/home/abuild/rpmbuild/BUILDROOT/google-or-tools-9.9-0.x86_64/usr/lib64/python3.11/site-packages/ortools-9.9.9999-py3.11.egg-info/PKG-INFO
As one can see, both the single quote from the (absolute) DESTDIR is taken verbatim, making the path relative for setup.py (it starts with
'/...
, not/...
) so the CWD is prepended, and the prefix is also quoted.Suggestions:
execute_process
invocationThis is the current command line executed:
'/usr/bin/python3.11' 'setup.py' 'install' '--root='/home/abuild/rpmbuild/BUILDROOT/google-or-tools-9.9-0.x86_64'' '--prefix="/usr"'