diff options
author | Denis THULIN <denis.thulin@openwide.fr> | 2016-05-31 17:03:41 +0200 |
---|---|---|
committer | Thomas Petazzoni <thomas.petazzoni@free-electrons.com> | 2016-06-11 16:13:31 +0200 |
commit | 1008ac4406a5544ec87985db880e68377031bca9 (patch) | |
tree | 2f552698ede31d0257f34774c44e05b283d9598f /docs/manual | |
parent | 7225917f9b587eec6cd30920839a08612ea52bcf (diff) | |
download | buildroot-1008ac4406a5544ec87985db880e68377031bca9.tar.gz buildroot-1008ac4406a5544ec87985db880e68377031bca9.zip |
scanpypi: new utility
A utility for creating python package from the python package index.
It fetches packages info from http://pypi.python.org and generates
corresponding packages files.
Signed-off-by: Denis THULIN <denis.thulin@openwide.fr>
Tested-by: Carlos Santos <casantos@datacom.ind.br>
Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
[Thomas: minor tweaks.]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'docs/manual')
-rw-r--r-- | docs/manual/adding-packages-python.txt | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/docs/manual/adding-packages-python.txt b/docs/manual/adding-packages-python.txt index 9bbc9f3682..94ac809fff 100644 --- a/docs/manual/adding-packages-python.txt +++ b/docs/manual/adding-packages-python.txt @@ -161,6 +161,55 @@ possible to customize what is done in any particular step: default Python one. However, using this method should be restricted to very specific cases. Do not use it in the general case. +[[scanpypi]] + +==== Generating a +python-package+ from a PyPI repository + +If the Python package for which you would like to create a Buildroot +package is available on PyPI, you may want to use the +scanpypi+ tool +located in +support/scripts+ to automate the process. + +You can find the list of existing PyPI packages +https://pypi.python.org[here]. + ++scanpypi+ requires Python's +setuptools+ package to be installed on +your host. + +When at the root of your buildroot directory just do : + +----------------------- +./support/script/scanpypi foo bar -o package +----------------------- + +This will generate packages +python-foo+ and +python-bar+ in the package +folder if they exist on https://pypi.python.org. + +Find the +external python modules+ menu and insert your package inside. +Keep in mind that the items inside a menu should be in alphabetical order. + +Please keep in mind that you'll most likely have to manually check the +package for any mistakes as there are things that cannot be guessed by +the generator (e.g. dependencies on any of the python core modules +such as BR2_PACKAGE_PYTHON_ZLIB). Also, please take note that the +license and license files are guessed and must be checked. You also +need to manually add the package to the +package/Config.in+ file. + +If your Buildroot package is not in the official Buildroot tree but in +a +BR2_EXTERNAL+ tree, use the -o flag as follows: + +----------------------- +./support/script/scanpypi foo bar -o other_package_dir +----------------------- + +This will generate packages +python-foo+ and +python-bar+ in the ++other_package_directory+ instead of +package+. + +Option +-h+ will list the available options: + +----------------------- +./support/script/scanpypi -h +----------------------- + [[python-package-cffi-backend]] ==== +python-package+ CFFI backend |