nokogiri 1.12.5 → 1.13.6

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of nokogiri might be problematic. Click here for more details.

Files changed (103) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +2 -0
  3. data/README.md +9 -7
  4. data/bin/nokogiri +63 -50
  5. data/dependencies.yml +13 -64
  6. data/ext/nokogiri/extconf.rb +64 -44
  7. data/ext/nokogiri/html4_sax_parser_context.c +2 -3
  8. data/ext/nokogiri/xml_document.c +35 -35
  9. data/ext/nokogiri/xml_document_fragment.c +0 -2
  10. data/ext/nokogiri/xml_dtd.c +2 -2
  11. data/ext/nokogiri/xml_encoding_handler.c +25 -11
  12. data/ext/nokogiri/xml_node.c +638 -333
  13. data/ext/nokogiri/xml_reader.c +37 -11
  14. data/ext/nokogiri/xml_sax_parser_context.c +10 -3
  15. data/ext/nokogiri/xml_xpath_context.c +72 -49
  16. data/ext/nokogiri/xslt_stylesheet.c +107 -9
  17. data/gumbo-parser/src/parser.c +0 -11
  18. data/lib/nokogiri/class_resolver.rb +67 -0
  19. data/lib/nokogiri/css/node.rb +9 -8
  20. data/lib/nokogiri/css/parser.rb +360 -341
  21. data/lib/nokogiri/css/parser.y +249 -244
  22. data/lib/nokogiri/css/parser_extras.rb +22 -20
  23. data/lib/nokogiri/css/syntax_error.rb +1 -0
  24. data/lib/nokogiri/css/tokenizer.rb +4 -3
  25. data/lib/nokogiri/css/tokenizer.rex +3 -2
  26. data/lib/nokogiri/css/xpath_visitor.rb +179 -82
  27. data/lib/nokogiri/css.rb +38 -6
  28. data/lib/nokogiri/decorators/slop.rb +8 -7
  29. data/lib/nokogiri/extension.rb +1 -1
  30. data/lib/nokogiri/gumbo.rb +1 -0
  31. data/lib/nokogiri/html.rb +16 -10
  32. data/lib/nokogiri/html4/builder.rb +1 -0
  33. data/lib/nokogiri/html4/document.rb +88 -77
  34. data/lib/nokogiri/html4/document_fragment.rb +11 -7
  35. data/lib/nokogiri/html4/element_description.rb +1 -0
  36. data/lib/nokogiri/html4/element_description_defaults.rb +426 -520
  37. data/lib/nokogiri/html4/entity_lookup.rb +2 -1
  38. data/lib/nokogiri/html4/sax/parser.rb +5 -2
  39. data/lib/nokogiri/html4/sax/parser_context.rb +1 -0
  40. data/lib/nokogiri/html4/sax/push_parser.rb +7 -7
  41. data/lib/nokogiri/html4.rb +11 -5
  42. data/lib/nokogiri/html5/document.rb +27 -10
  43. data/lib/nokogiri/html5/document_fragment.rb +5 -2
  44. data/lib/nokogiri/html5/node.rb +10 -3
  45. data/lib/nokogiri/html5.rb +69 -64
  46. data/lib/nokogiri/jruby/dependencies.rb +10 -9
  47. data/lib/nokogiri/syntax_error.rb +1 -0
  48. data/lib/nokogiri/version/constant.rb +2 -1
  49. data/lib/nokogiri/version/info.rb +20 -13
  50. data/lib/nokogiri/version.rb +1 -0
  51. data/lib/nokogiri/xml/attr.rb +5 -3
  52. data/lib/nokogiri/xml/attribute_decl.rb +2 -1
  53. data/lib/nokogiri/xml/builder.rb +34 -32
  54. data/lib/nokogiri/xml/cdata.rb +2 -1
  55. data/lib/nokogiri/xml/character_data.rb +1 -0
  56. data/lib/nokogiri/xml/document.rb +144 -103
  57. data/lib/nokogiri/xml/document_fragment.rb +41 -38
  58. data/lib/nokogiri/xml/dtd.rb +3 -2
  59. data/lib/nokogiri/xml/element_content.rb +1 -0
  60. data/lib/nokogiri/xml/element_decl.rb +2 -1
  61. data/lib/nokogiri/xml/entity_decl.rb +3 -2
  62. data/lib/nokogiri/xml/entity_reference.rb +1 -0
  63. data/lib/nokogiri/xml/namespace.rb +2 -0
  64. data/lib/nokogiri/xml/node/save_options.rb +8 -4
  65. data/lib/nokogiri/xml/node.rb +521 -351
  66. data/lib/nokogiri/xml/node_set.rb +50 -54
  67. data/lib/nokogiri/xml/notation.rb +12 -0
  68. data/lib/nokogiri/xml/parse_options.rb +12 -7
  69. data/lib/nokogiri/xml/pp/character_data.rb +8 -6
  70. data/lib/nokogiri/xml/pp/node.rb +24 -26
  71. data/lib/nokogiri/xml/pp.rb +1 -0
  72. data/lib/nokogiri/xml/processing_instruction.rb +2 -1
  73. data/lib/nokogiri/xml/reader.rb +17 -19
  74. data/lib/nokogiri/xml/relax_ng.rb +1 -0
  75. data/lib/nokogiri/xml/sax/document.rb +20 -19
  76. data/lib/nokogiri/xml/sax/parser.rb +37 -34
  77. data/lib/nokogiri/xml/sax/parser_context.rb +7 -3
  78. data/lib/nokogiri/xml/sax/push_parser.rb +5 -5
  79. data/lib/nokogiri/xml/sax.rb +1 -0
  80. data/lib/nokogiri/xml/schema.rb +7 -6
  81. data/lib/nokogiri/xml/searchable.rb +93 -62
  82. data/lib/nokogiri/xml/syntax_error.rb +5 -4
  83. data/lib/nokogiri/xml/text.rb +1 -0
  84. data/lib/nokogiri/xml/xpath/syntax_error.rb +2 -1
  85. data/lib/nokogiri/xml/xpath.rb +12 -0
  86. data/lib/nokogiri/xml/xpath_context.rb +2 -3
  87. data/lib/nokogiri/xml.rb +4 -3
  88. data/lib/nokogiri/xslt/stylesheet.rb +1 -0
  89. data/lib/nokogiri/xslt.rb +21 -13
  90. data/lib/nokogiri.rb +19 -16
  91. data/lib/xsd/xmlparser/nokogiri.rb +25 -24
  92. data/patches/libxml2/0004-use-glibc-strlen.patch +3 -3
  93. data/patches/libxml2/0006-update-automake-files-for-arm64.patch +2443 -1914
  94. data/patches/libxml2/0008-htmlParseComment-handle-abruptly-closed-comments.patch +61 -0
  95. data/patches/libxml2/0009-allow-wildcard-namespaces.patch +77 -0
  96. data/patches/libxslt/0001-update-automake-files-for-arm64.patch +2445 -1919
  97. data/ports/archives/libxml2-2.9.14.tar.xz +0 -0
  98. data/ports/archives/libxslt-1.1.35.tar.xz +0 -0
  99. metadata +109 -31
  100. data/patches/libxml2/0007-Fix-XPath-recursion-limit.patch +0 -31
  101. data/patches/libxslt/0002-Fix-xml2-config-check-in-configure-script.patch +0 -19
  102. data/ports/archives/libxml2-2.9.12.tar.gz +0 -0
  103. data/ports/archives/libxslt-1.1.34.tar.gz +0 -0
@@ -1,15 +1,12 @@
1
- Update config.guess and config.sub to the versions present in automake v1.16.3, so that users on
2
- aarch64/arm64/M1 can compile.
3
-
4
- --- a/config.sub
5
- +++ b/config.sub
1
+ --- ../nokogiri/tmp/x86_64-linux/nokogiri/3.1.0/tmp/x86_64-pc-linux-gnu/ports/libxslt/1.1.35/libxslt-1.1.35/config.sub 2022-02-16 11:28:23.000000000 -0500
2
+ +++ lib/config.sub 2021-04-02 11:37:10.265231915 -0400
6
3
  @@ -1,8 +1,8 @@
7
4
  #! /bin/sh
8
5
  # Configuration validation subroutine script.
9
6
  -# Copyright 1992-2018 Free Software Foundation, Inc.
10
7
  +# Copyright 1992-2020 Free Software Foundation, Inc.
11
8
 
12
- -timestamp='2018-08-29'
9
+ -timestamp='2018-02-22'
13
10
  +timestamp='2020-11-07'
14
11
 
15
12
  # This file is free software; you can redistribute it and/or modify it
@@ -41,1045 +38,2213 @@ aarch64/arm64/M1 can compile.
41
38
  exit 1 ;;
42
39
 
43
40
  *local*)
44
- @@ -111,7 +111,8 @@
41
+ @@ -110,1223 +110,1167 @@
42
+ exit 1;;
45
43
  esac
46
44
 
47
- # Split fields of configuration type
48
- -IFS="-" read -r field1 field2 field3 field4 <<EOF
45
+ -# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any).
46
+ -# Here we must recognize all the valid KERNEL-OS combinations.
47
+ -maybe_os=`echo "$1" | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
48
+ -case $maybe_os in
49
+ - nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
50
+ - linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
51
+ - knetbsd*-gnu* | netbsd*-gnu* | netbsd*-eabi* | \
52
+ - kopensolaris*-gnu* | cloudabi*-eabi* | \
53
+ - storm-chaos* | os2-emx* | rtmk-nova*)
54
+ - os=-$maybe_os
55
+ - basic_machine=`echo "$1" | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
56
+ - ;;
57
+ - android-linux)
58
+ - os=-linux-android
59
+ - basic_machine=`echo "$1" | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown
60
+ - ;;
61
+ - *)
62
+ - basic_machine=`echo "$1" | sed 's/-[^-]*$//'`
63
+ - if [ "$basic_machine" != "$1" ]
64
+ - then os=`echo "$1" | sed 's/.*-/-/'`
65
+ - else os=; fi
66
+ - ;;
67
+ -esac
68
+ -
69
+ -### Let's recognize common machines as not being operating systems so
70
+ -### that things like config.sub decstation-3100 work. We also
71
+ -### recognize some manufacturers as not being operating systems, so we
72
+ -### can provide default operating systems below.
73
+ -case $os in
74
+ - -sun*os*)
75
+ - # Prevent following clause from handling this invalid input.
76
+ - ;;
77
+ - -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \
78
+ - -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \
79
+ - -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \
80
+ - -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
81
+ - -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
82
+ - -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
83
+ - -apple | -axis | -knuth | -cray | -microblaze*)
84
+ - os=
85
+ - basic_machine=$1
86
+ - ;;
87
+ - -bluegene*)
88
+ - os=-cnk
89
+ - ;;
90
+ - -sim | -cisco | -oki | -wec | -winbond)
91
+ - os=
92
+ - basic_machine=$1
93
+ - ;;
94
+ - -scout)
95
+ - ;;
96
+ - -wrs)
97
+ - os=-vxworks
98
+ - basic_machine=$1
99
+ - ;;
100
+ - -chorusos*)
101
+ - os=-chorusos
102
+ - basic_machine=$1
103
+ - ;;
104
+ - -chorusrdb)
105
+ - os=-chorusrdb
106
+ - basic_machine=$1
107
+ - ;;
108
+ - -hiux*)
109
+ - os=-hiuxwe2
110
+ - ;;
111
+ - -sco6)
112
+ - os=-sco5v6
113
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
114
+ - ;;
115
+ - -sco5)
116
+ - os=-sco3.2v5
117
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
118
+ - ;;
119
+ - -sco4)
120
+ - os=-sco3.2v4
121
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
122
+ - ;;
123
+ - -sco3.2.[4-9]*)
124
+ - os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
125
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
126
+ - ;;
127
+ - -sco3.2v[4-9]*)
128
+ - # Don't forget version if it is 3.2v4 or newer.
129
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
130
+ - ;;
131
+ - -sco5v6*)
132
+ - # Don't forget version if it is 3.2v4 or newer.
133
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
134
+ - ;;
135
+ - -sco*)
136
+ - os=-sco3.2v2
137
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
138
+ - ;;
139
+ - -udk*)
140
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
141
+ - ;;
142
+ - -isc)
143
+ - os=-isc2.2
144
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
145
+ - ;;
146
+ - -clix*)
147
+ - basic_machine=clipper-intergraph
148
+ - ;;
149
+ - -isc*)
150
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-pc/'`
151
+ - ;;
152
+ - -lynx*178)
153
+ - os=-lynxos178
154
+ - ;;
155
+ - -lynx*5)
156
+ - os=-lynxos5
157
+ +# Split fields of configuration type
49
158
  +# shellcheck disable=SC2162
50
159
  +IFS="-" read field1 field2 field3 field4 <<EOF
