diff -r a221c86d9b33 -r 1c56c03b7ed5 scripts/build/binutils/elf2flt.sh --- a/scripts/build/binutils/elf2flt.sh Thu Oct 11 14:39:42 2012 +1000 +++ b/scripts/build/binutils/elf2flt.sh Fri Nov 16 15:25:57 2012 +0100 @@ -49,6 +49,8 @@ elf2flt_opts+=( "host=${CT_BUILD}" ) elf2flt_opts+=( "prefix=${CT_BUILDTOOLS_PREFIX_DIR}" ) + elf2flt_opts+=( "cflags=${CT_CFLAGS_FOR_BUILD}" ) + elf2flt_opts+=( "ldflags=${CT_LDFLAGS_FOR_BUILD}" ) elf2flt_opts+=( "binutils_bld=${CT_BUILD_DIR}/build-binutils-build-${CT_HOST}" ) do_elf2flt_backend "${elf2flt_opts[@]}" @@ -68,6 +70,7 @@ elf2flt_opts+=( "prefix=${CT_PREFIX_DIR}" ) elf2flt_opts+=( "static_build=${CT_STATIC_TOOLCHAIN}" ) elf2flt_opts+=( "cflags=${CT_CFLAGS_FOR_HOST}" ) + elf2flt_opts+=( "ldflags=${CT_LDFLAGS_FOR_HOST}" ) elf2flt_opts+=( "binutils_bld=${CT_BUILD_DIR}/build-binutils-host-${CT_HOST}" ) do_elf2flt_backend "${elf2flt_opts[@]}" @@ -102,12 +105,14 @@ # host : machine to run on : tuple : (none) # prefix : prefix to install into : dir : (none) # static_build : build statcially : bool : no -# cflags : host cflags to use : string : (empty) +# cflags : cflags to use : string : (empty) +# ldflags : ldflags to use : string : (empty) do_elf2flt_backend() { local host local prefix local static_build local cflags + local ldflags local binutils_bld local binutils_src local arg @@ -120,7 +125,8 @@ CT_DoLog EXTRA "Configuring elf2flt" CT_DoExecLog CFG \ - CFLAGS="${host_cflags}" \ + CFLAGS="${cflags}" \ + LDFLAGS="${ldflags}" \ "${CT_SRC_DIR}/elf2flt-${CT_ELF2FLT_VERSION}/configure" \ --build=${CT_BUILD} \ --host=${host} \