so strange, is ls multi-threaded somehow? what could ls
possibly need libpthread for?
ldd /bin/ls
linux-vdso.so.1 (0x00007ffff7fce000)
libselinux.so.1 => /lib/x86_64-linux-gnu/libselinux.so.1 (0x00007ffff7f57000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007ffff7d65000)
libpcre2-8.so.0 => /usr/lib/x86_64-linux-gnu/libpcre2-8.so.0 (0x00007ffff7cd2000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007ffff7ccc000)
/lib64/ld-linux-x86-64.so.2 (0x00007ffff7fcf000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007ffff7ca9000)
It's not
ls
itself that depends onlibpthread
. Uselddtree
frompax-utils
(sudo apt install pax-utils
) to see the dependency tree:ldd
shows all shared libraries that the file links to, including indirect dependencies.