51
- $1
52
- EOF
53
-
54
- @@ -123,37 +124,36 @@
160
+ +$1
161
+ +EOF
162
+ +
163
+ +# Separate into logical components for further validation
164
+ +case $1 in
165
+ + *-*-*-*-*)
166
+ + echo Invalid configuration \`"$1"\': more than four components >&2
167
+ + exit 1
55
168
  ;;
56
- *-*-*-*)
57
- basic_machine=$field1-$field2
58
- - os=$field3-$field4
169
+ - -lynx*)
170
+ - os=-lynxos
171
+ + *-*-*-*)
172
+ + basic_machine=$field1-$field2
59
173
  + basic_os=$field3-$field4
60
174
  ;;
61
- *-*-*)
62
- # Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two
63
- # parts
64
- maybe_os=$field2-$field3
65
- case $maybe_os in
66
- - nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc \
67
- - | linux-newlib* | linux-musl* | linux-uclibc* | uclinux-uclibc* \
175
+ - -ptx*)
176
+ - basic_machine=`echo "$1" | sed -e 's/86-.*/86-sequent/'`
177
+ + *-*-*)
178
+ + # Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two
179
+ + # parts
180
+ + maybe_os=$field2-$field3
181
+ + case $maybe_os in
68
182
  + nto-qnx* | linux-* | uclinux-uclibc* \
69
- | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \
70
- | netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \
71
- | storm-chaos* | os2-emx* | rtmk-nova*)
72
- basic_machine=$field1
73
- - os=$maybe_os
183
+ + | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \
184
+ + | netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \
185
+ + | storm-chaos* | os2-emx* | rtmk-nova*)
186
+ + basic_machine=$field1
74
187
  + basic_os=$maybe_os
75
- ;;
76
- android-linux)
77
- basic_machine=$field1-unknown
78
- - os=linux-android
188
+ + ;;
189
+ + android-linux)
190
+ + basic_machine=$field1-unknown
79
191
  + basic_os=linux-android
80
- ;;
81
- *)
82
- basic_machine=$field1-$field2
83
- - os=$field3
192
+ + ;;
193
+ + *)
194
+ + basic_machine=$field1-$field2
84
195
  + basic_os=$field3
85
- ;;
86
- esac
196
+ + ;;
197
+ + esac
87
198
  ;;
88
- *-*)
89
- - # A lone config we happen to match not fitting any patern
199
+ - -psos*)
200
+ - os=-psos
201
+ + *-*)
90
202
  + # A lone config we happen to match not fitting any pattern
91
- case $field1-$field2 in
92
- decstation-3100)
93
- basic_machine=mips-dec
94
- - os=
203
+ + case $field1-$field2 in
204
+ + decstation-3100)
205
+ + basic_machine=mips-dec
95
206
  + basic_os=
96
- ;;
97
- *-*)
98
- # Second component is usually, but not always the OS
99
- @@ -161,7 +161,7 @@
100
- # Prevent following clause from handling this valid os
101
- sun*os*)
102
- basic_machine=$field1
103
- - os=$field2
207
+ + ;;
208
+ + *-*)
209
+ + # Second component is usually, but not always the OS
210
+ + case $field2 in
211
+ + # Prevent following clause from handling this valid os
212
+ + sun*os*)
213
+ + basic_machine=$field1
104
214
  + basic_os=$field2
105
- ;;
106
- # Manufacturers
107
- dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \
108
- @@ -174,11 +174,11 @@
109
- | microblaze* | sim | cisco \
110
- | oki | wec | wrs | winbond)
111
- basic_machine=$field1-$field2
112
- - os=
215
+ + ;;
216
+ + # Manufacturers
217
+ + dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \
218
+ + | att* | 7300* | 3300* | delta* | motorola* | sun[234]* \
219
+ + | unicom* | ibm* | next | hp | isi* | apollo | altos* \
220
+ + | convergent* | ncr* | news | 32* | 3600* | 3100* \
221
+ + | hitachi* | c[123]* | convex* | sun | crds | omron* | dg \
222
+ + | ultra | tti* | harris | dolphin | highlevel | gould \
223
+ + | cbm | ns | masscomp | apple | axis | knuth | cray \
224
+ + | microblaze* | sim | cisco \
225
+ + | oki | wec | wrs | winbond)
226
+ + basic_machine=$field1-$field2
113
227
  + basic_os=
114
- ;;
115
- *)
116
- basic_machine=$field1
117
- - os=$field2
228
+ + ;;
229
+ + *)
230
+ + basic_machine=$field1
118
231
  + basic_os=$field2
119
- ;;
120
- esac
121
- ;;
122
- @@ -190,450 +190,451 @@
123
- case $field1 in
124
- 386bsd)
125
- basic_machine=i386-pc
126
- - os=bsd
232
+ + ;;
233
+ + esac
234
+ + ;;
235
+ + esac
236
+ ;;
237
+ - -mint | -mint[0-9]*)
238
+ - basic_machine=m68k-atari
239
+ - os=-mint
240
+ + *)
241
+ + # Convert single-component short-hands not valid as part of
242
+ + # multi-component configurations.
243
+ + case $field1 in
244
+ + 386bsd)
245
+ + basic_machine=i386-pc
127
246
  + basic_os=bsd
128
- ;;
129
- a29khif)
130
- basic_machine=a29k-amd
131
- - os=udi
247
+ + ;;
248
+ + a29khif)
249
+ + basic_machine=a29k-amd
132
250
  + basic_os=udi
133
- ;;
134
- adobe68k)
135
- basic_machine=m68010-adobe
136
- - os=scout
251
+ + ;;
252
+ + adobe68k)
253
+ + basic_machine=m68010-adobe
137
254
  + basic_os=scout
138
- ;;
139
- alliant)
140
- basic_machine=fx80-alliant
141
- - os=
255
+ + ;;
256
+ + alliant)
257
+ + basic_machine=fx80-alliant
142
258
  + basic_os=
143
- ;;
144
- altos | altos3068)
145
- basic_machine=m68k-altos
146
- - os=
259
+ + ;;
260
+ + altos | altos3068)
261
+ + basic_machine=m68k-altos
147
262
  + basic_os=
148
- ;;
149
- am29k)
150
- basic_machine=a29k-none
151
- - os=bsd
263
+ + ;;
264
+ + am29k)
265
+ + basic_machine=a29k-none
152
266
  + basic_os=bsd
153
- ;;
154
- amdahl)
155
- basic_machine=580-amdahl
156
- - os=sysv
267
+ + ;;
268
+ + amdahl)
269
+ + basic_machine=580-amdahl
157
270
  + basic_os=sysv
158
- ;;
159
- amiga)
160
- basic_machine=m68k-unknown
161
- - os=
271
+ + ;;
272
+ + amiga)
273
+ + basic_machine=m68k-unknown
162
274
  + basic_os=
163
- ;;
164
- amigaos | amigados)
165
- basic_machine=m68k-unknown
166
- - os=amigaos
275
+ + ;;
276
+ + amigaos | amigados)
277
+ + basic_machine=m68k-unknown
167
278
  + basic_os=amigaos
168
- ;;
169
- amigaunix | amix)
170
- basic_machine=m68k-unknown
171
- - os=sysv4
279
+ + ;;
280
+ + amigaunix | amix)
281
+ + basic_machine=m68k-unknown
172
282
  + basic_os=sysv4
173
- ;;
174
- apollo68)
175
- basic_machine=m68k-apollo
176
- - os=sysv
283
+ + ;;
284
+ + apollo68)
285
+ + basic_machine=m68k-apollo
177
286
  + basic_os=sysv
178
- ;;
179
- apollo68bsd)
180
- basic_machine=m68k-apollo
181
- - os=bsd
287
+ + ;;
288
+ + apollo68bsd)
289
+ + basic_machine=m68k-apollo
182
290
  + basic_os=bsd
183
- ;;
184
- aros)
185
- basic_machine=i386-pc
186
- - os=aros
291
+ + ;;
292
+ + aros)
293
+ + basic_machine=i386-pc
187
294
  + basic_os=aros
188
- ;;
189
- aux)
190
- basic_machine=m68k-apple
191
- - os=aux
295
+ + ;;
296
+ + aux)
297
+ + basic_machine=m68k-apple
192
298
  + basic_os=aux
193
- ;;
194
- balance)
195
- basic_machine=ns32k-sequent
196
- - os=dynix
299
+ + ;;
300
+ + balance)
301
+ + basic_machine=ns32k-sequent
197
302
  + basic_os=dynix
198
- ;;
199
- blackfin)
200
- basic_machine=bfin-unknown
201
- - os=linux
303
+ + ;;
304
+ + blackfin)
305
+ + basic_machine=bfin-unknown
202
306
  + basic_os=linux
203
- ;;
204
- cegcc)
205
- basic_machine=arm-unknown
206
- - os=cegcc
307
+ + ;;
308
+ + cegcc)
309
+ + basic_machine=arm-unknown
207
310
  + basic_os=cegcc
208
- ;;
209
- convex-c1)
210
- basic_machine=c1-convex
211
- - os=bsd
311
+ + ;;
312
+ + convex-c1)
313
+ + basic_machine=c1-convex
212
314
  + basic_os=bsd
213
- ;;
214
- convex-c2)
215
- basic_machine=c2-convex
216
- - os=bsd
315
+ + ;;
316
+ + convex-c2)
317
+ + basic_machine=c2-convex
217
318
  + basic_os=bsd
218
- ;;
219
- convex-c32)
220
- basic_machine=c32-convex
221
- - os=bsd
319
+ + ;;
320
+ + convex-c32)
321
+ + basic_machine=c32-convex
222
322
  + basic_os=bsd
223
- ;;
224
- convex-c34)
225
- basic_machine=c34-convex
226
- - os=bsd
323
+ + ;;
324
+ + convex-c34)
325
+ + basic_machine=c34-convex
227
326
  + basic_os=bsd
228
- ;;
229
- convex-c38)
230
- basic_machine=c38-convex
231
- - os=bsd
327
+ + ;;
328
+ + convex-c38)
329
+ + basic_machine=c38-convex
232
330
  + basic_os=bsd
233
- ;;
234
- cray)
235
- basic_machine=j90-cray
236
- - os=unicos
331
+ + ;;
332
+ + cray)
333
+ + basic_machine=j90-cray
237
334
  + basic_os=unicos
238
- ;;
239
- crds | unos)
240
- basic_machine=m68k-crds
241
- - os=
335
+ + ;;
336
+ + crds | unos)
337
+ + basic_machine=m68k-crds
242
338
  + basic_os=
243
- ;;
244
- da30)
245
- basic_machine=m68k-da30
246
- - os=
339
+ + ;;
340
+ + da30)
341
+ + basic_machine=m68k-da30
247
342
  + basic_os=
248
- ;;
249
- decstation | pmax | pmin | dec3100 | decstatn)
250
- basic_machine=mips-dec
251
- - os=
343
+ + ;;
344
+ + decstation | pmax | pmin | dec3100 | decstatn)
345
+ + basic_machine=mips-dec
252
346
  + basic_os=
253
- ;;
254
- delta88)
255
- basic_machine=m88k-motorola
256
- - os=sysv3
347
+ + ;;
348
+ + delta88)
349
+ + basic_machine=m88k-motorola
257
350
  + basic_os=sysv3
258
- ;;
259
- dicos)
260
- basic_machine=i686-pc
261
- - os=dicos
351
+ + ;;
352
+ + dicos)
353
+ + basic_machine=i686-pc
262
354
  + basic_os=dicos
263
- ;;
264
- djgpp)
265
- basic_machine=i586-pc
266
- - os=msdosdjgpp
355
+ + ;;
356
+ + djgpp)
357
+ + basic_machine=i586-pc
267
358
  + basic_os=msdosdjgpp
268
- ;;
269
- ebmon29k)
270
- basic_machine=a29k-amd
271
- - os=ebmon
359
+ + ;;
360
+ + ebmon29k)
361
+ + basic_machine=a29k-amd
272
362
  + basic_os=ebmon
273
- ;;
274
- es1800 | OSE68k | ose68k | ose | OSE)
275
- basic_machine=m68k-ericsson
276
- - os=ose
363
+ + ;;
364
+ + es1800 | OSE68k | ose68k | ose | OSE)
365
+ + basic_machine=m68k-ericsson
277
366
  + basic_os=ose
278
- ;;
279
- gmicro)
280
- basic_machine=tron-gmicro
281
- - os=sysv
367
+ + ;;
368
+ + gmicro)
369
+ + basic_machine=tron-gmicro
282
370
  + basic_os=sysv
283
- ;;
284
- go32)
285
- basic_machine=i386-pc
286
- - os=go32
371
+ + ;;
372
+ + go32)
373
+ + basic_machine=i386-pc
287
374
  + basic_os=go32
288
- ;;
289
- h8300hms)
290
- basic_machine=h8300-hitachi
291
- - os=hms
375
+ + ;;
376
+ + h8300hms)
377
+ + basic_machine=h8300-hitachi
292
378
  + basic_os=hms
293
- ;;
294
- h8300xray)
295
- basic_machine=h8300-hitachi
296
- - os=xray
379
+ + ;;
380
+ + h8300xray)
381
+ + basic_machine=h8300-hitachi
297
382
  + basic_os=xray
298
- ;;
299
- h8500hms)
300
- basic_machine=h8500-hitachi
301
- - os=hms
383
+ + ;;
384
+ + h8500hms)
385
+ + basic_machine=h8500-hitachi
302
386
  + basic_os=hms
303
- ;;
304
- harris)
305
- basic_machine=m88k-harris
306
- - os=sysv3
387
+ + ;;
388
+ + harris)
389
+ + basic_machine=m88k-harris
307
390
  + basic_os=sysv3
308
- ;;
309
- - hp300)
391
+ + ;;
310
392
  + hp300 | hp300hpux)
311
- basic_machine=m68k-hp
393
+ + basic_machine=m68k-hp
312
394
  + basic_os=hpux
313
- ;;
314
- hp300bsd)
315
- basic_machine=m68k-hp
316
- - os=bsd
317
- - ;;
318
- - hp300hpux)
319
- - basic_machine=m68k-hp
320
- - os=hpux
395
+ + ;;
396
+ + hp300bsd)
397
+ + basic_machine=m68k-hp
321
398
  + basic_os=bsd
322
- ;;
323
- hppaosf)
324
- basic_machine=hppa1.1-hp
325
- - os=osf
399
+ + ;;
400
+ + hppaosf)
401
+ + basic_machine=hppa1.1-hp
326
402
  + basic_os=osf
327
- ;;
328
- hppro)
329
- basic_machine=hppa1.1-hp
330
- - os=proelf
403
+ + ;;
404
+ + hppro)
405
+ + basic_machine=hppa1.1-hp
331
406
  + basic_os=proelf
332
- ;;
333
- i386mach)
334
- basic_machine=i386-mach
335
- - os=mach
336
- - ;;
337
- - vsta)
338
- - basic_machine=i386-pc
339
- - os=vsta
407
+ + ;;
408
+ + i386mach)
409
+ + basic_machine=i386-mach
340
410
  + basic_os=mach
341
- ;;
342
- isi68 | isi)
343
- basic_machine=m68k-isi
344
- - os=sysv
411
+ + ;;
412
+ + isi68 | isi)
413
+ + basic_machine=m68k-isi
345
414
  + basic_os=sysv
346
- ;;
347
- m68knommu)
348
- basic_machine=m68k-unknown
349
- - os=linux
415
+ + ;;
416
+ + m68knommu)
417
+ + basic_machine=m68k-unknown
350
418
  + basic_os=linux
351
- ;;
352
- magnum | m3230)
353
- basic_machine=mips-mips
354
- - os=sysv
419
+ + ;;
420
+ + magnum | m3230)
421
+ + basic_machine=mips-mips
355
422
  + basic_os=sysv
356
- ;;
357
- merlin)
358
- basic_machine=ns32k-utek
359
- - os=sysv
423
+ + ;;
424
+ + merlin)
425
+ + basic_machine=ns32k-utek
360
426
  + basic_os=sysv
361
- ;;
362
- mingw64)
363
- basic_machine=x86_64-pc
364
- - os=mingw64
427
+ + ;;
428
+ + mingw64)
429
+ + basic_machine=x86_64-pc
365
430
  + basic_os=mingw64
366
- ;;
367
- mingw32)
368
- basic_machine=i686-pc
369
- - os=mingw32
431
+ + ;;
432
+ + mingw32)
433
+ + basic_machine=i686-pc
370
434
  + basic_os=mingw32
371
- ;;
372
- mingw32ce)
373
- basic_machine=arm-unknown
374
- - os=mingw32ce
435
+ + ;;
436
+ + mingw32ce)
437
+ + basic_machine=arm-unknown
375
438
  + basic_os=mingw32ce
376
- ;;
377
- monitor)
378
- basic_machine=m68k-rom68k
379
- - os=coff
439
+ + ;;
440
+ + monitor)
441
+ + basic_machine=m68k-rom68k
380
442
  + basic_os=coff
381
- ;;
382
- morphos)
383
- basic_machine=powerpc-unknown
384
- - os=morphos
443
+ + ;;
444
+ + morphos)
445
+ + basic_machine=powerpc-unknown
385
446
  + basic_os=morphos
386
- ;;
387
- moxiebox)
388
- basic_machine=moxie-unknown
389
- - os=moxiebox
447
+ + ;;
448
+ + moxiebox)
449
+ + basic_machine=moxie-unknown
390
450
  + basic_os=moxiebox
391
- ;;
392
- msdos)
393
- basic_machine=i386-pc
394
- - os=msdos
451
+ + ;;
452
+ + msdos)
453
+ + basic_machine=i386-pc
395
454
  + basic_os=msdos
396
- ;;
397
- msys)
398
- basic_machine=i686-pc
399
- - os=msys
455
+ + ;;
456
+ + msys)
457
+ + basic_machine=i686-pc
400
458
  + basic_os=msys
401
- ;;
402
- mvs)
403
- basic_machine=i370-ibm
404
- - os=mvs
459
+ + ;;
460
+ + mvs)
461
+ + basic_machine=i370-ibm
405
462
  + basic_os=mvs
406
- ;;
407
- nacl)
408
- basic_machine=le32-unknown
409
- - os=nacl
463
+ + ;;
464
+ + nacl)
465
+ + basic_machine=le32-unknown
410
466
  + basic_os=nacl
411
- ;;
412
- ncr3000)
413
- basic_machine=i486-ncr
414
- - os=sysv4
467
+ + ;;
468
+ + ncr3000)
469
+ + basic_machine=i486-ncr
415
470
  + basic_os=sysv4
416
- ;;
417
- netbsd386)
418
- basic_machine=i386-pc
419
- - os=netbsd
471
+ + ;;
472
+ + netbsd386)
473
+ + basic_machine=i386-pc
420
474
  + basic_os=netbsd
421
- ;;
422
- netwinder)
423
- basic_machine=armv4l-rebel
424
- - os=linux
475
+ + ;;
476
+ + netwinder)
477
+ + basic_machine=armv4l-rebel
425
478
  + basic_os=linux
426
- ;;
427
- news | news700 | news800 | news900)
428
- basic_machine=m68k-sony
429
- - os=newsos
479
+ + ;;
480
+ + news | news700 | news800 | news900)
481
+ + basic_machine=m68k-sony
430
482
  + basic_os=newsos
431
- ;;
432
- news1000)
433
- basic_machine=m68030-sony
434
- - os=newsos
483
+ + ;;
484
+ + news1000)
485
+ + basic_machine=m68030-sony
435
486
  + basic_os=newsos
436
- ;;
437
- necv70)
438
- basic_machine=v70-nec
439
- - os=sysv
487
+ + ;;
488
+ + necv70)
489
+ + basic_machine=v70-nec
440
490
  + basic_os=sysv
441
- ;;
442
- nh3000)
443
- basic_machine=m68k-harris
444
- - os=cxux
491
+ + ;;
492
+ + nh3000)
493
+ + basic_machine=m68k-harris
445
494
  + basic_os=cxux
446
- ;;
447
- nh[45]000)
448
- basic_machine=m88k-harris
449
- - os=cxux
495
+ + ;;
496
+ + nh[45]000)
497
+ + basic_machine=m88k-harris
450
498
  + basic_os=cxux
451
- ;;
452
- nindy960)
453
- basic_machine=i960-intel
454
- - os=nindy
499
+ + ;;
500
+ + nindy960)
501
+ + basic_machine=i960-intel
455
502
  + basic_os=nindy
456
- ;;
457
- mon960)
458
- basic_machine=i960-intel
459
- - os=mon960
503
+ + ;;
504
+ + mon960)
505
+ + basic_machine=i960-intel
460
506
  + basic_os=mon960
461
- ;;
462
- nonstopux)
463
- basic_machine=mips-compaq
464
- - os=nonstopux
507
+ + ;;
508
+ + nonstopux)
509
+ + basic_machine=mips-compaq
465
510
  + basic_os=nonstopux
466
- ;;
467
- os400)
468
- basic_machine=powerpc-ibm
469
- - os=os400
511
+ + ;;
512
+ + os400)
513
+ + basic_machine=powerpc-ibm
470
514
  + basic_os=os400
471
- ;;
472
- OSE68000 | ose68000)
473
- basic_machine=m68000-ericsson
474
- - os=ose
515
+ + ;;
516
+ + OSE68000 | ose68000)
517
+ + basic_machine=m68000-ericsson
475
518
  + basic_os=ose
476
- ;;
477
- os68k)
478
- basic_machine=m68k-none
479
- - os=os68k
519
+ + ;;
520
+ + os68k)
521
+ + basic_machine=m68k-none
480
522
  + basic_os=os68k
481
- ;;
482
- paragon)
483
- basic_machine=i860-intel
484
- - os=osf
523
+ + ;;
524
+ + paragon)
525
+ + basic_machine=i860-intel
485
526
  + basic_os=osf
486
- ;;
487
- parisc)
488
- basic_machine=hppa-unknown
489
- - os=linux
527
+ + ;;
528
+ + parisc)
529
+ + basic_machine=hppa-unknown
490
530
  + basic_os=linux
491
531
  + ;;
492
532
  + psp)
493
533
  + basic_machine=mipsallegrexel-sony
494
534
  + basic_os=psp
495
- ;;
496
- pw32)
497
- basic_machine=i586-unknown
498
- - os=pw32
535
+ + ;;
536
+ + pw32)
537
+ + basic_machine=i586-unknown
499
538
  + basic_os=pw32
500
- ;;
501
- rdos | rdos64)
502
- basic_machine=x86_64-pc
503
- - os=rdos
539
+ + ;;
540
+ + rdos | rdos64)
541
+ + basic_machine=x86_64-pc
504
542
  + basic_os=rdos
505
- ;;
506
- rdos32)
507
- basic_machine=i386-pc
508
- - os=rdos
543
+ + ;;
544
+ + rdos32)
545
+ + basic_machine=i386-pc
509
546
  + basic_os=rdos
510
- ;;
511
- rom68k)
512
- basic_machine=m68k-rom68k
513
- - os=coff
547
+ + ;;
548
+ + rom68k)
549
+ + basic_machine=m68k-rom68k
514
550
  + basic_os=coff
515
- ;;
516
- sa29200)
517
- basic_machine=a29k-amd
518
- - os=udi
551
+ + ;;
552
+ + sa29200)
553
+ + basic_machine=a29k-amd
519
554
  + basic_os=udi
520
- ;;
521
- sei)
522
- basic_machine=mips-sei
523
- - os=seiux
555
+ + ;;
556
+ + sei)
557
+ + basic_machine=mips-sei
524
558
  + basic_os=seiux
525
- ;;
526
- sequent)
527
- basic_machine=i386-sequent
528
- - os=
559
+ + ;;
560
+ + sequent)
561
+ + basic_machine=i386-sequent
529
562
  + basic_os=
530
- ;;
531
- sps7)
532
- basic_machine=m68k-bull
533
- - os=sysv2
563
+ + ;;
564
+ + sps7)
565
+ + basic_machine=m68k-bull
534
566
  + basic_os=sysv2
535
- ;;
536
- st2000)
537
- basic_machine=m68k-tandem
538
- - os=
567
+ + ;;
568
+ + st2000)
569
+ + basic_machine=m68k-tandem
539
570
  + basic_os=
540
- ;;
541
- stratus)
542
- basic_machine=i860-stratus
543
- - os=sysv4
571
+ + ;;
572
+ + stratus)
573
+ + basic_machine=i860-stratus
544
574
  + basic_os=sysv4
545
- ;;
546
- sun2)
547
- basic_machine=m68000-sun
548
- - os=
575
+ + ;;
576
+ + sun2)
577
+ + basic_machine=m68000-sun
549
578
  + basic_os=
550
- ;;
551
- sun2os3)
552
- basic_machine=m68000-sun
553
- - os=sunos3
579
+ + ;;
580
+ + sun2os3)
581
+ + basic_machine=m68000-sun
554
582
  + basic_os=sunos3
555
- ;;
556
- sun2os4)
557
- basic_machine=m68000-sun
558
- - os=sunos4
583
+ + ;;
584
+ + sun2os4)
585
+ + basic_machine=m68000-sun
559
586
  + basic_os=sunos4
560
- ;;
561
- sun3)
562
- basic_machine=m68k-sun
563
- - os=
587
+ + ;;
588
+ + sun3)
589
+ + basic_machine=m68k-sun
564
590
  + basic_os=
565
- ;;
566
- sun3os3)
567
- basic_machine=m68k-sun
568
- - os=sunos3
591
+ + ;;
592
+ + sun3os3)
593
+ + basic_machine=m68k-sun
569
594
  + basic_os=sunos3
570
- ;;
571
- sun3os4)
572
- basic_machine=m68k-sun
573
- - os=sunos4
595
+ + ;;
596
+ + sun3os4)
597
+ + basic_machine=m68k-sun
574
598
  + basic_os=sunos4
575
- ;;
576
- sun4)
577
- basic_machine=sparc-sun
578
- - os=
599
+ + ;;
600
+ + sun4)
601
+ + basic_machine=sparc-sun
579
602
  + basic_os=
580
- ;;
581
- sun4os3)
582
- basic_machine=sparc-sun
583
- - os=sunos3
603
+ + ;;
604
+ + sun4os3)
605
+ + basic_machine=sparc-sun
584
606
  + basic_os=sunos3
585
- ;;
586
- sun4os4)
587
- basic_machine=sparc-sun
588
- - os=sunos4
607
+ + ;;
608
+ + sun4os4)
609
+ + basic_machine=sparc-sun
589
610
  + basic_os=sunos4
590
- ;;
591
- sun4sol2)
592
- basic_machine=sparc-sun
593
- - os=solaris2
611
+ + ;;
612
+ + sun4sol2)
613
+ + basic_machine=sparc-sun
594
614
  + basic_os=solaris2
595
- ;;
596
- sun386 | sun386i | roadrunner)
597
- basic_machine=i386-sun
598
- - os=
615
+ + ;;
616
+ + sun386 | sun386i | roadrunner)
617
+ + basic_machine=i386-sun
599
618
  + basic_os=
600
- ;;
601
- sv1)
602
- basic_machine=sv1-cray
603
- - os=unicos
619
+ + ;;
620
+ + sv1)
621
+ + basic_machine=sv1-cray
604
622
  + basic_os=unicos
605
- ;;
606
- symmetry)
607
- basic_machine=i386-sequent
608
- - os=dynix
623
+ + ;;
624
+ + symmetry)
625
+ + basic_machine=i386-sequent
609
626
  + basic_os=dynix
610
- ;;
611
- t3e)
612
- basic_machine=alphaev5-cray
613
- - os=unicos
627
+ + ;;
628
+ + t3e)
629
+ + basic_machine=alphaev5-cray
614
630
  + basic_os=unicos
615
- ;;
616
- t90)
617
- basic_machine=t90-cray
618
- - os=unicos
631
+ + ;;
632
+ + t90)
633
+ + basic_machine=t90-cray
619
634
  + basic_os=unicos
620
- ;;
621
- toad1)
622
- basic_machine=pdp10-xkl
623
- - os=tops20
635
+ + ;;
636
+ + toad1)
637
+ + basic_machine=pdp10-xkl
624
638
  + basic_os=tops20
625
- ;;
626
- tpf)
627
- basic_machine=s390x-ibm
628
- - os=tpf
639
+ + ;;
640
+ + tpf)
641
+ + basic_machine=s390x-ibm
629
642
  + basic_os=tpf
630
- ;;
631
- udi29k)
632
- basic_machine=a29k-amd
633
- - os=udi
643
+ + ;;
644
+ + udi29k)
645
+ + basic_machine=a29k-amd
634
646
  + basic_os=udi
635
- ;;
636
- ultra3)
637
- basic_machine=a29k-nyu
638
- - os=sym1
647
+ + ;;
648
+ + ultra3)
649
+ + basic_machine=a29k-nyu
639
650
  + basic_os=sym1
640
- ;;
641
- v810 | necv810)
642
- basic_machine=v810-nec
643
- - os=none
651
+ + ;;
652
+ + v810 | necv810)
653
+ + basic_machine=v810-nec
644
654
  + basic_os=none
645
- ;;
646
- vaxv)
647
- basic_machine=vax-dec
648
- - os=sysv
655
+ + ;;
656
+ + vaxv)
657
+ + basic_machine=vax-dec
649
658
  + basic_os=sysv
650
- ;;
651
- vms)
652
- basic_machine=vax-dec
653
- - os=vms
659
+ + ;;
660
+ + vms)
661
+ + basic_machine=vax-dec
654
662
  + basic_os=vms
655
663
  + ;;
656
664
  + vsta)
657
665
  + basic_machine=i386-pc
658
666
  + basic_os=vsta
659
- ;;
660
- vxworks960)
661
- basic_machine=i960-wrs
662
- - os=vxworks
667
+ + ;;
668
+ + vxworks960)
669
+ + basic_machine=i960-wrs
663
670
  + basic_os=vxworks
664
- ;;
665
- vxworks68)
666
- basic_machine=m68k-wrs
667
- - os=vxworks
671
+ + ;;
672
+ + vxworks68)
673
+ + basic_machine=m68k-wrs
668
674
  + basic_os=vxworks
669
- ;;
670
- vxworks29k)
671
- basic_machine=a29k-wrs
672
- - os=vxworks
675
+ + ;;
676
+ + vxworks29k)
677
+ + basic_machine=a29k-wrs
673
678
  + basic_os=vxworks
674
- ;;
675
- xbox)
676
- basic_machine=i686-pc
677
- - os=mingw32
679
+ + ;;
680
+ + xbox)
681
+ + basic_machine=i686-pc
678
682
  + basic_os=mingw32
679
- ;;
680
- ymp)
681
- basic_machine=ymp-cray
682
- - os=unicos
683
+ + ;;
684
+ + ymp)
685
+ + basic_machine=ymp-cray
683
686
  + basic_os=unicos
684
- ;;
685
- *)
686
- basic_machine=$1
687
- - os=
687
+ + ;;
688
+ + *)
689
+ + basic_machine=$1
688
690
  + basic_os=
689
- ;;
690
- esac
691
+ + ;;
692
+ + esac
693
+ ;;
694
+ esac
695
+
696
+ -# Decode aliases for certain CPU-COMPANY combinations.
697
+ +# Decode 1-component or ad-hoc basic machines
698
+ case $basic_machine in
699
+ - # Recognize the basic CPU types without company name.
700
+ - # Some are omitted here because they have special meanings below.
701
+ - 1750a | 580 \
702
+ - | a29k \
703
+ - | aarch64 | aarch64_be \
704
+ - | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
705
+ - | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
706
+ - | am33_2.0 \
707
+ - | arc | arceb \
708
+ - | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \
709
+ - | avr | avr32 \
710
+ - | ba \
711
+ - | be32 | be64 \
712
+ - | bfin \
713
+ - | c4x | c8051 | clipper \
714
+ - | d10v | d30v | dlx | dsp16xx \
715
+ - | e2k | epiphany \
716
+ - | fido | fr30 | frv | ft32 \
717
+ - | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
718
+ - | hexagon \
719
+ - | i370 | i860 | i960 | ia16 | ia64 \
720
+ - | ip2k | iq2000 \
721
+ - | k1om \
722
+ - | le32 | le64 \
723
+ - | lm32 \
724
+ - | m32c | m32r | m32rle | m68000 | m68k | m88k \
725
+ - | maxq | mb | microblaze | microblazeel | mcore | mep | metag \
726
+ - | mips | mipsbe | mipseb | mipsel | mipsle \
727
+ - | mips16 \
728
+ - | mips64 | mips64el \
729
+ - | mips64octeon | mips64octeonel \
730
+ - | mips64orion | mips64orionel \
731
+ - | mips64r5900 | mips64r5900el \
732
+ - | mips64vr | mips64vrel \
733
+ - | mips64vr4100 | mips64vr4100el \
734
+ - | mips64vr4300 | mips64vr4300el \
735
+ - | mips64vr5000 | mips64vr5000el \
736
+ - | mips64vr5900 | mips64vr5900el \
737
+ - | mipsisa32 | mipsisa32el \
738
+ - | mipsisa32r2 | mipsisa32r2el \
739
+ - | mipsisa32r6 | mipsisa32r6el \
740
+ - | mipsisa64 | mipsisa64el \
741
+ - | mipsisa64r2 | mipsisa64r2el \
742
+ - | mipsisa64r6 | mipsisa64r6el \
743
+ - | mipsisa64sb1 | mipsisa64sb1el \
744
+ - | mipsisa64sr71k | mipsisa64sr71kel \
745
+ - | mipsr5900 | mipsr5900el \
746
+ - | mipstx39 | mipstx39el \
747
+ - | mn10200 | mn10300 \
748
+ - | moxie \
749
+ - | mt \
750
+ - | msp430 \
751
+ - | nds32 | nds32le | nds32be \
752
+ - | nios | nios2 | nios2eb | nios2el \
753
+ - | ns16k | ns32k \
754
+ - | open8 | or1k | or1knd | or32 \
755
+ - | pdp10 | pj | pjl \
756
+ - | powerpc | powerpc64 | powerpc64le | powerpcle \
757
+ - | pru \
758
+ - | pyramid \
759
+ - | riscv32 | riscv64 \
760
+ - | rl78 | rx \
761
+ - | score \
762
+ - | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[234]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
763
+ - | sh64 | sh64le \
764
+ - | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
765
+ - | sparcv8 | sparcv9 | sparcv9b | sparcv9v \
766
+ - | spu \
767
+ - | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \
768
+ - | ubicom32 \
769
+ - | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \
770
+ - | visium \
771
+ - | wasm32 \
772
+ - | x86 | xc16x | xstormy16 | xtensa \
773
+ - | z8k | z80)
774
+ - basic_machine=$basic_machine-unknown
775
+ - ;;
776
+ - c54x)
777
+ - basic_machine=tic54x-unknown
778
+ - ;;
779
+ - c55x)
780
+ - basic_machine=tic55x-unknown
781
+ - ;;
782
+ - c6x)
783
+ - basic_machine=tic6x-unknown
784
+ - ;;
785
+ - leon|leon[3-9])
786
+ - basic_machine=sparc-$basic_machine
787
+ - ;;
788
+ - m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip)
789
+ - basic_machine=$basic_machine-unknown
790
+ - os=-none
791
+ + # Here we handle the default manufacturer of certain CPU types. It is in
792
+ + # some cases the only manufacturer, in others, it is the most popular.
793
+ + w89k)
794
+ + cpu=hppa1.1
795
+ + vendor=winbond
796
+ ;;
797
+ - m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65)
798
+ + op50n)
799
+ + cpu=hppa1.1
800
+ + vendor=oki
801
+ ;;
802
+ - ms1)
803
+ - basic_machine=mt-unknown
804
+ + op60c)
805
+ + cpu=hppa1.1
806
+ + vendor=oki
807
+ ;;
808
+ -
809
+ - strongarm | thumb | xscale)
810
+ - basic_machine=arm-unknown
811
+ + ibm*)
812
+ + cpu=i370
813
+ + vendor=ibm
814
+ ;;
815
+ - xgate)
816
+ - basic_machine=$basic_machine-unknown
817
+ - os=-none
818
+ + orion105)
819
+ + cpu=clipper
820
+ + vendor=highlevel
821
+ ;;
822
+ - xscaleeb)
823
+ - basic_machine=armeb-unknown
824
+ + mac | mpw | mac-mpw)
825
+ + cpu=m68k
826
+ + vendor=apple
827
+ ;;
828
+ -
829
+ - xscaleel)
830
+ - basic_machine=armel-unknown
831
+ + pmac | pmac-mpw)
832
+ + cpu=powerpc
833
+ + vendor=apple
834
+ ;;
835
+
836
+ - # We use `pc' rather than `unknown'
837
+ - # because (1) that's what they normally are, and
838
+ - # (2) the word "unknown" tends to confuse beginning users.
839
+ - i*86 | x86_64)
840
+ - basic_machine=$basic_machine-pc
841
+ - ;;
842
+ - # Object if more than one company name word.
843
+ - *-*-*)
844
+ - echo Invalid configuration \`"$1"\': machine \`"$basic_machine"\' not recognized 1>&2
845
+ - exit 1
846
+ - ;;
847
+ - # Recognize the basic CPU types with company name.
848
+ - 580-* \
849
+ - | a29k-* \
850
+ - | aarch64-* | aarch64_be-* \
851
+ - | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
852
+ - | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
853
+ - | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \
854
+ - | arm-* | armbe-* | armle-* | armeb-* | armv*-* \
855
+ - | avr-* | avr32-* \
856
+ - | ba-* \
857
+ - | be32-* | be64-* \
858
+ - | bfin-* | bs2000-* \
859
+ - | c[123]* | c30-* | [cjt]90-* | c4x-* \
860
+ - | c8051-* | clipper-* | craynv-* | cydra-* \
861
+ - | d10v-* | d30v-* | dlx-* \
862
+ - | e2k-* | elxsi-* \
863
+ - | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \
864
+ - | h8300-* | h8500-* \
865
+ - | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
866
+ - | hexagon-* \
867
+ - | i*86-* | i860-* | i960-* | ia16-* | ia64-* \
868
+ - | ip2k-* | iq2000-* \
869
+ - | k1om-* \
870
+ - | le32-* | le64-* \
871
+ - | lm32-* \
872
+ - | m32c-* | m32r-* | m32rle-* \
873
+ - | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
874
+ - | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \
875
+ - | microblaze-* | microblazeel-* \
876
+ - | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
877
+ - | mips16-* \
878
+ - | mips64-* | mips64el-* \
879
+ - | mips64octeon-* | mips64octeonel-* \
880
+ - | mips64orion-* | mips64orionel-* \
881
+ - | mips64r5900-* | mips64r5900el-* \
882
+ - | mips64vr-* | mips64vrel-* \
883
+ - | mips64vr4100-* | mips64vr4100el-* \
884
+ - | mips64vr4300-* | mips64vr4300el-* \
885
+ - | mips64vr5000-* | mips64vr5000el-* \
886
+ - | mips64vr5900-* | mips64vr5900el-* \
887
+ - | mipsisa32-* | mipsisa32el-* \
888
+ - | mipsisa32r2-* | mipsisa32r2el-* \
889
+ - | mipsisa32r6-* | mipsisa32r6el-* \
890
+ - | mipsisa64-* | mipsisa64el-* \
891
+ - | mipsisa64r2-* | mipsisa64r2el-* \
892
+ - | mipsisa64r6-* | mipsisa64r6el-* \
893
+ - | mipsisa64sb1-* | mipsisa64sb1el-* \
894
+ - | mipsisa64sr71k-* | mipsisa64sr71kel-* \
895
+ - | mipsr5900-* | mipsr5900el-* \
896
+ - | mipstx39-* | mipstx39el-* \
897
+ - | mmix-* \
898
+ - | mt-* \
899
+ - | msp430-* \
900
+ - | nds32-* | nds32le-* | nds32be-* \
901
+ - | nios-* | nios2-* | nios2eb-* | nios2el-* \
902
+ - | none-* | np1-* | ns16k-* | ns32k-* \
903
+ - | open8-* \
904
+ - | or1k*-* \
905
+ - | orion-* \
906
+ - | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
907
+ - | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \
908
+ - | pru-* \
909
+ - | pyramid-* \
910
+ - | riscv32-* | riscv64-* \
911
+ - | rl78-* | romp-* | rs6000-* | rx-* \
912
+ - | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
913
+ - | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
914
+ - | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
915
+ - | sparclite-* \
916
+ - | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx*-* \
917
+ - | tahoe-* \
918
+ - | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
919
+ - | tile*-* \
920
+ - | tron-* \
921
+ - | ubicom32-* \
922
+ - | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \
923
+ - | vax-* \
924
+ - | visium-* \
925
+ - | wasm32-* \
926
+ - | we32k-* \
927
+ - | x86-* | x86_64-* | xc16x-* | xps100-* \
928
+ - | xstormy16-* | xtensa*-* \
929
+ - | ymp-* \
930
+ - | z8k-* | z80-*)
931
+ - ;;
932
+ - # Recognize the basic CPU types without company name, with glob match.
933
+ - xtensa*)
934
+ - basic_machine=$basic_machine-unknown
935
+ - ;;
936
+ # Recognize the various machine names and aliases which stand
937
+ # for a CPU type and a company and sometimes even an OS.
938
+ - 386bsd)
939
+ - basic_machine=i386-pc
940
+ - os=-bsd
941
+ - ;;
942
+ 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
943
+ - basic_machine=m68000-att
944
+ + cpu=m68000
945
+ + vendor=att
946
+ ;;
947
+ 3b*)
948
+ - basic_machine=we32k-att
949
+ - ;;
950
+ - a29khif)
951
+ - basic_machine=a29k-amd
952
+ - os=-udi
953
+ - ;;
954
+ - abacus)
955
+ - basic_machine=abacus-unknown
956
+ - ;;
957
+ - adobe68k)
958
+ - basic_machine=m68010-adobe
959
+ - os=-scout
960
+ - ;;
961
+ - alliant | fx80)
962
+ - basic_machine=fx80-alliant
963
+ - ;;
964
+ - altos | altos3068)
965
+ - basic_machine=m68k-altos
966
+ - ;;
967
+ - am29k)
968
+ - basic_machine=a29k-none
969
+ - os=-bsd
970
+ - ;;
971
+ - amd64)
972
+ - basic_machine=x86_64-pc
973
+ - ;;
974
+ - amd64-*)
975
+ - basic_machine=x86_64-`echo "$basic_machine" | sed 's/^[^-]*-//'`
976
+ - ;;
977
+ - amdahl)
978
+ - basic_machine=580-amdahl
979
+ - os=-sysv
980
+ - ;;
981
+ - amiga | amiga-*)
982
+ - basic_machine=m68k-unknown
983
+ - ;;
984
+ - amigaos | amigados)
985
+ - basic_machine=m68k-unknown
986
+ - os=-amigaos
987
+ - ;;
988
+ - amigaunix | amix)
989
+ - basic_machine=m68k-unknown
990
+ - os=-sysv4
991
+ - ;;
992
+ - apollo68)
993
+ - basic_machine=m68k-apollo
994
+ - os=-sysv
995
+ - ;;
996
+ - apollo68bsd)
997
+ - basic_machine=m68k-apollo
998
+ - os=-bsd
999
+ - ;;
1000
+ - aros)
1001
+ - basic_machine=i386-pc
1002
+ - os=-aros
1003
+ - ;;
1004
+ - asmjs)
1005
+ - basic_machine=asmjs-unknown
1006
+ - ;;
1007
+ - aux)
1008
+ - basic_machine=m68k-apple
1009
+ - os=-aux
1010
+ - ;;
1011
+ - balance)
1012
+ - basic_machine=ns32k-sequent
1013
+ - os=-dynix
1014
+ - ;;
1015
+ - blackfin)
1016
+ - basic_machine=bfin-unknown
1017
+ - os=-linux
1018
+ - ;;
1019
+ - blackfin-*)
1020
+ - basic_machine=bfin-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1021
+ - os=-linux
1022
+ + cpu=we32k
1023
+ + vendor=att
691
1024
  ;;
692
- @@ -685,17 +686,17 @@
693
1025
  bluegene*)
694
- cpu=powerpc
695
- vendor=ibm
696
- - os=cnk
1026
+ - basic_machine=powerpc-ibm
1027
+ - os=-cnk
1028
+ - ;;
1029
+ - c54x-*)
1030
+ - basic_machine=tic54x-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1031
+ - ;;
1032
+ - c55x-*)
1033
+ - basic_machine=tic55x-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1034
+ - ;;
1035
+ - c6x-*)
1036
+ - basic_machine=tic6x-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1037
+ - ;;
1038
+ - c90)
1039
+ - basic_machine=c90-cray
1040
+ - os=-unicos
1041
+ - ;;
1042
+ - cegcc)
1043
+ - basic_machine=arm-unknown
1044
+ - os=-cegcc
1045
+ - ;;
1046
+ - convex-c1)
1047
+ - basic_machine=c1-convex
1048
+ - os=-bsd
1049
+ - ;;
1050
+ - convex-c2)
1051
+ - basic_machine=c2-convex
1052
+ - os=-bsd
1053
+ - ;;
1054
+ - convex-c32)
1055
+ - basic_machine=c32-convex
1056
+ - os=-bsd
1057
+ - ;;
1058
+ - convex-c34)
1059
+ - basic_machine=c34-convex
1060
+ - os=-bsd
1061
+ - ;;
1062
+ - convex-c38)
1063
+ - basic_machine=c38-convex
1064
+ - os=-bsd
1065
+ - ;;
1066
+ - cray | j90)
1067
+ - basic_machine=j90-cray
1068
+ - os=-unicos
1069
+ - ;;
1070
+ - craynv)
1071
+ - basic_machine=craynv-cray
1072
+ - os=-unicosmp
1073
+ - ;;
1074
+ - cr16 | cr16-*)
1075
+ - basic_machine=cr16-unknown
1076
+ - os=-elf
1077
+ - ;;
1078
+ - crds | unos)
1079
+ - basic_machine=m68k-crds
1080
+ - ;;
1081
+ - crisv32 | crisv32-* | etraxfs*)
1082
+ - basic_machine=crisv32-axis
1083
+ - ;;
1084
+ - cris | cris-* | etrax*)
1085
+ - basic_machine=cris-axis
1086
+ - ;;
1087
+ - crx)
1088
+ - basic_machine=crx-unknown
1089
+ - os=-elf
1090
+ - ;;
1091
+ - da30 | da30-*)
1092
+ - basic_machine=m68k-da30
1093
+ - ;;
1094
+ - decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
1095
+ - basic_machine=mips-dec
1096
+ + cpu=powerpc
1097
+ + vendor=ibm
697
1098
  + basic_os=cnk
698
1099
  ;;
699
1100
  decsystem10* | dec10*)
700
- cpu=pdp10
701
- vendor=dec
702
- - os=tops10
1101
+ - basic_machine=pdp10-dec
1102
+ - os=-tops10
1103
+ + cpu=pdp10
1104
+ + vendor=dec
703
1105
  + basic_os=tops10
704
1106
  ;;
705
1107
  decsystem20* | dec20*)
706
- cpu=pdp10
707
- vendor=dec
708
- - os=tops20
1108
+ - basic_machine=pdp10-dec
1109
+ - os=-tops20
1110
+ + cpu=pdp10
1111
+ + vendor=dec
709
1112
  + basic_os=tops20
710
1113
  ;;
711
1114
  delta | 3300 | motorola-3300 | motorola-delta \
712
1115
  | 3300-motorola | delta-motorola)
713
- @@ -705,7 +706,7 @@
1116
+ - basic_machine=m68k-motorola
1117
+ - ;;
1118
+ - delta88)
1119
+ - basic_machine=m88k-motorola
1120
+ - os=-sysv3
1121
+ - ;;
1122
+ - dicos)
1123
+ - basic_machine=i686-pc
1124
+ - os=-dicos
1125
+ - ;;
1126
+ - djgpp)
1127
+ - basic_machine=i586-pc
1128
+ - os=-msdosdjgpp
1129
+ - ;;
1130
+ - dpx20 | dpx20-*)
1131
+ - basic_machine=rs6000-bull
1132
+ - os=-bosx
1133
+ + cpu=m68k
1134
+ + vendor=motorola
1135
+ ;;
714
1136
  dpx2*)
715
- cpu=m68k
716
- vendor=bull
717
- - os=sysv3
1137
+ - basic_machine=m68k-bull
1138
+ - os=-sysv3
1139
+ - ;;
1140
+ - e500v[12])
1141
+ - basic_machine=powerpc-unknown
1142
+ - os=$os"spe"
1143
+ - ;;
1144
+ - e500v[12]-*)
1145
+ - basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1146
+ - os=$os"spe"
1147
+ - ;;
1148
+ - ebmon29k)
1149
+ - basic_machine=a29k-amd
1150
+ - os=-ebmon
1151
+ - ;;
1152
+ - elxsi)
1153
+ - basic_machine=elxsi-elxsi
1154
+ - os=-bsd
1155
+ + cpu=m68k
1156
+ + vendor=bull
718
1157
  + basic_os=sysv3
719
1158
  ;;
720
1159
  encore | umax | mmax)
721
- cpu=ns32k
722
- @@ -714,7 +715,7 @@
723
- elxsi)
724
- cpu=elxsi
725
- vendor=elxsi
726
- - os=${os:-bsd}
1160
+ - basic_machine=ns32k-encore
1161
+ + cpu=ns32k
1162
+ + vendor=encore
1163
+ ;;
1164
+ - es1800 | OSE68k | ose68k | ose | OSE)
1165
+ - basic_machine=m68k-ericsson
1166
+ - os=-ose
1167
+ + elxsi)
1168
+ + cpu=elxsi
1169
+ + vendor=elxsi
727
1170
  + basic_os=${basic_os:-bsd}
728
1171
  ;;
729
1172
  fx2800)
730
- cpu=i860
731
- @@ -727,7 +728,7 @@
1173
+ - basic_machine=i860-alliant
1174
+ + cpu=i860
1175
+ + vendor=alliant
1176
+ ;;
1177
+ genix)
1178
+ - basic_machine=ns32k-ns
1179
+ - ;;
1180
+ - gmicro)
1181
+ - basic_machine=tron-gmicro
1182
+ - os=-sysv
1183
+ - ;;
1184
+ - go32)
1185
+ - basic_machine=i386-pc
1186
+ - os=-go32
1187
+ + cpu=ns32k
1188
+ + vendor=ns
1189
+ ;;
732
1190
  h3050r* | hiux*)
733
- cpu=hppa1.1
734
- vendor=hitachi
735
- - os=hiuxwe2
1191
+ - basic_machine=hppa1.1-hitachi
1192
+ - os=-hiuxwe2
1193
+ - ;;
1194
+ - h8300hms)
1195
+ - basic_machine=h8300-hitachi
1196
+ - os=-hms
1197
+ - ;;
1198
+ - h8300xray)
1199
+ - basic_machine=h8300-hitachi
1200
+ - os=-xray
1201
+ - ;;
1202
+ - h8500hms)
1203
+ - basic_machine=h8500-hitachi
1204
+ - os=-hms
1205
+ - ;;
1206
+ - harris)
1207
+ - basic_machine=m88k-harris
1208
+ - os=-sysv3
1209
+ - ;;
1210
+ - hp300-*)
1211
+ - basic_machine=m68k-hp
1212
+ - ;;
1213
+ - hp300bsd)
1214
+ - basic_machine=m68k-hp
1215
+ - os=-bsd
1216
+ - ;;
1217
+ - hp300hpux)
1218
+ - basic_machine=m68k-hp
1219
+ - os=-hpux
1220
+ + cpu=hppa1.1
1221
+ + vendor=hitachi
736
1222
  + basic_os=hiuxwe2
737
1223
  ;;
738
1224
  hp3k9[0-9][0-9] | hp9[0-9][0-9])
739
- cpu=hppa1.0
740
- @@ -768,38 +769,38 @@
741
- vendor=hp
1225
+ - basic_machine=hppa1.0-hp
1226
+ + cpu=hppa1.0
1227
+ + vendor=hp
1228
+ ;;
1229
+ hp9k2[0-9][0-9] | hp9k31[0-9])
1230
+ - basic_machine=m68000-hp
1231
+ + cpu=m68000
1232
+ + vendor=hp
1233
+ ;;
1234
+ hp9k3[2-9][0-9])
1235
+ - basic_machine=m68k-hp
1236
+ + cpu=m68k
1237
+ + vendor=hp
1238
+ ;;
1239
+ hp9k6[0-9][0-9] | hp6[0-9][0-9])
1240
+ - basic_machine=hppa1.0-hp
1241
+ + cpu=hppa1.0
1242
+ + vendor=hp
1243
+ ;;
1244
+ hp9k7[0-79][0-9] | hp7[0-79][0-9])
1245
+ - basic_machine=hppa1.1-hp
1246
+ + cpu=hppa1.1
1247
+ + vendor=hp
1248
+ ;;
1249
+ hp9k78[0-9] | hp78[0-9])
1250
+ # FIXME: really hppa2.0-hp
1251
+ - basic_machine=hppa1.1-hp
1252
+ + cpu=hppa1.1
1253
+ + vendor=hp
1254
+ ;;
1255
+ hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893)
1256
+ # FIXME: really hppa2.0-hp
1257
+ - basic_machine=hppa1.1-hp
1258
+ + cpu=hppa1.1
1259
+ + vendor=hp
1260
+ ;;
1261
+ hp9k8[0-9][13679] | hp8[0-9][13679])
1262
+ - basic_machine=hppa1.1-hp
1263
+ + cpu=hppa1.1
1264
+ + vendor=hp
1265
+ ;;
1266
+ hp9k8[0-9][0-9] | hp8[0-9][0-9])
1267
+ - basic_machine=hppa1.0-hp
1268
+ - ;;
1269
+ - hppaosf)
1270
+ - basic_machine=hppa1.1-hp
1271
+ - os=-osf
1272
+ - ;;
1273
+ - hppro)
1274
+ - basic_machine=hppa1.1-hp
1275
+ - os=-proelf
1276
+ - ;;
1277
+ - i370-ibm* | ibm*)
1278
+ - basic_machine=i370-ibm
1279
+ + cpu=hppa1.0
1280
+ + vendor=hp
742
1281
  ;;
743
1282
  i*86v32)
744
- - cpu=`echo "$1" | sed -e 's/86.*/86/'`
1283
+ - basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
1284
+ - os=-sysv32
745
1285
  + cpu=$(echo "$1" | sed -e 's/86.*/86/')
746
- vendor=pc
747
- - os=sysv32
1286
+ + vendor=pc
748
1287
  + basic_os=sysv32
749
1288
  ;;
750
1289
  i*86v4*)
751
- - cpu=`echo "$1" | sed -e 's/86.*/86/'`
1290
+ - basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
1291
+ - os=-sysv4
752
1292
  + cpu=$(echo "$1" | sed -e 's/86.*/86/')
753
- vendor=pc
754
- - os=sysv4
1293
+ + vendor=pc
755
1294
  + basic_os=sysv4
756
1295
  ;;
757
1296
  i*86v)
758
- - cpu=`echo "$1" | sed -e 's/86.*/86/'`
1297
+ - basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
1298
+ - os=-sysv
759
1299
  + cpu=$(echo "$1" | sed -e 's/86.*/86/')
760
- vendor=pc
761
- - os=sysv
1300
+ + vendor=pc
762
1301
  + basic_os=sysv
763
1302
  ;;
764
1303
  i*86sol2)
765
- - cpu=`echo "$1" | sed -e 's/86.*/86/'`
1304
+ - basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
1305
+ - os=-solaris2
1306
+ - ;;
1307
+ - i386mach)
1308
+ - basic_machine=i386-mach
1309
+ - os=-mach
1310
+ - ;;
1311
+ - vsta)
1312
+ - basic_machine=i386-unknown
1313
+ - os=-vsta
766
1314
  + cpu=$(echo "$1" | sed -e 's/86.*/86/')
767
- vendor=pc
768
- - os=solaris2
1315
+ + vendor=pc
769
1316
  + basic_os=solaris2
770
- ;;
771
- j90 | j90-cray)
772
- cpu=j90
773
- vendor=cray
774
- - os=${os:-unicos}
1317
+ + ;;
1318
+ + j90 | j90-cray)
1319
+ + cpu=j90
1320
+ + vendor=cray
775
1321
  + basic_os=${basic_os:-unicos}
776
1322
  ;;
777
1323
  iris | iris4d)
778
- cpu=mips
779
- vendor=sgi
1324
+ - basic_machine=mips-sgi
780
1325
  - case $os in
1326
+ - -irix*)
1327
+ + cpu=mips
1328
+ + vendor=sgi
781
1329
  + case $basic_os in
782
- irix*)
1330
+ + irix*)
783
1331
  ;;
784
1332
  *)
785
- - os=irix4
1333
+ - os=-irix4
786
1334
  + basic_os=irix4
787
1335
  ;;
788
1336
  esac
789
1337
  ;;
790
- @@ -810,24 +811,26 @@
791
- *mint | mint[0-9]* | *MiNT | *MiNT[0-9]*)
792
- cpu=m68k
793
- vendor=atari
794
- - os=mint
1338
+ - isi68 | isi)
1339
+ - basic_machine=m68k-isi
1340
+ - os=-sysv
1341
+ - ;;
1342
+ - leon-*|leon[3-9]-*)
1343
+ - basic_machine=sparc-`echo "$basic_machine" | sed 's/-.*//'`
1344
+ - ;;
1345
+ - m68knommu)
1346
+ - basic_machine=m68k-unknown
1347
+ - os=-linux
1348
+ - ;;
1349
+ - m68knommu-*)
1350
+ - basic_machine=m68k-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1351
+ - os=-linux
1352
+ - ;;
1353
+ - magnum | m3230)
1354
+ - basic_machine=mips-mips
1355
+ - os=-sysv
1356
+ - ;;
1357
+ - merlin)
1358
+ - basic_machine=ns32k-utek
1359
+ - os=-sysv
1360
+ - ;;
1361
+ - microblaze*)
1362
+ - basic_machine=microblaze-xilinx
1363
+ - ;;
1364
+ - mingw64)
1365
+ - basic_machine=x86_64-pc
1366
+ - os=-mingw64
1367
+ - ;;
1368
+ - mingw32)
1369
+ - basic_machine=i686-pc
1370
+ - os=-mingw32
1371
+ - ;;
1372
+ - mingw32ce)
1373
+ - basic_machine=arm-unknown
1374
+ - os=-mingw32ce
1375
+ - ;;
1376
+ miniframe)
1377
+ - basic_machine=m68000-convergent
1378
+ - ;;
1379
+ - *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*)
1380
+ - basic_machine=m68k-atari
1381
+ - os=-mint
1382
+ - ;;
1383
+ - mips3*-*)
1384
+ - basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'`
1385
+ + cpu=m68000
1386
+ + vendor=convergent
1387
+ ;;
1388
+ - mips3*)
1389
+ - basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'`-unknown
1390
+ - ;;
1391
+ - monitor)
1392
+ - basic_machine=m68k-rom68k
1393
+ - os=-coff
1394
+ - ;;
1395
+ - morphos)
1396
+ - basic_machine=powerpc-unknown
1397
+ - os=-morphos
1398
+ - ;;
1399
+ - moxiebox)
1400
+ - basic_machine=moxie-unknown
1401
+ - os=-moxiebox
1402
+ - ;;
1403
+ - msdos)
1404
+ - basic_machine=i386-pc
1405
+ - os=-msdos
1406
+ - ;;
1407
+ - ms1-*)
1408
+ - basic_machine=`echo "$basic_machine" | sed -e 's/ms1-/mt-/'`
1409
+ - ;;
1410
+ - msys)
1411
+ - basic_machine=i686-pc
1412
+ - os=-msys
1413
+ - ;;
1414
+ - mvs)
1415
+ - basic_machine=i370-ibm
1416
+ - os=-mvs
1417
+ - ;;
1418
+ - nacl)
1419
+ - basic_machine=le32-unknown
1420
+ - os=-nacl
1421
+ - ;;
1422
+ - ncr3000)
1423
+ - basic_machine=i486-ncr
1424
+ - os=-sysv4
1425
+ - ;;
1426
+ - netbsd386)
1427
+ - basic_machine=i386-unknown
1428
+ - os=-netbsd
1429
+ - ;;
1430
+ - netwinder)
1431
+ - basic_machine=armv4l-rebel
1432
+ - os=-linux
1433
+ - ;;
1434
+ - news | news700 | news800 | news900)
1435
+ - basic_machine=m68k-sony
1436
+ - os=-newsos
1437
+ - ;;
1438
+ - news1000)
1439
+ - basic_machine=m68030-sony
1440
+ - os=-newsos
1441
+ + *mint | mint[0-9]* | *MiNT | *MiNT[0-9]*)
1442
+ + cpu=m68k
1443
+ + vendor=atari
795
1444
  + basic_os=mint
