Starting from glibc 2.34, libc.so.6 is a regular file instead of a symlink. Also all the symbols from its small libraries like libpthread, librt etc., are now moved into libc.so.6.
This leads to two issues:
- The default comparison by name doesn't work anymore for libc.so.6
- Counting symbols or symbol-versions for the small libraries of glibc is not going to work.
For this reason, if we are capturing a small library of glibc, we first try libc.so.6, using the comparison by name, versions and symbols. After that we will take the requested library from the same place where we also took libc.so.6.