LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 01-19-2009, 01:58 PM   #1
Gamma_User
LQ Newbie
 
Registered: Jan 2009
Location: Brazil, Curitiba
Distribution: Debian
Posts: 18

Rep: Reputation: 0
Question Linking libraries.


I have a directory with a lot of object fortran 90 files (a library directory). I would like to link them to others files in others directories using just one compiler option, e.g.

gfortran -[command to link] main.f90 -o main.x

Does anybody know the answer?
 
Old 01-19-2009, 05:24 PM   #2
chutsu
Member
 
Registered: Nov 2003
Location: UK
Distribution: Debian Lenny
Posts: 255

Rep: Reputation: 31
I think this website could give you part of the answer.
http://linuxmafia.com/faq/Admin/ld-lib-path.html

Note: It does mention that the solution is harmful, but sometimes you got to do it in order to make things work right?

Anyways I THINK to solve your problem you would have to do this:
$ export LD_LIBRARY_PATH="path_to_where_your_files_are"

But I'm not too sure, I had a similar problem and this solved it.
 
  


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
Linking to Shared Libraries with g++ random0 Programming 1 06-15-2006 10:12 PM
linking X11 libraries samqazi1 Linux - Software 2 01-04-2006 01:14 AM
Linking old libraries to new one? winterhunter Linux - Software 7 10-24-2005 04:37 AM
Linking program with .a libraries rudy2 Programming 2 04-22-2005 05:36 AM
Shared libraries and linking., devin Programming 3 04-08-2003 03:18 PM


All times are GMT -5. The time now is 07:14 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration