Re: A few quick questions about gfortran under cygwin



Walter Spector wrote:
> Downloaded the windows version and it actually works - sort of. It doesn't
> know about the cygwin dlls, so a lot of my 'system call'ish code does not
> easily link up.

Is this something that means the Windows version is broken, or merely a
result of the fact that non-cygwin programs in general don't know about
cygwin dlls on the system?

> Gfortran did compile about 6k lines of that I threw at it. Most not particularly
> challenging. However it did find a few non-Standard items in my code that needed
> cleaning up, which had previously gone unnoticed. Not going to say what they are,
> because otherwise someone associated with gfortran might 'fix' them...

Well, as Steve Kargl mentioned, gfortran is intended to have various
standard-compatibility options, such that if you prefer to have all of
the non-standard items to be diagnosed, you should tell it to use
"-std=f95". There appears, from the mailing list, to be quite a bit of
effort going into making the gfortran compiler very strict with regards
to the standard when this is specified.

> I would really hope the gfortran folk would resist the urge for total
> bug/backward-compatibility with g77. Some of those old extensions just
> introduce hard-to-find errors into codes. (One example: scanning the email
> archives, it seems the mixing of INTEGER/LOGICAL is going to be implemented
> soon. This is a true horror which should only be enabled with some sort of
> -badly_broken_code option.) IMHO it is better to keep the compiler clean, and
> issue diagnostics - by default - than to silently compile known error-prone
> 'extensions'.

I believe (though I could be misremembering) that this particular item
was the topic which prompted the implementation of a "-std=legacy"
option -- which is pretty much just a different spelling of your
"-badly_broken_code". :)

The default is definitely to issue diagnostics for this sort of thing,
though I believe they may well default to warnings rather than errors.
But this default is certainly changable, and it's possible to ask
gfortran to be quite strict if you wish it to be.

- Brooks


--
The "bmoses-nospam" address is valid; no unmunging needed.
.



Relevant Pages

  • Re: A few quick questions about gfortran under cygwin
    ... >> Downloaded the windows version and it actually works - sort of. ... >> Gfortran did compile about 6k lines of that I threw at it. ... "pretty much anything anyone tries to throw at the compiler". ...
    (comp.lang.fortran)
  • Re: gfortran: OK, I quit, you win
    ... > gfortran working under Windows. ... let me explain a bit how the GCC and gfortran ... > only distributed as a source code package ready to be build on a Unix ...
    (comp.lang.fortran)
  • Re: gfortran: OK, I quit, you win
    ... gfortran working under Windows. ... let me explain a bit how the GCC and gfortran ... only distributed as a source code package ready to be build on a Unix ...
    (comp.lang.fortran)
  • Re: module
    ... developers under Windows, unfortunately. ... to work would get gfortran over the hump as far as the Win32 API ... appropriate!gcc$ ATTRIBUTE to be set via the -mrtd switch. ... the STDCALL macro ...
    (comp.lang.fortran)
  • Re: fortran 2003 compiler
    ... Fujitsu for Windows are in maintenance mode. ... I would bet against a Lahey/Fujitsu Fortran 2003 compiler on any ... None of the gfortran developers are interested enough in Windows to ... I'd be willing to pitch in some money to pay a developer. ...
    (comp.lang.fortran)