Buildowrld tries to use old ld, and fails
Ed Maste
emaste at freebsd.org
Tue Sep 25 13:03:14 UTC 2018
On 25 September 2018 at 02:55, <soralx at cydem.org> wrote:
>
>> The normal procedure shouldn't need any LD= overrides; is there
>> something unique in your build? Any src.conf settings?
>
> Indeed, I had "WITHOUT_LLD_BOOTSTRAP=yes" in src.conf. Not sure how
> that line made it into this file on a number of my systems... perhaps
> an artifact of old -CURRENT upgrade procedure that I've forgotten about.
Glad to hear it's resolved now.
> I was just following a note 20180510 from UPDATING. It worked before.
> And there are no newer entries overruling the old note, so I thought
> it should still work as before...
Ah, indeed. In addition to that note now being obsolete (and no
superseding note) there's another issue: the LD= suggestion applied
only to buildkernel (but perhaps was not sufficiently clear).
> Strange that overriding LD works when pointing to ld from binutils, but
> not always with ld.lld linker; for example, 'stand/i386/mbr/' ignores
> "LD=ld.lld", but not "LD=/usr/local/bin/ld".
This is a side effect of the linker feature detection. What's
happening here is that when lld is detected the build adds the
-no-rosegment flag, so when LD=ld.lld is in use the flag is added,
then the linker invoked from the compiler driver doesn't handle the
flag. When LD=/usr/local/bin/ld the flag is not added at all.
I will see about an update for UPDATING.
More information about the freebsd-current
mailing list