3

i am trying to link lapack and a simple

locate lapack

returns

/usr/lib64/liblapack.so.3
/usr/lib64/liblapack.so.3.2.1

so in am trying to link it with

gfortran -o linreg driver.f90 LFsubroutines.f90 -L/usr/lib64 -llapack -fimplicit-none

but i get the following error:

/usr/lib64/gcc/x86_64-suse-linux/4.5/../../../../x86_64-suse-linux/bin/ld: cannot find -llapack

what is the problem here?

drjrm3
  • 4,474
  • 10
  • 53
  • 91

2 Answers2

3

You don't have the liblapack.so or liblapack.a file there (maybe you didn't install dev(el) package). You may try specifying the complete path instead

gfortran -o linreg driver.f90 LFsubroutines.f90 /usr/lib64/liblapack.so.3 -fimplicit-none
Michael Krelin - hacker
  • 138,757
  • 24
  • 193
  • 173
1

Try installing the following packages if you don't have the devel packages installed already on your system.

sudo yum install libgfortran libf2c blas lapack

Give that a shot...

animuson
  • 53,861
  • 28
  • 137
  • 147
Vasili
  • 11
  • 1