Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: gentoo-dev@l.g.o
Cc: "Michał Górny" <mgorny@g.o>
Subject: [gentoo-dev] [PATCH 2/3] distutils-r1.eclass: Run build_ext only with --jobs -gt 1
Date: Fri, 22 Apr 2022 07:50:49
Message-Id: 20220422075032.646637-2-mgorny@gentoo.org
In Reply to: [gentoo-dev] [PATCH 1/3] distutils-r1.eclass: Run build_ext only if there are 2+ files by "Michał Górny"
1 Signed-off-by: Michał Górny <mgorny@g.o>
2 ---
3 eclass/distutils-r1.eclass | 2 +-
4 1 file changed, 1 insertion(+), 1 deletion(-)
5
6 diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass
7 index d213cca4bb72..c314c52a78cd 100644
8 --- a/eclass/distutils-r1.eclass
9 +++ b/eclass/distutils-r1.eclass
10 @@ -1196,7 +1196,7 @@ distutils-r1_python_compile() {
11 #
12 # see extension.py for list of suffixes
13 # .pyx is added for Cython
14 - if [[ 2 -eq $(
15 + if [[ 1 -ne ${jobs} && 2 -eq $(
16 find '(' -name '*.c' -o -name '*.cc' -o -name '*.cpp' \
17 -o -name '*.cxx' -o -name '*.c++' -o -name '*.m' \
18 -o -name '*.mm' -o -name '*.pyx' ')' -printf '\n' |
19 --
20 2.35.1