Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

another (different?) installation issue #59

Closed
a-e-cole opened this issue Jan 23, 2019 · 3 comments
Closed

another (different?) installation issue #59

a-e-cole opened this issue Jan 23, 2019 · 3 comments
Labels
Install Errors in the installation process. Mac Issues specific to mac osx

Comments

@a-e-cole
Copy link

a-e-cole commented Jan 23, 2019

Hi! I'm trying to install on macOS Mojave and running into issues. Not sure whether they're related to problems others are having. When I attempt via pip:

Alex-Mac:ripser.py-master alex$ pip3 install ripser
Collecting ripser
  Using cached https://files.pythonhosted.org/packages/20/59/302dab2f1be85f32c57bdf8d4595d0437db76131b13504025abfc8373b03/ripser-0.3.0.tar.gz
Requirement already satisfied: Cython in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from ripser) (0.29.3)
Requirement already satisfied: numpy in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from ripser) (1.16.0)
Requirement already satisfied: scipy in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from ripser) (1.2.0)
Requirement already satisfied: matplotlib in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from ripser) (3.0.2)
Requirement already satisfied: scikit-learn in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from ripser) (0.20.2)
Requirement already satisfied: python-dateutil>=2.1 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from matplotlib->ripser) (2.7.5)
Requirement already satisfied: cycler>=0.10 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from matplotlib->ripser) (0.10.0)
Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from matplotlib->ripser) (2.3.1)
Requirement already satisfied: kiwisolver>=1.0.1 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from matplotlib->ripser) (1.0.1)
Requirement already satisfied: six>=1.5 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from python-dateutil>=2.1->matplotlib->ripser) (1.12.0)
Requirement already satisfied: setuptools in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from kiwisolver>=1.0.1->matplotlib->ripser) (40.6.2)
Building wheels for collected packages: ripser
  Building wheel for ripser (setup.py) ... error
  Complete output from command /Library/Frameworks/Python.framework/Versions/3.7/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/sr/kj8trxfd57sc9c_bwvwxl8nh0000gn/T/pip-install-wqfcvtit/ripser/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 /private/var/folders/sr/kj8trxfd57sc9c_bwvwxl8nh0000gn/T/pip-wheel-i8piv9uu --python-tag cp37:
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build/lib.macosx-10.9-x86_64-3.7
  creating build/lib.macosx-10.9-x86_64-3.7/ripser
  copying ripser/_version.py -> build/lib.macosx-10.9-x86_64-3.7/ripser
  copying ripser/__init__.py -> build/lib.macosx-10.9-x86_64-3.7/ripser
  copying ripser/ripser.py -> build/lib.macosx-10.9-x86_64-3.7/ripser
  running build_ext
  building 'pyRipser' extension
  creating build/temp.macosx-10.9-x86_64-3.7
  creating build/temp.macosx-10.9-x86_64-3.7/ripser
  gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch x86_64 -g -DUSE_COEFFICIENTS=1 -DNDEBUG=1 -DASSEMBLE_REDUCTION_MATRIX=1 -I./ripser -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -c ripser/pyRipser.cpp -o build/temp.macosx-10.9-x86_64-3.7/ripser/pyRipser.o -std=c++11 -Ofast -D_hypot=hypot
  In file included from /usr/local/lib/gcc/x86_64-apple-darwin14.0.0/4.9.2/include-fixed/syslimits.h:7:0,
                   from /usr/local/lib/gcc/x86_64-apple-darwin14.0.0/4.9.2/include-fixed/limits.h:34,
                   from /Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m/Python.h:11,
                   from ripser/pyRipser.cpp:42:
  /usr/local/lib/gcc/x86_64-apple-darwin14.0.0/4.9.2/include-fixed/limits.h:168:61: fatal error: limits.h: No such file or directory
   #include_next <limits.h>  /* recurse down to the real one */
                                                               ^
  compilation terminated.
  error: command 'gcc' failed with exit status 1
  
  ----------------------------------------
  Failed building wheel for ripser
  Running setup.py clean for ripser
