1 |
commit: c6f51f5dc2fe040900180ae160d6b1e0985f17b9 |
2 |
Author: Michał Górny <mgorny <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Jan 27 14:51:37 2021 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Jan 27 15:10:03 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c6f51f5d |
7 |
|
8 |
dev-lang/python: Readd check for failed semaphore checks in 3.7+ |
9 |
|
10 |
Reintroduce the check for failing semaphore checks that result in broken |
11 |
multiprocessing in Python. This check has been mistakenly removed |
12 |
while removing support for USE=-threads. |
13 |
|
14 |
Closes: https://bugs.gentoo.org/496328 |
15 |
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> |
16 |
|
17 |
dev-lang/python/python-3.7.9-r2.ebuild | 6 ++++++ |
18 |
dev-lang/python/python-3.8.7-r1.ebuild | 6 ++++++ |
19 |
dev-lang/python/python-3.9.1-r1.ebuild | 6 ++++++ |
20 |
3 files changed, 18 insertions(+) |
21 |
|
22 |
diff --git a/dev-lang/python/python-3.7.9-r2.ebuild b/dev-lang/python/python-3.7.9-r2.ebuild |
23 |
index 2311ff2ac1b..e40f7af712b 100644 |
24 |
--- a/dev-lang/python/python-3.7.9-r2.ebuild |
25 |
+++ b/dev-lang/python/python-3.7.9-r2.ebuild |
26 |
@@ -167,6 +167,12 @@ src_configure() { |
27 |
) |
28 |
|
29 |
OPT="" econf "${myeconfargs[@]}" |
30 |
+ |
31 |
+ if grep -q "#define POSIX_SEMAPHORES_NOT_ENABLED 1" pyconfig.h; then |
32 |
+ eerror "configure has detected that the sem_open function is broken." |
33 |
+ eerror "Please ensure that /dev/shm is mounted as a tmpfs with mode 1777." |
34 |
+ die "Broken sem_open function (bug 496328)" |
35 |
+ fi |
36 |
} |
37 |
|
38 |
src_compile() { |
39 |
|
40 |
diff --git a/dev-lang/python/python-3.8.7-r1.ebuild b/dev-lang/python/python-3.8.7-r1.ebuild |
41 |
index af74b94b479..2aee3c92285 100644 |
42 |
--- a/dev-lang/python/python-3.8.7-r1.ebuild |
43 |
+++ b/dev-lang/python/python-3.8.7-r1.ebuild |
44 |
@@ -173,6 +173,12 @@ src_configure() { |
45 |
) |
46 |
|
47 |
OPT="" econf "${myeconfargs[@]}" |
48 |
+ |
49 |
+ if grep -q "#define POSIX_SEMAPHORES_NOT_ENABLED 1" pyconfig.h; then |
50 |
+ eerror "configure has detected that the sem_open function is broken." |
51 |
+ eerror "Please ensure that /dev/shm is mounted as a tmpfs with mode 1777." |
52 |
+ die "Broken sem_open function (bug 496328)" |
53 |
+ fi |
54 |
} |
55 |
|
56 |
src_compile() { |
57 |
|
58 |
diff --git a/dev-lang/python/python-3.9.1-r1.ebuild b/dev-lang/python/python-3.9.1-r1.ebuild |
59 |
index 5dbe3f9ffb9..250c0d4af54 100644 |
60 |
--- a/dev-lang/python/python-3.9.1-r1.ebuild |
61 |
+++ b/dev-lang/python/python-3.9.1-r1.ebuild |
62 |
@@ -184,6 +184,12 @@ src_configure() { |
63 |
) |
64 |
|
65 |
OPT="" econf "${myeconfargs[@]}" |
66 |
+ |
67 |
+ if grep -q "#define POSIX_SEMAPHORES_NOT_ENABLED 1" pyconfig.h; then |
68 |
+ eerror "configure has detected that the sem_open function is broken." |
69 |
+ eerror "Please ensure that /dev/shm is mounted as a tmpfs with mode 1777." |
70 |
+ die "Broken sem_open function (bug 496328)" |
71 |
+ fi |
72 |
} |
73 |
|
74 |
src_compile() { |