tessgi / tvguide

A tool for determining whether stars and galaxies are observable by TESS.
MIT License
4 stars 4 forks source link

Install problems w/ fortran? #1

Closed jradavenport closed 7 years ago

jradavenport commented 7 years ago

Trying to install on my 2016 MacBook Pro, running MacOS 10.12.3.

I have a brand-new install of gFortran (v6.3.0), installed today, and conda/anaconda undated today (running Py2.7)

I have tried both the pip and github installs. Any suggestions?

Here is the output of trying pip install tvguide:


Building wheels for collected packages: tvguide
  Running setup.py bdist_wheel for tvguide ... error
  Complete output from command /Users/james/anaconda/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/d5/pj4fr_bd7dl0k3hvw2d592pc0000gn/T/pip-build-swwNIX/tvguide/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /var/folders/d5/pj4fr_bd7dl0k3hvw2d592pc0000gn/T/tmpNnAbZQpip-wheel- --python-tag cp27:
  running bdist_wheel
  running build
  running config_cc
  unifing config_cc, config, build_clib, build_ext, build commands --compiler options
  running config_fc
  unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
  running build_src
  build_src
  building extension "tvguide._tvguide" sources
  f2py options: []
    adding 'build/src.macosx-10.7-x86_64-2.7/fortranobject.c' to sources.
    adding 'build/src.macosx-10.7-x86_64-2.7' to include_dirs.
    adding 'build/src.macosx-10.7-x86_64-2.7/tvguide/_tvguide-f2pywrappers.f' to sources.
  tvguide - nothing done with h_files = ['tvguide/tvguide.inc']
  build_src: building npy-pkg config files
  running build_py
  creating build/lib.macosx-10.7-x86_64-2.7
  creating build/lib.macosx-10.7-x86_64-2.7/tvguide
  copying tvguide/__init__.py -> build/lib.macosx-10.7-x86_64-2.7/tvguide
  copying tvguide/tvguide.py -> build/lib.macosx-10.7-x86_64-2.7/tvguide
  copying tvguide/version.py -> build/lib.macosx-10.7-x86_64-2.7/tvguide
  running build_ext
  customize UnixCCompiler
  customize UnixCCompiler using build_ext
  customize Gnu95FCompiler
  Found executable /usr/local/bin/gfortran
  customize Gnu95FCompiler
  customize Gnu95FCompiler using build_ext
  building 'tvguide._tvguide' extension
  compiling C sources
  C compiler: gcc -fno-strict-aliasing -I/Users/james/anaconda/include -arch x86_64 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes

  creating build/temp.macosx-10.7-x86_64-2.7
  creating build/temp.macosx-10.7-x86_64-2.7/build
  creating build/temp.macosx-10.7-x86_64-2.7/build/src.macosx-10.7-x86_64-2.7
  creating build/temp.macosx-10.7-x86_64-2.7/build/src.macosx-10.7-x86_64-2.7/tvguide
  compile options: '-Ibuild/src.macosx-10.7-x86_64-2.7 -I/Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include -I/Users/james/anaconda/include/python2.7 -c'
  gcc: build/src.macosx-10.7-x86_64-2.7/fortranobject.c
  In file included from build/src.macosx-10.7-x86_64-2.7/fortranobject.c:2:
  In file included from build/src.macosx-10.7-x86_64-2.7/fortranobject.h:13:
  In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/arrayobject.h:4:
  In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:18:
  In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1788:
  /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: "Using deprecated NumPy API, disable it by "          "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
  #warning "Using deprecated NumPy API, disable it by " \
   ^
  1 warning generated.
  gcc: build/src.macosx-10.7-x86_64-2.7/tvguide/_tvguidemodule.c
  In file included from build/src.macosx-10.7-x86_64-2.7/tvguide/_tvguidemodule.c:19:
  In file included from build/src.macosx-10.7-x86_64-2.7/fortranobject.h:13:
  In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/arrayobject.h:4:
  In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:18:
  In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1788:
  /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: "Using deprecated NumPy API, disable it by "          "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
  #warning "Using deprecated NumPy API, disable it by " \
   ^
  build/src.macosx-10.7-x86_64-2.7/tvguide/_tvguidemodule.c:172:12: warning: unused function 'f2py_size' [-Wunused-function]
  static int f2py_size(PyArrayObject* var, ...)
             ^
  2 warnings generated.
  compiling Fortran sources
  Fortran f77 compiler: /usr/local/bin/gfortran -Wall -g -ffixed-form -fno-second-underscore -m64 -fPIC -O3 -funroll-loops
  Fortran f90 compiler: /usr/local/bin/gfortran -Wall -g -fno-second-underscore -m64 -fPIC -O3 -funroll-loops
  Fortran fix compiler: /usr/local/bin/gfortran -Wall -g -ffixed-form -fno-second-underscore -Wall -g -fno-second-underscore -m64 -fPIC -O3 -funroll-loops
  creating build/temp.macosx-10.7-x86_64-2.7/tvguide
  compile options: '-Ibuild/src.macosx-10.7-x86_64-2.7 -I/Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include -I/Users/james/anaconda/include/python2.7 -c'
  gfortran:f77: tvguide/tvguide_minimal.f
  f951: Warning: Nonconforming tab character in column 1 of line 53 [-Wtabs]
  f951: Warning: Nonconforming tab character in column 1 of line 55 [-Wtabs]
  f951: Warning: Nonconforming tab character in column 1 of line 56 [-Wtabs]
  f951: Warning: Nonconforming tab character in column 1 of line 59 [-Wtabs]
  FATAL:/opt/local/bin/../libexec/as/x86_64/as: I don't understand 'm' flag!
  f951: Warning: Nonconforming tab character in column 1 of line 53 [-Wtabs]
  f951: Warning: Nonconforming tab character in column 1 of line 55 [-Wtabs]
  f951: Warning: Nonconforming tab character in column 1 of line 56 [-Wtabs]
  f951: Warning: Nonconforming tab character in column 1 of line 59 [-Wtabs]
  FATAL:/opt/local/bin/../libexec/as/x86_64/as: I don't understand 'm' flag!
  error: Command "/usr/local/bin/gfortran -Wall -g -ffixed-form -fno-second-underscore -m64 -fPIC -O3 -funroll-loops -Ibuild/src.macosx-10.7-x86_64-2.7 -I/Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include -I/Users/james/anaconda/include/python2.7 -c -c tvguide/tvguide_minimal.f -o build/temp.macosx-10.7-x86_64-2.7/tvguide/tvguide_minimal.o" failed with exit status 1

  ----------------------------------------
  Failed building wheel for tvguide
  Running setup.py clean for tvguide
