Modules

François-Xavier Coudert Francois-Xavier.Coudert@lcp.u-psud.fr
Mon Feb 14 09:58:00 GMT 2005


> C:\cygwin\home\Tim\test>gfortran prog.f95
> 
> C:\DOCUME~1\Tim\LOCALS~1\Temp/ccc5aaaa.o(.text+0x7):prog.f95: undefined 
> reference to `__mymod__hello'

You have to link in the object file produced by the first compilation step:

gfortran prog.f95 mod.o

so that the hello subroutine (named __mymod__hello since it is in module 
mymod) can be incorporated into the executable code.

FX

-- 
Outside of a dog, a book is man's best friend.  Inside of a dog, it is too
dark to read.



More information about the Fortran mailing list