]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
gcc-cross-initial: Use good old bfd linker by default
authorKhem Raj <raj.khem@gmail.com>
Thu, 14 Aug 2014 05:05:15 +0000 (22:05 -0700)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 15 Aug 2014 17:19:51 +0000 (18:19 +0100)
We already indicate our intentions to use ld.bfd by
specifying it in configure using --with-ld which works
ok unless here where we manually create symlinks to
binutils-cross components, when we use ld-is-gold feature
default ld points to gold and this symlinking has to be
aware of the fact that we configured binutils and gcc-cross to use
gold as default ld but gcc-cross-initial uses BFD ld

This would be visible when using gold and rebuilding
eglibc

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-devtools/gcc/gcc-cross-initial.inc

index 5a6da8bbd2b1aa6cf48745c82b311d474dc66230..23a6d4beb4b1ced03b5fabc5ebba202d35661268 100644 (file)
@@ -57,7 +57,9 @@ do_install () {
        # found. These need to be relative paths so they work in different locations.
        dest=${D}${libexecdir}/gcc/${TARGET_SYS}/${BINV}/
        install -d $dest
-       for t in ar as ld nm objcopy objdump ranlib strip g77 gcc cpp gfortran; do
+       useld=${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', '.bfd', '', d)}
+       ln -sf ${BINRELPATH}/${TARGET_PREFIX}ld${useld} ${dest}ld
+       for t in ar as nm objcopy objdump ranlib strip g77 gcc cpp gfortran; do
                ln -sf ${BINRELPATH}/${TARGET_PREFIX}$t $dest$t
        done
        # fixed limits.h infact includes the so called real limits.h