This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Fortran Compiler Error CMBFAST

On Tue, 27 Jun 2006, Williams, Gerald S (Jerry) wrote:

> I just recreated the problem with some minimal code,
> and got some more information in the process:
> Create a file "foo.for" that contains one line:
>         include ''
> Create an empty file named in the same
> directory.
> Copy "foo.for" to "foo.f", "foo.FOR", and "foo.F" and
> try to compile all four of them from that directory:
> $ f77 -c foo.for    # runs OK
> $ f77 -c foo.f      # runs OK
> $ f77 -c foo.FOR    # runs OK
> $ f77 -c foo.F
> foo.F:1:
>            include ''
>            ^
> Unable to open INCLUDE file `' at (^)
> $ _

Doesn't foo.F represent a FORTRAN file that needs to be preprocessed by
the C preprocessor?  Changing foo.F to contain

#include ""

makes it work for me.

> So it seems that the rules by which the preprocessor
> looks in the current directory and/or the directory
> containing the source file does not apply to files
> named *.F for some reason. It's possible that this
> was intentional, although I don't get this behavior
> on my Linux box (which granted is using GCC version
> 3.2.3, so it could have changed since then...).

Does running f77 with '-v' help?
      |\      _,,,---,,_ |
ZZZzz /,`.-'`'    -.  ;-;;,_		Igor Peshansky, Ph.D. (name changed!)
     |,4-  ) )-,_. ,\ (  `'-'		old name: Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Las! je suis sot... -Mais non, tu ne l'es pas, puisque tu t'en rends compte."
"But no -- you are no fool; you call yourself a fool, there's proof enough in
that!" -- Rostand, "Cyrano de Bergerac"

Unsubscribe info:
Problem reports:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]