mirror of
https://git.FreeBSD.org/src.git
synced 2024-10-18 02:19:39 +00:00
rescue: Stop using LDADD_zstd
Ideally we'd be able to use LDADD_foo here for all our various libs and get the implicit dependencies, but rescue is a bit special. Historically this was just used to pick up the "private" in the name automatically (as far as I can tell), but now that _DP_pthread includes c we end up pulling in a -lc from this (along with -lcompiler_rt and -lsys). This results in -lc being before -lmd (and after, implictly, from the compiler driver), which, for the specific situation here, results in both libc.a's and libmd.a's md5c.o being included, giving duplicate definitions of _libmd_MD5Init and other symbols. With LLD 16+ we currently make that not an error for other reasons (which should probably be fixed), but not for older versions, nor for BFD, and so the build fails. Fix all this by just using -lprivatezstd in place of LDADD_zstd, which results in the exact same clang command line as we used to have prior to adding c (and sys) to _DP_pthread when linking rescue. Note that bsdbox already uses -lprivatezstd rather than LDADD_zstd. This reverts commit5fead429eb
. Reviewed by: imp Fixes:99ea675731
("lib{c,sys}: move auxargs more firmly into libsys")
This commit is contained in:
parent
d646dca3bc
commit
ff6b71c2b2
@ -216,7 +216,7 @@ CRUNCH_ALIAS_xz= unxz lzma unlzma xzcat lzcat
|
||||
|
||||
CRUNCH_PROGS_usr.bin+= zstd
|
||||
CRUNCH_ALIAS_zstd= unzstd zstdcat zstdmt
|
||||
CRUNCH_LIBS+= ${LDADD_zstd}
|
||||
CRUNCH_LIBS+= -lprivatezstd
|
||||
|
||||
CRUNCH_PROGS_usr.bin+= fetch
|
||||
CRUNCH_LIBS+= -lfetch
|
||||
|
Loading…
Reference in New Issue
Block a user