summaryrefslogtreecommitdiff
path: root/config/cc/gcc.in
blob: d7fa48f9e9f58bcc49ffdd5684854bc22c2b7eaf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
# Compiler options
#
## select CC_SUPPORT_CXX
## select CC_SUPPORT_FORTRAN
## select CC_SUPPORT_JAVA
## select CC_SUPPORT_ADA
## select CC_SUPPORT_OBJC
## select CC_SUPPORT_OBJCXX
##
## help gcc is the full-blown GNU compiler. This is what most people will choose.
## help
## help gcc supports many languages, a powerful code parser, optimised binary
## help output, and lots of other features.

config CC_GCC_SHOW_LINARO
    bool
    prompt "Show Linaro versions"
    help
      Linaro is maintaining some advanced/more stable/experimental versions
      of gcc, especially for the ARM architecture.
      
      Those versions have not been blessed by the gcc comunity (nor have they
      been cursed either!), but they look to be pretty much stable, and even
      more stable than the upstream versions. YMMV...
      
      If you do not know what this Linaro stuff is, then simply say 'n' here,
      and rest in peace. OTOH, if you know what you are doing, you will be
      able to use and enjoy :-) the Linaro versions by saying 'y' here.
      
      Linaro: http://www.linaro.org/

choice
    bool
    prompt "gcc version"

# Don't remove next line
# CT_INSERT_VERSION_BELOW

config CC_V_4_9_2
    bool
    prompt "4.9.2"
    select CC_GCC_4_9

config CC_V_4_9_1
    bool
    prompt "4.9.1"
    select CC_GCC_4_9

config CC_V_4_9_0
    bool
    prompt "4.9.0"
    select CC_GCC_4_9

config CC_V_linaro_4_8
    bool
    prompt "linaro-4.8-2014.08"
    depends on CC_GCC_SHOW_LINARO
    select CC_GCC_4_8

config CC_V_4_8_3
    bool
    prompt "4.8.3"
    select CC_GCC_4_8

config CC_V_4_8_2
    bool
    prompt "4.8.2"
    select CC_GCC_4_8

config CC_V_4_8_1
    bool
    prompt "4.8.1"
    select CC_GCC_4_8

config CC_V_4_8_0
    bool
    prompt "4.8.0"
    select CC_GCC_4_8

config CC_V_linaro_4_7
    bool
    prompt "linaro-4.7-2014.06"
    depends on CC_GCC_SHOW_LINARO
    select CC_GCC_4_7

config CC_V_4_7_4
    bool
    prompt "4.7.4"
    select CC_GCC_4_7

config CC_V_4_7_3
    bool
    prompt "4.7.3"
    select CC_GCC_4_7

config CC_V_4_7_2
    bool
    prompt "4.7.2"
    select CC_GCC_4_7

config CC_V_4_7_1
    bool
    prompt "4.7.1"
    select CC_GCC_4_7

config CC_V_4_7_0
    bool
    prompt "4.7.0"
    select CC_GCC_4_7

config CC_V_linaro_4_6
    bool
    prompt "linaro-4.6-2013.05"
    depends on CC_GCC_SHOW_LINARO
    select CC_GCC_4_6

config CC_V_4_6_4
    bool
    prompt "4.6.4"
    select CC_GCC_4_6

config CC_V_4_6_3
    bool
    prompt "4.6.3"
    select CC_GCC_4_6

config CC_V_4_6_2
    bool
    prompt "4.6.2"
    select CC_GCC_4_6

config CC_V_4_6_1
    bool
    prompt "4.6.1"
    select CC_GCC_4_6

config CC_V_4_6_0
    bool
    prompt "4.6.0"
    select CC_GCC_4_6

config CC_V_linaro_4_5
    bool
    prompt "linaro-4.5-2012.03"
    depends on CC_GCC_SHOW_LINARO
    select CC_GCC_4_5

config CC_V_4_5_3
    bool
    prompt "4.5.3"
    select CC_GCC_4_5

config CC_V_4_5_2
    bool
    prompt "4.5.2"
    select CC_GCC_4_5

config CC_V_4_5_1
    bool
    prompt "4.5.1"
    select CC_GCC_4_5

config CC_V_4_5_0
    bool
    prompt "4.5.0"
    select CC_GCC_4_5