796
1445
  ;;
797
1446
  news-3600 | risc-news)
798
- cpu=mips
799
- vendor=sony
800
- - os=newsos
1447
+ - basic_machine=mips-sony
1448
+ - os=-newsos
1449
+ - ;;
1450
+ - necv70)
1451
+ - basic_machine=v70-nec
1452
+ - os=-sysv
1453
+ + cpu=mips
1454
+ + vendor=sony
801
1455
  + basic_os=newsos
802
1456
  ;;
803
1457
  next | m*-next)
804
- cpu=m68k
805
- vendor=next
1458
+ - basic_machine=m68k-next
806
1459
  - case $os in
807
- - nextstep* )
1460
+ - -nextstep* )
1461
+ + cpu=m68k
1462
+ + vendor=next
808
1463
  + case $basic_os in
809
1464
  + openstep*)
810
1465
  + ;;
811
1466
  + nextstep*)
812
1467
  ;;
813
- ns2*)
814
- - os=nextstep2
1468
+ - -ns2*)
1469
+ - os=-nextstep2
1470
+ + ns2*)
815
1471
  + basic_os=nextstep2
816
1472
  ;;
817
1473
  *)
818
- - os=nextstep3
1474
+ - os=-nextstep3
819
1475
  + basic_os=nextstep3