Failed to build tvguide
Installing collected packages: tvguide
  Running setup.py install for tvguide ... error
    Complete output from command /Users/james/anaconda/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/d5/pj4fr_bd7dl0k3hvw2d592pc0000gn/T/pip-build-swwNIX/tvguide/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /var/folders/d5/pj4fr_bd7dl0k3hvw2d592pc0000gn/T/pip-FeQBzn-record/install-record.txt --single-version-externally-managed --compile:
    running install
    running build
    running config_cc
    unifing config_cc, config, build_clib, build_ext, build commands --compiler options
    running config_fc
    unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
    running build_src
    build_src
    building extension "tvguide._tvguide" sources
    f2py options: []
      adding 'build/src.macosx-10.7-x86_64-2.7/fortranobject.c' to sources.
      adding 'build/src.macosx-10.7-x86_64-2.7' to include_dirs.
      adding 'build/src.macosx-10.7-x86_64-2.7/tvguide/_tvguide-f2pywrappers.f' to sources.
    tvguide - nothing done with h_files = ['tvguide/tvguide.inc']
    build_src: building npy-pkg config files
    running build_py
    creating build/lib.macosx-10.7-x86_64-2.7
    creating build/lib.macosx-10.7-x86_64-2.7/tvguide
    copying tvguide/__init__.py -> build/lib.macosx-10.7-x86_64-2.7/tvguide
    copying tvguide/tvguide.py -> build/lib.macosx-10.7-x86_64-2.7/tvguide
    copying tvguide/version.py -> build/lib.macosx-10.7-x86_64-2.7/tvguide
    running build_ext
    customize UnixCCompiler
    customize UnixCCompiler using build_ext
    customize Gnu95FCompiler
    Found executable /usr/local/bin/gfortran
    customize Gnu95FCompiler
    customize Gnu95FCompiler using build_ext
    building 'tvguide._tvguide' extension
    compiling C sources
    C compiler: gcc -fno-strict-aliasing -I/Users/james/anaconda/include -arch x86_64 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes

    creating build/temp.macosx-10.7-x86_64-2.7
    creating build/temp.macosx-10.7-x86_64-2.7/build
    creating build/temp.macosx-10.7-x86_64-2.7/build/src.macosx-10.7-x86_64-2.7
    creating build/temp.macosx-10.7-x86_64-2.7/build/src.macosx-10.7-x86_64-2.7/tvguide
    compile options: '-Ibuild/src.macosx-10.7-x86_64-2.7 -I/Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include -I/Users/james/anaconda/include/python2.7 -c'
    gcc: build/src.macosx-10.7-x86_64-2.7/fortranobject.c
    In file included from build/src.macosx-10.7-x86_64-2.7/fortranobject.c:2:
    In file included from build/src.macosx-10.7-x86_64-2.7/fortranobject.h:13:
    In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/arrayobject.h:4:
    In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:18:
    In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1788:
    /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: "Using deprecated NumPy API, disable it by "          "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
    #warning "Using deprecated NumPy API, disable it by " \
     ^
    1 warning generated.
    gcc: build/src.macosx-10.7-x86_64-2.7/tvguide/_tvguidemodule.c
    In file included from build/src.macosx-10.7-x86_64-2.7/tvguide/_tvguidemodule.c:19:
    In file included from build/src.macosx-10.7-x86_64-2.7/fortranobject.h:13:
    In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/arrayobject.h:4:
    In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:18:
    In file included from /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1788:
    /Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: "Using deprecated NumPy API, disable it by "          "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
    #warning "Using deprecated NumPy API, disable it by " \
     ^
    build/src.macosx-10.7-x86_64-2.7/tvguide/_tvguidemodule.c:172:12: warning: unused function 'f2py_size' [-Wunused-function]
    static int f2py_size(PyArrayObject* var, ...)
               ^
    2 warnings generated.
    compiling Fortran sources
    Fortran f77 compiler: /usr/local/bin/gfortran -Wall -g -ffixed-form -fno-second-underscore -m64 -fPIC -O3 -funroll-loops
    Fortran f90 compiler: /usr/local/bin/gfortran -Wall -g -fno-second-underscore -m64 -fPIC -O3 -funroll-loops
    Fortran fix compiler: /usr/local/bin/gfortran -Wall -g -ffixed-form -fno-second-underscore -Wall -g -fno-second-underscore -m64 -fPIC -O3 -funroll-loops
    creating build/temp.macosx-10.7-x86_64-2.7/tvguide
    compile options: '-Ibuild/src.macosx-10.7-x86_64-2.7 -I/Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include -I/Users/james/anaconda/include/python2.7 -c'
    gfortran:f77: tvguide/tvguide_minimal.f
    f951: Warning: Nonconforming tab character in column 1 of line 53 [-Wtabs]
    f951: Warning: Nonconforming tab character in column 1 of line 55 [-Wtabs]
    f951: Warning: Nonconforming tab character in column 1 of line 56 [-Wtabs]
    f951: Warning: Nonconforming tab character in column 1 of line 59 [-Wtabs]
    FATAL:/opt/local/bin/../libexec/as/x86_64/as: I don't understand 'm' flag!
    f951: Warning: Nonconforming tab character in column 1 of line 53 [-Wtabs]
    f951: Warning: Nonconforming tab character in column 1 of line 55 [-Wtabs]
    f951: Warning: Nonconforming tab character in column 1 of line 56 [-Wtabs]
    f951: Warning: Nonconforming tab character in column 1 of line 59 [-Wtabs]
    FATAL:/opt/local/bin/../libexec/as/x86_64/as: I don't understand 'm' flag!
    error: Command "/usr/local/bin/gfortran -Wall -g -ffixed-form -fno-second-underscore -m64 -fPIC -O3 -funroll-loops -Ibuild/src.macosx-10.7-x86_64-2.7 -I/Users/james/anaconda/lib/python2.7/site-packages/numpy/core/include -I/Users/james/anaconda/include/python2.7 -c -c tvguide/tvguide_minimal.f -o build/temp.macosx-10.7-x86_64-2.7/tvguide/tvguide_minimal.o" failed with exit status 1

    ----------------------------------------
