config/binutils/binutils.in
author Johannes Stezenbach <js@sig21.net>
Thu Jul 29 19:30:37 2010 +0200 (2010-07-29)
branch1.7
changeset 2047 ace1d90c9b15
parent 1810 e44f67656c5f
child 2012 aefc8799ef0c
permissions -rw-r--r--
scripts: remove . from $PATH

Add CT_SanitizePath function which removes entries referring to ., /tmp
and non-existing directories from $PATH, and call it early in the
build script.

If . is in PATH, gcc-4.4.4 build breaks:

[ALL ] checking what assembler to use...
/tmp/build/targets/arm-unknown-linux-uclibcgnueabi/build/gcc-core-static/arm-unknown-linux-uclibcgnueabi/bin/as
...
[ALL ] config.status: creating as

i.e. "as" is supposed to be the arm-unknown-linux-uclibcgnueabi cross assembler,
but config.status creates a local "as" script which is calling the
host assembler.

Signed-off-by: Johannes Stezenbach <js@sig21.net>
[Yann E. MORIN: style fixes + explanations]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
(transplanted from 20dd8cef1c8adff0aa3e78ae6d7acfbc45ed5a83)
     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_20
    12     bool
    13     prompt "2.20"
    14 
    15 config BINUTILS_V_2_19_1
    16     bool
    17     prompt "2.19.1"
    18 
    19 config BINUTILS_V_2_19
    20     bool
    21     prompt "2.19"
    22 
    23 config BINUTILS_V_2_18
    24     bool
    25     prompt "2.18"
    26 
    27 config BINUTILS_V_2_17
    28     bool
    29     prompt "2.17 (OBSOLETE)"
    30     depends on OBSOLETE
    31 
    32 config BINUTILS_V_2_16_1
    33     bool
    34     prompt "2.16.1 (OBSOLETE)"
    35     depends on OBSOLETE
    36 
    37 endchoice
    38 
    39 config BINUTILS_VERSION
    40     string
    41 # Don't remove next line
    42 # CT_INSERT_VERSION_STRING_BELOW
    43     default "2.20" if BINUTILS_V_2_20
    44     default "2.19.1" if BINUTILS_V_2_19_1
    45     default "2.19" if BINUTILS_V_2_19
    46     default "2.18" if BINUTILS_V_2_18
    47     default "2.17" if BINUTILS_V_2_17
    48     default "2.16.1" if BINUTILS_V_2_16_1
    49 
    50 config BINUTILS_EXTRA_CONFIG
    51     string
    52     prompt "binutils extra config"
    53     default ""
    54     help
    55       Extra flags passed onto ./configure when configuring
    56 
    57 config BINUTILS_FOR_TARGET
    58     bool
    59     prompt "binutils libraries for the target"
    60     depends on ! BARE_METAL
    61     depends on ! BACKEND
    62     default n
    63     help
    64       Some utilities may need binutils libraries to be available on
    65       the target, eg. oprofile.
    66 
    67 if BINUTILS_FOR_TARGET
    68 
    69 config BINUTILS_FOR_TARGET_IBERTY
    70     bool
    71     prompt "libiberty"
    72     default y
    73 
    74 config BINUTILS_FOR_TARGET_BFD
    75     bool
    76     prompt "libbfd"
    77     default y
    78 
    79 config BINUTILS_TARGET_USE_GMP_MPFR
    80     bool
    81     prompt "Use GMP and MPFR"
    82     default n
    83     select GMP_TARGET
    84     select MPFR_TARGET
    85     help
    86       binutils can be configured to use GMP and MPFR.
    87       While this is automatically handled for the cross-binutils,
    88       You have to explicitly state so for the native libraries that
    89       will run on the target.
    90 
    91 endif # BINUTILS_FOR_TARGET