diff options
author | Samuli Piippo <samuli.piippo@gmail.com> | 2022-09-16 07:41:05 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-09-17 07:47:07 +0100 |
commit | 09ae62b662724c58c64b305bac05ed9302ce9d79 (patch) | |
tree | 012d5e963a0403e319897fed492c26154b56c08f /meta/recipes-devtools/gcc/gcc-target.inc | |
parent | 971cb0c9af502d568f9f050248c372c3b684d2d6 (diff) | |
download | poky-09ae62b662724c58c64b305bac05ed9302ce9d79.tar.gz |
gcc-cross-canadian: add default plugin linker
Fix multilib sdk issue where gcc is unable to find linker. Previous
fix was in cdd86896c8d29135f937968e9aa07f919cf543d3 using real-ld
symlink, but that prevented switching between bfd and gold linkers.
Running compiler with debug arguments shows that collect2 tries and
fails to find linker using the multilib triples:
$ $CC -v -Wl,-debug
...
Looking for 'real-ld'
Looking for 'collect-ld'
Looking for 'mips-oemllib32-linux-ld'
Looking for 'mips-oe-linux-mips-oemllib32-linux-ld'
...
collect2 version 12.2.0
ld_file_name = not found
...
collect2: fatal error: cannot find ‘ld’
Using --with-plugin-ld=ld in gcc-cross-canadian builds to set default
linker name for collect2, lets it find the linker correctly:
Looking for 'real-ld'
Looking for 'collect-ld'
Looking for 'ld'
...
collect2 version 12.2.0
ld_file_name = /usr/local/oecore-x86_64/sysroots/x86_64-oesdk-linux/usr/libexec/mips-oe-linux/gcc/mips-oe-linux/12.2.0/ld
Swith between bfd and gold linker works as expected now:
$ $CC -v -Wl,-debug -fuse-ld=gold
...
Looking for 'real-ld'
Looking for 'collect-ld'
Looking for 'ld.gold'
...
collect2 version 12.2.0
ld_file_name = /usr/local/oecore-x86_64/sysroots/x86_64-oesdk-linux/usr/libexec/i686-oe-linux/gcc/i686-oe-linux/12.2.0/ld.gold
(From OE-Core rev: cf1bb16b7f9f81514feaf1e4ecffd9039387bb89)
Signed-off-by: Samuli Piippo <samuli.piippo@qt.io>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/gcc/gcc-target.inc')
0 files changed, 0 insertions, 0 deletions