CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

/usr/bin/ld: cannot find -llagrangianTurbulence /usr/bin/ld: cannot find -lfluidTherm

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree3Likes
  • 1 Post By alexeym
  • 1 Post By floquation
  • 1 Post By floquation

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 13, 2015, 17:22
Default /usr/bin/ld: cannot find -llagrangianTurbulence /usr/bin/ld: cannot find -lfluidTherm
  #1
New Member
 
Luis
Join Date: Jan 2015
Posts: 2
Rep Power: 0
Luiggito is on a distinguished road
Hi,

When I try to compile my solver with wmake the next error appears:

/usr/bin/ld: cannot find -llagrangianTurbulence
/usr/bin/ld: cannot find -lfluidThermophysicalModels

Do somebody knows where can these libraries be found?

Thank you.
Luiggito is offline   Reply With Quote

Old   November 14, 2015, 10:06
Default
  #2
Senior Member
 
Alexey Matveichev
Join Date: Aug 2011
Location: Nancy, France
Posts: 1,930
Rep Power: 38
alexeym has a spectacular aura aboutalexeym has a spectacular aura about
Send a message via Skype™ to alexeym
Hi,

They should be in $FOAM_LIBBIN (the value depends on where OpenFOAM is installed, what compiler/OS you are using) folder.
Democritus likes this.
alexeym is offline   Reply With Quote

Old   March 30, 2016, 08:48
Default
  #3
New Member
 
Democritus's Avatar
 
Xiaoqiu HE
Join Date: Mar 2016
Location: Wuhan, China
Posts: 29
Rep Power: 10
Democritus is on a distinguished road
Hi~

Would you please tell me how to add this path to the system's default compile search path? I have a prompted error:
Quote:
/usr/bin/ld: cannot find -lfiniteVolume
/usr/bin/ld: cannot find -lmeshTools
It seems that the wmake do not search these libs in $FOAM_LIBBIN, so how to indicate the wmake to search libs in $FOAM_LIBBIN path?

Thank you!
Democritus is offline   Reply With Quote

Old   March 30, 2016, 09:18
Default
  #4
Senior Member
 
floquation's Avatar
 
Kevin van As
Join Date: Sep 2014
Location: TU Delft, The Netherlands
Posts: 252
Rep Power: 20
floquation will become famous soon enough
Quote:
Originally Posted by Democritus View Post
Would you please tell me how to add this path to the system's default compile search path?
(On Unix systems) The system variable "$LD_LIBRARY_PATH" is used for that.

Code:
LD_LIBRARY_PATH=$FOAM_LIBBIN:$LD_LIBRARY_PATH
This should however be done automatically if you source OpenFOAM's bashrc file, through the config/settings.sh script.
Democritus likes this.
floquation is offline   Reply With Quote

Old   March 30, 2016, 09:38
Default
  #5
New Member
 
Democritus's Avatar
 
Xiaoqiu HE
Join Date: Mar 2016
Location: Wuhan, China
Posts: 29
Rep Power: 10
Democritus is on a distinguished road
Thank you very much for your response!

I have checked the my ~/.bashrc , the last line was
Quote:
. /opt/openfoam30/etc/bashrc
Then I changed it to
Quote:
source /opt/openfoam30/etc/bashrc
But I have the same error. I will try to restart my PC then recheck this problem.
I will also update the situation.

Thank you very much for your help!
Democritus is offline   Reply With Quote

Old   March 30, 2016, 09:49
Default
  #6
New Member
 
Democritus's Avatar
 
Xiaoqiu HE
Join Date: Mar 2016
Location: Wuhan, China
Posts: 29
Rep Power: 10
Democritus is on a distinguished road
Quick Update~

I still have these prompted error
Quote:
/usr/bin/ld: cannot find -lfiniteVolume
/usr/bin/ld: cannot find -lmeshTools
collect2: error: ld returned 1 exit status
/opt/openfoam30/wmake/Makefile:147: recipe for target 'a.out' failed
make: *** [a.out] Error 1
Democritus is offline   Reply With Quote

Old   March 30, 2016, 10:12
Default
  #7
Senior Member
 
floquation's Avatar
 
Kevin van As
Join Date: Sep 2014
Location: TU Delft, The Netherlands
Posts: 252
Rep Power: 20
floquation will become famous soon enough
Firstly, what operating system are you using? As I must mention that my knowledge resides within Linux.

