[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: libtool--release--2.0 test results
From: |
Ralf Wildenhues |
Subject: |
Re: libtool--release--2.0 test results |
Date: |
Mon, 11 Oct 2004 18:35:59 +0200 |
User-agent: |
Mutt/1.4.1i |
* Ralf Wildenhues wrote on Mon, Oct 11, 2004 at 03:19:51PM CEST:
> * Peter O'Gorman wrote on Mon, Oct 11, 2004 at 02:47:04PM CEST:
> > Ralf Wildenhues wrote:
> >
> > >Furthermore, f77demo-make fails for the non-static configurations with a
> > >./.libs/libmix.so: undefined reference to `MAIN__'
> > >while trying to link cprogram. I'm not sure how to fix this, not being a
> > >Fortran expert.
*snip*
> > Anyway whatever object/library contains MAIN__ should have been in FLIBS,
> > and we rely on autoconf to figure out FLIBS.
To add to this: I confirmed that it is the libtool-created shared
libraries that require a function `MAIN__', not the libraries the
compiler adds to the link line. ifort adds a compiler-provided
object `for_main.o' to the link line creating the shared libary.
By creating the shared libraries with the linker flag `-nofor_main',
it is possible to eliminate the need for `MAIN__' (without the patch
I posted earlier). This currently does not work with libtool, as it
deletes that argument from the link line.
Quoting compiler docs:
| -nofor_main
| Default: Off
|
| Specifies that the main program is not written in Fortran. For
| example, if the main program is written in C and calls an Intel
| Fortran subprogram, specify -nofor_main when compiling the program
| with the ifort command. Specifying -nofor_main prevents linking
| for_main.o into programs. This is a link-time switch. If you omit
| -nofor_main, the main program must be a Fortran program.
Where should this be put?
Regards,
Ralf
- Re: libtool--release--2.0 test results, (continued)
Re: libtool--release--2.0 test results, Bob Friesenhahn, 2004/10/06
Re: libtool--release--2.0 test results, Noah Misch, 2004/10/07
Re: libtool--release--2.0 test results, Ralf Wildenhues, 2004/10/11
- Re: libtool--release--2.0 test results, Peter O'Gorman, 2004/10/11
- Re: libtool--release--2.0 test results, Ralf Wildenhues, 2004/10/11
- Re: libtool--release--2.0 test results,
Ralf Wildenhues <=
- Re: libtool--release--2.0 test results, Albert Chin, 2004/10/11
- Re: libtool--release--2.0 test results, Ralf Wildenhues, 2004/10/11
- Re: libtool--release--2.0 test results, Albert Chin, 2004/10/11
- Re: libtool--release--2.0 test results, Peter O'Gorman, 2004/10/11
- Re: libtool--release--2.0 test results, Ralf Wildenhues, 2004/10/12