wavebitscientific / functional-fortran

Functional programming for modern Fortran

Home Page:https://wavebitscientific.github.io/functional-fortran/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

functional-fortran

hhirsch47 opened this issue · comments

Can't open module file ‘mod_testing.mod’ for reading at (1): No such file or directory
won't compile with use mod_functional

Can you provide more info on how you build functional-fortran, as well as compiler details?

Built according to README.md. Computer is Lenovo with i7 6700hq, Fedora 27.

Please include the commands that you use and compiler name and version.

gfortran -I/usr/local/include ar.f90
gcc version 7.3.1 20180303 (Red Hat 7.3.1-5) (GCC)
ar.f90:
program ar
use mod_functional
write(,)arange(1,5)
end program ar
output:
ar.f90:(.text+0x7f): undefined reference to `__mod_functional_MOD_arange_i4'
collect2: error: ld returned 1 exit status
thank you,
hhirsch47

You need to link to the static library:

gfortran ar.f90 -I/usr/local/include -lfunctional