And*_*way 6 python fortran compilation compiler-flags f2py
我有一个FORTRAN代码,需要以下编译命令
gfortran -c interp.f -ffixed-format -ffix-line-length-none
Run Code Online (Sandbox Code Playgroud)
我在python中使用f2py模块编译了相同的内容
from numpy import f2py
f2py.compile(open('interp.f').read(),modulename='interp',extra_flags='-ffixed-format -ffix-line-length-none',verbose=0)
Run Code Online (Sandbox Code Playgroud)
它无法编译模块.它出现错误,指出无效的文件格式''at'ffize-format'
请帮忙
、-ffixed-format和-ffix-line-length-none似乎都不是有效的 gfortran 选项。考虑使用-ffixed-formand-ffixed-line-length-none代替。