From: Leif Lindholm <leif.lindholm@linaro.org>
To: edk2-devel@lists.01.org
Subject: CLANG cross-compilation issue
Date: Wed, 7 Sep 2016 16:27:01 +0100 [thread overview]
Message-ID: <20160907152701.GG16080@bivouac.eciton.net> (raw)
Hi all,
This is a report for the archive, rather than anything easily fixable.
While testing one of Ard's sets against CLANG, I tripped over a
behaviour exposed by commit a1b8baccc30b
(BaseTools GCC: use 'gcc' as the linker command for GCC44 and later).
This commit changes the CLANG profiles to invoke the linker via the
'clang' command, rather than as previously directly calling ld (with
appropriate cross toolchain prefix where needed).
Turns out clang, at least the one packaged in Debian 'Jessie', does
not scan the PATH when looking for cross-variants of GNU ld, but
rather goes and looks for it in some commonly used locations. Failing
to find any, it then falls back to the system-provided ld.
The symptom is a failed link step with the message:
/usr/bin/ld: unrecognised emulation mode: aarch64linux
As a workaround, I was able to get my build functional again by
creating a symbolic link /usr/bin/aarch64-linux-gnueabi-ld pointing at
the actual location of my cross-ld.
/
Leif
next reply other threads:[~2016-09-07 15:27 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-07 15:27 Leif Lindholm [this message]
2016-09-07 15:34 ` CLANG cross-compilation issue Andrew Fish
2016-09-15 9:49 ` Leif Lindholm
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160907152701.GG16080@bivouac.eciton.net \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox