octave install Error: A BLAS library was detected but found incompatible with your Fortran 77 compiler settings
Asked Answered
W

2

3

I'm trying to install octave 3.8.1 on a cluster running Redhat+IBM LSF. I don't have write access to any directory except my home dir. I have loaded three modules 1) pcre 8.33 2) blas 08/2013 3) lapack 3.5.0. But when I run ./configure, I got the error "configure: error: A BLAS library was detected but found incompatible with your Fortran 77 compiler settings.", as the image below shows.

enter image description here

I have tried loading module gfortran64 and add F77=gfortran as command line parameter, but this doesn't work. Could you please help me with this problem? If you need any information please tell me in this webpage. Thank you.

Whinny answered 3/5, 2014 at 4:22 Comment(7)
I'm not a Fortran expert, but I remember compilers aren't ABI compatible. Do you know if your BLAS was compiled with gfortran? What GCC version?Crampton
The BLAS in the cluster is provided by the management team so I don't know how they compiled it. If I compile the BLAS by myself and use my own copy of BLAS to make octave 3.8.1, could you please show me steps of how to do it? Thanks a lot!Whinny
You can run the command ldd /path/to/libblas.so to see what compiler it was linked against. To find the library, you can type locate libblas.so.Crampton
Thank you. I tried to run locate libblas.so, but it returns nothing. I have already loaded blas by typing "module load blas/08_2013".Whinny
I'm not familiar with loading libraries as modules, but you can try module show blas/08_2013 to get more information on what shell environment variables are being set. Print the output here if possible.Crampton
Thank you juliohm. I have decided to build my own BLAS and LAPACK, but there is still an error in building them. I have submitted a new question for this: #23463740. Could you please take a look at it?Whinny
Just remember clusters often have an optimized build for these basic linear algebra libraries. Recompiling it yourself it not necessarily the best option.Crampton
S
2

I've had the same problem. On a fresh install of CentOS 6.3 I was able to compile octave 4.0.0 successfully.

After installing the necessary dependencies (notably blas, lapack and pcre) I created symlinks to liblapack and libblas in some directory, e.g.:

mkdir /some/path
cd /some/path
ln -s /usr/lib64/libblas.so.3 libblas.so
ln -s /usr/lib64/liblapack.so.3 liblapack.so

Then put the relevant directory in LDFLAGS, e.g., in bash/sh:

LDFLAGS=-L/some/path ./configure

So either octave's configure didn't look in /usr/lib64, or it requires the name of the libraries to end in ".so" (not ".so.3"). I haven't investigated which of the two was the problem since the above worked for me.

/some/path can be deleted when octave has been installed.

Steelworker answered 9/6, 2015 at 21:34 Comment(0)
G
1

My octave repository was compiling flawlessly, until the day I installed gfortran and started to get the same message. I had been using f77 (from the fort77 package). Somehow, the configure script defaulted to gfortran, which [I believe] is incompatible with the BLAS libraries.

I would suggest using f77 in octave compilation instead of gfortran.

I compiled octave 4.0.0 on Mint 17.1, but I believe the issue is the same.

Godwin answered 6/7, 2015 at 22:40 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.