dependencies

Magnus Hagdorn Magnus.Hagdorn@glg.ed.ac.uk
Mon Sep 11 07:52:00 GMT 2006


On Sun, 2006-09-10 at 22:49 +0200, Daniel Franke wrote:
> On Friday 08 September 2006 18:23, Warren Turkal wrote:
> > Is there a way to make gfortran generate make dependencies a la gcc -M?
> 
> I spent the last week to work around these issues and could no come up
> with something more reasonable than the scripts already mentioned.
> Since I usually use autotools, I strive(d) to include depency checking
> automagically into my project setup.
> 
> My knowledge of automake/autoconf is reasonable but far from wizardry.
> Could -by any chance- someone comment on the probability to get full 
> dependency tracking with gfortran and autotools working within a reasonable 
> amount of time? (I would have asked this at the official autoconf mailing 
> list, but it seems, that it was abandoned a couple of months ago?!)
> 
> 
I also use autoconf and friends. I use the following incantation:
# F90 dependency tracking
f90_dep.mak:    $(srcdir)/*.F90 $(srcdir)/*.f
                $(top_srcdir)/scripts/f90_dependencies.py -o $@ $^

-include f90_dep.mak
This will automatically update the list of dependencies if any of the
*.F90 or *.f files has changed.
Ah, would be nice to get proper fortran support in autoconf. There is a
fairly comprehensively patched autoconf/automake system out there. It
would be nice if those changes got merged into the main autotools sets.
Ah well, once can hope.
cheers
magi



More information about the Fortran mailing list