Re: [PATCH 3/4] Makefile: lld: tell clang to use lld

From: Nathan Chancellor
Date: Fri Feb 08 2019 - 11:24:46 EST


On Fri, Feb 08, 2019 at 03:21:15PM +0100, Sedat Dilek wrote:
> Hi Nick,
>
> why don't you simply check for CONFIG_LD_IS_LLD existing (when [1] applied)?
>

Hi Sedat,

This section runs before Kconfig so we can't rely on the symbols it
generates. See commit 995167420797 ("kbuild: remove cc-name variable")
for Masahiro's explanation.

> If you want a specific version of ld.lld (you mentioned kernel module
> linking failure was fixed recently) why not transfer this into a
> scripts/lld-version.sh file?
>

We'll probably need that eventually but given that lld isn't ready for
widespread use, I don't think it's necessary.

> Greetings,
> - Sedat -
>
> [1] https://lore.kernel.org/patchwork/patch/1039719/ ("[1/4]
> init/Kconfig: add config support for detecting linker")

Nathan