"libcap_fileargs.so.1" not found

From: Frank Leonhardt <freebsd-doc_at_fjl.co.uk>
Date: Wed, 24 Jan 2024 12:20:31 UTC
This may have a simple fix, but it involves binary packages and these 
aren't my thing...

This is a plain machine I keep as a reference for the latest version of 
FreeBSD. In December I tried to "upgrade" it 14, but the result didn't 
work out so I reverted to 13.2. All seemed okay.

Except "wc" now barfs with 'ld-elf.so.1: Shared object 
"libcap_fileargs.so.1" not found, required by "wc"'

libcap_fileargs.so.1 is present and correct, as far as I can tell:

-r--r--r--  1 root  wheel  12684 Dec  8 17:23 
/usr/lib32/libcap_fileargs.so.1
-r-xr-xr-x  1 root  wheel  13744 Dec  8 17:23 /usr/bin/wc.broken

Other files  in /usr/bin have the same timestamp but those I've tried 
seem to work just fine.

To get me moving I've simply recompiled wc.c, but I'd like to know 
what's going on here. Did the rolled-back upgrade to 14 not roll back 
fully, and what's the "official" solution?

Thanks, Frank.