[Numpy-discussion] Building Numeric with a native blas ?
Chris Barker
Chris.Barker at noaa.gov
Thu Jul 29 15:01:07 CDT 2004
HI all,
I decided I want to try to get this working on my gentoo linux box. I
started by emerging the gentoo atlas package.
Now I've gone into the Numeric setup.py, and have gotten confused. These
seem to be the relevant lines (unchanged from how they came with Numeric
23.3):
# delete all but the first one in this list if using your own LAPACK/BLAS
sourcelist = [os.path.join('Src', 'lapack_litemodule.c'),
# os.path.join('Src', 'blas_lite.c'),
# os.path.join('Src', 'f2c_lite.c'),
# os.path.join('Src', 'zlapack_lite.c'),
# os.path.join('Src', 'dlapack_lite.c')
That's all well and good, except that they are all deleted except the
first one. And it looks like I don't want that one either.
]
# set these to use your own BLAS;
library_dirs_list = ['/usr/lib/atlas']
libraries_list = ['lapack', 'cblas', 'f77blas', 'atlas', 'g2c']
# if you also set `use_dotblas` (see below), you'll
need:
# ['lapack', 'cblas', 'f77blas', 'atlas', 'g2c']
This also seems to be set already.
I don't have a '/usr/lib/atlas', so I set:
library_dirs_list = []
All the libraries in libraries_list are in /usr/lib/
include_dirs = ['/usr/include/atlas'] # You may need to set this to
find cblas.h
cblas.h is in : /usr/include/, so I set this to:
include_dirs = []
Now everything compiled and installed just fine, but when I try to use
it, I get:
File "/usr/lib/python2.3/site-packages/Numeric/LinearAlgebra.py",
line 8, in ?
import lapack_lite
ImportError: dynamic module does not define init function (initlapack_lite)
SO I tried adding
sourcelist = [os.path.join('Src', 'lapack_litemodule.c')]
back in. Now I can build and install, but get:
Traceback (most recent call last):
File "./TestBlas.py", line 4, in ?
from LinearAlgebra import *
File "/usr/lib/python2.3/site-packages/Numeric/LinearAlgebra.py",
line 8, in ?
import lapack_lite
ImportError: /usr/lib/python2.3/site-packages/Numeric/lapack_lite.so:
undefined symbol: dgesdd_
Now I'm stuck.
-CHB
--
Christopher Barker, Ph.D.
Oceanographer
NOAA/OR&R/HAZMAT (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception
Chris.Barker at noaa.gov
More information about the Numpy-discussion
mailing list