Re: WRAPIT compilers on OSX

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Thu Jun 30 2011 - 07:55:29 MDT

Hi Jared,

This was taken offline briefly. It turns out that WRAPIT only recognizes the g77/gfortran compilers for MacOSX right now.

I think the quick fix is to edit $NCARG_ROOT/bin/WRAPIT and change the second line in this block of code:

  else if ($arg:q == "-pg") then
    if ($OS == Linux) then


  else if ($arg:q == "-pg") then
    if ($OS == Linux || $OS == Darwin) then

Do a similar thing for these lines:

  else if ($arg:q == "-in") then
    if ($OS == Linux) then

Let me know if this works, and I'll incorporate the changes on our end.



On Jun 29, 2011, at 11:45 AM, Dennis Shea wrote:

> %> WRAPIT -h
> [snip]
> ------------------------ Linux Compilers ---------------------------
> The default linux fortran compiler is the GNU gfortran compiler. If
> your system has one of the supported linux fortran compilers you must
> specify which one you want to use by the appropriate command line
> option, otherwise the gfortran compiler will be used.
> The supported linux fortran compilers are the Portland Group
> (pgf90), the Lahey/Fujitsu (lf95), and the g95 compiler (g95),
> and the Intel compiler (ifc/ifort).
> OPTION: -pg to specify the Portland Group compiler.
> OPTION: -lf to specify the Lahey/Fujitsu compiler.
> OPTION: -in to specify the Intel compiler.
> OPTION: -g95 to specify the g95 compiler.
> OPTION: -gf to specify the gfortran compiler.
> OPTION: -g77 to specify the old g77 compiler.
> [snip]
> On 6/29/11 11:30 AM, Jared Lee wrote:
>> Hi, is there a reason why WRAPIT is incompatible with the pgf90 and ifort compilers on Mac OSX? Why are gfortran, g95, and g77 the only compilers allowed? (I'm using NCL 5.2.1.)
>> I ask because my work machine was just changed this week from a Linux system to a Mac (OS 10.6.8), and I'm running these codes on my desktop system. In one of my Fortran 90 codes on which I use WRAPIT, gfortran consistently chokes on the 'backspace' command, by giving me an "unattached unit" error. I never had that problem before on other architectures when WRAPIT allowed me to use other compilers. Fortunately for me, I see a way that I can rework my Fortran code to avoid needing to use 'backspace' (and it should make my code marginally more efficient anyway), because I suspect this is a bug in gfortran (I did an 'inquire' right before the 'backspace' and everything checked out okay... I'm completely stumped why I'm getting the "unattached unit" error).
>> I also ran into problems with gfortran because some of my lines exceeded 132 characters in length. That was a simple enough fix to make, but still inconvenient because of not being allowed by WRAPIT to use a compiler other than gfortran.
>> Anyway, can WRAPIT be modified to allow non-GNU compilers to be used on Mac OSX?
>> Jared
>> _______________________________________________
>> ncl-talk mailing list
>> List instructions, subscriber options, unsubscribe:
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:

ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
Received on Thu Jun 30 07:55:44 2011

This archive was generated by hypermail 2.1.8 : Thu Jun 30 2011 - 12:54:44 MDT