This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: problem after compiling with g++


On 1970-01-01, Stephen Schweizer wrote:

> ./a.out: error while loading shared libraries:
> libstdc++.so.5: cannot open shared object file: No
> such file or directory
> 
> I do, however, have this library since I just compiled
> gcc 3.2 from the source.  It is located in /usr/lib
> and /usr/local/lib.  Can someone tell me how to fix
> this?

Symptom: a.out needs some dll and claims that it can't find
it.  (try ldd a.out, *very* usefull command)

Solution:

Step 1:
Make sure the dll exists
(verify with the famous ls -l command :-)

Step 2:
Make sure your executable (a.out) is looking at the right
places. (By default often only /lib and /usr/lib are looked
for.) Either change your LD_LIBRARY_PATH, or edit
/etc/ld.so.conf (if you know what you're doing). For details
about both options see man ld.so

Hope this helps.
(It has nothing to do with GCC by the way.)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]