On Fri, 15 Jun 2007 17:03:12 +0000 (UTC)
Charlie Yanaitis <charles.yanaitis@rochester.edu> wrote:
> Karl Edler <kte608 <at> mail.usask.ca> writes:
>>>> Now the build fails with something about -fPIC which I
>>don't understand.
>> Here is the last bit of the output from "python setup.py
>>build" (notice
>> : relocation R_X86_64_PC32 against `atl_f77wrap_dscal__'
>>can not be used
>> when making a shared object; recompile with -fPIC):
>> Karl, I posted yesterday and ran into the same problem
>with Redhat, the
> "recompile with -fPIC". I did recompile the Atlas
>libraries with -fPIC but scipy
> doesn't seem to pick up on it. I'm eager for a solution
>to this problem and will
> be watching this thread. If I find out anything more,
>I'll let you know.
>> Have a good weekend!
>>>> _______________________________________________
> SciPy-user mailing list
>SciPy-user@scipy.org>http://projects.scipy.org/mailman/listinfo/scipy-user
This is what you can find in INSTALL.txt
of atlas3.7.33.tar.bz2
ATLAS natively builds to a static library (i.e. libs that
usually end in
".a" under unix and ".lib" under windows). ATLAS always
builds such a library,
but it can also optionally be requested to build a
dynamic/shared library
(typically ending in .so for unix or .dll windows). In
order to do so, you
must tell ATLAS up front to compile with the proper flags
(the same is
true when building netlib's LAPACK, see the LAPACK note
below). Assuming
you are using the gnu C and Fortran compilers, you can add
the following
commands to your configure command:
-Fa alg -fPIC
to force ATLAS to be built using position independent code
(required for a
dynamic lib). If you use non-gnu compilers, you'll need
to use -Fa to
pass the correct flag(s) to append to force position
independent code for
each compiler (don't forget the gcc compiler used in the
index files).
NOTE: Since gcc uses one less int register when compiling
with this flag, this
could potentially impact performance of the
architectural defaults,
but we have not seen it so far.
After you build is complete, you can cd to the OBJdir/lib
directory, and
ask ATLAS to build the .so you want. If you want all
libraries, including
the Fortran77 routines, the target choices are :
shared : Create shared versions of ATLAS's
sequential libs
ptshared : Create shared versions of ATLAS's threaded
libs
If you want only the C routines (eg. you don't have a
fortran compiler):
cshared : Create shared versions of ATLAS's
sequential libs
cptshared : Create shared versions of ATLAS's threaded
libs
Nils