Gentoo Archives: gentoo-commits

From: Matt Turner <mattst88@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-libs/glibc/
Date: Thu, 26 Mar 2020 04:37:46
Message-Id: 1585197450.7daa03609079248a30f64366345bd728e65da38e.mattst88@gentoo
1 commit: 7daa03609079248a30f64366345bd728e65da38e
2 Author: Matt Turner <mattst88 <AT> gentoo <DOT> org>
3 AuthorDate: Wed Mar 25 21:34:07 2020 +0000
4 Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org>
5 CommitDate: Thu Mar 26 04:37:30 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7daa0360
7
8 sys-libs/glibc: Drop SPARC CHOST mangling
9
10 Before "multiarch" support in glibc, picking a different CHOST would
11 select which optimized paths were built. Multiarch support was added in
12 glibc commit 3afd5a3b5556 (sparc: Add multiarch support for
13 memset/bzero/memcpy.) in 2010 before glibc-2.12.
14
15 Before glibc-2.30 glibc dropped support for SPARC v7 in commit
16 5d9b7b9fa734 (Remove 32 bit sparc v7 support) and in the process cleaned
17 up some configuration logic that accepted a wide variety of (now unused
18 CHOST values), thus causing the build to fail for us when we select a
19 now unknown CHOST.
20
21 Simply drop this logic, since it shouldn't be needed for any glibc since
22 2.11.
23
24 Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>
25
26 sys-libs/glibc/glibc-2.30-r6.ebuild | 62 ++++---------------------------------
27 sys-libs/glibc/glibc-2.31-r2.ebuild | 62 ++++---------------------------------
28 sys-libs/glibc/glibc-9999.ebuild | 62 ++++---------------------------------
29 3 files changed, 18 insertions(+), 168 deletions(-)
30
31 diff --git a/sys-libs/glibc/glibc-2.30-r6.ebuild b/sys-libs/glibc/glibc-2.30-r6.ebuild
32 index 5b0ea0c9dc1..a2c6434e559 100644
33 --- a/sys-libs/glibc/glibc-2.30-r6.ebuild
34 +++ b/sys-libs/glibc/glibc-2.30-r6.ebuild
35 @@ -301,77 +301,27 @@ setup_target_flags() {
36 filter-flags "-fcall-used-g7"
37 append-flags "-fcall-used-g6"
38
39 - # If the CHOST is the basic one (e.g. not sparcv9-xxx already),
40 - # try to pick a better one so glibc can use cpu-specific .S files.
41 - # We key off the CFLAGS to get a good value. Also need to handle
42 - # version skew.
43 - # We can't force users to set their CHOST to their exact machine
44 - # as many of these are not recognized by config.sub/gcc and such :(.
45 - # Note: If the mcpu values don't scale, we might try probing CPP defines.
46 - # Note: Should we factor in -Wa,-AvXXX flags too ? Or -mvis/etc... ?
47 -
48 local cpu
49 case ${CTARGET} in
50 sparc64-*)
51 + cpu="sparc64"
52 case $(get-flag mcpu) in
53 - niagara[234])
54 - if ver_test -ge 2.8 ; then
55 - cpu="sparc64v2"
56 - elif ver_test -ge 2.4 ; then
57 - cpu="sparc64v"
58 - elif ver_test -ge 2.2.3 ; then
59 - cpu="sparc64b"
60 - fi
61 - ;;
62 - niagara)
63 - if ver_test -ge 2.4 ; then
64 - cpu="sparc64v"
65 - elif ver_test -ge 2.2.3 ; then
66 - cpu="sparc64b"
67 - fi
68 - ;;
69 - ultrasparc3)
70 - cpu="sparc64b"
71 - ;;
72 - *)
73 + v9)
74 # We need to force at least v9a because the base build doesn't
75 # work with just v9.
76 # https://sourceware.org/bugzilla/show_bug.cgi?id=19477
77 - [[ -z ${cpu} ]] && append-flags "-Wa,-xarch=v9a"
78 + append-flags "-Wa,-xarch=v9a"
79 ;;
80 esac
81 ;;
82 sparc-*)
83 case $(get-flag mcpu) in
84 - niagara[234])
85 - if ver_test -ge 2.8 ; then
86 - cpu="sparcv9v2"
87 - elif ver_test -ge 2.4 ; then
88 - cpu="sparcv9v"
89 - elif ver_test -ge 2.2.3 ; then
90 - cpu="sparcv9b"
91 - else
92 - cpu="sparcv9"
93 - fi
94 - ;;
95 - niagara)
96 - if ver_test -ge 2.4 ; then
97 - cpu="sparcv9v"
98 - elif ver_test -ge 2.2.3 ; then
99 - cpu="sparcv9b"
100 - else
101 - cpu="sparcv9"
102 - fi
103 - ;;
104 - ultrasparc3)
105 - cpu="sparcv9b"
106 - ;;
107 - v9|ultrasparc)
108 - cpu="sparcv9"
109 - ;;
110 v8|supersparc|hypersparc|leon|leon3)
111 cpu="sparcv8"
112 ;;
113 + *)
114 + cpu="sparcv9"
115 + ;;
116 esac
117 ;;
118 esac
119
120 diff --git a/sys-libs/glibc/glibc-2.31-r2.ebuild b/sys-libs/glibc/glibc-2.31-r2.ebuild
121 index 15ee5c7051c..e180533f0fc 100644
122 --- a/sys-libs/glibc/glibc-2.31-r2.ebuild
123 +++ b/sys-libs/glibc/glibc-2.31-r2.ebuild
124 @@ -292,77 +292,27 @@ setup_target_flags() {
125 filter-flags "-fcall-used-g7"
126 append-flags "-fcall-used-g6"
127
128 - # If the CHOST is the basic one (e.g. not sparcv9-xxx already),
129 - # try to pick a better one so glibc can use cpu-specific .S files.
130 - # We key off the CFLAGS to get a good value. Also need to handle
131 - # version skew.
132 - # We can't force users to set their CHOST to their exact machine
133 - # as many of these are not recognized by config.sub/gcc and such :(.
134 - # Note: If the mcpu values don't scale, we might try probing CPP defines.
135 - # Note: Should we factor in -Wa,-AvXXX flags too ? Or -mvis/etc... ?
136 -
137 local cpu
138 case ${CTARGET} in
139 sparc64-*)
140 + cpu="sparc64"
141 case $(get-flag mcpu) in
142 - niagara[234])
143 - if ver_test -ge 2.8 ; then
144 - cpu="sparc64v2"
145 - elif ver_test -ge 2.4 ; then
146 - cpu="sparc64v"
147 - elif ver_test -ge 2.2.3 ; then
148 - cpu="sparc64b"
149 - fi
150 - ;;
151 - niagara)
152 - if ver_test -ge 2.4 ; then
153 - cpu="sparc64v"
154 - elif ver_test -ge 2.2.3 ; then
155 - cpu="sparc64b"
156 - fi
157 - ;;
158 - ultrasparc3)
159 - cpu="sparc64b"
160 - ;;
161 - *)
162 + v9)
163 # We need to force at least v9a because the base build doesn't
164 # work with just v9.
165 # https://sourceware.org/bugzilla/show_bug.cgi?id=19477
166 - [[ -z ${cpu} ]] && append-flags "-Wa,-xarch=v9a"
167 + append-flags "-Wa,-xarch=v9a"
168 ;;
169 esac
170 ;;
171 sparc-*)
172 case $(get-flag mcpu) in
173 - niagara[234])
174 - if ver_test -ge 2.8 ; then
175 - cpu="sparcv9v2"
176 - elif ver_test -ge 2.4 ; then
177 - cpu="sparcv9v"
178 - elif ver_test -ge 2.2.3 ; then
179 - cpu="sparcv9b"
180 - else
181 - cpu="sparcv9"
182 - fi
183 - ;;
184 - niagara)
185 - if ver_test -ge 2.4 ; then
186 - cpu="sparcv9v"
187 - elif ver_test -ge 2.2.3 ; then
188 - cpu="sparcv9b"
189 - else
190 - cpu="sparcv9"
191 - fi
192 - ;;
193 - ultrasparc3)
194 - cpu="sparcv9b"
195 - ;;
196 - v9|ultrasparc)
197 - cpu="sparcv9"
198 - ;;
199 v8|supersparc|hypersparc|leon|leon3)
200 cpu="sparcv8"
201 ;;
202 + *)
203 + cpu="sparcv9"
204 + ;;
205 esac
206 ;;
207 esac
208
209 diff --git a/sys-libs/glibc/glibc-9999.ebuild b/sys-libs/glibc/glibc-9999.ebuild
210 index a8207576779..1bc1d7e7ec8 100644
211 --- a/sys-libs/glibc/glibc-9999.ebuild
212 +++ b/sys-libs/glibc/glibc-9999.ebuild
213 @@ -291,77 +291,27 @@ setup_target_flags() {
214 filter-flags "-fcall-used-g7"
215 append-flags "-fcall-used-g6"
216
217 - # If the CHOST is the basic one (e.g. not sparcv9-xxx already),
218 - # try to pick a better one so glibc can use cpu-specific .S files.
219 - # We key off the CFLAGS to get a good value. Also need to handle
220 - # version skew.
221 - # We can't force users to set their CHOST to their exact machine
222 - # as many of these are not recognized by config.sub/gcc and such :(.
223 - # Note: If the mcpu values don't scale, we might try probing CPP defines.
224 - # Note: Should we factor in -Wa,-AvXXX flags too ? Or -mvis/etc... ?
225 -
226 local cpu
227 case ${CTARGET} in
228 sparc64-*)
229 + cpu="sparc64"
230 case $(get-flag mcpu) in
231 - niagara[234])
232 - if ver_test -ge 2.8 ; then
233 - cpu="sparc64v2"
234 - elif ver_test -ge 2.4 ; then
235 - cpu="sparc64v"
236 - elif ver_test -ge 2.2.3 ; then
237 - cpu="sparc64b"
238 - fi
239 - ;;
240 - niagara)
241 - if ver_test -ge 2.4 ; then
242 - cpu="sparc64v"
243 - elif ver_test -ge 2.2.3 ; then
244 - cpu="sparc64b"
245 - fi
246 - ;;
247 - ultrasparc3)
248 - cpu="sparc64b"
249 - ;;
250 - *)
251 + v9)
252 # We need to force at least v9a because the base build doesn't
253 # work with just v9.
254 # https://sourceware.org/bugzilla/show_bug.cgi?id=19477
255 - [[ -z ${cpu} ]] && append-flags "-Wa,-xarch=v9a"
256 + append-flags "-Wa,-xarch=v9a"
257 ;;
258 esac
259 ;;
260 sparc-*)
261 case $(get-flag mcpu) in
262 - niagara[234])
263 - if ver_test -ge 2.8 ; then
264 - cpu="sparcv9v2"
265 - elif ver_test -ge 2.4 ; then
266 - cpu="sparcv9v"
267 - elif ver_test -ge 2.2.3 ; then
268 - cpu="sparcv9b"
269 - else
270 - cpu="sparcv9"
271 - fi
272 - ;;
273 - niagara)
274 - if ver_test -ge 2.4 ; then
275 - cpu="sparcv9v"
276 - elif ver_test -ge 2.2.3 ; then
277 - cpu="sparcv9b"
278 - else
279 - cpu="sparcv9"
280 - fi
281 - ;;
282 - ultrasparc3)
283 - cpu="sparcv9b"
284 - ;;
285 - v9|ultrasparc)
286 - cpu="sparcv9"
287 - ;;
288 v8|supersparc|hypersparc|leon|leon3)
289 cpu="sparcv8"
290 ;;
291 + *)
292 + cpu="sparcv9"
293 + ;;
294 esac
295 ;;
296 esac