Questions tagged [ldd]

ldd is a unix command-line tool to print shared library dependencies for an executable or shared library.

If a program is dynamically linked, i.e. uses shared libraries, the program requires some number of external libraries in order to run. ldd is a tool to list the required libraries and shows if those libraries can be found in the current configuration.

Questions about using and understanding ldd output should use this tag.

From a unix command-line running

man ldd

will provide more information.

254 questions
0
votes
1 answer

Is there a Windows equivalent for the UNIX ldd command?

I have a list of DLLs and I would like to know the versions of all other DLLs, used by those files. In UNIX this is very simple: ldd *.dll But in Windows this does not work (I tried using my Ubuntu WSL). Does anybody know a commandline command for…
Dominique
  • 16,450
  • 15
  • 56
  • 112
0
votes
1 answer

Extremely basic question about how shared objects are found and loaded

I have a shared object library (well, technically a MATLAB mexfile) that links against other shared object libraries. When I run ldd on it, I see this: [spocops@draco libs]$ ldd render_prf_collection.mexa64 linux-vdso.so.1…
quarkpt
  • 119
  • 6
0
votes
1 answer

Why does ldd fail to find libstdc++ in /usr/local/lib64 without LD_LIBRARY_PATH?

I would like to run a program compiled with gcc-11 on a raspberry pi 4b without having to specify LD_LIBRARY_PATH or having to link with the library path. At the moment, if I have to specity the path to the new libstdc++ in LD_LIBRARY_PATH,…
Come Raczy
  • 1,590
  • 17
  • 26
0
votes
0 answers

GNU autotool shared lib dependencies Build OK but runtime symbol lookup ERROR

I have a funny error, please help me! I have a main.c, liba.so, libb.so. liba.so has a public function func_a(), and libb.so has public function func_b(). main.c call func_a() and func_a() calls func_b() inside: main.c: main() { bla_bla(); …
drymon
  • 113
  • 1
  • 6
0
votes
2 answers

Formats Error (could not find ldd binary)!

I'm using CentOS5 and trying to install a script that requires ldd. I've tried: yum install gcc glibc glibc-common yum update gcc glibc glibc-common Yum reinstall yum gcc glibc glibc-common The first two say it's already installed, the latter…
Ben Moore
  • 1
  • 1
0
votes
1 answer

ldd does not show the dependency which make then needs

I have the program which needs v2xmvtest.so. When i try to build it via make i get undefined reference to * Seems like that function from libssl1.0. (If i install it, it's built fine) But i do not see the place where these function are used. More…
Fyria
  • 1
0
votes
1 answer

Extract filepaths and copy to pwd

How do can extract the path of *.so files and copy them to pwd? I think they can be extracted by regex (between => and (), but do not know how. linux-vdso.so.1 (0x00007ffdd63c7000) libcurl.so.4 (0x00007f5462ffd000) libjansson.so.4…
wsdzbm
  • 3,096
  • 3
  • 25
  • 28
0
votes
1 answer

can we pass a shared library that one of our target's dependency needs at run time?

A.so is provided by a third party B.so depends on A.so, but in the makefile, B.so is not linked to A.so (not dynamically nor statically). C is a test executable for the B library. In the makefile, C is dynamically linked to B and A. ldd B.so NO…
hamaney
  • 454
  • 7
  • 16
0
votes
2 answers

How do I can print shared dependencies of ios app in Linux

I want to print shared object dependencies of ios app in linux script for crash parsing. But I am getting following error while executing commands. 1) ldd ./demoApp.app not a regular file 2) ldd ./demoApp.ipa not a dynamic executable 3) ldd…
Bhupesh Kumar
  • 369
  • 2
  • 18
0
votes
1 answer

Resolving dynamic library locations on Mac OS Catalina

I'm trying to understand the process by which Mac OS Catalina determines the locations of dynamic libraries and resolves name conflicts at runtime. The information on this…
quarkpt
  • 119
  • 6
0
votes
0 answers

ldd & shared object error Linux - how to troubleshoot?

I'd like to learn how to troubleshoot the following error: ERROR: could not load library "/usr/pgsql-11/lib/postgis-3.so": /lib64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by /usr/local/lib/libproj.so.15) Related: $ ldd…
Dan
  • 931
  • 2
  • 18
  • 31
0
votes
1 answer

libmicrohttpd: undefined reference to `pthread_setname_np@GLIBC_2.12' when linking

I am using libmicrohttpd 0.9.53 in my project and decided to update it to the latest version (0.9.71). I am cross-compiling for ARM and this is the output of arm-linux-gcc --version: arm-linux-gcc (4.4.4_09.06.2010) 4.4.4 Copyright (C) 2010 Free…
godo
  • 195
  • 1
  • 11
0
votes
1 answer

ldd shows libm.so.6 but still linking with -lm is needed

I built a library and ldd shows that it references libm.so.6: ldd liba.so ... libm.so.6 => /lib64/libm.so.6 (0x00007fdf53e85000) ... But when I compile my program I get: $ gcc mytest.c -I/path/to/a/header…
JenyaKh
  • 2,040
  • 17
  • 25
0
votes
0 answers

Cannot find shared object in LD_LIBRARY_PATH ( Amazon Linux )

I have a python runtime on aws lambda. As there known issue that ghostscript is broken on aws lambda ami ( in my case its amazon linux because of python 3.7 ). So i collected whatever so's that are missing on ami and grouped it with package. The…
0
votes
1 answer

API for ldd (or objdump)?

I need to programmatically inspect the library dependencies of a given executable. Is there a better way than running the ldd (or objdump) commands and parsing their output? Is there an API available which gives the same results as ldd ?
Saurabh Nanda
  • 6,373
  • 5
  • 31
  • 60