Failed to build ripser
Installing collected packages: ripser
  Running setup.py install for ripser ... error
    Complete output from command /Library/Frameworks/Python.framework/Versions/3.7/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/sr/kj8trxfd57sc9c_bwvwxl8nh0000gn/T/pip-install-wqfcvtit/ripser/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /private/var/folders/sr/kj8trxfd57sc9c_bwvwxl8nh0000gn/T/pip-record-mn9lirpo/install-record.txt --single-version-externally-managed --compile:
    running install
    running build
    running build_py
    creating build
    creating build/lib.macosx-10.9-x86_64-3.7
    creating build/lib.macosx-10.9-x86_64-3.7/ripser
    copying ripser/_version.py -> build/lib.macosx-10.9-x86_64-3.7/ripser
    copying ripser/__init__.py -> build/lib.macosx-10.9-x86_64-3.7/ripser
    copying ripser/ripser.py -> build/lib.macosx-10.9-x86_64-3.7/ripser
    running build_ext
    building 'pyRipser' extension
    creating build/temp.macosx-10.9-x86_64-3.7
    creating build/temp.macosx-10.9-x86_64-3.7/ripser
    gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch x86_64 -g -DUSE_COEFFICIENTS=1 -DNDEBUG=1 -DASSEMBLE_REDUCTION_MATRIX=1 -I./ripser -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -c ripser/pyRipser.cpp -o build/temp.macosx-10.9-x86_64-3.7/ripser/pyRipser.o -std=c++11 -Ofast -D_hypot=hypot
    In file included from /usr/local/lib/gcc/x86_64-apple-darwin14.0.0/4.9.2/include-fixed/syslimits.h:7:0,
                     from /usr/local/lib/gcc/x86_64-apple-darwin14.0.0/4.9.2/include-fixed/limits.h:34,
                     from /Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m/Python.h:11,
                     from ripser/pyRipser.cpp:42:
    /usr/local/lib/gcc/x86_64-apple-darwin14.0.0/4.9.2/include-fixed/limits.h:168:61: fatal error: limits.h: No such file or directory
     #include_next <limits.h>  /* recurse down to the real one */
                                                                 ^
    compilation terminated.
    error: command 'gcc' failed with exit status 1`
    
    ----------------------------------------
`Command "/Library/Frameworks/Python.framework/Versions/3.7/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/sr/kj8trxfd57sc9c_bwvwxl8nh0000gn/T/pip-install-wqfcvtit/ripser/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /private/var/folders/sr/kj8trxfd57sc9c_bwvwxl8nh0000gn/T/pip-record-mn9lirpo/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/sr/kj8trxfd57sc9c_bwvwxl8nh0000gn/T/pip-install-wqfcvtit/ripser/

and when I try directly from the master branch:

Alex-Mac:ripser.py-master alex$ python3 setup.py install
Add compile flag macs
running install
running bdist_egg
running egg_info
writing ripser.egg-info/PKG-INFO
writing dependency_links to ripser.egg-info/dependency_links.txt
writing requirements to ripser.egg-info/requires.txt
writing top-level names to ripser.egg-info/top_level.txt
reading manifest file 'ripser.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'ripser.egg-info/SOURCES.txt'
installing library code to build/bdist.macosx-10.9-x86_64/egg
running install_lib
running build_py
running build_ext
building 'pyRipser' extension
gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch x86_64 -g -DUSE_COEFFICIENTS=1 -DNDEBUG=1 -DASSEMBLE_REDUCTION_MATRIX=1 -I./ripser -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -c ripser/pyRipser.cpp -o build/temp.macosx-10.9-x86_64-3.7/ripser/pyRipser.o -std=c++11 -Ofast -D_hypot=hypot -stdlib=libc++
gcc: error: unrecognized command line option ‘-stdlib=libc++’
error: command 'gcc' failed with exit status 1

Any advice would be much appreciated!

@sauln
Copy link
Member

sauln commented Jan 24, 2019

This is a different issue and I'm not sure exactly what's wrong. How did you install your Python? Could you try installing python-dev as well to see if that helps.

@a-e-cole
Copy link
Author

This is with Python 3.7.2 installed from https://www.python.org/downloads/.

I haven't tried with python-dev yet but using homebrew to install Python 3 has given me a successful install! Either with pip or by the master branch download. Strange!

@sauln
Copy link
Member

sauln commented Jan 28, 2019

Great! I'm glad the home-brew install worked. I'll play around with the versions from python.org and see if I can get it to break also.

@sauln sauln closed this as completed Feb 19, 2019
@sauln sauln added Install Errors in the installation process. Mac Issues specific to mac osx labels Mar 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Install Errors in the installation process. Mac Issues specific to mac osx
Projects
None yet
Development

No branches or pull requests

2 participants