Date: Tue, 23 Oct 2018 14:03:21 +0200 From: Stefan Esser <se@freebsd.org> To: "Julian H. Stacey" <jhs@berklix.com> Cc: FreeBSD Current <freebsd-current@freebsd.org> Subject: Re: careless commits disrupt Message-ID: <3736ed03-e849-fb14-daac-2653d86f6202@freebsd.org> In-Reply-To: <201810222109.w9ML96bF050497@fire.js.berklix.net> References: <201810222109.w9ML96bF050497@fire.js.berklix.net>
next in thread | previous in thread | raw e-mail | index | archive | help
Am 22.10.18 um 23:09 schrieb Julian H. Stacey:
> Hi, Reference:
>> From: Stefan Esser <se@freebsd.org>
>> Date: Fri, 12 Oct 2018 11:44:59 +0200
>
> Stefan Esser wrote:
>> I might have mentioned, that I always preserve old shared libraries in
>> /usr/lib/compat before running "make delete-old-libs".
>
> Good idea, are you doing that manually, or do you have a patch to share ?
I do it manually, but I have a script that checks for programs in the
base system and packages that use any library moved to the lib/compat
directory - see below.
The base system checks should never give any output (unless there are
old and obsolete binaries).
I use the package list to identify packages that must be rebuilt to
make the compat libraries obsolete. Since there may be shared library
version conflicts, if some
Regards, STefan
------------------------------------------------------------
#!/bin/sh
find_compat_depend () {
local dir="$1"
local pattern="$2"
find "$dir" -type f ${pattern:+-name "$pattern"} \
-exec sh -c "ldd {} 2>/dev/null | grep -lq /compat/ && echo {}" \;
}
echo "Base system programs referencing compat libraries:"
find_compat_depend /bin ""
find_compat_depend /sbin ""
find_compat_depend /libexec ""
#find_compat_depend /lib "lib*.so.*"
find_compat_depend /usr/bin ""
find_compat_depend /usr/sbin ""
find_compat_depend /usr/libexec ""
#find_compat_depend /usr/lib "lib*.so.*"
echo
echo "Installed packages referencing compat libraries:"
{
find_compat_depend /usr/local/bin ""
find_compat_depend /usr/local/sbin ""
find_compat_depend /usr/local/libexec ""
find_compat_depend /usr/local/lib "lib*.so.*"
} | xargs pkg which -q | sort -u
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3736ed03-e849-fb14-daac-2653d86f6202>
