Closed bjmorgan closed 5 years ago
Installing with pip was giving the following error:
pip
compiling Fortran 90 module sources Fortran f77 compiler: /usr/bin/gfortran -Wall -g -ffixed-form -fno-second-underscore -fPIC -O3 -funroll-loops Fortran f90 compiler: /usr/bin/gfortran -Wall -g -fno-second-underscore -fPIC -O3 -funroll-loops Fortran fix compiler: /usr/bin/gfortran -Wall -g -ffixed-form -fno-second-underscore -Wall -g -fno-second-underscore -fPIC -O3 -funroll-loops creating build/temp.linux-x86_64-3.6/crystal_torture compile options: '-I/home/bjm42/.pyenv/versions/3.6.7/envs/crystal_torture/lib/python3.6/site-packages/numpy/core/include -c' extra options: '-Jbuild/temp.linux-x86_64-3.6 -Ibuild/temp.linux-x86_64-3.6' extra f90 options: '-fopenmp -lgomp -O3' gfortran:f90: ./crystal_torture/tort.f90 gfortran: error: unrecognized command line option ‘-fopenmp -lgomp -O3’ error: Command "/usr/bin/gfortran -Wall -g -fno-second-underscore -fPIC -O3 -funroll-loops -I/home/bjm42/.pyenv/versions/3.6.7/envs/crystal_torture/lib/python3.6/site-packages/numpy/core/include -c -c ./crystal_torture/tort.f90 -o build/temp.linux-x86_64-3.6/crystal_torture/tort.o -Jbuild/temp.linux-x86_64-3.6 -Ibuild/temp.linux-x86_64-3.6 -fopenmp -lgomp -O3" failed with exit status 1
This appears to be fixed by passing fortran compiler options as a list, rather than a single string, i.e.
[‘-fopenmp -lgomp -O3’]
becomes
['fopenmp', '-lgomp', '-O3']
check_f2py_compiler() now returns dict(list(str)) instead of dict(str), and these arguments are no longer wrapped in lists in setup_tort_ext().
check_f2py_compiler()
dict(list(str))
dict(str)
setup_tort_ext()
This appears to fix the problem on:
master
Installing with
pip
was giving the following error:This appears to be fixed by passing fortran compiler options as a list, rather than a single string, i.e.
becomes
check_f2py_compiler()
now returnsdict(list(str))
instead ofdict(str)
, and these arguments are no longer wrapped in lists insetup_tort_ext()
.This appears to fix the problem on:
master
.