1 |
commit: 618de7feba4b2063ee29bca02c413125022bf95d |
2 |
Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Aug 20 22:34:52 2020 +0000 |
4 |
Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Aug 20 22:48:53 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=618de7fe |
7 |
|
8 |
toolchain.eclass: always enable --with-long-double-128 for glibc targets |
9 |
|
10 |
Unless overridden glibc enables 128-bit 'long double' for |
11 |
glibc 2.4 and above. But with crossdev change 7283a01 |
12 |
("set --without-headers by default") we don't install any |
13 |
headers for stage1-gcc. As a result gcc pessimistically |
14 |
disables 128-bit 'long double'. |
15 |
|
16 |
The change enables --with-long-double-128 for glibc targets |
17 |
for stage1-gcc. |
18 |
|
19 |
Reported-by: hanetzer <AT> startmail.com |
20 |
Closes: https://bugs.gentoo.org/738248 |
21 |
Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org> |
22 |
|
23 |
eclass/toolchain.eclass | 8 ++++++++ |
24 |
1 file changed, 8 insertions(+) |
25 |
|
26 |
diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass |
27 |
index db02ee6be50..a3c948a9352 100644 |
28 |
--- a/eclass/toolchain.eclass |
29 |
+++ b/eclass/toolchain.eclass |
30 |
@@ -912,6 +912,14 @@ toolchain_src_configure() { |
31 |
--disable-threads |
32 |
--without-headers |
33 |
) |
34 |
+ if [[ $needed_libc == glibc ]]; then |
35 |
+ # By default gcc looks at glibc's headers |
36 |
+ # to detect long double support. This does |
37 |
+ # not work for --disable-headers mode. |
38 |
+ # Any >=glibc-2.4 is good enough for float128. |
39 |
+ # The option appeared in gcc-4.2. |
40 |
+ confgcc+=( --with-long-double-128 ) |
41 |
+ fi |
42 |
elif has_version "${CATEGORY}/${needed_libc}[headers-only(-)]" ; then |
43 |
confgcc+=( |
44 |
"${confgcc_no_libc[@]}" |