Modules

Tim Freeman timncfc@bigpond.net.au
Mon Feb 14 11:18:00 GMT 2005


Hi Carsten,

>
> You cannot link to modules.  These are needed at compile time and you 
> don't need to refer to them on the command line (unless they're in a 
> different directry, so you specify -Imodule-dir)
>
> You should organize your utility .o files in a library (with the ar 
> utility), the linker step then just involves
>
> gfortran -o mainprog mainprog.o -lmylibrary
>
Thanks; it makes good sense now. I'll try building some libraries.

Tim.



More information about the Fortran mailing list