820
1476
  ;;
821
1477
  esac
822
1478
  ;;
823
- @@ -838,12 +841,12 @@
1479
+ - nh3000)
1480
+ - basic_machine=m68k-harris
1481
+ - os=-cxux
1482
+ - ;;
1483
+ - nh[45]000)
1484
+ - basic_machine=m88k-harris
1485
+ - os=-cxux
1486
+ - ;;
1487
+ - nindy960)
1488
+ - basic_machine=i960-intel
1489
+ - os=-nindy
1490
+ - ;;
1491
+ - mon960)
1492
+ - basic_machine=i960-intel
1493
+ - os=-mon960
1494
+ - ;;
1495
+ - nonstopux)
1496
+ - basic_machine=mips-compaq
1497
+ - os=-nonstopux
1498
+ - ;;
1499
+ np1)
1500
+ - basic_machine=np1-gould
1501
+ - ;;
1502
+ - neo-tandem)
1503
+ - basic_machine=neo-tandem
1504
+ - ;;
1505
+ - nse-tandem)
1506
+ - basic_machine=nse-tandem
1507
+ - ;;
1508
+ - nsr-tandem)
1509
+ - basic_machine=nsr-tandem
1510
+ - ;;
1511
+ - nsv-tandem)
1512
+ - basic_machine=nsv-tandem
1513
+ - ;;
1514
+ - nsx-tandem)
1515
+ - basic_machine=nsx-tandem
1516
+ + cpu=np1
1517
+ + vendor=gould
1518
+ ;;
824
1519
  op50n-* | op60c-*)
825
- cpu=hppa1.1
826
- vendor=oki
827
- - os=proelf
1520
+ - basic_machine=hppa1.1-oki
1521
+ - os=-proelf
1522
+ - ;;
1523
+ - openrisc | openrisc-*)
1524
+ - basic_machine=or32-unknown
1525
+ - ;;
1526
+ - os400)
1527
+ - basic_machine=powerpc-ibm
1528
+ - os=-os400
1529
+ - ;;
1530
+ - OSE68000 | ose68000)
1531
+ - basic_machine=m68000-ericsson
1532
+ - os=-ose
1533
+ - ;;
1534
+ - os68k)
1535
+ - basic_machine=m68k-none
1536
+ - os=-os68k
1537
+ + cpu=hppa1.1
1538
+ + vendor=oki
828
1539
  + basic_os=proelf
829
1540
  ;;
830
1541
  pa-hitachi)
831
- cpu=hppa1.1
832
- vendor=hitachi
833
- - os=hiuxwe2
1542
+ - basic_machine=hppa1.1-hitachi
1543
+ - os=-hiuxwe2
1544
+ - ;;
1545
+ - paragon)
1546
+ - basic_machine=i860-intel
1547
+ - os=-osf
1548
+ - ;;
1549
+ - parisc)
1550
+ - basic_machine=hppa-unknown
1551
+ - os=-linux
1552
+ - ;;
1553
+ - parisc-*)
1554
+ - basic_machine=hppa-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1555
+ - os=-linux
1556
+ + cpu=hppa1.1
1557
+ + vendor=hitachi
834
1558
  + basic_os=hiuxwe2
835
1559
  ;;
836
1560
  pbd)
837
- cpu=sparc
838
- @@ -880,12 +883,12 @@
839
- sde)
840
- cpu=mipsisa32
841
- vendor=sde
842
- - os=${os:-elf}
1561
+ - basic_machine=sparc-tti
1562
+ + cpu=sparc
1563
+ + vendor=tti
1564
+ ;;
1565
+ pbb)
1566
+ - basic_machine=m68k-tti
1567
+ + cpu=m68k
1568
+ + vendor=tti
1569
+ ;;
1570
+ - pc532 | pc532-*)
1571
+ - basic_machine=ns32k-pc532
1572
+ + pc532)
1573
+ + cpu=ns32k
1574
+ + vendor=pc532
1575
+ ;;
1576
+ - pc98)
1577
+ - basic_machine=i386-pc
1578
+ + pn)
1579
+ + cpu=pn
1580
+ + vendor=gould
1581
+ ;;
1582
+ - pc98-*)
1583
+ - basic_machine=i386-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1584
+ + power)
1585
+ + cpu=power
1586
+ + vendor=ibm
1587
+ ;;
1588
+ - pentium | p5 | k5 | k6 | nexgen | viac3)
1589
+ - basic_machine=i586-pc
1590
+ + ps2)
1591
+ + cpu=i386
1592
+ + vendor=ibm
1593
+ ;;
1594
+ - pentiumpro | p6 | 6x86 | athlon | athlon_*)
1595
+ - basic_machine=i686-pc
1596
+ + rm[46]00)
1597
+ + cpu=mips
1598
+ + vendor=siemens
1599
+ ;;
1600
+ - pentiumii | pentium2 | pentiumiii | pentium3)
1601
+ - basic_machine=i686-pc
1602
+ + rtpc | rtpc-*)
1603
+ + cpu=romp
1604
+ + vendor=ibm
1605
+ ;;
1606
+ - pentium4)
1607
+ - basic_machine=i786-pc
1608
+ + sde)
1609
+ + cpu=mipsisa32
1610
+ + vendor=sde
843
1611
  + basic_os=${basic_os:-elf}
844
1612
  ;;
845
- simso-wrs)
846
- cpu=sparclite
847
- vendor=wrs
848
- - os=vxworks
1613
+ - pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
1614
+ - basic_machine=i586-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1615
+ + simso-wrs)
1616
+ + cpu=sparclite
1617
+ + vendor=wrs
849
1618
  + basic_os=vxworks
850
1619
  ;;
851
- tower | tower-32)
852
- cpu=m68k
853
- @@ -902,7 +905,7 @@
854
- w89k-*)
855
- cpu=hppa1.1
856
- vendor=winbond
857
- - os=proelf
1620
+ - pentiumpro-* | p6-* | 6x86-* | athlon-*)
1621
+ - basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1622
+ + tower | tower-32)
1623
+ + cpu=m68k
1624
+ + vendor=ncr
1625
+ ;;
1626
+ - pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
1627
+ - basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1628
+ + vpp*|vx|vx-*)
1629
+ + cpu=f301
1630
+ + vendor=fujitsu
1631
+ ;;
1632
+ - pentium4-*)
1633
+ - basic_machine=i786-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1634
+ + w65)
1635
+ + cpu=w65
1636
+ + vendor=wdc
1637
+ ;;
1638
+ - pn)
1639
+ - basic_machine=pn-gould
1640
+ + w89k-*)
1641
+ + cpu=hppa1.1
1642
+ + vendor=winbond
858
1643
  + basic_os=proelf
859
1644
  ;;
860
- none)
861
- cpu=none
862
- @@ -914,11 +917,12 @@
863
- ;;
864
- leon-*|leon[3-9]-*)
865
- cpu=sparc
866
- - vendor=`echo "$basic_machine" | sed 's/-.*//'`
1645
+ - power) basic_machine=power-ibm
1646
+ + none)
1647
+ + cpu=none
1648
+ + vendor=none
1649
+ ;;
1650
+ - ppc | ppcbe) basic_machine=powerpc-unknown
1651
+ + leon|leon[3-9])
1652
+ + cpu=sparc
1653
+ + vendor=$basic_machine
1654
+ ;;
1655
+ - ppc-* | ppcbe-*)
1656
+ - basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1657
+ + leon-*|leon[3-9]-*)
1658
+ + cpu=sparc
867
1659
  + vendor=$(echo "$basic_machine" | sed 's/-.*//')
868
1660
  ;;
869
-
870
- *-*)
871
- - IFS="-" read -r cpu vendor <<EOF
1661
+ - ppcle | powerpclittle)
1662
+ - basic_machine=powerpcle-unknown
1663
+ +
1664
+ + *-*)
872
1665
  + # shellcheck disable=SC2162
873
1666
  + IFS="-" read cpu vendor <<EOF
874
- $basic_machine
875
- EOF
1667
+ +$basic_machine
1668
+ +EOF
876
1669
  ;;
877
- @@ -950,15 +954,15 @@
878
-
879
- # Decode basic machines in the full and proper CPU-Company form.
880
- case $cpu-$vendor in
881
- - # Here we handle the default manufacturer of certain CPU types in cannonical form. It is in
1670
+ - ppcle-* | powerpclittle-*)
1671
+ - basic_machine=powerpcle-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1672
+ + # We use `pc' rather than `unknown'
1673
+ + # because (1) that's what they normally are, and
1674
+ + # (2) the word "unknown" tends to confuse beginning users.
1675
+ + i*86 | x86_64)
1676
+ + cpu=$basic_machine
1677
+ + vendor=pc
1678
+ ;;
1679
+ - ppc64) basic_machine=powerpc64-unknown
1680
+ + # These rules are duplicated from below for sake of the special case above;
1681
+ + # i.e. things that normalized to x86 arches should also default to "pc"
1682
+ + pc98)
1683
+ + cpu=i386
1684
+ + vendor=pc
1685
+ ;;
1686
+ - ppc64-*) basic_machine=powerpc64-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1687
+ + x64 | amd64)
1688
+ + cpu=x86_64
1689
+ + vendor=pc
1690
+ ;;
1691
+ - ppc64le | powerpc64little)
1692
+ - basic_machine=powerpc64le-unknown
1693
+ + # Recognize the basic CPU types without company name.
1694
+ + *)
1695
+ + cpu=$basic_machine
1696
+ + vendor=unknown
1697
+ ;;
1698
+ - ppc64le-* | powerpc64little-*)
1699
+ - basic_machine=powerpc64le-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1700
+ +esac
1701
+ +
1702
+ +unset -v basic_machine
1703
+ +
1704
+ +# Decode basic machines in the full and proper CPU-Company form.
1705
+ +case $cpu-$vendor in
882
1706
  + # Here we handle the default manufacturer of certain CPU types in canonical form. It is in
883
- # some cases the only manufacturer, in others, it is the most popular.
884
- craynv-unknown)
885
- vendor=cray
886
- - os=${os:-unicosmp}
1707
+ + # some cases the only manufacturer, in others, it is the most popular.
1708
+ + craynv-unknown)
1709
+ + vendor=cray
887
1710
  + basic_os=${basic_os:-unicosmp}
888
1711
  ;;
889
- c90-unknown | c90-cray)
890
- vendor=cray
891
- - os=${os:-unicos}
1712
+ - ps2)
1713
+ - basic_machine=i386-ibm
1714
+ + c90-unknown | c90-cray)
1715
+ + vendor=cray
892
1716
  + basic_os=${Basic_os:-unicos}
893
1717
  ;;
894
- fx80-unknown)
895
- vendor=alliant
896
- @@ -1002,7 +1006,7 @@
897
- dpx20-unknown | dpx20-bull)
898
- cpu=rs6000
899
- vendor=bull
900
- - os=${os:-bosx}
1718
+ - pw32)
1719
+ - basic_machine=i586-unknown
1720
+ - os=-pw32
1721
+ - ;;
1722
+ - rdos | rdos64)
1723
+ - basic_machine=x86_64-pc
1724
+ - os=-rdos
1725
+ - ;;
1726
+ - rdos32)
1727
+ - basic_machine=i386-pc
1728
+ - os=-rdos
1729
+ - ;;
1730
+ - rom68k)
1731
+ - basic_machine=m68k-rom68k
1732
+ - os=-coff
1733
+ + fx80-unknown)
1734
+ + vendor=alliant
1735
+ ;;
1736
+ - rm[46]00)
1737
+ - basic_machine=mips-siemens
1738
+ + romp-unknown)
1739
+ + vendor=ibm
1740
+ ;;
1741
+ - rtpc | rtpc-*)
1742
+ - basic_machine=romp-ibm
1743
+ + mmix-unknown)
1744
+ + vendor=knuth
1745
+ ;;
1746
+ - s390 | s390-*)
1747
+ - basic_machine=s390-ibm
1748
+ + microblaze-unknown | microblazeel-unknown)
1749
+ + vendor=xilinx
1750
+ ;;
1751
+ - s390x | s390x-*)
1752
+ - basic_machine=s390x-ibm
1753
+ + rs6000-unknown)
1754
+ + vendor=ibm
1755
+ ;;
1756
+ - sa29200)
1757
+ - basic_machine=a29k-amd
1758
+ - os=-udi
1759
+ + vax-unknown)
1760
+ + vendor=dec
1761
+ ;;
1762
+ - sb1)
1763
+ - basic_machine=mipsisa64sb1-unknown
1764
+ + pdp11-unknown)
1765
+ + vendor=dec
1766
+ ;;
1767
+ - sb1el)
1768
+ - basic_machine=mipsisa64sb1el-unknown
1769
+ + we32k-unknown)
1770
+ + vendor=att
1771
+ ;;
1772
+ - sde)
1773
+ - basic_machine=mipsisa32-sde
1774
+ - os=-elf
1775
+ + cydra-unknown)
1776
+ + vendor=cydrome
1777
+ ;;
1778
+ - sei)
1779
+ - basic_machine=mips-sei
1780
+ - os=-seiux
1781
+ + i370-ibm*)
1782
+ + vendor=ibm
1783
+ ;;
1784
+ - sequent)
1785
+ - basic_machine=i386-sequent
1786
+ + orion-unknown)
1787
+ + vendor=highlevel
1788
+ ;;
1789
+ - sh5el)
1790
+ - basic_machine=sh5le-unknown
1791
+ + xps-unknown | xps100-unknown)
1792
+ + cpu=xps100
1793
+ + vendor=honeywell
1794
+ ;;
1795
+ - simso-wrs)
1796
+ - basic_machine=sparclite-wrs
1797
+ - os=-vxworks
1798
+ +
1799
+ + # Here we normalize CPU types with a missing or matching vendor
1800
+ + dpx20-unknown | dpx20-bull)
1801
+ + cpu=rs6000
1802
+ + vendor=bull
901
1803
  + basic_os=${basic_os:-bosx}
902
1804
  ;;
903
-
904
- # Here we normalize CPU types irrespective of the vendor
905
- @@ -1011,7 +1015,7 @@
906
- ;;
907
- blackfin-*)
908
- cpu=bfin
909
- - os=linux
1805
+ - sps7)
1806
+ - basic_machine=m68k-bull
1807
+ - os=-sysv2
1808
+ - ;;
1809
+ - spur)
1810
+ - basic_machine=spur-unknown
1811
+ - ;;
1812
+ - st2000)
1813
+ - basic_machine=m68k-tandem
1814
+ - ;;
1815
+ - stratus)
1816
+ - basic_machine=i860-stratus
1817
+ - os=-sysv4
1818
+ +
1819
+ + # Here we normalize CPU types irrespective of the vendor
1820
+ + amd64-*)
1821
+ + cpu=x86_64
1822
+ ;;
1823
+ - strongarm-* | thumb-*)
1824
+ - basic_machine=arm-`echo "$basic_machine" | sed 's/^[^-]*-//'`
1825
+ + blackfin-*)
1826
+ + cpu=bfin
910
1827
  + basic_os=linux
911
1828
  ;;
912
- c54x-*)
913
- cpu=tic54x
914
- @@ -1024,7 +1028,7 @@
915
- ;;
916
- e500v[12]-*)
917
- cpu=powerpc
918
- - os=$os"spe"
1829
+ - sun2)
1830
+ - basic_machine=m68000-sun
1831
+ + c54x-*)
1832
+ + cpu=tic54x
1833
+ ;;
1834
+ - sun2os3)
1835
+ - basic_machine=m68000-sun
1836
+ - os=-sunos3
1837
+ + c55x-*)
1838
+ + cpu=tic55x
1839
+ ;;
1840
+ - sun2os4)
1841
+ - basic_machine=m68000-sun
1842
+ - os=-sunos4
1843
+ + c6x-*)
1844
+ + cpu=tic6x
1845
+ ;;
1846
+ - sun3os3)
1847
+ - basic_machine=m68k-sun
1848
+ - os=-sunos3
1849
+ + e500v[12]-*)
1850
+ + cpu=powerpc
919
1851
  + basic_os=${basic_os}"spe"
920
1852
  ;;
921
- mips3*-*)
922
- cpu=mips64
923
- @@ -1034,7 +1038,7 @@
924
- ;;
925
- m68knommu-*)
926
- cpu=m68k
927
- - os=linux
1853
+ - sun3os4)
1854
+ - basic_machine=m68k-sun
1855
+ - os=-sunos4
1856
+ + mips3*-*)
1857
+ + cpu=mips64
1858
+ ;;
1859
+ - sun4os3)
1860
+ - basic_machine=sparc-sun
1861
+ - os=-sunos3
1862
+ + ms1-*)
1863
+ + cpu=mt
1864
+ ;;
1865
+ - sun4os4)
1866
+ - basic_machine=sparc-sun
1867
+ - os=-sunos4
1868
+ + m68knommu-*)
1869
+ + cpu=m68k
928
1870
  + basic_os=linux
929
1871
  ;;
