Add Support for pip's --platform, --no-binary, & --only-binary options#33
Add Support for pip's --platform, --no-binary, & --only-binary options#33MLBZ521 wants to merge 5 commits intogregneagle:mainfrom
pip's --platform, --no-binary, & --only-binary options#33Conversation
|
Can all that complexity not just go into the requirements file? Have you found out what versions of pip support all of these options? |
|
From the research I've done, any conditionals that are applied in the requirements file are applied to the system that is current running pip. Where I'm trying to build a relocatable Python Framework that is system agnostic (at least, for macOS). Example:
This creates an issue if trying to deploy at single relocatable framework Obviously a work around would be to simply create two different relocatable frameworks; one Intel based and one ARM based, but if Universal wheel binaries exist, this does allow for a single "universal" relocatable framework. |
|
Regarding what versions of From the
|
|
I feel like I'm missing something here, since the Munki pkg build script uses make_relocatable_python_framework.py to build a Universal framework, and pretty sure Autopkg does as well. |
|
The requirements file the Munki pkg build script uses is here: https://github.com/munki/munki/blob/main/code/tools/py3_requirements.txt and uses You can see how |
|
Ah, ok... So a couple things:
I think that clears some things up. I guess it just depends on which approach you wanted to take? |
|
Well, I dunno. I've tried the Example: Even though cryptography built wheel is labeled But if I do: I get the desired results: I've tried different combinations of things, including a different version of |
This feature allows the user to specify additional
pipoptions to filter against when installing libraries.Particularly, I ran into an issue where I was wanting to build a "Universal" relocatable Python.Framework, but
pipwill natively install the a matching architecture wheel if available, even if a universal build is available.With the support for these three options, I also included the ability to pass multiple values for each option (which
pipsupports), butoptparsedoes not, so a callback function was added inlocallibs/__init__.pyto support this.Example usage would be: