[SciPy-user] blas/lapack issue on a freebsd box...

Robert Kern robert.kern at gmail.com
Wed Dec 6 14:26:21 EST 2006


fred wrote:
>> This is part of your problem. Do you have a site.cfg file? If so, please
>> post it.
>>
>>   
> Ok. I have this one, in 
> /usr/local/lib/python2.4/site-packages/numpy/distutils:
> 
> [atlas]
> library_dirs = /usr/lib/atlas/3dnow/
> atlas_libs = lapack, blas
> 
> Looks wrong, no ?

Quite wrong. You should remove it.

Also, put your site.cfg files next to the setup.py files for the package you are
building. numpy.distutils will find it if it's in that location, but that's a
bad place for it.

>> You ought to have sections that look like these:
>>
>>
>> [DEFAULT]
>> library_dirs=/usr/local/lib
>> include_dirs=/usr/local/include
>>
>> [blas_opt]
>> libraries=f77blas, cblas, atlas
>>
>> [lapack_opt]
>> libraries=lapack, f77blas, cblas, atlas
>>
>>   
> I have deleted the lines above, and put yours.
> But nothing changes :-(

Something should have changed. Maybe you don't get a successful compile, but the
output of "python setup.py config" should be different.

>> Possibly, you might also need to add g2c to the end of the libraries= lines.
>>
> Hmm, I have no g2c on my freebsd box.

What FORTRAN compiler are you using? What FORTRAN compiler did you configure
ATLAS with?

>> Now, those libraries lists are from what I normally see installed from
>> ATLAS.
>> Given that I've never seen libalapack_r.so.1 before, it's possible that
>> ATLAS
>> gets build strangely on your machine. Please also give us a list of the
>> libraries that ATLAS installs. Also tell us where you got
>> /usr/local/lib/liblapack.so and /usr/local/lib/libblas.so .
>>   
> Information for atlas-devel-3.7.11:
> 
> Files:
> /usr/local/include/cblas.h
> /usr/local/include/clapack.h
> /usr/local/include/blas.h
> /usr/local/include/lapack.h
> /usr/local/lib/libalapack.a
> /usr/local/lib/libalapack.so.1
> /usr/local/lib/libalapack.so
> /usr/local/lib/libalapack_r.a
> /usr/local/lib/libalapack_r.so.1
> /usr/local/lib/libalapack_r.so
> /usr/local/lib/libatlas.a
> /usr/local/lib/libatlas.so.1
> /usr/local/lib/libatlas.so
> /usr/local/lib/libatlas_r.a
> /usr/local/lib/libatlas_r.so.1
> /usr/local/lib/libatlas_r.so
> /usr/local/lib/libcblas.a
> /usr/local/lib/libcblas.so.1
> /usr/local/lib/libcblas.so
> /usr/local/lib/libcblas_r.a
> /usr/local/lib/libcblas_r.so.1
> /usr/local/lib/libcblas_r.so
> /usr/local/lib/libf77blas.a
> /usr/local/lib/libf77blas.so.1
> /usr/local/lib/libf77blas.so
> /usr/local/lib/libf77blas_r.a
> /usr/local/lib/libf77blas_r.so.1
> /usr/local/lib/libf77blas_r.so
> /usr/local/lib/libptcblas.a
> /usr/local/lib/libptcblas.so.1
> /usr/local/lib/libptcblas.so
> /usr/local/lib/libptf77blas.a
> /usr/local/lib/libptf77blas.so.1
> /usr/local/lib/libptf77blas.so
> /usr/local/lib/libtstatlas.a
> /usr/local/lib/libtstatlas.so.1
> /usr/local/lib/libtstatlas.so
> /usr/local/lib/libtstatlas_r.a
> /usr/local/lib/libtstatlas_r.so.1
> /usr/local/lib/libtstatlas_r.so
> /usr/local/share/doc/atlas/AtlasCredits.txt
> /usr/local/share/doc/atlas/ChangeLog
> /usr/local/share/doc/atlas/DirStruct.txt
> /usr/local/share/doc/atlas/INDEX.txt
> /usr/local/share/doc/atlas/LibReadme.txt
> /usr/local/share/doc/atlas/TestTime.txt
> /usr/local/share/doc/atlas/TroubleShoot.txt
> /usr/local/share/doc/atlas/Windows.txt
> /usr/local/share/doc/atlas/atlas_contrib.ps
> /usr/local/share/doc/atlas/atlas_devel.ps
> /usr/local/share/doc/atlas/atlas_over.ps
> /usr/local/share/doc/atlas/cblas.ps
> /usr/local/share/doc/atlas/cblasqref.ps
> /usr/local/share/doc/atlas/f77blasqref.ps
> /usr/local/share/doc/atlas/lapackqref.ps
> 
> I got liblapack.so from lapack-3.0_1 and libblas.so from blas-1.0 binary 
> packages.

Okay, try these sections:


[DEFAULT]
library_dirs=/usr/local/lib
include_dirs=/usr/local/include

[blas_opt]
libraries=f77blas, cblas, atlas

[lapack_opt]
libraries=alapack, f77blas, cblas, atlas


> Thanks in advance.
> 
> 
> PS : building scipy-0.5.1 requires that atlas be built with static libs.

Says who? (It's possibly true, I don't know, but I'd like to know where you are
getting this information from.)

If that's the case, then add


[DEFAULT]
search_static_first = true


> PS2 : thanks to added me to the EditorsList ;-)

No problem.

-- 
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless enigma
 that is made terrible by our own mad attempt to interpret it as though it had
 an underlying truth."
  -- Umberto Eco



More information about the SciPy-User mailing list