summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* *.eclass: @ECLASS-VARIABLE renamed to @ECLASS_VARIABLEUlrich Müller2022-03-241-7/+7
| | | | | Bug: https://bugs.gentoo.org/835396 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* python-utils-r1.eclass: Support matching impls by stdlib versionMichał Górny2022-02-091-12/+6
| | | | | | | | | | | | | | Update _python_impl_matches() (used to implement python_gen*, python_setup) to support specifying stdlib versions ("3.8", "3.9") in addition to exact implementation names. This makes handling PyPy3 version changes much easier when dealing with backports. For example, if you specify "3.8", then the spec will match python3_8 and pypy3, for as long as we supply PyPy3.8. Once we upgrade to PyPy3.9 completely, it will stop matching pypy3 and we won't have to manually keep updating these deps. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Remove PYTHON_MULTI_USEDEPMichał Górny2022-02-091-7/+0
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Inline & simplify USE-deps in gen_cond_depMichał Górny2022-02-091-42/+3
| | | | | | | | | | | Generate simpler USE-deps inline in python_gen_cond_dep() and remove _python_gen_usedep(). The original code always repeated USE deps on all targets to aid Portage in giving better suggestions. However, since there always will be exactly one implementation selected, this is unnecessary and we can just have every cond-dep match exactly that one target. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* eclass: Update links to Gentoo Python GuideMichał Górny2022-01-291-1/+1
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python*-r1.eclass: Remove explicit dep on python-execMichał Górny2022-01-091-7/+1
| | | | | | | | The dev-lang/python-exec dependency is now enforced through dev-lang/python, remove the explicit dep to reduce the metadata size and make dependency resolution lighter. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Set @PROVIDESMichał Górny2021-09-021-0/+1
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Enable EAPI 8Michał Górny2021-06-231-2/+2
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Ban PYTHON_MULTI_USEDEP in EAPI 8Michał Górny2021-06-231-6/+6
| | | | | | | PYTHON_MULTI_USEDEP was a temporary transition measure, and is now equivalent to PYTHON_USEDEP. Ban it in EAPI 8 to clean up ebuilds. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Update doc for -2/-3 arg removalMichał Górny2021-06-231-20/+16
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Remove support for EAPIs prior to 6Michał Górny2021-04-091-4/+3
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Update examples to use BDEPENDMichał Górny2021-03-281-2/+2
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python*-r1.eclass: Check for invalid impl patternsMichał Górny2020-08-071-0/+4
| | | | | | | | | | | | | Check for invalid implementation patterns passed to python_gen* functions, python_setup, etc. Currently the functions silently ignore pattern mismatches which is fine for patterns matching historical implementations but also hides errors in patterns. After this change, each pattern must match at least one current or historical implementation. If no match is found, the function dies indicating developer's mistake. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Fix eclassdocMichał Górny2020-07-041-2/+8
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Allow using PYTHON_USEDEP againMichał Górny2020-04-141-8/+14
| | | | | | | | | Instead of requiring people to type PYTHON_MULTI_USEDEP, permit shorter form of PYTHON_USEDEP. This does not restore the old behavior but improves consistency between eclasses that was broken by python-single-r1 API changes. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-utils-r1.eclass: Mark python_export privateMichał Górny2020-03-221-4/+4
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-utils-r1.eclass: Make python_wrapper_setup privateMichał Górny2020-03-221-2/+2
| | | | | | | | This function was never meant to be a part of the public API. Correct the mistake by renaming it to _python_wrapper_setup(), and adding a QA warning under the old name. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Report impl used by python_setupMichał Górny2020-03-051-0/+2
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python*-r1.eclass, distutils-r1.eclass: Link to Python GuideMichał Górny2020-03-051-2/+2
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Remove unused PYTHON_TARGETSMichał Górny2020-02-101-27/+8
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Remove deprecated PYTHON_USEDEP APIMichał Górny2020-02-101-110/+16
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python*-r1.eclass: Update examples for virtual/pypy removalMichał Górny2019-12-301-1/+1
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Revert "Remove deprecated PYTHON_USEDEP..."Michał Górny2019-12-071-13/+109
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Revert "Remove unused PYTHON_TARGETS"Michał Górny2019-12-071-8/+27
| | | | | | Pushed too many commits. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Remove unused PYTHON_TARGETSMichał Górny2019-12-071-27/+8
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Remove deprecated PYTHON_USEDEP APIMichał Górny2019-12-071-109/+13
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Use new-style flags for python-exec depMichał Górny2019-12-071-7/+8
| | | | | | | Depend on PYTHON_TARGETS directly in dev-lang/python-exec dep, instead of relying on old-style PYTHON_USEDEP. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Introduce PYTHON_{SINGLE,MULTI}_USEDEP APIMichał Górny2019-12-071-16/+93
| | | | | | | | | | | | | Introduce a new API that replaces PYTHON_USEDEP with PYTHON_SINGLE_USEDEP variable and PYTHON_MULTI_USEDEP placeholder. The former can be used directly (or via python_gen_cond_dep) when depending on other python-single-r1 packages, the latter can be used via python_gen_cond_dep when depending on python-r1 packages. Long term, the new API will enable us to remove redundant PYTHON_TARGETS flags from python-single-r1 packages. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python*r1.eclass: Remove python-exec:0 leftoverMichał Górny2019-12-071-5/+1
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python*r1.eclass: Reliably allow empty <pattern>s to gen funcsMichał Górny2019-12-071-5/+4
| | | | | | | | | Reliably allow empty pattern lists (equivalent to no restrictions) in all pattern-based generator functions, notably python_gen_cond_dep. Previously, only some of the functions accepted them while others failed via _python_impl_matches function. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: Restore PYTHON_SINGLE_TARGET for one implMichał Górny2019-12-071-94/+49
| | | | | | | | | | | | | | Undo the hack that removes PYTHON_SINGLE_TARGET (in favor of plain PYTHON_TARGETS) when the package supports only one target. Instead, output both kinds of flags consistently for all packages, and use IUSE defaults to enable them when only one interpreter is supported. This should give similar end results without creating unnecessary differences between ebuilds with one and multiple implementations. It will make future API changes easier, as well as simplify tooling used to detect eclass type. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python*-r1.eclass: Deprecate python_gen_usedepMichał Górny2019-12-071-16/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | Deprecate python_gen_usedep() in favor of python_gen_cond_dep(). The latter is a newer API that generates full USE-conditional blocks rather than pure USE-dependency strings. As such, it can replace all uses of the former, and is safer to use in general. In particular: dev-python/foo[$(python_gen_usedep -2)] dev-python/bar[$(python_gen_usedep -2)] installs the dependency (with no implementation match enforced) even if there's no python2 implementation enabled, while: $(python_gen_cond_dep ' dev-python/foo[${PYTHON_USEDEP}] dev-python/bar[${PYTHON_USEDEP}] ' -2) installs it only if there's at least one implementation requiring it. Since the functions are used in global scope only, a deprecation warning is emitted only once, during the sourcing for pkg_setup phase. This avoids having it output during metadata cache regeneration. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* python-single-r1.eclass: add @SUPPORTED_EAPISMichał Górny2018-08-151-0/+1
|
* python-single-r1.eclass: Enable EAPI 7 (no changes)Michał Górny2018-05-071-2/+2
|
* python-single-r1.eclass: Document new pattern supportMichał Górny2017-05-161-2/+23
|
* python-single-r1.eclass: python_gen_impl_dep, use _python_impl_matches()Michał Górny2017-05-161-8/+5
|
* python-single-r1.eclass: python_gen_cond_dep, use _python_impl_matches()Michał Górny2017-05-161-15/+11
|
* python-single-r1.eclass: python_gen_useflags, use _python_impl_matches()Michał Górny2017-05-161-8/+4
|
* python-single-r1.eclass: python_gen_usedep, use _python_impl_matches()Michał Górny2017-05-161-11/+7
|
* python-single-r1.eclass: Add integrity checks for globalsMichał Górny2017-03-081-6/+30
|
* python-single-r1.eclass: Refactor global setter to use locals, NFCMichał Górny2017-03-081-8/+12
|
* python-single-r1.eclass: Remove stale EAPI=4 branch in globalsMichał Górny2017-03-081-6/+2
|
* Drop $Id$ per council decision in bug #611234.Robin H. Johnson2017-02-281-1/+0
| | | | Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
* python-single-r1.eclass: Always output use-cond in PYTHON_DEPSMichał Górny2017-02-191-1/+1
| | | | | | | | Output a USE conditional in PYTHON_DEPS even when using only a single target. While this does not make a strict difference since the target flag is in REQUIRED_USE anyway, it results in more unified output and makes it easier to catch mistakes if someone plays with the eclass in the future.
* python-single-r1.eclass: Remove EAPI=4 exceptionsMichał Górny2017-02-171-21/+1
|
* python-single-r1.eclass: drop stray '}' in example docstringSergei Trofimovich2016-11-051-1/+1
|
* python-single-r1.eclass: Add python_gen_impl_dep, alike in python-r1Michał Górny2015-12-311-0/+58
|
* python-single-r1.eclass: Support PYTHON_COMPAT_OVERRIDEMichał Górny2015-12-221-0/+36
|
* python-single-r1.eclass: Fix python_gen_* w/ single PYTHON_COMPAT implMichał Górny2015-12-221-4/+16
| | | | | | | Fix python_gen_useflags() and python_gen_cond_dep() to output correct flag name when only a single implementation is listed in PYTHON_COMPAT. In this case, the PYTHON_SINGLE_TARGET flags are not emitted and PYTHON_TARGETS are used directly instead.
* python*-r1.eclass: Commonize PYTHON_COMPAT processing, cache the resultMichał Górny2015-12-221-44/+17
| | | | | | | | | Introduce a common _python_set_impls function in python-utils-r1.eclass that validates and processes PYTHON_COMPAT, then stores the result in _PYTHON_SUPPORTED_IMPLS and _PYTHON_UNSUPPORTED_IMPLS variables. Reuse those variables in all python-r1 suite eclasses, effectively reducing code duplication and providing cache for repeated implementation support checks.