config/binutils/binutils.in
author "Yann E. MORIN" <yann.morin.1998@free.fr>
Mon Dec 30 19:08:37 2013 +0100 (2013-12-30)
changeset 3257 7b7d953f9cfb
parent 3240 bc4b36e3df0c
child 3263 16f46c7ed41b
permissions -rw-r--r--
binutils/binutils: 2.23.2 is a 2_23_or_later (ie. has gold)

Thus spake Niels:
This commit adds support for binutils 2.23.2

http://crosstool-ng.org/hg/crosstool-ng/rev/bc4b36e3df0c

However, in 'config/binutils/binutils.in <http://binutils.in>' the
Kconfig option to select this version of binutils does not automatically
select the symbol 'BINUTILS_2_23_or_later'. This makes gold unavailable
for the latest version of binutils. I'm not sure whether this is on
purpose or not, my impression is that you forgot to add the line "select
BINUTILS_2_23_or_later".

The problem still persists in the latest version in the repository
(032ebcc89c96).

Reported-by: Niels Penneman <niels@penneman.org>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
     1 # binutils options
     2 
     3 comment "GNU binutils"
     4 
     5 choice
     6     bool
     7     prompt "binutils version"
     8 # Don't remove next line
     9 # CT_INSERT_VERSION_BELOW
    10 
    11 config BINUTILS_V_2_23_2
    12     bool
    13     prompt "2.23.2 (EXPERIMENTAL)"
    14     depends on EXPERIMENTAL
    15     select BINUTILS_2_23_or_later
    16 
    17 config BINUTILS_V_2_23_1
    18     bool
    19     prompt "2.23.1 (EXPERIMENTAL)"
    20     depends on EXPERIMENTAL
    21     select BINUTILS_2_23_or_later
    22 
    23 config BINUTILS_V_2_22
    24     bool
    25     prompt "2.22"
    26     select BINUTILS_2_22_or_later
    27 
    28 config BINUTILS_V_2_21_53
    29     bool
    30     prompt "2.21.53"
    31     select BINUTILS_2_21_or_later
    32 
    33 config BINUTILS_V_2_21_1a
    34     bool
    35     prompt "2.21.1a"
    36     select BINUTILS_2_21_or_later
    37 
    38 config BINUTILS_V_2_20_1a
    39     bool
    40     prompt "2.20.1a"
    41     select BINUTILS_2_20_or_later
    42 
    43 config BINUTILS_V_2_19_1a
    44     bool
    45     prompt "2.19.1a"
    46     select BINUTILS_2_19_or_later
    47 
    48 config BINUTILS_V_2_18a
    49     bool
    50     prompt "2.18a"
    51     select BINUTILS_2_18_or_later
    52 
    53 config BINUTILS_CUSTOM
    54     bool
    55     prompt "Custom binutils"
    56     depends on EXPERIMENTAL
    57     select BINUTILS_2_22_or_later
    58 
    59 endchoice
    60 
    61 if BINUTILS_CUSTOM
    62 
    63 config BINUTILS_CUSTOM_LOCATION
    64     string
    65     prompt "Full path to custom binutils source"
    66     default ""
    67     help
    68       Enter the path to the directory (or tarball) of your source for binutils,
    69       or leave blank to use default CT_CUSTOM_LOCATION_ROOT_DIR/binutils
    70 
    71 endif # BINUTILS_CUSTOM
    72 
    73 config BINUTILS_VERSION
    74     string
    75 # Don't remove next line
    76 # CT_INSERT_VERSION_STRING_BELOW
    77     default "2.23.2" if BINUTILS_V_2_23_2
    78     default "2.23.1" if BINUTILS_V_2_23_1
    79     default "2.22" if BINUTILS_V_2_22
    80     default "2.21.53" if BINUTILS_V_2_21_53
    81     default "2.21.1a" if BINUTILS_V_2_21_1a
    82     default "2.20.1a" if BINUTILS_V_2_20_1a
    83     default "2.19.1a" if BINUTILS_V_2_19_1a
    84     default "2.18a" if BINUTILS_V_2_18a
    85     default "custom" if BINUTILS_CUSTOM
    86 
    87 config BINUTILS_2_23_or_later
    88     bool
    89     select BINUTILS_2_22_or_later
    90     select BINUTILS_HAS_GOLD
    91     select BINUTILS_HAS_PLUGINS
    92 
    93 config BINUTILS_2_22_or_later
    94     bool
    95     select BINUTILS_2_21_or_later
    96     select BINUTILS_HAS_GOLD
    97     select BINUTILS_HAS_PLUGINS
    98 
    99 config BINUTILS_2_21_or_later
   100     bool
   101     select BINUTILS_2_20_or_later
   102     select BINUTILS_HAS_GOLD
   103     select BINUTILS_HAS_PLUGINS
   104 
   105 config BINUTILS_2_20_or_later
   106     bool
   107     select BINUTILS_2_19_or_later
   108 
   109 config BINUTILS_2_19_or_later
   110     bool
   111     select BINUTILS_2_18_or_later
   112 
   113 config BINUTILS_2_18_or_later
   114     bool
   115     select BINUTILS_HAS_PKGVERSION_BUGURL
   116     select BINUTILS_HAS_HASH_STYLE
   117 
   118 config BINUTILS_HAS_HASH_STYLE
   119     bool
   120 
   121 config BINUTILS_HAS_GOLD
   122     bool
   123 
   124 # gold only suports the listed architectures
   125 config BINUTILS_GOLD_SUPPORTS_ARCH
   126     bool
   127     default y if ARCH_arm
   128     default y if ARCH_x86
   129 
   130 config BINUTILS_HAS_PLUGINS
   131     bool
   132 
   133 config BINUTILS_HAS_PKGVERSION_BUGURL
   134     bool
   135 
   136 # Force using the BFD linker if needed
   137 # This is the case for some C libraries (eg. glibc and
   138 # eglibc at least) and affected components can select this
   139 config BINUTILS_FORCE_LD_BFD
   140     bool
   141 
   142 choice
   143     bool
   144     prompt "Linkers to enable"
   145 
   146 config BINUTILS_LINKER_LD
   147     bool
   148     prompt "ld"
   149     help
   150       The historical, bfd linker.
   151 
   152 config BINUTILS_LINKER_GOLD
   153     bool
   154     prompt "gold"
   155     depends on BINUTILS_HAS_GOLD
   156     depends on BINUTILS_GOLD_SUPPORTS_ARCH
   157     depends on ! BINUTILS_FORCE_LD_BFD
   158     select BINUTILS_GOLD_INSTALLED
   159     help
   160       gold is a new, optimised, multi-threaded linker with support
   161       for plugins. Designed to be a drop-in replacement for the
   162       original linker, ld, it can be much faster, with a 5:1 or
   163       bigger ratio being not uncommon, YMMV.
   164 
   165 config BINUTILS_LINKER_LD_GOLD
   166     bool
   167     prompt "ld, gold"
   168     depends on BINUTILS_HAS_GOLD
   169     depends on BINUTILS_GOLD_SUPPORTS_ARCH
   170     select BINUTILS_GOLD_INSTALLED
   171     select BINUTILS_LINKER_BOTH
   172     help
   173       Both the historical ld and the new gold linkers will be
   174       installed, with ld being the default linker used.
   175       
   176       See help for gold, above.
   177 
   178 config BINUTILS_LINKER_GOLD_LD
   179     bool
   180     prompt "gold, ld"
   181     depends on BINUTILS_HAS_GOLD
   182     depends on BINUTILS_GOLD_SUPPORTS_ARCH
   183     select BINUTILS_GOLD_INSTALLED
   184     select BINUTILS_LINKER_BOTH
   185     select BINUTILS_LD_WRAPPER if BINUTILS_FORCE_LD_BFD
   186     help
   187       Both the historical ld and the new gold linkers will be
   188       installed, with gold being the default linker used.
   189       
   190       See help for gold, above.
   191 
   192 endchoice # Enable linkers
   193 
   194 if BINUTILS_LINKER_GOLD
   195 comment "WARNING! gold is not capable of"
   196 comment "|         building glibc/eglibc!"
   197 endif # BINUTILS_LINKER_GOLD
   198 
   199 config BINUTILS_GOLD_INSTALLED
   200     bool
   201 
   202 config BINUTILS_GOLD_THREADS
   203     bool
   204     prompt "|  Enable threaded gold"
   205     depends on BINUTILS_GOLD_INSTALLED
   206     help
   207       When configured with threads, gold can link in parallel,
   208       possibly cooperating with a make jobserver.
   209 
   210 config BINUTILS_LINKER_BOTH
   211     bool
   212 
   213 config BINUTILS_LINKERS_LIST
   214     string
   215     default "ld"        if BINUTILS_LINKER_LD
   216     default "gold"      if BINUTILS_LINKER_GOLD
   217     default "ld,gold"   if BINUTILS_LINKER_LD_GOLD
   218     default "gold,ld"   if BINUTILS_LINKER_GOLD_LD
   219 
   220 config BINUTILS_LD_WRAPPER
   221     bool
   222     prompt "|  Add ld wrapper"
   223     depends on BINUTILS_LINKER_BOTH
   224     help
   225       Add an ld wrapper that calls to either gold or ld.
   226       
   227       By default, the wrapper will call to the default wrapper,
   228       but if you set the environment variable CTNG_LD_IS, you
   229       can change which linker will get called:
   230         CTNG_LD_IS=gold     will unconditionally call the gold linker
   231         CTNG_LD_IS=bfd      will unconditionally call the old bfd ld linker
   232 
   233 config BINUTILS_LINKER_DEFAULT
   234     string
   235     default "bfd"   if BINUTILS_LINKER_LD || BINUTILS_LINKER_LD_GOLD
   236     default "gold"  if BINUTILS_LINKER_GOLD || BINUTILS_LINKER_GOLD_LD
   237 
   238 config BINUTILS_PLUGINS
   239     bool
   240     prompt "Enable support for plugins"
   241     depends on BINUTILS_HAS_PLUGINS
   242     depends on ! STATIC_TOOLCHAIN
   243     help
   244       binutils can be extended through the use of plugins.
   245       Especially, gold can use the lto-plugin, as installed
   246       by gcc, to handle LTO.
   247 
   248 config BINUTILS_EXTRA_CONFIG_ARRAY
   249     string
   250     prompt "binutils extra config"
   251     default ""
   252     help
   253       Extra flags passed onto ./configure when configuring
   254       
   255       You can enter multiple arguments here, and arguments can contain spaces
   256       if they are properly quoted (or escaped, but prefer quotes). Eg.:
   257           --with-foo="1st arg with 4 spaces" --with-bar=2nd-arg-without-space
   258 
   259 config BINUTILS_FOR_TARGET
   260     bool
   261     prompt "binutils libraries for the target"
   262     depends on ! BARE_METAL
   263     depends on ! BACKEND
   264     help
   265       Some utilities may need binutils libraries to be available on
   266       the target, eg. oprofile.
   267 
   268 if BINUTILS_FOR_TARGET
   269 
   270 config BINUTILS_FOR_TARGET_IBERTY
   271     bool
   272     prompt "libiberty"
   273     default y
   274 
   275 config BINUTILS_FOR_TARGET_BFD
   276     bool
   277     prompt "libbfd"
   278     default y
   279 
   280 endif # BINUTILS_FOR_TARGET