---
Can you post the output of the following command:
Code:
echo -e ${LD_LIBRARY_PATH//:/\\n} && echo "" && echo "$FOAM_LIBBIN"
This will print two environmental variables (in a nice format) to the terminal.
If correct, the very last line shown (i.e. $FOAM_LIBBIN) should be contained within the printed list (i.e. $LD_LIBRARY_PATH).

---
Also make sure that $FOAM_LIBBIN actually has the libraries you need. You can test this using:
Code:
find $FOAM_LIBBIN -iname "*finitevolume*"
find $FOAM_LIBBIN -iname "*meshtools*"
Does this give a result that looks something like?:
Quote:
/opt/.../lib/libfiniteVolume.so
(And similar for meshTools.)
Democritus likes this.
floquation is offline   Reply With Quote

Old   March 30, 2016, 21:28
Default
  #8
New Member
 
Democritus's Avatar
 
Xiaoqiu HE
Join Date: Mar 2016
Location: Wuhan, China
Posts: 29
Rep Power: 10
Democritus is on a distinguished road
Thank you very much! As a starter of Linux, your advice and thoughts about the problem shed light on the knowledge that I should learn~

The OS I am using is ubuntu 15.10; Basing on your suggestion, the first thing I check is the real path of my $FOAM_LIBBIN, I check it as following
Quote:
hxq@hxq-All-Series:~$ cd $FOAM_LIBBIN
hxq@hxq-All-Series:/opt/openfoam30/platforms/linux64GccDPInt32Opt/lib$

meaning: $FOAM_LIBBIN = /opt/openfoam30/platforms/linux64GccDPInt32Opt/lib
then I typed the first command and get following results:
Quote:
hxq@hxq-All-Series:~$ echo -e ${LD_LIBRARY_PATH//:/\\n} && echo "" && echo "$FOAM_LIBBIN"
/opt/ThirdParty-3.0.1/platforms/linux64Gcc/gperftools-svn/lib
/opt/paraviewopenfoam44/lib/paraview-4.4
/opt/openfoam30/platforms/linux64GccDPInt32Opt/lib/openmpi-system
/opt/ThirdParty-3.0.1/platforms/linux64GccDPInt32Opt/lib/openmpi-system
/usr/lib/openmpi/lib
/home/hxq/OpenFOAM/hxq-3.0.1/platforms/linux64GccDPInt32Opt/lib
/opt/site/3.0.1/platforms/linux64GccDPInt32Opt/lib
/opt/openfoam30/platforms/linux64GccDPInt32Opt/lib
/opt/ThirdParty-3.0.1/platforms/linux64GccDPInt32Opt/lib
/opt/openfoam30/platforms/linux64GccDPInt32Opt/lib/dummy

/opt/openfoam30/platforms/linux64GccDPInt32Opt/lib

I think that means the path is properly set.

Then I try to search the finiteVolume and meshTools lib in this path, I get:
Quote:
hxq@hxq-All-Series:~$ find $FOAM_LIBBIN -iname "*finitevolume*"
/opt/openfoam30/platforms/linux64GccDPInt32Opt/lib/libfiniteVolume.so
hxq@hxq-All-Series:~$ find $FOAM_LIBBIN -iname "*meshTools*"
/opt/openfoam30/platforms/linux64GccDPInt32Opt/lib/libmeshTools.so
The lib files are in the right path and the path is properly set!
I am really confused. Should I reinstall the OpenFOAM as the tricks of Windows?
Thank you!
Democritus is offline   Reply With Quote

Old   March 30, 2016, 21:56
Default
  #9
New Member
 
Democritus's Avatar
 
Xiaoqiu HE
Join Date: Mar 2016
Location: Wuhan, China
Posts: 29
Rep Power: 10
Democritus is on a distinguished road
Quick Update!

The problem is solved! I have made a very very stupid mistake!
In my project's Make/files, once it was like these
Quote:
helmholtzFoam_Hxq.C

EXE = .
Then I change it to
Quote:
helmholtzFoam_Hxq.C

EXE = ~/myCode/helmholtzFoam_Hxq/helmholtzFoam_Hxq
Then the compile process goes well!
Thank you floquation, for your precious time and advice on my problem!
Democritus is offline   Reply With Quote

Old   May 2, 2016, 00:54
Default /usr/bin/ld:
  #10
Member
 
Zhiheng Wang
Join Date: Mar 2016
Posts: 72
Rep Power: 10
Zhiheng Wang is on a distinguished road
Quote:
Originally Posted by Democritus View Post
Quick Update~

I still have these prompted error
Hi,
You can also modify your make file LIB as -I($LSRC)/finiteVolume/lnInclude \
some time LD_LIBRARY_PATH needs to be fixed every time.
Zhiheng Wang is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
OpenFoam171: error /usr/bin/ld: cannot find -llduSolvers Schipper OpenFOAM Programming & Development 9 August 26, 2020 05:31
OpenFOAM 1.6-ext git installation on Ubuntu 11.10 x64 Attesz OpenFOAM Installation 45 January 13, 2012 12:38
/usr/bin/ld: cannot find -lincompressibleRASModels (OF-1.7.x) kumar OpenFOAM Installation 6 March 17, 2011 02:29
Allwmake error: /usr/bin/ld: cannot find -lautoMesh ranas OpenFOAM Bugs 2 August 3, 2009 21:55
Errors running allwmake in OpenFOAM141dev with WM_COMPILE_OPTION%3ddebug unoder OpenFOAM Installation 11 January 30, 2008 20:30


All times are GMT -4. The time now is 04:56.