config CC_V_linaro_4_4
    bool
    prompt "linaro-4.4-2011.02-0"
    depends on CC_GCC_SHOW_LINARO
    select CC_GCC_4_4

config CC_V_4_4_7
    bool
    prompt "4.4.7"
    select CC_GCC_4_4

config CC_V_4_4_6
    bool
    prompt "4.4.6"
    select CC_GCC_4_4

config CC_V_4_4_5
    bool
    prompt "4.4.5"
    select CC_GCC_4_4

config CC_V_4_4_4
    bool
    prompt "4.4.4"
    select CC_GCC_4_4

config CC_V_4_4_3
    bool
    prompt "4.4.3"
    select CC_GCC_4_4

config CC_V_4_4_2
    bool
    prompt "4.4.2"
    select CC_GCC_4_4

config CC_V_4_4_1
    bool
    prompt "4.4.1"
    select CC_GCC_4_4

config CC_V_4_4_0
    bool
    prompt "4.4.0"
    select CC_GCC_4_4

config CC_V_4_3_6
    bool
    prompt "4.3.6"
    select CC_GCC_4_3

config CC_V_4_3_5
    bool
    prompt "4.3.5"
    select CC_GCC_4_3

config CC_V_4_3_4
    bool
    prompt "4.3.4"
    select CC_GCC_4_3

config CC_V_4_3_3
    bool
    prompt "4.3.3"
    select CC_GCC_4_3

config CC_V_4_3_2
    bool
    prompt "4.3.2"
    select CC_GCC_4_3

config CC_V_4_3_1
    bool
    prompt "4.3.1"
    select CC_GCC_4_3

config CC_V_4_2_4
    bool
    prompt "4.2.4"
    select CC_GCC_4_2

# We need that one, it's the only version with avr32 support
# because we have a patch for it
config CC_V_4_2_2
    bool
    prompt "4.2.2"
    select CC_GCC_4_2

config CC_V_4_1_2
    bool
    prompt "4.1.2 (OBSOLETE)"
    depends on OBSOLETE

config CC_V_4_0_4
    bool
    prompt "4.0.4 (OBSOLETE)"
    depends on OBSOLETE

config CC_V_3_4_6
    bool
    prompt "3.4.6 (OBSOLETE)"
    depends on OBSOLETE

config CC_CUSTOM
    bool
    prompt "Custom gcc"
    depends on EXPERIMENTAL
    select CC_GCC_latest

endchoice

if CC_CUSTOM

config CC_CUSTOM_LOCATION
    string
    prompt "Full path to custom gcc source"
    default ""
    help
      Enter the path to the directory (or tarball) of your source for gcc,
      or leave blank to use default CT_CUSTOM_LOCATION_ROOT_DIR/gcc

endif #CC_CUSTOM

config CC_GCC_4_2
    bool
    select CC_GCC_4_2_or_later

config CC_GCC_4_2_or_later
    bool

config CC_GCC_4_3
    bool
    select CC_GCC_4_3_or_later
    select CC_GCC_USE_GMP_MPFR
    select CC_GCC_HAS_PKGVERSION_BUGURL

config CC_GCC_4_3_or_later
    bool
    select CC_GCC_4_2_or_later

config CC_GCC_4_4
    bool
    select CC_GCC_4_4_or_later
    select CC_GCC_USE_GMP_MPFR
    select CC_GCC_HAS_GRAPHITE
    select CC_GCC_HAS_PKGVERSION_BUGURL

config CC_GCC_4_4_or_later
    bool
    select CC_GCC_4_3_or_later

config CC_GCC_4_5
    bool
    select CC_GCC_4_5_or_later
    select CC_GCC_USE_GMP_MPFR
    select CC_GCC_USE_MPC
    select CC_GCC_HAS_GRAPHITE
    select CC_GCC_HAS_LTO
    select CC_GCC_HAS_PKGVERSION_BUGURL
    select CC_GCC_HAS_BUILD_ID

config CC_GCC_4_5_or_later
    bool
    select CC_GCC_4_4_or_later

