summaryrefslogtreecommitdiffstats
path: root/meta/classes/setuptools3.bbclass
AgeCommit message (Collapse)Author
2022-08-12classes: Update classes to match new bitbake class scope functionalityRichard Purdie
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>
2022-08-12classes: Add SPDX license identifiersRichard Purdie
As stated in our top level license files, the license is MIT unless otherwise stated. Add SPDX identifers accordingly. Replace older license statementa with the standardised syntax. Also drop "All Rights Reserved" expression as it isn't used now, doesn't mean anything and is confusing. (From OE-Core rev: 081a391fe09a21265881e39a2a496e4e10b4f80b) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-08-12classes: Add copyright statements to files without oneRichard Purdie
Where there isn't a copyright statement, add one to make it explicit. Also drop editor config lines where they were present. (From OE-Core rev: 880c1ea3edc8edef974e65b2d424fc36809ea034) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-05-29setuptools3: clean up classRoss Burton
Remove a commented-out B, re-order DEPENDS< and add comments. (From OE-Core rev: 046db6d8bbcad3962a9585ef7ebd10d428953ccb) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-03-13meta: rename pip_install_wheel.bbclass to python_pep517.bbclassRoss Burton
pip_install_wheel shouldn't restricted to just using Pip to install wheels (the installer module is simplier and likely a better option), and in the future may be extended to also provide do_compile() using the build module. (From OE-Core rev: 3bdf64b97facce9706cc579bdbc9a80e0d48428f) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-03-09setuptools3: respect PIP_INSTALL_DIST_PATHRoss Burton
pip_install_wheel expects the wheels to be in PIP_INSTALL_DIST_PATH but this class was writing to the same directory through chance not design. Respect PIP_INSTALL_DIST_PATH as the output directory. (From OE-Core rev: 12857a77ad424c3c3cbc37275374a603e528d9f1) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-03-08setuptools3.bbclass: clean upRoss Burton
There's been a lot of work in this class lately, so a little spring cleaning is needed. Create wheels verbosely to help debug problems. Remove unused SETUPTOOLS_INSTALL_ARGS, these can't be passed to bdist_wheel. Remove duplicate manipulation of files in bindir as pip_install_wheel does the same. Remove obsolete deletion of easy-install.pth, wheels don't generate that. Remove obsolete ${datadir}/share fixup, pip-installed wheels can't generate that path combination. Remove purging of ${D} references from *.py, these won't be written by standard setuptools, and recipes can do it themselves to work around specific issues if needed. Remove obsolete vardepsexclude of MACHINE on do_install, as that variable isn't referenced. (From OE-Core rev: 57c477ca13e352b6f9b21385abbfaad9778c6398) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-03-02pip_install_wheel: improve wheel handlingKonrad Weihmann
- replace python3 prefix when guessing the wheel name as there are still plenty of recipes out there that do use python3 prefixes - remove all previously generated wheels matching the glob to avoid installing any outdated blob via cleandirs in setuptools3 class. Unfortunetaly proposed dist-dir or bdist-dir are not respected by setuptools, likely due because they are overridable by the setup script - don't use PV in glob, as PV doesn't necessarily align with the version used inside of the setuptools configuration. this will avoid having the user set PYPA_WHEEL in a lot of recipes - respect SETUPTOOLS_SETUP_PATH in PIP_INSTALL_DIST_PATH and use B as a fallback only (in case this class is inherited without setuptools3 class being there as well). recipes like python3-smbus run in a subfolder of the workspace and were failing in before this adjustment (From OE-Core rev: 6f2d85a7b7d94101f2ce67115166fa86c185650f) Signed-off-by: Konrad Weihmann <kweihmann@outlook.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-02-25setuptools3.bbclass: refactor for wheelsTim Orling
Depend on python3-wheel-native so that we can build with 'setup.py bdist_wheel'. Use pip_install_wheel class to install the built wheels with pip, as intended by upstream Python. [YOCTO #14638] (From OE-Core rev: 8b39c0bc535814e04d01d50a4891cb31b6bf84bd) Signed-off-by: Tim Orling <tim.orling@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-01-12setuptools3: refactor for no distutils bbclassesTim Orling
Add setuptools3-base.bbclass as a re-usable starting point similar to what used to be distutils-common-base.bbclass and disutils3-base.bbclass. We no longer need to support python2, so no need for a setuptools-common-base.bbclass. Refactor setuptools3.bbclass to use setuptools3-base.bbclass instead of the distulis*.bbclasses. (From OE-Core rev: ca73393a36c4144662ea8570f904154188e9815a) Signed-off-by: Tim Orling <tim.orling@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-07-26distutils/setuptools, distutils3/setuptools3: improve reproducibilityHongxu Jia
- Unify var-DISTUTILS_INSTALL_ARGS in distutils and setuptools - Supply "--root" directory to the "install" command, and use it as a prefix to strip off the purported filename encoded in bytecode files. (It strips build path prefix from .pyc files) [YOCTO #8446] [YOCTO #12084] (From OE-Core rev: 21f0c5a50e00ac34975d79fd48f08730d8f19b15) Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-06-08python3-distribute: Upgrade to python3-setuptools 15.2Alejandro Hernandez
python3-distribute was merged back to python3-setuptools in 2013, and it is no longer being maintained, this upgrade also provides functionality that will be needed for python3-pip. [YOCTO #7763] (From OE-Core rev: 8922e609cb947e34cde6e48b82ff37a932d8d8db) Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-02-02classes: Add distutils for python3Khem Raj
In line with python2 add distutils and setuptools classes for handing python3 Use python-distribute instead of python-setuptools in setuptools bbclass Remove --single-version-externally-managed since its setuptools specific and we dont use it anymore Do build_ext as separate step during compile Add DISTUTILS_BUILD_EXT_ARGS for modules to pass flags to build_ext step in setup.py Add build_ext as sepate step during compile and add the cross sysrooted library and headers since we are cross compiling Use ${PYTHON_PN} in place of hardcoding python name Remove the /etc/share if its empty Since OE-Core times we now have machine specific sysroots for targets unlike before when we used arch specific sysroots so reflect that here Use MACHINE for sysroot when not building for build host Python's machinery replaces directories in sysroot path to match OE's staging area sysroots. Earlier we use to have HOST_SYS represent sysroot always but now we use MACHINE to represent target sysroots but HOST_SYS to represent host sysroot. This patch caters to that difference (From OE-Core rev: 8bb0206ed67228c88dd5bc2d8b36ce28f48b78f4) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>