automake
[Top][All Lists]
Advanced

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

Re: Improved Fortran support


From: Tom Tromey
Subject: Re: Improved Fortran support
Date: 05 Mar 2001 00:21:52 -0700

>>>>> "Chris" == marq  <address@hidden> writes:

Chris> Hi again!

Sorry for the delay on this.  I got info from GNU last week (or maybe
before?  I forget) that your copyright assignment came through.  So
I'd like to finish up what is left to make the F95 support work.

Chris> Of course. The problem is that with
Chris>   bin_PROGRAMS = prog
Chris>   prog_SOURCES = some.f90 foo.f90 bar.F90
Chris> in Makefile.am, bar.o does not appear in the automatically
Chris> generated dependency list for prog.

You need to write:

   bin_PROGRAMS = prog
   prog_SOURCES = some.f90 foo.f90 bar.F90
   SUFFIXES = .f90 .F90

   .f90.o:
        ...

   .F90.o:
        ...

Maybe you did that.  It isn't clear.

Chris>   F77=f90 ./configure

Chris> But really, IMHO this is just a simple hack to work around a
Chris> missing feature.

I agree.  I'll look at your patch again soon.

>> Since the body of this, lang_f95_finish, and lang_f7_finish are
>> nearly identical, how about making a new subroutine which all three
>> call with the appropriate arguments?  That would seem to make
>> maintenance easier.

Chris> Hmm. As Martin pointed out a long while ago, F90 has a complex
Chris> structure when it comes to dependencies due to the existence of
Chris> module files. In a very basic support mode, the targets to be
Chris> generated are indeed very similar to the ones required by
Chris> f77. But over time, if someone finds ways to represent module
Chris> appropriately in Makefiles, these routines might differ
Chris> substantially. I don't know what's the best way to start this -
Chris> what's your advice?

Ok, I wasn't aware of this.  I know nothing whatsoever about Fortran.

The very best thing to do would be to implement automatic dependency
tracking for f90 and for any other Fortran dialect where the compiler
can for some reason read multiple files for a single compilation (eg
including preprocessing) and thus needs dependency tracking.

We have some machinery that should be able to help with this.  However
in the end it probably boils down to what f90 compilers are capable of
telling you.

Tom



reply via email to

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