From: Julien Stephan <jstephan@baylibre.com>
To: openembedded-core@lists.openembedded.org
Cc: Julien Stephan <jstephan@baylibre.com>
Subject: [PATCH 0/7] Devtool/Recipetool: adding pypi support
Date: Fri, 17 Nov 2023 12:12:11 +0100 [thread overview]
Message-ID: <20231117111218.3344066-1-jstephan@baylibre.com> (raw)
Hello all,
This series adds basic support for the pypi class in devtool/recipetool.
The idea is to be able to detect that a package is available on pypi and
in that case inherits from pypi class. This helps to produce cleaner
recipes for pypi packages.
To do this, I am adding a new optional callback "process_url" that
plugin can register to implement some logic on matching url.
By implementing this callback in create_buildsys_python we can match on
pypi URLs directly or on release tarballs hosted on "files.pythonhosted.org".
To create a recipe taking advantage of the pypi class we can use one of the
following new syntax:
* recipetool create https://pypi.org/project/<package>
* recipetool create https://pypi.org/project/<package>/<version>
* recipetool create https://pypi.org/project/<package> --version <version>
or the old syntax:
* recipetool create https://files.pythonhosted.org/packages/<...>
If the URL points to a github URL or a release tarball not coming from
"files.pythonhosted.org", the created recipe is the same as before.
One can also use the newly added "--no-pypi" switch to NOT inherit
from pypi class on matching URL, to keep legacy behaviour.
This series also contains some bug fixes I found during my testing.
Pushed my dev branch here: https://git.yoctoproject.org/poky-contrib/log/?h=jstephan/devtool-add-pypi-support
Cheers
Julien
Julien Stephan (7):
bitbake: utils: remove spaces on empty lines
recipetool: create_buildsys_python.py: initialize metadata
recipetool: create: add trailing newlines
recipetool: create: add new optional process_url callback for plugins
recipetool: create_buildsys_python: add pypi support
oeqa/selftest/recipetool: remove spaces on empty lines
oeqa/selftest/recipetool/devtool: add test for pypi class
bitbake/lib/bb/utils.py | 16 +--
meta/lib/oeqa/selftest/cases/devtool.py | 4 +-
meta/lib/oeqa/selftest/cases/recipetool.py | 114 +++++++++++++-----
scripts/lib/devtool/standard.py | 3 +
scripts/lib/recipetool/create.py | 63 ++++++----
.../lib/recipetool/create_buildsys_python.py | 73 +++++++++++
6 files changed, 208 insertions(+), 65 deletions(-)
--
2.42.0
next reply other threads:[~2023-11-17 11:12 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-17 11:12 Julien Stephan [this message]
2023-11-17 11:12 ` [PATCH 1/7] bitbake: utils: remove spaces on empty lines Julien Stephan
2023-11-17 11:12 ` [PATCH 2/7] recipetool: create_buildsys_python.py: initialize metadata Julien Stephan
2023-11-17 11:12 ` [PATCH 3/7] recipetool: create: add trailing newlines Julien Stephan
2023-11-17 11:12 ` [PATCH 4/7] recipetool: create: add new optional process_url callback for plugins Julien Stephan
2023-11-17 11:12 ` [PATCH 5/7] recipetool: create_buildsys_python: add pypi support Julien Stephan
2023-11-17 11:12 ` [PATCH 6/7] oeqa/selftest/recipetool: remove spaces on empty lines Julien Stephan
2023-11-17 11:12 ` [PATCH 7/7] oeqa/selftest/recipetool/devtool: add test for pypi class Julien Stephan
2023-11-18 10:10 ` [OE-core] [PATCH 0/7] Devtool/Recipetool: adding pypi support Alexandre Belloni
[not found] ` <1798AFE6117EC794.26894@lists.openembedded.org>
2023-11-18 13:48 ` Alexandre Belloni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20231117111218.3344066-1-jstephan@baylibre.com \
--to=jstephan@baylibre.com \
--cc=openembedded-core@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox