This is liable to change in the future.
These prebuilt libraries can either be whl files or eggs
whls for most packages are available for download from PyPI. The whl used may be downloaded with
remote_file. However, Buck does not attempt to infer dependency information from pip, so that information will have to be imparted by the user.
To create an egg for a package, run
python setup.py bdist_egg in the package source distribution.
The short name for this build target.
The path to the
.eggto use. Note:
.eggfiles have a very particular naming convention that must be followed - otherwise pex will not find the dependency properly at runtime!
prebuilt_python_library()rules which this library depends on. These may also be
python_libraryrules if you want to depend on a source-based copy of the library.
List of build target patterns that identify the build rules that can include this rule as a dependency, for example, by listing it in their
exported_depsattributes. For more information, see visibility.
# A simple prebuilt_python_library with no external dependencies. remote_file( name = "requests-download", url = "https://files.pythonhosted.org/packages/51/bd/23c926cd341ea6b7dd0b2a00aba99ae0f828be89d72b2190f27c11d4b7fb/requests-2.22.0-py2.py3-none-any.whl", sha1 = "e1fc28120002395fe1f2da9aacea4e15a449d9ee", out = "requests-2.22.0-py2.py3-none-any.whl", ) prebuilt_python_library( name = "requests", binary_src = ":requests-download", ) # A slightly more complex example prebuilt_python_library( name = "greenlet", binary_src = "greenlet-0.4.7-py2.7-macosx-10.10-x86_64.egg", ) prebuilt_python_library( name = "gevent", binary_src = "gevent-1.0.2-py2.7-macosx-10.10-x86_64.egg", deps = [ ":greenlet", ], )