LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-31-2014, 11:36 PM   #1
rdx
Member
 
Registered: Apr 2007
Location: Dallas
Distribution: Slackware64 14.2
Posts: 283

Rep: Reputation: 25
finding dynamic libraries


I compile some libraries and the dynamic libraries get put in /usr/local/lib When I try to run the program it fails saying it can't find the dynamic libs. How do I cure this please?

I'm guessing that setting the environment variable LD_LIBRARY_PATH might be helpful.

Last edited by rdx; 09-01-2014 at 12:16 AM. Reason: guessing
 
Old 09-01-2014, 01:53 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,771

Rep: Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302
yes, you need to put the location to your libs into LD_LIBRARY_PATH
http://tldp.org/HOWTO/Program-Librar...libraries.html
 
1 members found this post helpful.
Old 09-02-2014, 12:24 AM   #3
rdx
Member
 
Registered: Apr 2007
Location: Dallas
Distribution: Slackware64 14.2
Posts: 283

Original Poster
Rep: Reputation: 25
Hmm, another solution?

/sbin/ldconfig /usr/local/lib/libgsl.so.0
I think this is another way to achieve the same thing, except on a system wide basis.
 
Old 09-02-2014, 12:33 AM   #4
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,771

Rep: Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302Reputation: 7302
ldconfig will reconfigure your system, the changes will remain as long as you change it again (see the man page). LD_LIBRARY_PATH will only modify your current environment.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I ensure dynamic libraries are where they should be? jemenake Linux - Server 2 10-27-2011 01:28 AM
Thread limits in dynamic libraries as opposed to static libraries pmkenny1234 Linux - Software 0 04-26-2011 02:22 PM
Dynamic Libraries in Linux - C++ lodziarz Programming 5 03-24-2008 02:42 PM
Dynamic link libraries eshwar_ind Programming 1 05-09-2004 11:02 PM
linux dynamic libraries aizkorri Programming 4 10-09-2002 03:26 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:26 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration