Hi,
I also came up with a solution that appeared to work. It was discussed
some time ago on comp.lang.fortran. I'd have to look hard to see
whether your scheme and mine work the same way.
The problem with all of these is that there is the implicit assumption
that a USEing .f90 file needs only the modules' .M files to be
compiled. There is no guarantee that this is true; there is no
guarantee that there will even be .M files or the equivalents; and
another problem that is not solved is the variety of names that
the .M files could have -- i.e., cross-platform portability of
the makefile even when the assumed paradigm is valid.
I have been dismayed, for example, to discover that when the same
module is compiled by the same compiler at different optimization
levels, the .M (actually, .mod) file changes. How do I know
that the changes are not important? Maybe at a higher optimization
level information is included which allows module functions to be in-lined
in the USEing routine, for example.
On UNIX, at least, I don't see anything in the SGI or the IBM/AIX
f90 pages that say, explicitly, that the USEing routine needs only
the .M (or .mod) file from the module -- though there is langauge
that makes this a likely assumption. For instance, the -I
compiler option tells the compiler to use the specified directory for
files named in INCLUDE statements and for .mod files associated
with USE statements. But it still doesn't say that the .mod file
is all the USEing routine needs.
-P.
--
*********** How can we have ethnic music without ethnic hatred? ***********
* Peter S. Shenkin; Chemistry, Columbia U.; 3000 Broadway, Mail Code 3153 *
** NY, NY 10027; [log in to unmask]; (212)854-5143; FAX: 678-9039 ***
*MacroModel WWW page: http://www.columbia.edu/cu/chemistry/mmod/mmod.html *
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|