Andy Stow Away
Andy Stow Away

Reputation: 647

Issues when using f2py module in python code

I have a FORTRAN code that required the following compile command

gfortran -c interp.f -ffixed-format -ffix-line-length-none

I compiled the same using f2py module in python

from numpy import f2py

f2py.compile(open('interp.f').read(),modulename='interp',extra_flags='-ffixed-format -ffix-line-length-none',verbose=0)

It is unable to compile the module. It gives an error saying invalid file format '' at '-ffized-format'

Please help

Upvotes: 6

Views: 728

Answers (1)

Oleg2718281828
Oleg2718281828

Reputation: 1039

Neither -ffixed-format, nor -ffix-line-length-none seem to be valid gfortran options. Consider using -ffixed-form and -ffixed-line-length-none instead.

Upvotes: 1

Related Questions