libtool-patches
[Top][All Lists]
Advanced

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

Re: PIC flags not found for mpif77(ifort)


From: Christian Rössel
Subject: Re: PIC flags not found for mpif77(ifort)
Date: Fri, 17 Dec 2010 13:25:45 +0100
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.13) Gecko/20101208 Thunderbird/3.1.7

Hi Ralf,

On 12/16/2010 09:54 PM, Ralf Wildenhues wrote:
> Hello Christian,
>
> * Christian Rössel wrote on Thu, Dec 16, 2010 at 05:27:23PM CET:
>> Am 12/16/2010 11:19 AM, schrieb Christian Rössel:
>>> Am 12/15/2010 9:21 PM, schrieb Ralf Wildenhues:
>>>> Hmm.  Is $GCC = yes for this compiler?  That would be surprising.
>>>> Why else would the new branch not be matched?
>>>
>>> yes, the Intel compiler claims to be a GNU compiler:
>>>
>>> checking for gcc... icc
> [...]
>>> checking whether we are using the GNU C compiler... yes
>>>
>>> I'm not sure how autoconf performs this check, but we came up with the
>>> following to distinguish Intel from GNU:
>
> Thanks.  So far we've more or less fared well with the assumption that
> if the compiler claims it is GNU, then we just use the GCC settings.
> If that doesn't work, then it's the compiler's fault to claim being GNU.
>
> And now I wonder why you are having problems with 'mpif77 -f77=ifort'
> because either it claims to be GNU (and then should accept -fPIC) or it
> doesn't claim to be GNU (and then my proposed patch, including the fix
> you spotted to double-quote the [CF]) should have worked.  Can you show
> the config.log for the F77=mpif77 case that fails to detect the PIC flag?
> Thanks.

I checked again and you are right, with the fixed patch it works out of
the box. ifort 11.1 does not claim to be a GNU compiler (whereas icc and
icpc do). I somehow mixed up the output of the different compilers as we
use them all in our project. Sorry for the confusion.

> As far as I remember, the older ifort versions at least didn't claim to
> be GNU (unlike icc or icpc).
>
>>> #if defined(__GNUC__) && ! (defined(__INTEL_COMPILER) || defined(__ICC))
>>> /* using a gnu but not an intel compiler */
>>> #endif
>>
>> to prevent configure to identify Intel compilers as GNU compiler you
>> need to add following code to _AC_LANG_COMPILER_GNU:
>>
>> #if defined(__INTEL_COMPILER) || defined(__ICC)
>>        choke me
>> #endif
>>
>> This is not a valid patch, I know. Can you please give me a hint where
>> to find a how-to for providing autotools patches?
>
> Good question.  The git[0] development trees[1] of Autoconf and Libtool
> have files named HACKING that explain some bits.  Generalities are
> documented in the GNU Coding Standards[2].  Portability issues are
> documented in the portability sections of the Autoconf manual[3].
> Patches posted as 'diff -u' output are fine however; 'git diff' or
> 'git format-patch' output is more convenient for us.
>
> [0] http://git-scm.com/
> [1] http://savannah.gnu.org/git/?group=autoconf
>     http://savannah.gnu.org/git/?group=libtool
> [2] http://www.gnu.org/prep/standards/html_node/index.html
> [3] http://www.gnu.org/software/autoconf/manual/html_node/Portable-Shell.html

Thanks a lot!

Christian

>>>>> BTW, the same problem occurs for mpif77 and mpif90 using the PGI
>>>>> compilers. Called with -V they produce:
>>>>>
>>>>> pgf90 10.9-0 64-bit target on x86-64 Linux -tp core2-64
>>>>> Copyright 1989-2000, The Portland Group, Inc. All Rights Reserved.
>>>>> Copyright 2000-2010, STMicroelectronics, Inc. All Rights Reserved.
>>>>
>>>> I suppose that could be fixed with the diff below on top
>>>> (pending the fix for the issue above).
>>>
>>> The patch for PGI works!
>
> Great.  I've pushed that patch to the git tree.
>
> Thanks,
> Ralf


--
Christian Rössel
Jülich Supercomputing Centre
Telefon +49 2461 61-1773

------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------
Forschungszentrum Juelich GmbH
52425 Juelich
Sitz der Gesellschaft: Juelich
Eingetragen im Handelsregister des Amtsgerichts Dueren Nr. HR B 3498
Vorsitzender des Aufsichtsrats: MinDirig Dr. Karl Eugen Huthmacher
Geschaeftsfuehrung: Prof. Dr. Achim Bachem (Vorsitzender),
Dr. Ulrich Krafft (stellv. Vorsitzender), Prof. Dr.-Ing. Harald Bolt,
Prof. Dr. Sebastian M. Schmidt
------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------



reply via email to

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