diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-08-10 14:35:29 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-08-12 15:27:17 +0100 |
commit | fd1517e2b51a170f2427122c6b95396db251d827 (patch) | |
tree | dabfe3e631339c2fc99a9ee7febb0f9c128e325e /meta/classes-recipe/setuptools3.bbclass | |
parent | 10317912ee319ccf7f83605d438b5cbf9663f296 (diff) | |
download | poky-fd1517e2b51a170f2427122c6b95396db251d827.tar.gz |
classes: Update classes to match new bitbake class scope functionality
Move classes to classes-global or classes-recipe as appropriate to take
advantage of new bitbake functionality to check class scope/usage.
(From OE-Core rev: f5c128008365e141082c129417eb72d2751e8045)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes-recipe/setuptools3.bbclass')
-rw-r--r-- | meta/classes-recipe/setuptools3.bbclass | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/meta/classes-recipe/setuptools3.bbclass b/meta/classes-recipe/setuptools3.bbclass new file mode 100644 index 0000000000..4c6e79ee9a --- /dev/null +++ b/meta/classes-recipe/setuptools3.bbclass | |||
@@ -0,0 +1,38 @@ | |||
1 | # | ||
2 | # Copyright OpenEmbedded Contributors | ||
3 | # | ||
4 | # SPDX-License-Identifier: MIT | ||
5 | # | ||
6 | |||
7 | inherit setuptools3-base python_pep517 | ||
8 | |||
9 | DEPENDS += "python3-setuptools-native python3-wheel-native" | ||
10 | |||
11 | SETUPTOOLS_BUILD_ARGS ?= "" | ||
12 | |||
13 | SETUPTOOLS_SETUP_PATH ?= "${S}" | ||
14 | |||
15 | setuptools3_do_configure() { | ||
16 | : | ||
17 | } | ||
18 | |||
19 | setuptools3_do_compile() { | ||
20 | cd ${SETUPTOOLS_SETUP_PATH} | ||
21 | NO_FETCH_BUILD=1 \ | ||
22 | STAGING_INCDIR=${STAGING_INCDIR} \ | ||
23 | STAGING_LIBDIR=${STAGING_LIBDIR} \ | ||
24 | ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py \ | ||
25 | bdist_wheel --verbose --dist-dir ${PEP517_WHEEL_PATH} ${SETUPTOOLS_BUILD_ARGS} || \ | ||
26 | bbfatal_log "'${PYTHON_PN} setup.py bdist_wheel ${SETUPTOOLS_BUILD_ARGS}' execution failed." | ||
27 | } | ||
28 | setuptools3_do_compile[vardepsexclude] = "MACHINE" | ||
29 | do_compile[cleandirs] += "${PEP517_WHEEL_PATH}" | ||
30 | |||
31 | # This could be removed in the future but some recipes in meta-oe still use it | ||
32 | setuptools3_do_install() { | ||
33 | python_pep517_do_install | ||
34 | } | ||
35 | |||
36 | EXPORT_FUNCTIONS do_configure do_compile do_install | ||
37 | |||
38 | export LDSHARED="${CCLD} -shared" | ||