930
- m9s12z-* | m68hcs12z-* | hcs12z-* | s12z-*)
931
- cpu=s12z
932
- @@ -1044,7 +1048,7 @@
933
- ;;
934
- parisc-*)
935
- cpu=hppa
936
- - os=linux
1872
+ - sun4sol2)
1873
+ - basic_machine=sparc-sun
1874
+ - os=-solaris2
1875
+ + m9s12z-* | m68hcs12z-* | hcs12z-* | s12z-*)
1876
+ + cpu=s12z
1877
+ ;;
1878
+ - sun3 | sun3-*)
1879
+ - basic_machine=m68k-sun
1880
+ + openrisc-*)
1881
+ + cpu=or32
1882
+ ;;
1883
+ - sun4)
1884
+ - basic_machine=sparc-sun
1885
+ + parisc-*)
1886
+ + cpu=hppa
937
1887
  + basic_os=linux
938
1888
  ;;
939
- pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
940
- cpu=i586
941
- @@ -1080,7 +1084,7 @@
942
- cpu=mipsisa64sb1el
943
- ;;
944
- sh5e[lb]-*)
945
- - cpu=`echo "$cpu" | sed 's/^\(sh.\)e\(.\)$/\1\2e/'`
1889
+ - sun386 | sun386i | roadrunner)
1890
+ - basic_machine=i386-sun
1891
+ + pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
1892
+ + cpu=i586
1893
+ ;;
1894
+ - sv1)
1895
+ - basic_machine=sv1-cray
1896
+ - os=-unicos
1897
+ + pentiumpro-* | p6-* | 6x86-* | athlon-* | athalon_*-*)
1898
+ + cpu=i686
1899
+ ;;
1900
+ - symmetry)
1901
+ - basic_machine=i386-sequent
1902
+ - os=-dynix
1903
+ + pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
1904
+ + cpu=i686
1905
+ ;;
1906
+ - t3e)
1907
+ - basic_machine=alphaev5-cray
1908
+ - os=-unicos
1909
+ + pentium4-*)
1910
+ + cpu=i786
1911
+ ;;
1912
+ - t90)
1913
+ - basic_machine=t90-cray
1914
+ - os=-unicos
1915
+ + pc98-*)
1916
+ + cpu=i386
1917
+ ;;
1918
+ - tile*)
1919
+ - basic_machine=$basic_machine-unknown
1920
+ - os=-linux-gnu
1921
+ + ppc-* | ppcbe-*)
1922
+ + cpu=powerpc
1923
+ ;;
1924
+ - tx39)
1925
+ - basic_machine=mipstx39-unknown
1926
+ + ppcle-* | powerpclittle-*)
1927
+ + cpu=powerpcle
1928
+ ;;
1929
+ - tx39el)
1930
+ - basic_machine=mipstx39el-unknown
1931
+ + ppc64-*)
1932
+ + cpu=powerpc64
1933
+ ;;
1934
+ - toad1)
1935
+ - basic_machine=pdp10-xkl
1936
+ - os=-tops20
1937
+ + ppc64le-* | powerpc64little-*)
1938
+ + cpu=powerpc64le
1939
+ ;;
1940
+ - tower | tower-32)
1941
+ - basic_machine=m68k-ncr
1942
+ + sb1-*)
1943
+ + cpu=mipsisa64sb1
1944
+ ;;
1945
+ - tpf)
1946
+ - basic_machine=s390x-ibm
1947
+ - os=-tpf
1948
+ - ;;
1949
+ - udi29k)
1950
+ - basic_machine=a29k-amd
1951
+ - os=-udi
1952
+ - ;;
1953
+ - ultra3)
1954
+ - basic_machine=a29k-nyu
1955
+ - os=-sym1
1956
+ - ;;
1957
+ - v810 | necv810)
1958
+ - basic_machine=v810-nec
1959
+ - os=-none
1960
+ - ;;
1961
+ - vaxv)
1962
+ - basic_machine=vax-dec
1963
+ - os=-sysv
1964
+ - ;;
1965
+ - vms)
1966
+ - basic_machine=vax-dec
1967
+ - os=-vms
1968
+ + sb1el-*)
1969
+ + cpu=mipsisa64sb1el
1970
+ ;;
1971
+ - vpp*|vx|vx-*)
1972
+ - basic_machine=f301-fujitsu
1973
+ + sh5e[lb]-*)
946
1974
  + cpu=$(echo "$cpu" | sed 's/^\(sh.\)e\(.\)$/\1\2e/')
947
1975
  ;;
948
- spur-*)
949
- cpu=spur
950
- @@ -1098,13 +1102,16 @@
951
- cpu=x86_64
1976
+ - vxworks960)
1977
+ - basic_machine=i960-wrs
1978
+ - os=-vxworks
1979
+ - ;;
1980
+ - vxworks68)
1981
+ - basic_machine=m68k-wrs
1982
+ - os=-vxworks
1983
+ - ;;
1984
+ - vxworks29k)
1985
+ - basic_machine=a29k-wrs
1986
+ - os=-vxworks
1987
+ - ;;
1988
+ - w65*)
1989
+ - basic_machine=w65-wdc
1990
+ - os=-none
1991
+ + spur-*)
1992
+ + cpu=spur
1993
+ ;;
1994
+ - w89k-*)
1995
+ - basic_machine=hppa1.1-winbond
1996
+ - os=-proelf
1997
+ + strongarm-* | thumb-*)
1998
+ + cpu=arm
1999
+ ;;
2000
+ - x64)
2001
+ - basic_machine=x86_64-pc
2002
+ + tx39-*)
2003
+ + cpu=mipstx39
2004
+ ;;
2005
+ - xbox)
2006
+ - basic_machine=i686-pc
2007
+ - os=-mingw32
2008
+ + tx39el-*)
2009
+ + cpu=mipstx39el
2010
+ ;;
2011
+ - xps | xps100)
2012
+ - basic_machine=xps100-honeywell
2013
+ + x64-*)
2014
+ + cpu=x86_64
952
2015
  ;;
953
2016
  xscale-* | xscalee[bl]-*)
954
- - cpu=`echo "$cpu" | sed 's/^xscale/arm/'`
2017
+ - basic_machine=`echo "$basic_machine" | sed 's/^xscale/arm/'`
955
2018
  + cpu=$(echo "$cpu" | sed 's/^xscale/arm/')
956
- + ;;
2019
+ ;;
2020
+ - ymp)
2021
+ - basic_machine=ymp-cray
2022
+ - os=-unicos
2023
+ - ;;
2024
+ - none)
2025
+ - basic_machine=none-none
2026
+ - os=-none
957
2027
  + arm64-*)
958
2028
  + cpu=aarch64
959
2029
  ;;
960
2030
 
961
- - # Recognize the cannonical CPU Types that limit and/or modify the
2031
+ -# Here we handle the default manufacturer of certain CPU types. It is in
2032
+ -# some cases the only manufacturer, in others, it is the most popular.
2033
+ - w89k)
2034
+ - basic_machine=hppa1.1-winbond
2035
+ - ;;
2036
+ - op50n)
2037
+ - basic_machine=hppa1.1-oki
2038
+ - ;;
2039
+ - op60c)
2040
+ - basic_machine=hppa1.1-oki
962
2041
  + # Recognize the canonical CPU Types that limit and/or modify the
963
- # company names they are paired with.
964
- cr16-*)
965
- - os=${os:-elf}
2042
+ + # company names they are paired with.
2043
+ + cr16-*)
966
2044
  + basic_os=${basic_os:-elf}
967
2045
  ;;
968
- crisv32-* | etraxfs*-*)
969
- cpu=crisv32
970
- @@ -1115,7 +1122,7 @@
971
- vendor=axis
972
- ;;
973
- crx-*)
974
- - os=${os:-elf}
2046
+ - romp)
2047
+ - basic_machine=romp-ibm
2048
+ + crisv32-* | etraxfs*-*)
2049
+ + cpu=crisv32
2050
+ + vendor=axis
2051
+ ;;
2052
+ - mmix)
2053
+ - basic_machine=mmix-knuth
2054
+ + cris-* | etrax*-*)
2055
+ + cpu=cris
2056
+ + vendor=axis
2057
+ ;;
2058
+ - rs6000)
2059
+ - basic_machine=rs6000-ibm
2060
+ + crx-*)
975
2061
  + basic_os=${basic_os:-elf}
976
2062
  ;;
977
- neo-tandem)
978
- cpu=neo
979
- @@ -1137,20 +1144,16 @@
980
- cpu=nsx
981
- vendor=tandem
982
- ;;
983
- - s390-*)
984
- - cpu=s390
985
- - vendor=ibm
2063
+ - vax)
2064
+ - basic_machine=vax-dec
986
2065
  - ;;
987
- - s390x-*)
988
- - cpu=s390x
989
- - vendor=ibm
2066
+ - pdp11)
2067
+ - basic_machine=pdp11-dec
2068
+ - ;;
2069
+ - we32k)
2070
+ - basic_machine=we32k-att
2071
+ - ;;
2072
+ - sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele)
2073
+ - basic_machine=sh-unknown
2074
+ + neo-tandem)
2075
+ + cpu=neo
2076
+ + vendor=tandem
2077
+ ;;
2078
+ - cydra)
2079
+ - basic_machine=cydra-cydrome
2080
+ + nse-tandem)
2081
+ + cpu=nse
2082
+ + vendor=tandem
2083
+ ;;
2084
+ - orion)
2085
+ - basic_machine=orion-highlevel
2086
+ + nsr-tandem)
2087
+ + cpu=nsr
2088
+ + vendor=tandem
2089
+ ;;
2090
+ - orion105)
2091
+ - basic_machine=clipper-highlevel
2092
+ + nsv-tandem)
2093
+ + cpu=nsv
2094
+ + vendor=tandem
2095
+ ;;
2096
+ - mac | mpw | mac-mpw)
2097
+ - basic_machine=m68k-apple
2098
+ + nsx-tandem)
2099
+ + cpu=nsx
2100
+ + vendor=tandem
2101
+ ;;
2102
+ - pmac | pmac-mpw)
2103
+ - basic_machine=powerpc-apple
990
2104
  + mipsallegrexel-sony)
991
2105
  + cpu=mipsallegrexel
992
2106
  + vendor=sony
993
2107
  ;;
994
- tile*-*)
995
- - os=${os:-linux-gnu}
2108
+ - *-unknown)
2109
+ - # Make sure to match an already-canonicalized machine name.
2110
+ + tile*-*)
996
2111
  + basic_os=${basic_os:-linux-gnu}
997
2112
  ;;
998
-
2113
+ +
999
2114
  *)