config CC_GCC_4_6
    bool
    select CC_GCC_4_6_or_later
    select CC_GCC_USE_GMP_MPFR
    select CC_GCC_USE_MPC
    select CC_GCC_HAS_GRAPHITE
    select CC_GCC_HAS_LTO
    select CC_GCC_HAS_PKGVERSION_BUGURL
    select CC_GCC_HAS_BUILD_ID
    select CC_GCC_HAS_LIBQUADMATH

config CC_GCC_4_6_or_later
    bool
    select CC_GCC_4_5_or_later

config CC_GCC_4_7
    bool
    select CC_GCC_4_7_or_later
    select CC_GCC_USE_GMP_MPFR
    select CC_GCC_USE_MPC
    select CC_GCC_HAS_GRAPHITE
    select CC_GCC_HAS_LTO
    select CC_GCC_HAS_PKGVERSION_BUGURL
    select CC_GCC_HAS_BUILD_ID
    select CC_GCC_HAS_LNK_HASH_STYLE
    select CC_GCC_HAS_LIBQUADMATH

config CC_GCC_4_7_or_later
    bool
    select CC_GCC_4_6_or_later

config CC_GCC_4_8
    bool
    select CC_GCC_4_8_or_later
    select CC_GCC_USE_GMP_MPFR
    select CC_GCC_USE_MPC
    select CC_GCC_HAS_GRAPHITE
    select CC_GCC_HAS_LTO
    select CC_GCC_HAS_PKGVERSION_BUGURL
    select CC_GCC_HAS_BUILD_ID
    select CC_GCC_HAS_LNK_HASH_STYLE
    select CC_GCC_HAS_LIBQUADMATH
    select CC_GCC_HAS_LIBSANITIZER
    select CC_SUPPORT_GOLANG

config CC_GCC_4_8_or_later
    bool
    select CC_GCC_4_7_or_later

config CC_GCC_4_9
    bool
    select CC_GCC_4_9_or_later
    select CC_GCC_USE_GMP_MPFR
    select CC_GCC_USE_MPC
    select CC_GCC_HAS_GRAPHITE
    select CC_GCC_HAS_LTO
    select CC_GCC_HAS_PKGVERSION_BUGURL
    select CC_GCC_HAS_BUILD_ID
    select CC_GCC_HAS_LNK_HASH_STYLE
    select CC_GCC_HAS_LIBQUADMATH
    select CC_GCC_HAS_LIBSANITIZER
    select CC_SUPPORT_GOLANG

config CC_GCC_4_9_or_later
    bool
    select CC_GCC_4_8_or_later

config CC_GCC_latest
    bool
    select CC_GCC_4_9_or_later
    select CC_GCC_USE_GMP_MPFR
    select CC_GCC_USE_MPC
    select CC_GCC_HAS_GRAPHITE
    select CC_GCC_HAS_LTO
    select CC_GCC_HAS_PKGVERSION_BUGURL
    select CC_GCC_HAS_BUILD_ID
    select CC_GCC_HAS_LNK_HASH_STYLE
    select CC_GCC_HAS_LIBQUADMATH
    select CC_GCC_HAS_LIBSANITIZER

config CC_GCC_HAS_GRAPHITE
    bool

# For graphite: gcc 4.4..4.7 need ppl, while 4.8.. need isl
# Prompt in config/cc/gcc.in.2
config CC_GCC_USE_GRAPHITE
    bool
    default y
    depends on CC_GCC_HAS_GRAPHITE
    select CLOOG_NEEDED
    select PPL_NEEDED if !CC_GCC_4_8_or_later
    select ISL_NEEDED if CC_GCC_4_8_or_later
    help
      Enable the GRAPHITE loop optimsations.
      
      On some systems (eg. Cygwin), PPL and/or CLooG (required to enable
      GRAPHITE) may not build properly (yet), so you'll have to say 'N'
      here (or help debug the issues)

# The way LTO works is a bit twisted.
# See: http://gcc.gnu.org/wiki/LinkTimeOptimization#Requirements
# Basically:
#   - if binutils has plugins: LTO is handled by ld/gold by loading
#     the plugin when linking
#   - if binutils does not have plugins: LTO is handled by collect2
# In any case, LTO support does not depend on plugins, but takes
# advantage of it
config CC_GCC_HAS_LTO
    bool

# Prompt in config/cc/gcc.in.2
config CC_GCC_USE_LTO
    bool
    default y
    depends on CC_GCC_HAS_LTO
    select CC_GCC_USE_LIBELF if CC_GCC_4_5
    help
      Enable the Link Time Optimisations.

