toon-members
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Toon-members] blas, lapack needing gfortran and MAIN__


From: Gerhard Reitmayr
Subject: Re: [Toon-members] blas, lapack needing gfortran and MAIN__
Date: Wed, 07 Jun 2006 12:27:19 +0100
User-agent: Mozilla Thunderbird 1.0.8 (X11/20060411)

I am seeing the same thing here on a SuSe 10.0 box. I think the
following solves the MAIN__ symbol problem:

mercator gr281: rpm -ql gcc-fortran
/usr/bin/gfortran
/usr/lib/gcc/i586-suse-linux/4.0.2/f951
/usr/lib/libgfortran.a
/usr/lib/libgfortran.la
/usr/lib/libgfortran.so
/usr/lib/libgfortran.so.0
/usr/lib/libgfortran.so.0.0.0
/usr/lib/libgfortranbegin.a
/usr/lib/libgfortranbegin.la
/usr/share/info/gfortran.info.gz
/usr/share/man/man1/gfortran.1.gz

mercator gr281: nm /usr/lib/libgfortranbegin.a

fmain.o:
         U _gfortran_set_args
00000000 T main
         U MAIN__

so we should test for libgfortranbegin.a as well and link against that
too, that should provide us with the missing MAIN__ symbol??

Gerhard

Paul Smith wrote:
> TooN  doesn't work out of the box on my new SuSe 10.1 system:
> 
> - f2c complains about not being able to find MAIN__ (both in the
> configure script for libcvd and, if that is commented out, when linking
> my program)
> - when blas tries to link, it complains about not being able to find
> _gfortran_st_write and some other _gfortran_st_* functions.
> 
> I've been able to fix this by also linking with -lgfortran and by defining
> 
> extern "C"
> {
>   void MAIN__() {}
> }
> 
> somewhere in my source code.
> 
> Has anyone else had similar problems, and done some fixes? It should be
> a simple matter to change the libcvd configure script (and my own one)
> to also check whether gfortran is needed or not, but the MAIN__ problem
> is a bit more difficult. Thoughts anyone?
> 
> (If it makes any difference, I'm using
> gcc 4.1.0-25
> blas 3.0-939
> lapack 3.0-939
> f2c 0.11-1067
> )
> 
> Cheers
> 
> Paul
> 
> 
> 
> 
> _______________________________________________
> Toon-members mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/toon-members


-- 
Gerhard Reitmayr
MIL, Engineering Department, Cambridge University
http://www.eng.cam.ac.uk/~gr281/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]