1000
- - # Recognize the cannonical CPU types that are allowed with any
2115
+ - echo Invalid configuration \`"$1"\': machine \`"$basic_machine"\' not recognized 1>&2
2116
+ - exit 1
1001
2117
  + # Recognize the canonical CPU types that are allowed with any
1002
- # company name.
1003
- case $cpu in
1004
- 1750a | 580 \
1005
- @@ -1161,13 +1164,14 @@
1006
- | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] \
1007
- | alphapca5[67] | alpha64pca5[67] \
1008
- | am33_2.0 \
2118
+ + # company name.
2119
+ + case $cpu in
2120
+ + 1750a | 580 \
2121
+ + | a29k \
2122
+ + | aarch64 | aarch64_be \
2123
+ + | abacus \
2124
+ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] \
2125
+ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] \
2126
+ + | alphapca5[67] | alpha64pca5[67] \
2127
+ + | am33_2.0 \
1009
2128
  + | amdgcn \
1010
- | arc | arceb \
1011
- - | arm | arm[lb]e | arme[lb] | armv* \
2129
+ + | arc | arceb \
1012
2130
  + | arm | arm[lb]e | arme[lb] | armv* \
1013
- | avr | avr32 \
1014
- | asmjs \
1015
- | ba \
1016
- | be32 | be64 \
1017
- - | bfin | bs2000 \
2131
+ + | avr | avr32 \
2132
+ + | asmjs \
2133
+ + | ba \
2134
+ + | be32 | be64 \
1018
2135
  + | bfin | bpf | bs2000 \
1019
- | c[123]* | c30 | [cjt]90 | c4x \
1020
- | c8051 | clipper | craynv | csky | cydra \
1021
- | d10v | d30v | dlx | dsp16xx \
1022
- @@ -1182,13 +1186,13 @@
1023
- | le32 | le64 \
1024
- | lm32 \
1025
- | m32c | m32r | m32rle \
1026
- - | m5200 | m68000 | m680[012346]0 | m68360 | m683?2 | m68k | v70 | w65 \
1027
- - | m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip \
2136
+ + | c[123]* | c30 | [cjt]90 | c4x \
2137
+ + | c8051 | clipper | craynv | csky | cydra \
2138
+ + | d10v | d30v | dlx | dsp16xx \
2139
+ + | e2k | elxsi | epiphany \
2140
+ + | f30[01] | f700 | fido | fr30 | frv | ft32 | fx80 \
2141
+ + | h8300 | h8500 \
2142
+ + | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
2143
+ + | hexagon \
2144
+ + | i370 | i*86 | i860 | i960 | ia16 | ia64 \
2145
+ + | ip2k | iq2000 \
2146
+ + | k1om \
2147
+ + | le32 | le64 \
2148
+ + | lm32 \
2149
+ + | m32c | m32r | m32rle \
1028
2150
  + | m5200 | m68000 | m680[012346]0 | m68360 | m683?2 | m68k \
1029
2151
  + | m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x \
1030
- | m88110 | m88k | maxq | mb | mcore | mep | metag \
1031
- | microblaze | microblazeel \
1032
- | mips | mipsbe | mipseb | mipsel | mipsle \
1033
- | mips16 \
1034
- - | mips64 | mips64el \
2152
+ + | m88110 | m88k | maxq | mb | mcore | mep | metag \
2153
+ + | microblaze | microblazeel \
2154
+ + | mips | mipsbe | mipseb | mipsel | mipsle \
2155
+ + | mips16 \
1035
2156
  + | mips64 | mips64eb | mips64el \
1036
- | mips64octeon | mips64octeonel \
1037
- | mips64orion | mips64orionel \
1038
- | mips64r5900 | mips64r5900el \
1039
- @@ -1215,19 +1219,22 @@
1040
- | nds32 | nds32le | nds32be \
1041
- | nfp \
1042
- | nios | nios2 | nios2eb | nios2el \
1043
- - | none | np1 | ns16k | ns32k \
2157
+ + | mips64octeon | mips64octeonel \
2158
+ + | mips64orion | mips64orionel \
2159
+ + | mips64r5900 | mips64r5900el \
2160
+ + | mips64vr | mips64vrel \
2161
+ + | mips64vr4100 | mips64vr4100el \
2162
+ + | mips64vr4300 | mips64vr4300el \
2163
+ + | mips64vr5000 | mips64vr5000el \
2164
+ + | mips64vr5900 | mips64vr5900el \
2165
+ + | mipsisa32 | mipsisa32el \
2166
+ + | mipsisa32r2 | mipsisa32r2el \
2167
+ + | mipsisa32r6 | mipsisa32r6el \
2168
+ + | mipsisa64 | mipsisa64el \
2169
+ + | mipsisa64r2 | mipsisa64r2el \
2170
+ + | mipsisa64r6 | mipsisa64r6el \
2171
+ + | mipsisa64sb1 | mipsisa64sb1el \
2172
+ + | mipsisa64sr71k | mipsisa64sr71kel \
2173
+ + | mipsr5900 | mipsr5900el \
2174
+ + | mipstx39 | mipstx39el \
2175
+ + | mmix \
2176
+ + | mn10200 | mn10300 \
2177
+ + | moxie \
2178
+ + | mt \
2179
+ + | msp430 \
2180
+ + | nds32 | nds32le | nds32be \
2181
+ + | nfp \
2182
+ + | nios | nios2 | nios2eb | nios2el \
1044
2183
  + | none | np1 | ns16k | ns32k | nvptx \
1045
- | open8 \
1046
- | or1k* \
1047
- | or32 \
1048
- | orion \
2184
+ + | open8 \
2185
+ + | or1k* \
2186
+ + | or32 \
2187
+ + | orion \
1049
2188
  + | picochip \
1050
- | pdp10 | pdp11 | pj | pjl | pn | power \
1051
- | powerpc | powerpc64 | powerpc64le | powerpcle | powerpcspe \
1052
- | pru \
1053
- | pyramid \
1054
- | riscv | riscv32 | riscv64 \
1055
- | rl78 | romp | rs6000 | rx \
2189
+ + | pdp10 | pdp11 | pj | pjl | pn | power \
2190
+ + | powerpc | powerpc64 | powerpc64le | powerpcle | powerpcspe \
2191
+ + | pru \
2192
+ + | pyramid \
2193
+ + | riscv | riscv32 | riscv64 \
2194
+ + | rl78 | romp | rs6000 | rx \
1056
2195
  + | s390 | s390x \
1057
- | score \
1058
- - | sh | sh[1234] | sh[24]a | sh[24]ae[lb] | sh[23]e | she[lb] | sh[lb]e \
2196
+ + | score \
1059
2197
  + | sh | shl \
1060
2198
  + | sh[1234] | sh[24]a | sh[24]ae[lb] | sh[23]e | she[lb] | sh[lb]e \
1061
- | sh[1234]e[lb] | sh[12345][lb]e | sh[23]ele | sh64 | sh64le \
1062
- | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet \
1063
- | sparclite \
1064
- @@ -1237,10 +1244,11 @@
1065
- | tic30 | tic4x | tic54x | tic55x | tic6x | tic80 \
1066
- | tron \
1067
- | ubicom32 \
1068
- - | v850 | v850e | v850e1 | v850es | v850e2 | v850e2v3 \
2199
+ + | sh[1234]e[lb] | sh[12345][lb]e | sh[23]ele | sh64 | sh64le \
2200
+ + | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet \
2201
+ + | sparclite \
2202
+ + | sparcv8 | sparcv9 | sparcv9b | sparcv9v | sv1 | sx* \
2203
+ + | spu \
2204
+ + | tahoe \
2205
+ + | tic30 | tic4x | tic54x | tic55x | tic6x | tic80 \
2206
+ + | tron \
2207
+ + | ubicom32 \
1069
2208
  + | v70 | v850 | v850e | v850e1 | v850es | v850e2 | v850e2v3 \
1070
- | vax \
1071
- | visium \
1072
- - | wasm32 \
2209
+ + | vax \
2210
+ + | visium \
1073
2211
  + | w65 \
1074
2212
  + | wasm32 | wasm64 \
1075
- | we32k \
1076
- | x86 | x86_64 | xc16x | xgate | xps100 \
1077
- | xstormy16 | xtensa* \
1078
- @@ -1270,8 +1278,47 @@
2213
+ + | we32k \
2214
+ + | x86 | x86_64 | xc16x | xgate | xps100 \
2215
+ + | xstormy16 | xtensa* \
2216
+ + | ymp \
2217
+ + | z8k | z80)
2218
+ + ;;
2219
+ +
2220
+ + *)
2221
+ + echo Invalid configuration \`"$1"\': machine \`"$cpu-$vendor"\' not recognized 1>&2
2222
+ + exit 1
2223
+ + ;;
2224
+ + esac
2225
+ ;;
2226
+ esac
2227
+
2228
+ # Here we canonicalize certain aliases for manufacturers.
2229
+ -case $basic_machine in
2230
+ - *-digital*)
2231
+ - basic_machine=`echo "$basic_machine" | sed 's/digital.*/dec/'`
2232
+ +case $vendor in
2233
+ + digital*)
2234
+ + vendor=dec
2235
+ ;;
2236
+ - *-commodore*)
2237
+ - basic_machine=`echo "$basic_machine" | sed 's/commodore.*/cbm/'`
2238
+ + commodore*)
2239
+ + vendor=cbm
2240
+ ;;
2241
+ *)
2242
+ ;;
2243
+ @@ -1334,203 +1278,213 @@
1079
2244
 
1080
2245
  # Decode manufacturer-specific aliases for certain operating systems.
1081
2246
 
1082
- -if [ x$os != x ]
2247
+ -if [ x"$os" != x"" ]
1083
2248
  +if test x$basic_os != x
1084
2249
  then
1085
2250
  +
@@ -1124,184 +2289,301 @@ aarch64/arm64/M1 can compile.
1124
2289
  case $os in
1125
2290
  # First match some system type aliases that might get confused
1126
2291
  # with valid system types.
1127
- @@ -1283,7 +1330,7 @@
1128
- os=cnk
1129
- ;;
1130
- solaris1 | solaris1.*)
2292
+ - # -solaris* is a basic system type, with this one exception.
2293
+ - -auroraux)
2294
+ - os=-auroraux
2295
+ + # solaris* is a basic system type, with this one exception.
2296
+ + auroraux)
2297
+ + os=auroraux
2298
+ ;;
2299
+ - -solaris1 | -solaris1.*)
1131
2300
  - os=`echo $os | sed -e 's|solaris1|sunos4|'`
2301
+ + bluegene*)
2302
+ + os=cnk
2303
+ ;;
2304
+ - -solaris)
2305
+ - os=-solaris2
2306
+ + solaris1 | solaris1.*)
1132
2307
  + os=$(echo $os | sed -e 's|solaris1|sunos4|')
1133
2308
  ;;
1134
- solaris)
1135
- os=solaris2
1136
- @@ -1291,9 +1338,6 @@
1137
- unixware*)
1138
- os=sysv4.2uw
2309
+ - -unixware*)
2310
+ - os=-sysv4.2uw
2311
+ + solaris)
2312
+ + os=solaris2
1139
2313
  ;;
1140
- - gnu/linux*)
2314
+ - -gnu/linux*)
1141
2315
  - os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
1142
- - ;;
1143
- # es1800 is here to avoid being matched by es* (a different OS)
1144
- es1800*)
1145
- os=ose
1146
- @@ -1315,12 +1359,9 @@
1147
- os=sco3.2v4
1148
- ;;
1149
- sco3.2.[4-9]*)
1150
- - os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
1151
- - ;;
1152
- - sco3.2v[4-9]* | sco5v6*)
1153
- - # Don't forget version if it is 3.2v4 or newer.
1154
- + os=$(echo $os | sed -e 's/sco3.2./sco3.2v/')
2316
+ + unixware*)
2317
+ + os=sysv4.2uw
1155
2318
  ;;
1156
- - scout)
1157
- + sco*v* | scout)
1158
- # Don't match below
1159
- ;;
1160
- sco*)
1161
- @@ -1329,78 +1370,26 @@
1162
- psos*)
1163
- os=psos
2319
+ # es1800 is here to avoid being matched by es* (a different OS)
2320
+ - -es1800*)
2321
+ - os=-ose
2322
+ + es1800*)
2323
+ + os=ose
1164
2324
  ;;
1165
2325
  - # Now accept the basic system types.
1166
2326
  - # The portable systems comes first.
1167
2327
  - # Each alternative MUST end in a * to match a version number.
1168
- - # sysv* is not here because it comes later, after sysvr4.
1169
- - gnu* | bsd* | mach* | minix* | genix* | ultrix* | irix* \
1170
- - | *vms* | esix* | aix* | cnk* | sunos | sunos[34]*\
1171
- - | hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \
1172
- - | sym* | kopensolaris* | plan9* \
1173
- - | amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \
1174
- - | aos* | aros* | cloudabi* | sortix* \
1175
- - | nindy* | vxsim* | vxworks* | ebmon* | hms* | mvs* \
1176
- - | clix* | riscos* | uniplus* | iris* | isc* | rtu* | xenix* \
1177
- - | knetbsd* | mirbsd* | netbsd* \
1178
- - | bitrig* | openbsd* | solidbsd* | libertybsd* \
1179
- - | ekkobsd* | kfreebsd* | freebsd* | riscix* | lynxos* \
1180
- - | bosx* | nextstep* | cxux* | aout* | elf* | oabi* \
1181
- - | ptx* | coff* | ecoff* | winnt* | domain* | vsta* \
1182
- - | udi* | eabi* | lites* | ieee* | go32* | aux* | hcos* \
1183
- - | chorusrdb* | cegcc* | glidix* \
1184
- - | cygwin* | msys* | pe* | moss* | proelf* | rtems* \
1185
- - | midipix* | mingw32* | mingw64* | linux-gnu* | linux-android* \
1186
- - | linux-newlib* | linux-musl* | linux-uclibc* \
1187
- - | uxpv* | beos* | mpeix* | udk* | moxiebox* \
1188
- - | interix* | uwin* | mks* | rhapsody* | darwin* \
1189
- - | openstep* | oskit* | conix* | pw32* | nonstopux* \
1190
- - | storm-chaos* | tops10* | tenex* | tops20* | its* \
1191
- - | os2* | vos* | palmos* | uclinux* | nucleus* \
1192
- - | morphos* | superux* | rtmk* | windiss* \
1193
- - | powermax* | dnix* | nx6 | nx7 | sei* | dragonfly* \
1194
- - | skyos* | haiku* | rdos* | toppers* | drops* | es* \
1195
- - | onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \
1196
- - | midnightbsd*)
2328
+ - # -sysv* is not here because it comes later, after sysvr4.
2329
+ - -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
2330
+ - | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\
2331
+ - | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \
2332
+ - | -sym* | -kopensolaris* | -plan9* \
2333
+ - | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
2334
+ - | -aos* | -aros* | -cloudabi* | -sortix* \
2335
+ - | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
2336
+ - | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
2337
+ - | -hiux* | -knetbsd* | -mirbsd* | -netbsd* \
2338
+ - | -bitrig* | -openbsd* | -solidbsd* | -libertybsd* \
2339
+ - | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
2340
+ - | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
2341
+ - | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
2342
+ - | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
2343
+ - | -chorusos* | -chorusrdb* | -cegcc* | -glidix* \
2344
+ - | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
2345
+ - | -midipix* | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \
2346
+ - | -linux-newlib* | -linux-musl* | -linux-uclibc* \
2347
+ - | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \
2348
+ - | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* \
2349
+ - | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
2350
+ - | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
2351
+ - | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
2352
+ - | -morphos* | -superux* | -rtmk* | -windiss* \
2353
+ - | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
2354
+ - | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* \
2355
+ - | -onefs* | -tirtos* | -phoenix* | -fuchsia* | -redox* | -bme* \
2356
+ - | -midnightbsd*)
1197
2357
  - # Remember, each alternative MUST END IN *, to match a version number.
1198
2358
  - ;;
1199
- qnx*)
1200
- - case $cpu in
1201
- - x86 | i*86)
2359
+ - -qnx*)
2360
+ - case $basic_machine in
2361
+ - x86-* | i*86-*)
1202
2362
  - ;;
1203
2363
  - *)
1204
- - os=nto-$os
2364
+ - os=-nto$os
1205
2365
  - ;;
1206
2366
  - esac
1207
- + os=qnx
2367
+ + # Some version numbers need modification
2368
+ + chorusos*)
2369
+ + os=chorusos
1208
2370
  ;;
1209
- hiux*)
1210
- os=hiuxwe2
2371
+ - -nto-qnx*)
2372
+ + isc)
2373
+ + os=isc2.2
1211
2374
  ;;
1212
- - nto-qnx*)
1213
- - ;;
1214
- - nto*)
2375
+ - -nto*)
1215
2376
  - os=`echo $os | sed -e 's|nto|nto-qnx|'`
1216
- - ;;
1217
- - sim | xray | os68k* | v88r* \
1218
- - | windows* | osx | abug | netware* | os9* \
1219
- - | macos* | mpw* | magic* | mmixware* | mon960* | lnews*)
1220
- - ;;
1221
- - linux-dietlibc)
1222
- - os=linux-dietlibc
1223
- - ;;
1224
- - linux*)
2377
+ + sco6)
2378
+ + os=sco5v6
2379
+ ;;
2380
+ - -sim | -xray | -os68k* | -v88r* \
2381
+ - | -windows* | -osx | -abug | -netware* | -os9* \
2382
+ - | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*)
2383
+ + sco5)
2384
+ + os=sco3.2v5
2385
+ ;;
2386
+ - -mac*)
2387
+ - os=`echo "$os" | sed -e 's|mac|macos|'`
2388
+ + sco4)
2389
+ + os=sco3.2v4
2390
+ ;;
2391
+ - -linux-dietlibc)
2392
+ - os=-linux-dietlibc
2393
+ + sco3.2.[4-9]*)
2394
+ + os=$(echo $os | sed -e 's/sco3.2./sco3.2v/')
2395
+ ;;
2396
+ - -linux*)
1225
2397
  - os=`echo $os | sed -e 's|linux|linux-gnu|'`
1226
- - ;;
1227
- lynx*178)
1228
- os=lynxos178
2398
+ + sco*v* | scout)
2399
+ + # Don't match below
2400
+ ;;
2401
+ - -sunos5*)
2402
+ - os=`echo "$os" | sed -e 's|sunos5|solaris2|'`
2403
+ + sco*)
2404
+ + os=sco3.2v2
2405
+ ;;
2406
+ - -sunos6*)
2407
+ - os=`echo "$os" | sed -e 's|sunos6|solaris3|'`
2408
+ + psos*)
2409
+ + os=psos
1229
2410
  ;;
1230
- lynx*5)
1231
- os=lynxos5
2411
+ - -opened*)
2412
+ - os=-openedition
2413
+ + qnx*)
2414
+ + os=qnx
2415
+ ;;
2416
+ - -os400*)
2417
+ - os=-os400
2418
+ + hiux*)
2419
+ + os=hiuxwe2
2420
+ ;;
2421
+ - -wince*)
2422
+ - os=-wince
2423
+ + lynx*178)
2424
+ + os=lynxos178
2425
+ ;;
2426
+ - -utek*)
2427
+ - os=-bsd
2428
+ + lynx*5)
2429
+ + os=lynxos5
1232
2430
  ;;
2431
+ - -dynix*)
2432
+ - os=-bsd
1233
2433
  + lynxos*)
1234
2434
  + # don't get caught up in next wildcard
1235
- + ;;
1236
- lynx*)
1237
- os=lynxos
1238
2435
  ;;
1239
- - mac*)
1240
- - os=`echo "$os" | sed -e 's|mac|macos|'`
2436
+ - -acis*)
2437
+ - os=-aos
2438
+ + lynx*)
2439
+ + os=lynxos
2440
+ ;;
2441
+ - -atheos*)
2442
+ - os=-atheos
1241
2443
  + mac[0-9]*)
1242
2444
  + os=$(echo "$os" | sed -e 's|mac|macos|')
1243
2445
  ;;
1244
- opened*)
1245
- os=openedition
1246
- @@ -1409,10 +1398,10 @@
1247
- os=os400
2446
+ - -syllable*)
2447
+ - os=-syllable
2448
+ + opened*)
2449
+ + os=openedition
1248
2450
  ;;
1249
- sunos5*)
1250
- - os=`echo "$os" | sed -e 's|sunos5|solaris2|'`
2451
+ - -386bsd)
2452
+ - os=-bsd
2453
+ + os400*)
2454
+ + os=os400
2455
+ ;;
2456
+ - -ctix* | -uts*)
2457
+ - os=-sysv
2458
+ + sunos5*)
1251
2459
  + os=$(echo "$os" | sed -e 's|sunos5|solaris2|')
1252
2460
  ;;
1253
- sunos6*)
1254
- - os=`echo "$os" | sed -e 's|sunos6|solaris3|'`
2461
+ - -nova*)
2462
+ - os=-rtmk-nova
2463
+ + sunos6*)
1255
2464
  + os=$(echo "$os" | sed -e 's|sunos6|solaris3|')
1256
2465
  ;;
1257
- wince*)
1258
- os=wince
1259
- @@ -1444,12 +1433,9 @@
1260
- ns2)
1261
- os=nextstep2
2466
+ - -ns2)
2467
+ - os=-nextstep2
2468
+ + wince*)
2469
+ + os=wince
1262
2470
  ;;
1263
- - nsk*)
1264
- - os=nsk
1265
- - ;;
1266
- # Preserve the version number of sinix5.
1267
- sinix5.*)
2471
+ - -nsk*)
2472
+ - os=-nsk
2473
+ + utek*)
2474
+ + os=bsd
2475
+ ;;
2476
+ - # Preserve the version number of sinix5.
2477
+ - -sinix5.*)
1268
2478
  - os=`echo $os | sed -e 's|sinix|sysv|'`
2479
+ + dynix*)
2480
+ + os=bsd
2481
+ + ;;
2482
+ + acis*)
2483
+ + os=aos
2484
+ + ;;
2485
+ + atheos*)
2486
+ + os=atheos
2487
+ + ;;
2488
+ + syllable*)
2489
+ + os=syllable
2490
+ + ;;
2491
+ + 386bsd)
2492
+ + os=bsd
2493
+ + ;;
2494
+ + ctix* | uts*)
2495
+ + os=sysv
2496
+ ;;
2497
+ - -sinix*)
2498
+ - os=-sysv4
2499
+ + nova*)
2500
+ + os=rtmk-nova
2501
+ ;;
2502
+ - -tpf*)
2503
+ - os=-tpf
2504
+ + ns2)
2505
+ + os=nextstep2
2506
+ ;;
2507
+ - -triton*)
2508
+ - os=-sysv3
2509
+ + # Preserve the version number of sinix5.
2510
+ + sinix5.*)
1269
2511
  + os=$(echo $os | sed -e 's|sinix|sysv|')
1270
2512
  ;;
1271
- sinix*)
1272
- os=sysv4
1273
- @@ -1472,18 +1458,12 @@
1274
- sysvr4)
1275
- os=sysv4
1276
- ;;
1277
- - # This must come after sysvr4.
1278
- - sysv*)
1279
- - ;;
1280
- ose*)
1281
- os=ose
1282
- ;;
1283
- *mint | mint[0-9]* | *MiNT | MiNT[0-9]*)
1284
- os=mint
1285
- ;;
1286
- - zvmoe)
1287
- - os=zvmoe
1288
- - ;;
1289
- dicos*)
1290
- os=dicos
1291
- ;;
1292
- @@ -1500,19 +1480,11 @@
2513
+ - -oss*)
2514
+ - os=-sysv3
2515
+ + sinix*)
2516
+ + os=sysv4
2517
+ ;;
2518
+ - -svr4*)
2519
+ - os=-sysv4
2520
+ + tpf*)
2521
+ + os=tpf
2522
+ ;;
2523
+ - -svr3)
2524
+ - os=-sysv3
2525
+ + triton*)
2526
+ + os=sysv3
2527
+ ;;
2528
+ - -sysvr4)
2529
+ - os=-sysv4
2530
+ + oss*)
2531
+ + os=sysv3
2532
+ ;;
2533
+ - # This must come after -sysvr4.
2534
+ - -sysv*)
2535
+ + svr4*)
2536
+ + os=sysv4
2537
+ ;;
2538
+ - -ose*)
2539
+ - os=-ose
2540
+ + svr3)
2541
+ + os=sysv3
2542
+ ;;
2543
+ - -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
2544
+ - os=-mint
2545
+ + sysvr4)
2546
+ + os=sysv4
2547
+ ;;
2548
+ - -zvmoe)
2549
+ - os=-zvmoe
2550
+ + ose*)
2551
+ + os=ose
2552
+ ;;
2553
+ - -dicos*)
2554
+ - os=-dicos
2555
+ + *mint | mint[0-9]* | *MiNT | MiNT[0-9]*)
2556
+ + os=mint
2557
+ ;;
2558
+ - -pikeos*)
2559
+ + dicos*)
2560
+ + os=dicos
2561
+ + ;;
2562
+ + pikeos*)
2563
+ # Until real need of OS specific support for
2564
+ # particular features comes up, bare metal
2565
+ # configurations are quite functional.
2566
+ - case $basic_machine in
2567
+ + case $cpu in
2568
+ arm*)
2569
+ - os=-eabi
2570
+ + os=eabi
2571
+ ;;
2572
+ *)
2573
+ - os=-elf
2574
+ + os=elf
1293
2575
  ;;
1294
2576
  esac
1295
2577
  ;;
1296
- - nacl*)
2578
+ - -nacl*)
1297
2579
  - ;;
1298
- - ios)
1299
- - ;;
1300
- - none)
2580
+ - -ios)
1301
2581
  - ;;
1302
- - *-eabi)
2582
+ - -none)
1303
2583
  - ;;
1304
2584
  *)
2585
+ - # Get rid of the `-' at the beginning of $os.
2586
+ - os=`echo $os | sed 's/[^-]*-//'`
1305
2587
  - echo Invalid configuration \`"$1"\': system \`"$os"\' not recognized 1>&2
1306
2588
  - exit 1
1307
2589
  + # No normalization, but not necessarily accepted, that comes below.
@@ -1311,26 +2593,244 @@ aarch64/arm64/M1 can compile.
1311
2593
  else
1312
2594
 
1313
2595
  # Here we handle the default operating systems that come with various machines.
1314
- @@ -1525,6 +1497,7 @@
2596
+ @@ -1543,258 +1497,356 @@
1315
2597
  # will signal an error saying that MANUFACTURER isn't an operating
1316
2598
  # system, and we'll never get to this point.
1317
2599
 
2600
+ -case $basic_machine in
1318
2601
  +kernel=
1319
- case $cpu-$vendor in
2602
+ +case $cpu-$vendor in
1320
2603
  score-*)
1321
- os=elf
1322
- @@ -1536,7 +1509,8 @@
1323
- os=riscix1.2
2604
+ - os=-elf
2605
+ + os=elf
2606
+ ;;
2607
+ spu-*)
2608
+ - os=-elf
2609
+ + os=elf
2610
+ ;;
2611
+ *-acorn)
2612
+ - os=-riscix1.2
2613
+ + os=riscix1.2
1324
2614
  ;;
1325
2615
  arm*-rebel)
1326
- - os=linux
2616
+ - os=-linux
1327
2617
  + kernel=linux
1328
2618
  + os=gnu
1329
2619
  ;;
1330
2620
  arm*-semi)
1331
- os=aout
1332
- @@ -1702,84 +1676,173 @@
1333
- os=none
2621
+ - os=-aout
2622
+ + os=aout
2623
+ ;;
2624
+ c4x-* | tic4x-*)
2625
+ - os=-coff
2626
+ + os=coff
2627
+ ;;
2628
+ c8051-*)
2629
+ - os=-elf
2630
+ + os=elf
2631
+ + ;;
2632
+ + clipper-intergraph)
2633
+ + os=clix
2634
+ ;;
2635
+ hexagon-*)
2636
+ - os=-elf
2637
+ + os=elf
2638
+ ;;
2639
+ tic54x-*)
2640
+ - os=-coff
2641
+ + os=coff
2642
+ ;;
2643
+ tic55x-*)
2644
+ - os=-coff
2645
+ + os=coff
2646
+ ;;
2647
+ tic6x-*)
2648
+ - os=-coff
2649
+ + os=coff
2650
+ ;;
2651
+ # This must come before the *-dec entry.
2652
+ pdp10-*)
2653
+ - os=-tops20
2654
+ + os=tops20
2655
+ ;;
2656
+ pdp11-*)
2657
+ - os=-none
2658
+ + os=none
2659
+ ;;
2660
+ *-dec | vax-*)
2661
+ - os=-ultrix4.2
2662
+ + os=ultrix4.2
2663
+ ;;
2664
+ m68*-apollo)
2665
+ - os=-domain
2666
+ + os=domain
2667
+ ;;
2668
+ i386-sun)
2669
+ - os=-sunos4.0.2
2670
+ + os=sunos4.0.2
2671
+ ;;
2672
+ m68000-sun)
2673
+ - os=-sunos3
2674
+ + os=sunos3
2675
+ ;;
2676
+ m68*-cisco)
2677
+ - os=-aout
2678
+ + os=aout
2679
+ ;;
2680
+ mep-*)
2681
+ - os=-elf
2682
+ + os=elf
2683
+ ;;
2684
+ mips*-cisco)
2685
+ - os=-elf
2686
+ + os=elf
2687
+ ;;
2688
+ mips*-*)
2689
+ - os=-elf
2690
+ + os=elf
2691
+ ;;
2692
+ or32-*)
2693
+ - os=-coff
2694
+ + os=coff
2695
+ ;;
2696
+ *-tti) # must be before sparc entry or we get the wrong os.
2697
+ - os=-sysv3
2698
+ + os=sysv3
2699
+ ;;
2700
+ sparc-* | *-sun)
2701
+ - os=-sunos4.1.1
2702
+ + os=sunos4.1.1
2703
+ ;;
2704
+ pru-*)
2705
+ - os=-elf
2706
+ + os=elf
2707
+ ;;
2708
+ *-be)
2709
+ - os=-beos
2710
+ + os=beos
2711
+ ;;
2712
+ *-ibm)
2713
+ - os=-aix
2714
+ + os=aix
2715
+ ;;
2716
+ *-knuth)
2717
+ - os=-mmixware
2718
+ + os=mmixware
2719
+ ;;
2720
+ *-wec)
2721
+ - os=-proelf
2722
+ + os=proelf
2723
+ ;;
2724
+ *-winbond)
2725
+ - os=-proelf
2726
+ + os=proelf
2727
+ ;;
2728
+ *-oki)
2729
+ - os=-proelf
2730
+ + os=proelf
2731
+ ;;
2732
+ *-hp)
2733
+ - os=-hpux
2734
+ + os=hpux
2735
+ ;;
2736
+ *-hitachi)
2737
+ - os=-hiux
2738
+ + os=hiux
2739
+ ;;
2740
+ i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
2741
+ - os=-sysv
2742
+ + os=sysv
2743
+ ;;
2744
+ *-cbm)
2745
+ - os=-amigaos
2746
+ + os=amigaos
2747
+ ;;
2748
+ *-dg)
2749
+ - os=-dgux
2750
+ + os=dgux
2751
+ ;;
2752
+ *-dolphin)
2753
+ - os=-sysv3
2754
+ + os=sysv3
2755
+ ;;
2756
+ m68k-ccur)
2757
+ - os=-rtu
2758
+ + os=rtu
2759
+ ;;
2760
+ m88k-omron*)
2761
+ - os=-luna
2762
+ + os=luna
2763
+ ;;
2764
+ *-next)
2765
+ - os=-nextstep
2766
+ + os=nextstep
2767
+ ;;
2768
+ *-sequent)
2769
+ - os=-ptx
2770
+ + os=ptx
2771
+ ;;
2772
+ *-crds)
2773
+ - os=-unos
2774
+ + os=unos
2775
+ ;;
2776
+ *-ns)
2777
+ - os=-genix
2778
+ + os=genix
2779
+ ;;
2780
+ i370-*)
2781
+ - os=-mvs
2782
+ + os=mvs
2783
+ ;;
2784
+ *-gould)
2785
+ - os=-sysv
2786
+ + os=sysv
2787
+ ;;
2788
+ *-highlevel)
2789
+ - os=-bsd
2790
+ + os=bsd
2791
+ ;;
2792
+ *-encore)
2793
+ - os=-bsd
2794
+ + os=bsd
2795
+ ;;
2796
+ *-sgi)
2797
+ - os=-irix
2798
+ + os=irix
2799
+ ;;
2800
+ *-siemens)
2801
+ - os=-sysv4
2802
+ + os=sysv4
2803
+ ;;
2804
+ *-masscomp)
2805
+ - os=-rtu
2806
+ + os=rtu
2807
+ ;;
2808
+ f30[01]-fujitsu | f700-fujitsu)
2809
+ - os=-uxpv
2810
+ + os=uxpv
2811
+ ;;
2812
+ *-rom68k)
2813
+ - os=-coff
2814
+ + os=coff
2815
+ ;;
2816
+ *-*bug)
2817
+ - os=-coff
2818
+ + os=coff
2819
+ ;;
2820
+ *-apple)
2821
+ - os=-macos
2822
+ + os=macos
2823
+ ;;
2824
+ *-atari*)
2825
+ - os=-mint
2826
+ + os=mint
2827
+ + ;;
2828
+ + *-wrs)
2829
+ + os=vxworks
2830
+ ;;
2831
+ *)
2832
+ - os=-none
2833
+ + os=none
1334
2834
  ;;
1335
2835
  esac
1336
2836
  +
@@ -1423,1089 +2923,115 @@ aarch64/arm64/M1 can compile.
1423
2923
  +
1424
2924
  # Here we handle the case where we know the os, and the CPU type, but not the
1425
2925
  # manufacturer. We pick the logical manufacturer.
1426
- case $vendor in
1427
- unknown)
2926
+ -vendor=unknown
2927
+ -case $basic_machine in
2928
+ - *-unknown)
1428
2929
  - case $os in
1429
- - riscix*)
2930
+ - -riscix*)
2931
+ +case $vendor in
2932
+ + unknown)
1430
2933
  + case $cpu-$os in
1431
2934
  + *-riscix*)
1432
2935
  vendor=acorn
1433
2936
  ;;
1434
- - sunos*)
2937
+ - -sunos*)
1435
2938
  + *-sunos*)
1436
2939
  vendor=sun
1437
2940
  ;;
1438
- - cnk*|-aix*)
2941
+ - -cnk*|-aix*)
1439
2942
  + *-cnk* | *-aix*)
1440
2943
  vendor=ibm
1441
2944
  ;;
1442
- - beos*)
2945
+ - -beos*)
1443
2946
  + *-beos*)
1444
2947
  vendor=be
1445
2948
  ;;
1446
- - hpux*)
2949
+ - -hpux*)
1447
2950
  + *-hpux*)
1448
2951
  vendor=hp
1449
2952
  ;;
1450
- - mpeix*)
2953
+ - -mpeix*)
1451
2954
  + *-mpeix*)
1452
2955
  vendor=hp
1453
2956
  ;;
1454
- - hiux*)
2957
+ - -hiux*)
1455
2958
  + *-hiux*)
1456
2959
  vendor=hitachi
1457
2960
  ;;
1458
- - unos*)
2961
+ - -unos*)
1459
2962
  + *-unos*)
1460
2963
  vendor=crds
1461
2964
  ;;
1462
- - dgux*)
2965
+ - -dgux*)
1463
2966
  + *-dgux*)
1464
2967
  vendor=dg
1465
2968
  ;;
1466
- - luna*)
2969
+ - -luna*)
1467
2970
  + *-luna*)
1468
2971
  vendor=omron
1469
2972
  ;;
1470
- - genix*)
2973
+ - -genix*)
1471
2974
  + *-genix*)
1472
2975
  vendor=ns
1473
2976
  ;;
1474
- - clix*)
2977
+ - -mvs* | -opened*)
1475
2978
  + *-clix*)
1476
- vendor=intergraph
1477
- ;;
1478
- - mvs* | opened*)
2979
+ + vendor=intergraph
2980
+ + ;;
1479
2981
  + *-mvs* | *-opened*)
1480
2982
  + vendor=ibm
1481
2983
  + ;;
1482
2984
  + *-os400*)
1483
2985
  vendor=ibm
1484
2986
  ;;
1485
- - os400*)
2987
+ - -os400*)
1486
2988
  + s390-* | s390x-*)
1487
2989
  vendor=ibm
1488
2990
  ;;
1489
- - ptx*)
2991
+ - -ptx*)
1490
2992
  + *-ptx*)
1491
2993
  vendor=sequent
1492
2994
  ;;
1493
- - tpf*)
2995
+ - -tpf*)
1494
2996
  + *-tpf*)
1495
2997
  vendor=ibm
1496
2998
  ;;
1497
- - vxsim* | vxworks* | windiss*)
2999
+ - -vxsim* | -vxworks* | -windiss*)
1498
3000
  + *-vxsim* | *-vxworks* | *-windiss*)
1499
3001
  vendor=wrs
1500
3002
  ;;
1501
- - aux*)
3003
+ - -aux*)
1502
3004
  + *-aux*)
1503
3005
  vendor=apple
1504
3006
  ;;
1505
- - hms*)
3007
+ - -hms*)
1506
3008
  + *-hms*)
1507
3009
  vendor=hitachi
1508
3010
  ;;
1509
- - mpw* | macos*)
3011
+ - -mpw* | -macos*)
1510
3012
  + *-mpw* | *-macos*)
1511
3013
  vendor=apple
1512
3014
  ;;
1513
- - *mint | mint[0-9]* | *MiNT | MiNT[0-9]*)
3015
+ - -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
1514
3016
  + *-*mint | *-mint[0-9]* | *-*MiNT | *-MiNT[0-9]*)
1515
3017
  vendor=atari
1516
3018
  ;;
1517
- - vos*)
3019
+ - -vos*)
1518
3020
  + *-vos*)
1519
3021
  vendor=stratus
1520
3022
  ;;
1521
3023
  esac
3024
+ - basic_machine=`echo "$basic_machine" | sed "s/unknown/$vendor/"`
1522
3025
  ;;
1523
3026
  esac
1524
3027
 
1525
- -echo "$cpu-$vendor-$os"
3028
+ -echo "$basic_machine$os"
1526
3029
  +echo "$cpu-$vendor-${kernel:+$kernel-}$os"
1527
3030
  exit
1528
3031
 
1529
3032
  # Local variables:
1530
- --- a/config.guess
1531
- +++ b/config.guess
1532
- @@ -1,8 +1,8 @@
1533
- #! /bin/sh
1534
- # Attempt to guess a canonical system name.
1535
- -# Copyright 1992-2018 Free Software Foundation, Inc.
1536
- +# Copyright 1992-2020 Free Software Foundation, Inc.
1537
-
1538
- -timestamp='2018-08-29'
1539
- +timestamp='2020-11-07'
1540
-
1541
- # This file is free software; you can redistribute it and/or modify it
1542
- # under the terms of the GNU General Public License as published by
1543
- @@ -32,7 +32,7 @@
1544
- # Please send patches to <config-patches@gnu.org>.
1545
-
1546
-
1547
- -me=`echo "$0" | sed -e 's,.*/,,'`
1548
- +me=$(echo "$0" | sed -e 's,.*/,,')
1549
-
1550
- usage="\
1551
- Usage: $0 [OPTION]
1552
- @@ -50,7 +50,7 @@
1553
- GNU config.guess ($timestamp)
1554
-
1555
- Originally written by Per Bothner.
1556
- -Copyright 1992-2018 Free Software Foundation, Inc.
1557
- +Copyright 1992-2020 Free Software Foundation, Inc.
1558
-
1559
- This is free software; see the source for copying conditions. There is NO
1560
- warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
1561
- @@ -96,13 +96,14 @@
1562
-
1563
- tmp=
1564
- # shellcheck disable=SC2172
1565
- -trap 'test -z "$tmp" || rm -fr "$tmp"' 1 2 13 15
1566
- -trap 'exitcode=$?; test -z "$tmp" || rm -fr "$tmp"; exit $exitcode' 0
1567
- +trap 'test -z "$tmp" || rm -fr "$tmp"' 0 1 2 13 15
1568
-
1569
- set_cc_for_build() {
1570
- + # prevent multiple calls if $tmp is already set
1571
- + test "$tmp" && return 0
1572
- : "${TMPDIR=/tmp}"
1573
- # shellcheck disable=SC2039
1574
- - { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
1575
- + { tmp=$( (umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null) && test -n "$tmp" && test -d "$tmp" ; } ||
1576
- { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } ||
1577
- { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } ||
1578
- { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; }
1579
- @@ -130,10 +131,10 @@
1580
- PATH=$PATH:/.attbin ; export PATH
1581
- fi
1582
-
1583
- -UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
1584
- -UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
1585
- -UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
1586
- -UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
1587
- +UNAME_MACHINE=$( (uname -m) 2>/dev/null) || UNAME_MACHINE=unknown
1588
- +UNAME_RELEASE=$( (uname -r) 2>/dev/null) || UNAME_RELEASE=unknown
1589
- +UNAME_SYSTEM=$( (uname -s) 2>/dev/null) || UNAME_SYSTEM=unknown
1590
- +UNAME_VERSION=$( (uname -v) 2>/dev/null) || UNAME_VERSION=unknown
1591
-
1592
- case "$UNAME_SYSTEM" in
1593
- Linux|GNU|GNU/*)
1594
- @@ -149,17 +150,15 @@
1595
- #elif defined(__dietlibc__)
1596
- LIBC=dietlibc
1597
- #else
1598
- + #include <stdarg.h>
1599
- + #ifdef __DEFINED_va_list
1600
- + LIBC=musl
1601
- + #else
1602
- LIBC=gnu
1603
- #endif
1604
- + #endif
1605
- EOF
1606
- - eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`"
1607
- -
1608
- - # If ldd exists, use it to detect musl libc.
1609
- - if command -v ldd >/dev/null && \
1610
- - ldd --version 2>&1 | grep -q ^musl
1611
- - then
1612
- - LIBC=musl
1613
- - fi
1614
- + eval "$($CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g')"
1615
- ;;
1616
- esac
1617
-
1618
- @@ -178,19 +177,20 @@
1619
- # Note: NetBSD doesn't particularly care about the vendor
1620
- # portion of the name. We always set it to "unknown".
1621
- sysctl="sysctl -n hw.machine_arch"
1622
- - UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \
1623
- + UNAME_MACHINE_ARCH=$( (uname -p 2>/dev/null || \
1624
- "/sbin/$sysctl" 2>/dev/null || \
1625
- "/usr/sbin/$sysctl" 2>/dev/null || \
1626
- - echo unknown)`
1627
- + echo unknown))
1628
- case "$UNAME_MACHINE_ARCH" in
1629
- + aarch64eb) machine=aarch64_be-unknown ;;
1630
- armeb) machine=armeb-unknown ;;
1631
- arm*) machine=arm-unknown ;;
1632
- sh3el) machine=shl-unknown ;;
1633
- sh3eb) machine=sh-unknown ;;
1634
- sh5el) machine=sh5le-unknown ;;
1635
- earmv*)
1636
- - arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'`
1637
- - endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'`
1638
- + arch=$(echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,')
1639
- + endian=$(echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p')
1640
- machine="${arch}${endian}"-unknown
1641
- ;;
1642
- *) machine="$UNAME_MACHINE_ARCH"-unknown ;;
1643
- @@ -221,7 +221,7 @@
1644
- case "$UNAME_MACHINE_ARCH" in
1645
- earm*)
1646
- expr='s/^earmv[0-9]/-eabi/;s/eb$//'
1647
- - abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"`
1648
- + abi=$(echo "$UNAME_MACHINE_ARCH" | sed -e "$expr")
1649
- ;;
1650
- esac
1651
- # The OS release
1652
- @@ -234,7 +234,7 @@
1653
- release='-gnu'
1654
- ;;
1655
- *)
1656
- - release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2`
1657
- + release=$(echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2)
1658
- ;;
1659
- esac
1660
- # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
1661
- @@ -243,15 +243,15 @@
1662
- echo "$machine-${os}${release}${abi-}"
1663
- exit ;;
1664
- *:Bitrig:*:*)
1665
- - UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'`
1666
- + UNAME_MACHINE_ARCH=$(arch | sed 's/Bitrig.//')
1667
- echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE"
1668
- exit ;;
1669
- *:OpenBSD:*:*)
1670
- - UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
1671
- + UNAME_MACHINE_ARCH=$(arch | sed 's/OpenBSD.//')
1672
- echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE"
1673
- exit ;;
1674
- *:LibertyBSD:*:*)
1675
- - UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'`
1676
- + UNAME_MACHINE_ARCH=$(arch | sed 's/^.*BSD\.//')
1677
- echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE"
1678
- exit ;;
1679
- *:MidnightBSD:*:*)
1680
- @@ -263,6 +263,9 @@
1681
- *:SolidBSD:*:*)
1682
- echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE"
1683
- exit ;;
1684
- + *:OS108:*:*)
1685
- + echo "$UNAME_MACHINE"-unknown-os108_"$UNAME_RELEASE"
1686
- + exit ;;
1687
- macppc:MirBSD:*:*)
1688
- echo powerpc-unknown-mirbsd"$UNAME_RELEASE"
1689
- exit ;;
1690
- @@ -272,26 +275,29 @@
1691
- *:Sortix:*:*)
1692
- echo "$UNAME_MACHINE"-unknown-sortix
1693
- exit ;;
1694
- + *:Twizzler:*:*)
1695
- + echo "$UNAME_MACHINE"-unknown-twizzler
1696
- + exit ;;
1697
- *:Redox:*:*)
1698
- echo "$UNAME_MACHINE"-unknown-redox
1699
- exit ;;
1700
- mips:OSF1:*.*)
1701
- - echo mips-dec-osf1
1702
- - exit ;;
1703
- + echo mips-dec-osf1
1704
- + exit ;;
1705
- alpha:OSF1:*:*)
1706
- case $UNAME_RELEASE in
1707
- *4.0)
1708
- - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
1709
- + UNAME_RELEASE=$(/usr/sbin/sizer -v | awk '{print $3}')
1710
- ;;
1711
- *5.*)
1712
- - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
1713
- + UNAME_RELEASE=$(/usr/sbin/sizer -v | awk '{print $4}')
1714
- ;;
1715
- esac
1716
- # According to Compaq, /usr/sbin/psrinfo has been available on
1717
- # OSF/1 and Tru64 systems produced since 1995. I hope that
1718
- # covers most systems running today. This code pipes the CPU
1719
- # types through head -n 1, so we only detect the type of CPU 0.
1720
- - ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
1721
- + ALPHA_CPU_TYPE=$(/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1)
1722
- case "$ALPHA_CPU_TYPE" in
1723
- "EV4 (21064)")
1724
- UNAME_MACHINE=alpha ;;
1725
- @@ -329,7 +335,7 @@
1726
- # A Tn.n version is a released field test version.
1727
- # A Xn.n version is an unreleased experimental baselevel.
1728
- # 1.2 uses "1.2" for uname -r.
1729
- - echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`"
1730
- + echo "$UNAME_MACHINE"-dec-osf"$(echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz)"
1731
- # Reset EXIT trap before exiting to avoid spurious non-zero exit code.
1732
- exitcode=$?
1733
- trap '' 0
1734
- @@ -363,7 +369,7 @@
1735
- exit ;;
1736
- Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
1737
- # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
1738
- - if test "`(/bin/universe) 2>/dev/null`" = att ; then
1739
- + if test "$( (/bin/universe) 2>/dev/null)" = att ; then
1740
- echo pyramid-pyramid-sysv3
1741
- else
1742
- echo pyramid-pyramid-bsd
1743
- @@ -376,54 +382,59 @@
1744
- echo sparc-icl-nx6
1745
- exit ;;
1746
- DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
1747
- - case `/usr/bin/uname -p` in
1748
- + case $(/usr/bin/uname -p) in
1749
- sparc) echo sparc-icl-nx7; exit ;;
1750
- esac ;;
1751
- s390x:SunOS:*:*)
1752
- - echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
1753
- + echo "$UNAME_MACHINE"-ibm-solaris2"$(echo "$UNAME_RELEASE" | sed -e 's/[^.]*//')"
1754
- exit ;;
1755
- sun4H:SunOS:5.*:*)
1756
- - echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
1757
- + echo sparc-hal-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')"
1758
- exit ;;
1759
- sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
1760
- - echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
1761
- + echo sparc-sun-solaris2"$(echo "$UNAME_RELEASE" | sed -e 's/[^.]*//')"
1762
- exit ;;
1763
- i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
1764
- echo i386-pc-auroraux"$UNAME_RELEASE"
1765
- exit ;;
1766
- i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
1767
- - UNAME_REL="`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`"
1768
- - case `isainfo -b` in
1769
- - 32)
1770
- - echo i386-pc-solaris2"$UNAME_REL"
1771
- - ;;
1772
- - 64)
1773
- - echo x86_64-pc-solaris2"$UNAME_REL"
1774
- - ;;
1775
- - esac
1776
- + set_cc_for_build
1777
- + SUN_ARCH=i386
1778
- + # If there is a compiler, see if it is configured for 64-bit objects.
1779
- + # Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
1780
- + # This test works for both compilers.
1781
- + if test "$CC_FOR_BUILD" != no_compiler_found; then
1782
- + if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
1783
- + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
1784
- + grep IS_64BIT_ARCH >/dev/null
1785
- + then
1786
- + SUN_ARCH=x86_64
1787
- + fi
1788
- + fi
1789
- + echo "$SUN_ARCH"-pc-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')"
1790
- exit ;;
1791
- sun4*:SunOS:6*:*)
1792
- # According to config.sub, this is the proper way to canonicalize
1793
- # SunOS6. Hard to guess exactly what SunOS6 will be like, but
1794
- # it's likely to be more like Solaris than SunOS4.
1795
- - echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
1796
- + echo sparc-sun-solaris3"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')"
1797
- exit ;;
1798
- sun4*:SunOS:*:*)
1799
- - case "`/usr/bin/arch -k`" in
1800
- + case "$(/usr/bin/arch -k)" in
1801
- Series*|S4*)
1802
- - UNAME_RELEASE=`uname -v`
1803
- + UNAME_RELEASE=$(uname -v)
1804
- ;;
1805
- esac
1806
- # Japanese Language versions have a version number like `4.1.3-JL'.
1807
- - echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`"
1808
- + echo sparc-sun-sunos"$(echo "$UNAME_RELEASE"|sed -e 's/-/_/')"
1809
- exit ;;
1810
- sun3*:SunOS:*:*)
1811
- echo m68k-sun-sunos"$UNAME_RELEASE"
1812
- exit ;;
1813
- sun*:*:4.2BSD:*)
1814
- - UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
1815
- + UNAME_RELEASE=$( (sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null)
1816
- test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3
1817
- - case "`/bin/arch`" in
1818
- + case "$(/bin/arch)" in
1819
- sun3)
1820
- echo m68k-sun-sunos"$UNAME_RELEASE"
1821
- ;;
1822
- @@ -503,8 +514,8 @@
1823
- }
1824
- EOF
1825
- $CC_FOR_BUILD -o "$dummy" "$dummy.c" &&
1826
- - dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` &&
1827
- - SYSTEM_NAME=`"$dummy" "$dummyarg"` &&
1828
- + dummyarg=$(echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p') &&
1829
- + SYSTEM_NAME=$("$dummy" "$dummyarg") &&
1830
- { echo "$SYSTEM_NAME"; exit; }
1831
- echo mips-mips-riscos"$UNAME_RELEASE"
1832
- exit ;;
1833
- @@ -531,11 +542,11 @@
1834
- exit ;;
1835
- AViiON:dgux:*:*)
1836
- # DG/UX returns AViiON for all architectures
1837
- - UNAME_PROCESSOR=`/usr/bin/uname -p`
1838
- - if [ "$UNAME_PROCESSOR" = mc88100 ] || [ "$UNAME_PROCESSOR" = mc88110 ]
1839
- + UNAME_PROCESSOR=$(/usr/bin/uname -p)
1840
- + if test "$UNAME_PROCESSOR" = mc88100 || test "$UNAME_PROCESSOR" = mc88110
1841
- then
1842
- - if [ "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx ] || \
1843
- - [ "$TARGET_BINARY_INTERFACE"x = x ]
1844
- + if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \
1845
- + test "$TARGET_BINARY_INTERFACE"x = x
1846
- then
1847
- echo m88k-dg-dgux"$UNAME_RELEASE"
1848
- else
1849
- @@ -559,17 +570,17 @@
1850
- echo m68k-tektronix-bsd
1851
- exit ;;
1852
- *:IRIX*:*:*)
1853
- - echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`"
1854
- + echo mips-sgi-irix"$(echo "$UNAME_RELEASE"|sed -e 's/-/_/g')"
1855
- exit ;;
1856
- ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
1857
- echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
1858
- - exit ;; # Note that: echo "'`uname -s`'" gives 'AIX '
1859
- + exit ;; # Note that: echo "'$(uname -s)'" gives 'AIX '
1860
- i*86:AIX:*:*)
1861
- echo i386-ibm-aix
1862
- exit ;;
1863
- ia64:AIX:*:*)
1864
- - if [ -x /usr/bin/oslevel ] ; then
1865
- - IBM_REV=`/usr/bin/oslevel`
1866
- + if test -x /usr/bin/oslevel ; then
1867
- + IBM_REV=$(/usr/bin/oslevel)
1868
- else
1869
- IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
1870
- fi
1871
- @@ -589,7 +600,7 @@
1872
- exit(0);
1873
- }
1874
- EOF
1875
- - if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"`
1876
- + if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=$("$dummy")
1877
- then
1878
- echo "$SYSTEM_NAME"
1879
- else
1880
- @@ -602,15 +613,15 @@
1881
- fi
1882
- exit ;;
1883
- *:AIX:*:[4567])
1884
- - IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
1885
- + IBM_CPU_ID=$(/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }')
1886
- if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then
1887
- IBM_ARCH=rs6000
1888
- else
1889
- IBM_ARCH=powerpc
1890
- fi
1891
- - if [ -x /usr/bin/lslpp ] ; then
1892
- - IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
1893
- - awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
1894
- + if test -x /usr/bin/lslpp ; then
1895
- + IBM_REV=$(/usr/bin/lslpp -Lqc bos.rte.libc |
1896
- + awk -F: '{ print $3 }' | sed s/[0-9]*$/0/)
1897
- else
1898
- IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
1899
- fi
1900
- @@ -638,14 +649,14 @@
1901
- echo m68k-hp-bsd4.4
1902
- exit ;;
1903
- 9000/[34678]??:HP-UX:*:*)
1904
- - HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
1905
- + HPUX_REV=$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//')
1906
- case "$UNAME_MACHINE" in
1907
- 9000/31?) HP_ARCH=m68000 ;;
1908
- 9000/[34]??) HP_ARCH=m68k ;;
1909
- 9000/[678][0-9][0-9])
1910
- - if [ -x /usr/bin/getconf ]; then
1911
- - sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
1912
- - sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
1913
- + if test -x /usr/bin/getconf; then
1914
- + sc_cpu_version=$(/usr/bin/getconf SC_CPU_VERSION 2>/dev/null)
1915
- + sc_kernel_bits=$(/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null)
1916
- case "$sc_cpu_version" in
1917
- 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0
1918
- 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1
1919
- @@ -657,7 +668,7 @@
1920
- esac ;;
1921
- esac
1922
- fi
1923
- - if [ "$HP_ARCH" = "" ]; then
1924
- + if test "$HP_ARCH" = ""; then
1925
- set_cc_for_build
1926
- sed 's/^ //' << EOF > "$dummy.c"
1927
-
1928
- @@ -692,11 +703,11 @@
1929
- exit (0);
1930
- }
1931
- EOF
1932
- - (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"`
1933
- + (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=$("$dummy")
1934
- test -z "$HP_ARCH" && HP_ARCH=hppa
1935
- fi ;;
1936
- esac
1937
- - if [ "$HP_ARCH" = hppa2.0w ]
1938
- + if test "$HP_ARCH" = hppa2.0w
1939
- then
1940
- set_cc_for_build
1941
-
1942
- @@ -720,7 +731,7 @@
1943
- echo "$HP_ARCH"-hp-hpux"$HPUX_REV"
1944
- exit ;;
1945
- ia64:HP-UX:*:*)
1946
- - HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'`
1947
- + HPUX_REV=$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//')
1948
- echo ia64-hp-hpux"$HPUX_REV"
1949
- exit ;;
1950
- 3050*:HI-UX:*:*)
1951
- @@ -750,7 +761,7 @@
1952
- exit (0);
1953
- }
1954
- EOF
1955
- - $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` &&
1956
- + $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=$("$dummy") &&
1957
- { echo "$SYSTEM_NAME"; exit; }
1958
- echo unknown-hitachi-hiuxwe2
1959
- exit ;;
1960
- @@ -770,7 +781,7 @@
1961
- echo hppa1.0-hp-osf
1962
- exit ;;
1963
- i*86:OSF1:*:*)
1964
- - if [ -x /usr/sbin/sysversion ] ; then
1965
- + if test -x /usr/sbin/sysversion ; then
1966
- echo "$UNAME_MACHINE"-unknown-osf1mk
1967
- else
1968
- echo "$UNAME_MACHINE"-unknown-osf1
1969
- @@ -819,14 +830,14 @@
1970
- echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'
1971
- exit ;;
1972
- F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
1973
- - FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`
1974
- - FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
1975
- - FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'`
1976
- + FUJITSU_PROC=$(uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz)
1977
- + FUJITSU_SYS=$(uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///')
1978
- + FUJITSU_REL=$(echo "$UNAME_RELEASE" | sed -e 's/ /_/')
1979
- echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
1980
- exit ;;
1981
- 5000:UNIX_System_V:4.*:*)
1982
- - FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'`
1983
- - FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'`
1984
- + FUJITSU_SYS=$(uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///')
1985
- + FUJITSU_REL=$(echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/')
1986
- echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
1987
- exit ;;
1988
- i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
1989
- @@ -839,25 +850,25 @@
1990
- echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE"
1991
- exit ;;
1992
- arm:FreeBSD:*:*)
1993
- - UNAME_PROCESSOR=`uname -p`
1994
- + UNAME_PROCESSOR=$(uname -p)
1995
- set_cc_for_build
1996
- if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
1997
- | grep -q __ARM_PCS_VFP
1998
- then
1999
- - echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabi
2000
- + echo "${UNAME_PROCESSOR}"-unknown-freebsd"$(echo ${UNAME_RELEASE}|sed -e 's/[-(].*//')"-gnueabi
2001
- else
2002
- - echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabihf
2003
- + echo "${UNAME_PROCESSOR}"-unknown-freebsd"$(echo ${UNAME_RELEASE}|sed -e 's/[-(].*//')"-gnueabihf
2004
- fi
2005
- exit ;;
2006
- *:FreeBSD:*:*)
2007
- - UNAME_PROCESSOR=`/usr/bin/uname -p`
2008
- + UNAME_PROCESSOR=$(/usr/bin/uname -p)
2009
- case "$UNAME_PROCESSOR" in
2010
- amd64)
2011
- UNAME_PROCESSOR=x86_64 ;;
2012
- i386)
2013
- UNAME_PROCESSOR=i586 ;;
2014
- esac
2015
- - echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
2016
- + echo "$UNAME_PROCESSOR"-unknown-freebsd"$(echo "$UNAME_RELEASE"|sed -e 's/[-(].*//')"
2017
- exit ;;
2018
- i*:CYGWIN*:*)
2019
- echo "$UNAME_MACHINE"-pc-cygwin
2020
- @@ -890,18 +901,18 @@
2021
- echo "$UNAME_MACHINE"-pc-uwin
2022
- exit ;;
2023
- amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
2024
- - echo x86_64-unknown-cygwin
2025
- + echo x86_64-pc-cygwin
2026
- exit ;;
2027
- prep*:SunOS:5.*:*)
2028
- - echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
2029
- + echo powerpcle-unknown-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')"
2030
- exit ;;
2031
- *:GNU:*:*)
2032
- # the GNU system
2033
- - echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`"
2034
- + echo "$(echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,')-unknown-$LIBC$(echo "$UNAME_RELEASE"|sed -e 's,/.*$,,')"
2035
- exit ;;
2036
- *:GNU/*:*:*)
2037
- # other systems with GNU libc and userland
2038
- - echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC"
2039
- + echo "$UNAME_MACHINE-unknown-$(echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]")$(echo "$UNAME_RELEASE"|sed -e 's/[-(].*//')-$LIBC"
2040
- exit ;;
2041
- *:Minix:*:*)
2042
- echo "$UNAME_MACHINE"-unknown-minix
2043
- @@ -914,7 +925,7 @@
2044
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
2045
- exit ;;
2046
- alpha:Linux:*:*)
2047
- - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
2048
- + case $(sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null) in
2049
- EV5) UNAME_MACHINE=alphaev5 ;;
2050
- EV56) UNAME_MACHINE=alphaev56 ;;
2051
- PCA56) UNAME_MACHINE=alphapca56 ;;
2052
- @@ -981,22 +992,50 @@
2053
- exit ;;
2054
- mips:Linux:*:* | mips64:Linux:*:*)
2055
- set_cc_for_build
2056
- + IS_GLIBC=0
2057
- + test x"${LIBC}" = xgnu && IS_GLIBC=1
2058
- sed 's/^ //' << EOF > "$dummy.c"
2059
- #undef CPU
2060
- - #undef ${UNAME_MACHINE}
2061
- - #undef ${UNAME_MACHINE}el
2062
- + #undef mips
2063
- + #undef mipsel
2064
- + #undef mips64
2065
- + #undef mips64el
2066
- + #if ${IS_GLIBC} && defined(_ABI64)
2067
- + LIBCABI=gnuabi64
2068
- + #else
2069
- + #if ${IS_GLIBC} && defined(_ABIN32)
2070
- + LIBCABI=gnuabin32
2071
- + #else
2072
- + LIBCABI=${LIBC}
2073
- + #endif
2074
- + #endif
2075
- +
2076
- + #if ${IS_GLIBC} && defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6
2077
- + CPU=mipsisa64r6
2078
- + #else
2079
- + #if ${IS_GLIBC} && !defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6
2080
- + CPU=mipsisa32r6
2081
- + #else
2082
- + #if defined(__mips64)
2083
- + CPU=mips64
2084
- + #else
2085
- + CPU=mips
2086
- + #endif
2087
- + #endif
2088
- + #endif
2089
- +
2090
- #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
2091
- - CPU=${UNAME_MACHINE}el
2092
- + MIPS_ENDIAN=el
2093
- #else
2094
- #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
2095
- - CPU=${UNAME_MACHINE}
2096
- + MIPS_ENDIAN=
2097
- #else
2098
- - CPU=
2099
- + MIPS_ENDIAN=
2100
- #endif
2101
- #endif
2102
- EOF
2103
- - eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU'`"
2104
- - test "x$CPU" != x && { echo "$CPU-unknown-linux-$LIBC"; exit; }
2105
- + eval "$($CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI')"
2106
- + test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; }
2107
- ;;
2108
- mips64el:Linux:*:*)
2109
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
2110
- @@ -1015,7 +1054,7 @@
2111
- exit ;;
2112
- parisc:Linux:*:* | hppa:Linux:*:*)
2113
- # Look for CPU level
2114
- - case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
2115
- + case $(grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2) in
2116
- PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;;
2117
- PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;;
2118
- *) echo hppa-unknown-linux-"$LIBC" ;;
2119
- @@ -1055,7 +1094,17 @@
2120
- echo "$UNAME_MACHINE"-dec-linux-"$LIBC"
2121
- exit ;;
2122
- x86_64:Linux:*:*)
2123
- - echo "$UNAME_MACHINE"-pc-linux-"$LIBC"
2124
- + set_cc_for_build
2125
- + LIBCABI=$LIBC
2126
- + if test "$CC_FOR_BUILD" != no_compiler_found; then
2127
- + if (echo '#ifdef __ILP32__'; echo IS_X32; echo '#endif') | \
2128
- + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
2129
- + grep IS_X32 >/dev/null
2130
- + then
2131
- + LIBCABI="$LIBC"x32
2132
- + fi
2133
- + fi
2134
- + echo "$UNAME_MACHINE"-pc-linux-"$LIBCABI"
2135
- exit ;;
2136
- xtensa*:Linux:*:*)
2137
- echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
2138
- @@ -1095,7 +1144,7 @@
2139
- echo "$UNAME_MACHINE"-pc-msdosdjgpp
2140
- exit ;;
2141
- i*86:*:4.*:*)
2142
- - UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'`
2143
- + UNAME_REL=$(echo "$UNAME_RELEASE" | sed 's/\/MP$//')
2144
- if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
2145
- echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL"
2146
- else
2147
- @@ -1104,19 +1153,19 @@
2148
- exit ;;
2149
- i*86:*:5:[678]*)
2150
- # UnixWare 7.x, OpenUNIX and OpenServer 6.
2151
- - case `/bin/uname -X | grep "^Machine"` in
2152
- + case $(/bin/uname -X | grep "^Machine") in
2153
- *486*) UNAME_MACHINE=i486 ;;
2154
- *Pentium) UNAME_MACHINE=i586 ;;
2155
- *Pent*|*Celeron) UNAME_MACHINE=i686 ;;
2156
- esac
2157
- - echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}{$UNAME_VERSION}"
2158
- + echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}"
2159
- exit ;;
2160
- i*86:*:3.2:*)
2161
- if test -f /usr/options/cb.name; then
2162
- - UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
2163
- + UNAME_REL=$(sed -n 's/.*Version //p' </usr/options/cb.name)
2164
- echo "$UNAME_MACHINE"-pc-isc"$UNAME_REL"
2165
- elif /bin/uname -X 2>/dev/null >/dev/null ; then
2166
- - UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
2167
- + UNAME_REL=$( (/bin/uname -X|grep Release|sed -e 's/.*= //'))
2168
- (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
2169
- (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
2170
- && UNAME_MACHINE=i586
2171
- @@ -1166,7 +1215,7 @@
2172
- 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0)
2173
- OS_REL=''
2174
- test -r /etc/.relid \
2175
- - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
2176
- + && OS_REL=.$(sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid)
2177
- /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
2178
- && { echo i486-ncr-sysv4.3"$OS_REL"; exit; }
2179
- /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
2180
- @@ -1177,7 +1226,7 @@
2181
- NCR*:*:4.2:* | MPRAS*:*:4.2:*)
2182
- OS_REL='.3'
2183
- test -r /etc/.relid \
2184
- - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
2185
- + && OS_REL=.$(sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid)
2186
- /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
2187
- && { echo i486-ncr-sysv4.3"$OS_REL"; exit; }
2188
- /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
2189
- @@ -1210,7 +1259,7 @@
2190
- exit ;;
2191
- *:SINIX-*:*:*)
2192
- if uname -p 2>/dev/null >/dev/null ; then
2193
- - UNAME_MACHINE=`(uname -p) 2>/dev/null`
2194
- + UNAME_MACHINE=$( (uname -p) 2>/dev/null)
2195
- echo "$UNAME_MACHINE"-sni-sysv4
2196
- else
2197
- echo ns32k-sni-sysv
2198
- @@ -1244,7 +1293,7 @@
2199
- echo mips-sony-newsos6
2200
- exit ;;
2201
- R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
2202
- - if [ -d /usr/nec ]; then
2203
- + if test -d /usr/nec; then
2204
- echo mips-nec-sysv"$UNAME_RELEASE"
2205
- else
2206
- echo mips-unknown-sysv"$UNAME_RELEASE"
2207
- @@ -1292,44 +1341,48 @@
2208
- *:Rhapsody:*:*)
2209
- echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE"
2210
- exit ;;
2211
- + arm64:Darwin:*:*)
2212
- + echo aarch64-apple-darwin"$UNAME_RELEASE"
2213
- + exit ;;
2214
- *:Darwin:*:*)
2215
- - UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
2216
- - set_cc_for_build
2217
- - if test "$UNAME_PROCESSOR" = unknown ; then
2218
- - UNAME_PROCESSOR=powerpc
2219
- + UNAME_PROCESSOR=$(uname -p)
2220
- + case $UNAME_PROCESSOR in
2221
- + unknown) UNAME_PROCESSOR=powerpc ;;
2222
- + esac
2223
- + if command -v xcode-select > /dev/null 2> /dev/null && \
2224
- + ! xcode-select --print-path > /dev/null 2> /dev/null ; then
2225
- + # Avoid executing cc if there is no toolchain installed as
2226
- + # cc will be a stub that puts up a graphical alert
2227
- + # prompting the user to install developer tools.
2228
- + CC_FOR_BUILD=no_compiler_found
2229
- + else
2230
- + set_cc_for_build
2231
- fi
2232
- - if test "`echo "$UNAME_RELEASE" | sed -e 's/\..*//'`" -le 10 ; then
2233
- - if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
2234
- - if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
2235
- - (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
2236
- - grep IS_64BIT_ARCH >/dev/null
2237
- - then
2238
- - case $UNAME_PROCESSOR in
2239
- - i386) UNAME_PROCESSOR=x86_64 ;;
2240
- - powerpc) UNAME_PROCESSOR=powerpc64 ;;
2241
- - esac
2242
- - fi
2243
- - # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc
2244
- - if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \
2245
- - (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
2246
- - grep IS_PPC >/dev/null
2247
- - then
2248
- - UNAME_PROCESSOR=powerpc
2249
- - fi
2250
- + if test "$CC_FOR_BUILD" != no_compiler_found; then
2251
- + if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
2252
- + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
2253
- + grep IS_64BIT_ARCH >/dev/null
2254
- + then
2255
- + case $UNAME_PROCESSOR in
2256
- + i386) UNAME_PROCESSOR=x86_64 ;;
2257
- + powerpc) UNAME_PROCESSOR=powerpc64 ;;
2258
- + esac
2259
- + fi
2260
- + # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc
2261
- + if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \
2262
- + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
2263
- + grep IS_PPC >/dev/null
2264
- + then
2265
- + UNAME_PROCESSOR=powerpc
2266
- fi
2267
- elif test "$UNAME_PROCESSOR" = i386 ; then
2268
- - # Avoid executing cc on OS X 10.9, as it ships with a stub
2269
- - # that puts up a graphical alert prompting to install
2270
- - # developer tools. Any system running Mac OS X 10.7 or
2271
- - # later (Darwin 11 and later) is required to have a 64-bit
2272
- - # processor. This is not true of the ARM version of Darwin
2273
- - # that Apple uses in portable devices.
2274
- - UNAME_PROCESSOR=x86_64
2275
- + # uname -m returns i386 or x86_64
2276
- + UNAME_PROCESSOR=$UNAME_MACHINE
2277
- fi
2278
- echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE"
2279
- exit ;;
2280
- *:procnto*:*:* | *:QNX:[0123456789]*:*)
2281
- - UNAME_PROCESSOR=`uname -p`
2282
- + UNAME_PROCESSOR=$(uname -p)
2283
- if test "$UNAME_PROCESSOR" = x86; then
2284
- UNAME_PROCESSOR=i386
2285
- UNAME_MACHINE=pc
2286
- @@ -1397,10 +1450,10 @@
2287
- echo mips-sei-seiux"$UNAME_RELEASE"
2288
- exit ;;
2289
- *:DragonFly:*:*)
2290
- - echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`"
2291
- + echo "$UNAME_MACHINE"-unknown-dragonfly"$(echo "$UNAME_RELEASE"|sed -e 's/[-(].*//')"
2292
- exit ;;
2293
- *:*VMS:*:*)
2294
- - UNAME_MACHINE=`(uname -p) 2>/dev/null`
2295
- + UNAME_MACHINE=$( (uname -p) 2>/dev/null)
2296
- case "$UNAME_MACHINE" in
2297
- A*) echo alpha-dec-vms ; exit ;;
2298
- I*) echo ia64-dec-vms ; exit ;;
2299
- @@ -1410,7 +1463,7 @@
2300
- echo i386-pc-xenix
2301
- exit ;;
2302
- i*86:skyos:*:*)
2303
- - echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`"
2304
- + echo "$UNAME_MACHINE"-pc-skyos"$(echo "$UNAME_RELEASE" | sed -e 's/ .*$//')"
2305
- exit ;;
2306
- i*86:rdos:*:*)
2307
- echo "$UNAME_MACHINE"-pc-rdos
2308
- @@ -1424,8 +1477,148 @@
2309
- amd64:Isilon\ OneFS:*:*)
2310
- echo x86_64-unknown-onefs
2311
- exit ;;
2312
- + *:Unleashed:*:*)
2313
- + echo "$UNAME_MACHINE"-unknown-unleashed"$UNAME_RELEASE"
2314
- + exit ;;
2315
- esac
2316
-
2317
- +# No uname command or uname output not recognized.
2318
- +set_cc_for_build
2319
- +cat > "$dummy.c" <<EOF
2320
- +#ifdef _SEQUENT_
2321
- +#include <sys/types.h>
2322
- +#include <sys/utsname.h>
2323
- +#endif
2324
- +#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__)
2325
- +#if defined (vax) || defined (__vax) || defined (__vax__) || defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__)
2326
- +#include <signal.h>
2327
- +#if defined(_SIZE_T_) || defined(SIGLOST)
2328
- +#include <sys/utsname.h>
2329
- +#endif
2330
- +#endif
2331
- +#endif
2332
- +main ()
2333
- +{
2334
- +#if defined (sony)
2335
- +#if defined (MIPSEB)
2336
- + /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed,
2337
- + I don't know.... */
2338
- + printf ("mips-sony-bsd\n"); exit (0);
2339
- +#else
2340
- +#include <sys/param.h>
2341
- + printf ("m68k-sony-newsos%s\n",
2342
- +#ifdef NEWSOS4
2343
- + "4"
2344
- +#else
2345
- + ""
2346
- +#endif
2347
- + ); exit (0);
2348
- +#endif
2349
- +#endif
2350
- +
2351
- +#if defined (NeXT)
2352
- +#if !defined (__ARCHITECTURE__)
2353
- +#define __ARCHITECTURE__ "m68k"
2354
- +#endif
2355
- + int version;
2356
- + version=$( (hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null);
2357
- + if (version < 4)
2358
- + printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
2359
- + else
2360
- + printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version);
2361
- + exit (0);
2362
- +#endif
2363
- +
2364
- +#if defined (MULTIMAX) || defined (n16)
2365
- +#if defined (UMAXV)
2366
- + printf ("ns32k-encore-sysv\n"); exit (0);
2367
- +#else
2368
- +#if defined (CMU)
2369
- + printf ("ns32k-encore-mach\n"); exit (0);
2370
- +#else
2371
- + printf ("ns32k-encore-bsd\n"); exit (0);
2372
- +#endif
2373
- +#endif
2374
- +#endif
2375
- +
2376
- +#if defined (__386BSD__)
2377
- + printf ("i386-pc-bsd\n"); exit (0);
2378
- +#endif
2379
- +
2380
- +#if defined (sequent)
2381
- +#if defined (i386)
2382
- + printf ("i386-sequent-dynix\n"); exit (0);
2383
- +#endif
2384
- +#if defined (ns32000)
2385
- + printf ("ns32k-sequent-dynix\n"); exit (0);
2386
- +#endif
2387
- +#endif
2388
- +
2389
- +#if defined (_SEQUENT_)
2390
- + struct utsname un;
2391
- +
2392
- + uname(&un);
2393
- + if (strncmp(un.version, "V2", 2) == 0) {
2394
- + printf ("i386-sequent-ptx2\n"); exit (0);
2395
- + }
2396
- + if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
2397
- + printf ("i386-sequent-ptx1\n"); exit (0);
2398
- + }
2399
- + printf ("i386-sequent-ptx\n"); exit (0);
2400
- +#endif
2401
- +
2402
- +#if defined (vax)
2403
- +#if !defined (ultrix)
2404
- +#include <sys/param.h>
2405
- +#if defined (BSD)
2406
- +#if BSD == 43
2407
- + printf ("vax-dec-bsd4.3\n"); exit (0);
2408
- +#else
2409
- +#if BSD == 199006
2410
- + printf ("vax-dec-bsd4.3reno\n"); exit (0);
2411
- +#else
2412
- + printf ("vax-dec-bsd\n"); exit (0);
2413
- +#endif
2414
- +#endif
2415
- +#else
2416
- + printf ("vax-dec-bsd\n"); exit (0);
2417
- +#endif
2418
- +#else
2419
- +#if defined(_SIZE_T_) || defined(SIGLOST)
2420
- + struct utsname un;
2421
- + uname (&un);
2422
- + printf ("vax-dec-ultrix%s\n", un.release); exit (0);
2423
- +#else
2424
- + printf ("vax-dec-ultrix\n"); exit (0);
2425
- +#endif
2426
- +#endif
2427
- +#endif
2428
- +#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__)
2429
- +#if defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__)
2430
- +#if defined(_SIZE_T_) || defined(SIGLOST)
2431
- + struct utsname *un;
2432
- + uname (&un);
2433
- + printf ("mips-dec-ultrix%s\n", un.release); exit (0);
2434
- +#else
2435
- + printf ("mips-dec-ultrix\n"); exit (0);
2436
- +#endif
2437
- +#endif
2438
- +#endif
2439
- +
2440
- +#if defined (alliant) && defined (i860)
2441
- + printf ("i860-alliant-bsd\n"); exit (0);
2442
- +#endif
2443
- +
2444
- + exit (1);
2445
- +}
2446
- +EOF
2447
- +
2448
- +$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=$($dummy) &&
2449
- + { echo "$SYSTEM_NAME"; exit; }
2450
- +
2451
- +# Apollos put the system type in the environment.
2452
- +test -d /usr/apollo && { echo "$ISP-apollo-$SYSTYPE"; exit; }
2453
- +
2454
- echo "$0: unable to guess system type" >&2
2455
-
2456
- case "$UNAME_MACHINE:$UNAME_SYSTEM" in
2457
- @@ -1448,6 +1641,12 @@
2458
- https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
2459
- and
2460
- https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
2461
- +EOF
2462
- +
2463
- +year=$(echo $timestamp | sed 's,-.*,,')
2464
- +# shellcheck disable=SC2003
2465
- +if test "$(expr "$(date +%Y)" - "$year")" -lt 3 ; then
2466
- + cat >&2 <<EOF
2467
-
2468
- If $0 has already been updated, send the following data and any
2469
- information you think might be pertinent to config-patches@gnu.org to
2470
- @@ -1455,26 +1654,27 @@
2471
-
2472
- config.guess timestamp = $timestamp
2473
-
2474
- -uname -m = `(uname -m) 2>/dev/null || echo unknown`
2475
- -uname -r = `(uname -r) 2>/dev/null || echo unknown`
2476
- -uname -s = `(uname -s) 2>/dev/null || echo unknown`
2477
- -uname -v = `(uname -v) 2>/dev/null || echo unknown`
2478
- -
2479
- -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null`
2480
- -/bin/uname -X = `(/bin/uname -X) 2>/dev/null`
2481
- -
2482
- -hostinfo = `(hostinfo) 2>/dev/null`
2483
- -/bin/universe = `(/bin/universe) 2>/dev/null`
2484
- -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null`
2485
- -/bin/arch = `(/bin/arch) 2>/dev/null`
2486
- -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null`
2487
- -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null`
2488
- +uname -m = $( (uname -m) 2>/dev/null || echo unknown)
2489
- +uname -r = $( (uname -r) 2>/dev/null || echo unknown)
2490
- +uname -s = $( (uname -s) 2>/dev/null || echo unknown)
2491
- +uname -v = $( (uname -v) 2>/dev/null || echo unknown)
2492
- +
2493
- +/usr/bin/uname -p = $( (/usr/bin/uname -p) 2>/dev/null)
2494
- +/bin/uname -X = $( (/bin/uname -X) 2>/dev/null)
2495
- +
2496
- +hostinfo = $( (hostinfo) 2>/dev/null)
2497
- +/bin/universe = $( (/bin/universe) 2>/dev/null)
2498
- +/usr/bin/arch -k = $( (/usr/bin/arch -k) 2>/dev/null)
2499
- +/bin/arch = $( (/bin/arch) 2>/dev/null)
2500
- +/usr/bin/oslevel = $( (/usr/bin/oslevel) 2>/dev/null)
2501
- +/usr/convex/getsysinfo = $( (/usr/convex/getsysinfo) 2>/dev/null)
2502
-
2503
- UNAME_MACHINE = "$UNAME_MACHINE"
2504
- UNAME_RELEASE = "$UNAME_RELEASE"
2505
- UNAME_SYSTEM = "$UNAME_SYSTEM"
2506
- UNAME_VERSION = "$UNAME_VERSION"
2507
- EOF
2508
- +fi
2509
-
2510
- exit 1
2511
-
3033
+ -# eval: (add-hook 'write-file-functions 'time-stamp)
3034
+ +# eval: (add-hook 'before-save-hook 'time-stamp)
3035
+ # time-stamp-start: "timestamp='"
3036
+ # time-stamp-format: "%:y-%02m-%02d"
3037
+ # time-stamp-end: "'"