Command "/Users/james/anaconda/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/d5/pj4fr_bd7dl0k3hvw2d592pc0000gn/T/pip-build-swwNIX/tvguide/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /var/folders/d5/pj4fr_bd7dl0k3hvw2d592pc0000gn/T/pip-FeQBzn-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/d5/pj4fr_bd7dl0k3hvw2d592pc0000gn/T/pip-build-swwNIX/tvguide/````
mrtommyb commented 7 years ago

aahh, ok. Thanks Jim

jradavenport commented 7 years ago

:( sorry to be a bummer... I was scared by the big error msg, and after running all updates I didn't know where else to turn!

mrtommyb commented 7 years ago

Similar issues are referenced in https://github.com/dmlc/xgboost/issues/1945 and https://github.com/jbwhit/til/issues/3. I'm not sure I see a solution there but I'll keep searching.

mrtommyb commented 7 years ago

It does seems to be mac specific and possibly related to a macports/homebrew not playing together

mrtommyb commented 7 years ago

I will add that we intend to have a working webtool version of this in a few weeks (although this is clearly not a solution).

jradavenport commented 7 years ago

Was able to get it installed!

I had to mess with my path, and make sure /opt/local/bin was the last place it looked for things....

time will tell if that borks up other stuff on my laptop, but for now tvguide is installed and working!

now for the inevitable heartbreak from the target I want being too close to the equator

mrtommyb commented 7 years ago

thanks Jim. Hopefully, this is an isolated case. I've been trying to avoid rewriting the fortran code in python but if others have this issue then I might have to.