config CC_GCC_HAS_PKGVERSION_BUGURL
    bool

config CC_GCC_HAS_BUILD_ID
    bool

config CC_GCC_HAS_LNK_HASH_STYLE
    bool

# Only enable gcc's support for plugins if binutils has it as well
# They are usefull only when doing LTO, but it does no harm enabling
# them even without LTO.
config CC_GCC_ENABLE_PLUGINS
    bool
    depends on BINUTILS_PLUGINS
    depends on ! STATIC_TOOLCHAIN
    default y

# If binutils installs gold, enable support for gold in gcc
config CC_GCC_GOLD
    bool
    depends on BINUTILS_GOLD_INSTALLED
    default y

config CC_GCC_USE_GMP_MPFR
    bool
    select GMP_NEEDED
    select MPFR_NEEDED

config CC_GCC_USE_MPC
    bool
    select MPC_NEEDED

config CC_GCC_USE_LIBELF
    bool
    select LIBELF_NEEDED

config CC_GCC_HAS_LIBQUADMATH
    bool

config CC_GCC_HAS_LIBSANITIZER
    bool

config CC_VERSION
    string
# Don't remove next line
# CT_INSERT_VERSION_STRING_BELOW
    default "4.9.2" if CC_V_4_9_2
    default "4.9.1" if CC_V_4_9_1
    default "4.9.0" if CC_V_4_9_0
    default "linaro-4.8-2014.08" if CC_V_linaro_4_8
    default "4.8.3" if CC_V_4_8_3
    default "4.8.2" if CC_V_4_8_2
    default "4.8.1" if CC_V_4_8_1
    default "4.8.0" if CC_V_4_8_0
    default "linaro-4.7-2014.06" if CC_V_linaro_4_7
    default "4.7.4" if CC_V_4_7_4
    default "4.7.3" if CC_V_4_7_3
    default "4.7.2" if CC_V_4_7_2
    default "4.7.1" if CC_V_4_7_1
    default "4.7.0" if CC_V_4_7_0
    default "linaro-4.6-2013.05" if CC_V_linaro_4_6
    default "4.6.4" if CC_V_4_6_4
    default "4.6.3" if CC_V_4_6_3
    default "4.6.2" if CC_V_4_6_2
    default "4.6.1" if CC_V_4_6_1
    default "4.6.0" if CC_V_4_6_0
    default "linaro-4.5-2012.03" if CC_V_linaro_4_5
    default "4.5.3" if CC_V_4_5_3
    default "4.5.2" if CC_V_4_5_2
    default "4.5.1" if CC_V_4_5_1
    default "4.5.0" if CC_V_4_5_0
    default "linaro-4.4-2011.02-0" if CC_V_linaro_4_4
    default "4.4.7" if CC_V_4_4_7
    default "4.4.6" if CC_V_4_4_6
    default "4.4.5" if CC_V_4_4_5
    default "4.4.4" if CC_V_4_4_4
    default "4.4.3" if CC_V_4_4_3
    default "4.4.2" if CC_V_4_4_2
    default "4.4.1" if CC_V_4_4_1
    default "4.4.0" if CC_V_4_4_0
    default "4.3.6" if CC_V_4_3_6
    default "4.3.5" if CC_V_4_3_5
    default "4.3.4" if CC_V_4_3_4
    default "4.3.3" if CC_V_4_3_3
    default "4.3.2" if CC_V_4_3_2
    default "4.3.1" if CC_V_4_3_1
    default "4.3.0" if CC_V_4_3_0
    default "4.2.4" if CC_V_4_2_4
    default "4.2.2" if CC_V_4_2_2
    default "4.1.2" if CC_V_4_1_2
    default "4.0.4" if CC_V_4_0_4
    default "3.4.6" if CC_V_3_4_6
    default "custom" if CC_CUSTOM

config CC_LANG_JAVA_USE_ECJ
    bool
    default y
    depends on CC_LANG_JAVA
    depends on CC_GCC_4_3_or_later

# Fortran always requires GMP+MPFR, whatever the gcc version
config CC_LANG_FORTRAN
    select CC_GCC_USE_GMP_MPFR