If I have a library built from one or fortran modules, is it possible to compile it with fort into object files or library archives, then link against it from a main program compiled & linked with a different fortran compiler? I know module files are incompatible, but presuming there was a way to generate an appropriate set mod files for each compiler, but the object/archive being linked against was compiled by a different compiler?
I think the answer is no, because there is no standardized Fortran ABI, or something like that, is that correct?
I ask because I want to write some install rules for my project, and was thinking that if library objects are not compatible between Fortran compilers I would install the .a and .so files as <prefix>/lib/COMPILER_ID/libmyproj and the module files as <prefix>/include/COMPILER_ID/myproj.mod
Is there a better way? Does this sound sane?