Page MenuHomeFreeBSD

rescue: Link libzutil after libzfs.
ClosedPublic

Authored by jhb on Sep 29 2022, 10:25 PM.
Tags
None
Referenced Files
F169094184: D36811.id111228.diff
Mon, Aug 31, 9:43 AM
F169084681: D36811.id111384.diff
Mon, Aug 31, 9:08 AM
F169055080: D36811.id.diff
Mon, Aug 31, 6:48 AM
F169054489: D36811.diff
Mon, Aug 31, 6:43 AM
Unknown Object (File)
Sat, Aug 22, 9:14 AM
Unknown Object (File)
Fri, Aug 21, 11:21 AM
Unknown Object (File)
Wed, Aug 19, 8:02 AM
Unknown Object (File)
Tue, Aug 18, 8:38 PM
Subscribers

Details

Summary

libzfs depends on symbols defined in libzutil. For static linking
ld.bfd is less forgiving than lld, so rescue was failing to link when
using ld.bfd due to unresolved symbols from libzutil used by libzfs.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jhb requested review of this revision.Sep 29 2022, 10:25 PM

I would argue that this is a bug in ld.lld.

This revision is now accepted and ready to land.Sep 30 2022, 12:27 AM

There is a note about this in ld.lld's man page under IMPLEMENTATION NOTES. There is a --warn-backrefs option documented there that we may want to investigate.

This revision was automatically updated to reflect the committed changes.