1 |
On Sun, 15 May 2016 11:30:00 +0200 |
2 |
Michał Górny <mgorny@g.o> wrote: |
3 |
|
4 |
> Do not apply PATCHES and user patches (either via the EAPI 6 default or |
5 |
> pre-EAPI 5 code) when DISTUTILS_OPTIONAL is being used. In this case, |
6 |
> distutils functions are usually called conditionally, in a subdirectory, |
7 |
> while both PATCHES and user patches are usually intended to be applied |
8 |
> top-level. |
9 |
> |
10 |
> There is no ebuild relying on distutils-r1_src_prepare applying patches |
11 |
> with DISTUTILS_OPTIONAL. In fact, there are ebuilds which work around |
12 |
> this behavior. |
13 |
> --- |
14 |
> eclass/distutils-r1.eclass | 12 +++++++----- |
15 |
> 1 file changed, 7 insertions(+), 5 deletions(-) |
16 |
> |
17 |
> diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass |
18 |
> index e8de5ad..afd29ed 100644 |
19 |
> --- a/eclass/distutils-r1.eclass |
20 |
> +++ b/eclass/distutils-r1.eclass |
21 |
> @@ -315,11 +315,13 @@ _distutils-r1_disable_ez_setup() { |
22 |
> distutils-r1_python_prepare_all() { |
23 |
> debug-print-function ${FUNCNAME} "${@}" |
24 |
> |
25 |
> - if [[ ${EAPI} != [45] ]]; then |
26 |
> - default |
27 |
> - else |
28 |
> - [[ ${PATCHES} ]] && epatch "${PATCHES[@]}" |
29 |
> - epatch_user |
30 |
> + if [[ ! ${DISTUTILS_OPTIONAL} ]]; then |
31 |
> + if [[ ${EAPI} != [45] ]]; then |
32 |
> + default |
33 |
> + else |
34 |
> + [[ ${PATCHES} ]] && epatch "${PATCHES[@]}" |
35 |
> + epatch_user |
36 |
> + fi |
37 |
> fi |
38 |
> |
39 |
> # by default, use in-source build if python_prepare() is used |
40 |
|
41 |
Merged. |
42 |
|
43 |
-- |
44 |
Best regards, |
45 |
Michał Górny |
46 |
<http://dev.gentoo.org/~mgorny/> |