depend-cleanup.sh: Handle stale libc++.so ldscripts.

libc++ was moved from /usr/lib to /lib, but the libc++.so linker
script is not regenerated when the value of SHLIB changes.

Reported by:	cy
This commit is contained in:
John Baldwin 2021-12-30 14:10:05 -08:00
parent b7b447fd4c
commit dda9847275

View File

@ -78,3 +78,10 @@ fi
clean_dep cddl/lib/libspl atomic S
# 20211207 cbdec8db18b5 switch to libthr-friendly pdfork
clean_dep lib/libc pdfork S
# 20211230 5e6a2d6eb220 libc++.so.1 path changed in ldscript
if [ -e "$OBJTOP"/lib/libc++/libc++.ld ] && \
fgrep -q "/usr/lib/libc++.so" "$OBJTOP"/lib/libc++/libc++.ld; then
echo "Removing old libc++ linker script"
rm -f "$OBJTOP"/lib/libc++/libc++.ld
fi