Safer way to find binaries linked against lib instead of ldd