[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: CVS Build problem (what.m missing?)
From: |
Fredrik Lingvall |
Subject: |
Re: CVS Build problem (what.m missing?) |
Date: |
Fri, 26 Oct 2007 09:38:56 +0200 |
User-agent: |
Thunderbird 2.0.0.6 (X11/20070807) |
John W. Eaton wrote:
> On 25-Oct-2007, Fredrik Lingvall wrote:
>
> | So the fortran test file seems OK but ./conftest don't print anything
> | (it should be 'succeeded'
> | or 'failed', right?). Too verify that there is no problem with the BLAS
> | lib I did this in matlab,
> |
> | >> zx = 1:10 + i*zeros(1,10);
> | >> zy = zeros(1,10) + i*(1:10);
> | >> zy*zx'
> |
> | ans =
> |
> | 0 + 3.8500e+02i
> |
> | >>
> |
> |
> | which uses the same BLAS and LAPACK libs, which is set by these exports:
> |
> | export BLAS_VERSION=/usr/local/lib/libBLAS.so
> | export LAPACK_VERSION=/usr/local/lib/libLAPACK.so
> | export LAPACK_VERBOSITY=1
> | export MATLAB_MEM_MGR=system
>
> So it works with Matlab. This doesn't verify that your lapack library
> is compiled such that it uses the same calling convention for
> functions returning complex values that is used by gfortran. What
> happens if you take the program that configure is trying to compile,
> save it in foo.f, and run
>
> gfortran foo.f -L/usr/local/lib -lBLAS -lLAPACK
> ./a.out
>
> What does that print?
fllap4 octave # gfortran foo.f -L/usr/local/lib -lBLAS -lLAPACK
fllap4 octave # ./a.out
succeeded
> If that succeeds, then I think you need to look
> at config.log to see precisely how the test program is being compiled
> and why it fails.
>
The relevant part of config.log:
configure:11923: $? = 0
configure:11950: result: yes
configure:11954: result: adding -mieee-fp to FFLAGS
configure:12189: defining FFLAGS to be -O3 -pipe -mtune=pentium-m
-march=pentium-m -mfpmath=sse -msse2 -fomit-frame-pointer -funroll-loops
-fprefetch-loop-arrays -pthread -mieee-fp
configure:12224: checking whether gfortran accepts -ffloat-store
configure:12248: gfortran -o conftest -O3 -pipe -mtune=pentium-m
-march=pentium-m -mfpmath=sse -msse2 -fomit-frame-pointer -funroll-loops
-fprefetch-loop-arrays -pthread -mieee-fp -ffloat-store conftest.f -lz
-lm >&5
configure:12254: $? = 0
configure:12281: result: yes
configure:12284: result: setting F77_FLOAT_STORE_FLAG to -ffloat-store
configure:12372: checking for sgemm_ in /usr/local/lib/libBLAS.so
configure:12410: gcc -o conftest -O3 -pipe -mtune=pentium-m
-march=pentium-m -mfpmath=sse -msse2 -fomit-frame-pointer -funroll-loops
-fprefetch-loop-arrays -pthread conftest.c /usr/local/lib/libBLAS.so
-lz -lm -L/usr/lib/gcc/i686-pc-linux-gnu/4.1.2
-L/usr/lib/gcc/i686-pc-linux-gnu/4.1.2/../../../../i686-pc-linux-gnu/lib
-L/usr/lib/gcc/i686-pc-linux-gnu/4.1.2/../../.. -lz -lgfortranbegin
-lgfortran -lm -lpthread >&5
configure:12416: $? = 0
configure:12432: result: yes
configure:13828: checking for cheev_ in /usr/local/lib/libLAPACK.so
configure:13866: gcc -o conftest -O3 -pipe -mtune=pentium-m
-march=pentium-m -mfpmath=sse -msse2 -fomit-frame-pointer -funroll-loops
-fprefetch-loop-arrays -pthread conftest.c /usr/local/lib/libLAPACK.so
/usr/local/lib/libBLAS.so -lz -lm
-L/usr/lib/gcc/i686-pc-linux-gnu/4.1.2
-L/usr/lib/gcc/i686-pc-linux-gnu/4.1.2/../../../../i686-pc-linux-gnu/lib
-L/usr/lib/gcc/i686-pc-linux-gnu/4.1.2/../../.. -lz -lgfortranbegin
-lgfortran -lm -lpthread >&5
configure:13872: $? = 0
configure:13888: result: yes
configure:14095: checking BLAS library calling convention compatibility
configure:14138: result: no
configure:14140: WARNING: Your BLAS library was apparently compiled with
a Fortran
configure:14142: WARNING: compiler that uses a different calling
convention from
configure:14144: WARNING: the one used by the selected compiler, gfortran.
configure:14146: error: You must correct this problem before building
Octave.
I had some initial problems compiling the foo.f. It seems that gfortran
i picky regarding white space.
Compiling:
program foo
double complex zdotu, zx(10), zy(10), retval
integer n, incx, incy
n = 10
incx = 1
incy = 1
do 10 i = 1, n
zx(i) = dcmplx (i, 0)
zy(i) = dcmplx (0, i)
10 continue
retval = zdotu (n, zx, incx, zy, incy)
if (retval .eq. dcmplx (0, 385)) then
print *, 'succeeded'
else
print *, 'failed'
print *, retval
endif
end
gives the error,
fllap4 octave # gfortran foo.f -L/usr/local/lib -lBLAS -lLAPACK
In file foo.f:1
program foo
1
Error: Non-numeric character in statement label at (1)
In file foo.f:1
program foo
1
Error: Unclassifiable statement at (1)
but
program foo
double complex zdotu, zx(10), zy(10), retval
integer n, incx, incy
n = 10
incx = 1
incy = 1
do 10 i = 1, n
zx(i) = dcmplx (i, 0)
zy(i) = dcmplx (0, i)
10 continue
retval = zdotu (n, zx, incx, zy, incy)
if (retval .eq. dcmplx (0, 385)) then
print *, 'succeeded'
else
print *, 'failed'
print *, retval
endif
end
compiles without problems. Could this be the reason for the conftest
problem (I'm not very familiar
with how the autoconf stuff works).
/Fredrik
- Re: CVS Build problem (what.m missing?), (continued)
- Re: CVS Build problem (what.m missing?), David Bateman, 2007/10/23
- Re: CVS Build problem (what.m missing?), Fredrik Lingvall, 2007/10/23
- Re: CVS Build problem (what.m missing?), David Bateman, 2007/10/23
- Re: CVS Build problem (what.m missing?), Fredrik Lingvall, 2007/10/23
- Re: CVS Build problem (what.m missing?), John W. Eaton, 2007/10/23
- Re: CVS Build problem (what.m missing?), Fredrik Lingvall, 2007/10/23
- Re: CVS Build problem (what.m missing?), John W. Eaton, 2007/10/23
- Re: CVS Build problem (what.m missing?), Fredrik Lingvall, 2007/10/25
- Re: CVS Build problem (what.m missing?), Fredrik Lingvall, 2007/10/25
- Re: CVS Build problem (what.m missing?), John W. Eaton, 2007/10/25
- Re: CVS Build problem (what.m missing?),
Fredrik Lingvall <=
- Re: CVS Build problem (what.m missing?), John W. Eaton, 2007/10/26
- Re: CVS Build problem (what.m missing?), Fredrik Lingvall, 2007/10/31
- Re: CVS Build problem (what.m missing?), John W. Eaton, 2007/10/31
- Re: CVS Build problem (what.m missing?), Fredrik Lingvall, 2007/10/31
- Re: CVS Build problem (what.m missing?), John Swensen, 2007/10/31
- Re: CVS Build problem (what.m missing?), John W. Eaton, 2007/10/31
- Re: CVS Build problem (what.m missing?), Fredrik Lingvall, 2007/10/31
- Re: CVS Build problem (what.m missing?), John W. Eaton, 2007/10/31
- Re: CVS Build problem (what.m missing?), John Swensen, 2007/10/31
- Re: CVS Build problem (what.m missing?), John W. Eaton, 2007/10/31