autoconf
[Top][All Lists]
Advanced

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

Re: fortran.m4 _AC_FC_LIBRARY_LDFLAGS


From: Ralf Wildenhues
Subject: Re: fortran.m4 _AC_FC_LIBRARY_LDFLAGS
Date: Thu, 09 Jun 2011 21:31:26 +0200

Hi Jim,

thanks for the report.

On Wed, Jun 08, 2011 at 10:25:13AM -0600, Jim Edwards wrote:
> I think that I've found a bug in this function,  I am using pgf90 10.3-0
> and the -v flag is producing a line which includes a flag -list which is
> then interpreted as a library and causes a failure later when it trys to
> link.
> 
> In the function I found:
> 
>       # Ignore these flags.
>     -lang* | -lcrt*.o | -lc | -lgcc* | -lSystem | -libmil | -little \
>       |-LANG:=* | -LIST:* | -LNO:* | -link )
>       ;;
> 
> 
> And the obvious thing to do is add -list to this list.

And that is IMVHO the correct fix here, too.  Would love to be beaten to
pushing the fix though.

>  I did that and it
> solves the problem.   But this list seems really kludgey to me - wouldn't it
> be better to test link with all of the -lwhatever
> flags and keep the ones that pass that test?

Well, the problem is that some of the above won't cause failures in every
case, for example -lc and -lgcc.  So we might not notice that we should
drop these flags.  Also, trying to drop them one by one, or adding them
one by one is not necessarily sufficient to find a suitable set, as there
may be interdependencies between the libraries.  The last point is mostly
moot on all modern systems, due to working interdependent library linking.

Cheers,
Ralf


reply via email to

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