question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Mac OS Mojave installation error - error: command 'clang' failed with exit status 1

See original GitHub issue

Hi,

When trying to install Velocyto on macOS 10.14.4 (Mojave) I receive the following error:

Collecting velocyto
  Using cached https://files.pythonhosted.org/packages/81/66/e8fff9d3b824fd99c0f678c47c740fec058ce2d9a0cfdf11b114ea8889f2/velocyto-0.17.17.tar.gz
Requirement already satisfied: numpy in /usr/local/lib/python3.7/site-packages (from velocyto) (1.16.3)
Requirement already satisfied: scipy in /usr/local/lib/python3.7/site-packages (from velocyto) (1.2.1)
Requirement already satisfied: cython in /usr/local/lib/python3.7/site-packages (from velocyto) (0.29.7)
Requirement already satisfied: numba in /usr/local/lib/python3.7/site-packages (from velocyto) (0.43.1)
Requirement already satisfied: matplotlib in /usr/local/lib/python3.7/site-packages (from velocyto) (3.0.3)
Requirement already satisfied: scikit-learn in /usr/local/lib/python3.7/site-packages (from velocyto) (0.20.3)
Requirement already satisfied: h5py in /usr/local/lib/python3.7/site-packages (from velocyto) (2.9.0)
Requirement already satisfied: loompy in /usr/local/lib/python3.7/site-packages (from velocyto) (2.0.17)
Requirement already satisfied: pysam in /usr/local/lib/python3.7/site-packages (from velocyto) (0.15.2)
Requirement already satisfied: Click in /usr/local/lib/python3.7/site-packages (from velocyto) (7.0)
Requirement already satisfied: pandas in /usr/local/lib/python3.7/site-packages (from velocyto) (0.24.2)
Requirement already satisfied: llvmlite>=0.28.0dev0 in /usr/local/lib/python3.7/site-packages (from numba->velocyto) (0.28.0)
Requirement already satisfied: python-dateutil>=2.1 in /usr/local/lib/python3.7/site-packages (from matplotlib->velocyto) (2.8.0)
Requirement already satisfied: cycler>=0.10 in /usr/local/lib/python3.7/site-packages (from matplotlib->velocyto) (0.10.0)
Requirement already satisfied: kiwisolver>=1.0.1 in /usr/local/lib/python3.7/site-packages (from matplotlib->velocyto) (1.0.1)
Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 in /usr/local/lib/python3.7/site-packages (from matplotlib->velocyto) (2.4.0)
Requirement already satisfied: six in /usr/local/lib/python3.7/site-packages (from h5py->velocyto) (1.12.0)
Requirement already satisfied: setuptools in /usr/local/lib/python3.7/site-packages (from loompy->velocyto) (40.8.0)
Requirement already satisfied: pytz>=2011k in /usr/local/lib/python3.7/site-packages (from pandas->velocyto) (2019.1)
Building wheels for collected packages: velocyto
  Building wheel for velocyto (setup.py) ... error
  Complete output from command /usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/m5/xjs7y13n2_s81sxlztjk1z7h0000gn/T/pip-install-gn6cymm9/velocyto/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/m5/xjs7y13n2_s81sxlztjk1z7h0000gn/T/pip-wheel-gyph1018 --python-tag cp37:
  ['-c', 'bdist_wheel', '-d', '/private/var/folders/m5/xjs7y13n2_s81sxlztjk1z7h0000gn/T/pip-wheel-gyph1018', '--python-tag', 'cp37']
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build/lib.macosx-10.14-x86_64-3.7
  creating build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/transcript_model.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/diffusion.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/metadata.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/analysis.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/molitem.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/_version.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/neighbors.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/constants.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/estimation.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/__init__.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/feature.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/logic.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/indexes.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/utils.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/gene_info.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/r_interface.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/segment_match.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/counter.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/serialization.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  copying velocyto/read.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
  creating build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
  copying velocyto/commands/velocyto.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
  copying velocyto/commands/run.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
  copying velocyto/commands/__init__.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
  copying velocyto/commands/run_smartseq2.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
  copying velocyto/commands/dropest_bc_correct.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
  copying velocyto/commands/run_dropest.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
  copying velocyto/commands/run10x.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
  copying velocyto/commands/_run.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
  running build_ext
  building 'velocyto.speedboosted' extension
  creating build/temp.macosx-10.14-x86_64-3.7
  creating build/temp.macosx-10.14-x86_64-3.7/velocyto
  clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c velocyto/speedboosted.c -o build/temp.macosx-10.14-x86_64-3.7/velocyto/speedboosted.o -fopenmp -ffast-math
  velocyto/speedboosted.c:613:10: fatal error: 'numpy/arrayobject.h' file not found
  #include "numpy/arrayobject.h"
           ^~~~~~~~~~~~~~~~~~~~~
  1 error generated.
  error: command 'clang' failed with exit status 1
  
  ----------------------------------------
  Failed building wheel for velocyto
  Running setup.py clean for velocyto
Failed to build velocyto
Installing collected packages: velocyto
  Running setup.py install for velocyto ... error
    Complete output from command /usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/m5/xjs7y13n2_s81sxlztjk1z7h0000gn/T/pip-install-gn6cymm9/velocyto/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/m5/xjs7y13n2_s81sxlztjk1z7h0000gn/T/pip-record-hpsa6hb2/install-record.txt --single-version-externally-managed --compile:
    ['-c', 'install', '--record', '/private/var/folders/m5/xjs7y13n2_s81sxlztjk1z7h0000gn/T/pip-record-hpsa6hb2/install-record.txt', '--single-version-externally-managed', '--compile']
    running install
    running build
    running build_py
    creating build
    creating build/lib.macosx-10.14-x86_64-3.7
    creating build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/transcript_model.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/diffusion.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/metadata.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/analysis.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/molitem.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/_version.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/neighbors.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/constants.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/estimation.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/__init__.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/feature.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/logic.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/indexes.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/utils.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/gene_info.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/r_interface.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/segment_match.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/counter.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/serialization.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    copying velocyto/read.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto
    creating build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
    copying velocyto/commands/velocyto.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
    copying velocyto/commands/run.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
    copying velocyto/commands/__init__.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
    copying velocyto/commands/run_smartseq2.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
    copying velocyto/commands/dropest_bc_correct.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
    copying velocyto/commands/run_dropest.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
    copying velocyto/commands/run10x.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
    copying velocyto/commands/_run.py -> build/lib.macosx-10.14-x86_64-3.7/velocyto/commands
    running build_ext
    building 'velocyto.speedboosted' extension
    creating build/temp.macosx-10.14-x86_64-3.7
    creating build/temp.macosx-10.14-x86_64-3.7/velocyto
    clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c velocyto/speedboosted.c -o build/temp.macosx-10.14-x86_64-3.7/velocyto/speedboosted.o -fopenmp -ffast-math
    velocyto/speedboosted.c:613:10: fatal error: 'numpy/arrayobject.h' file not found
    #include "numpy/arrayobject.h"
             ^~~~~~~~~~~~~~~~~~~~~
    1 error generated.
    error: command 'clang' failed with exit status 1
    
    ----------------------------------------
Command "/usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/m5/xjs7y13n2_s81sxlztjk1z7h0000gn/T/pip-install-gn6cymm9/velocyto/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/m5/xjs7y13n2_s81sxlztjk1z7h0000gn/T/pip-record-hpsa6hb2/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/m5/xjs7y13n2_s81sxlztjk1z7h0000gn/T/pip-install-gn6cymm9/velocyto/

I installed all dependencies using

conda install numpy scipy cython numba matplotlib scikit-learn h5py click

As well as pysam using pip and all seem to be installed correctly.

I can’t seem to find a solution in any of the other posts about installation errors.

Any help would be much appreciated.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:13

github_iconTop GitHub Comments

5reactions
AustinGutierrezcommented, Jun 4, 2019

I’m experiencing the same exact issue on macOS Mojave (10.14.5)

1reaction
cap76commented, Jun 23, 2019

Having the same problem. Running conda. Tried resolving based on similar problems elsewhere:

export CFLAGS=“-I /path/to/numpygetincl $CFLAGS”

where path/to/numpygetinc is found via numpy.get_include() in Python. Unfortunately this just kicks error down the road to:

Installing collected packages: velocyto Running setup.py install for velocyto … error Complete output from command /usr/local/opt/python/bin/python3.6 -u -c “import setuptools, tokenize;file=‘/private/var/folders/7c/cvkdt6yx031g81ncvhd2t56r0000gn/T/pip-install-pw_lg8bv/velocyto/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/7c/cvkdt6yx031g81ncvhd2t56r0000gn/T/pip-record-c5bls8cc/install-record.txt --single-version-externally-managed --compile: [‘-c’, ‘install’, ‘–record’, ‘/private/var/folders/7c/cvkdt6yx031g81ncvhd2t56r0000gn/T/pip-record-c5bls8cc/install-record.txt’, ‘–single-version-externally-managed’, ‘–compile’] running install running build running build_py creating build creating build/lib.macosx-10.13-x86_64-3.6 creating build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/transcript_model.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/diffusion.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/metadata.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/analysis.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/molitem.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/_version.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/neighbors.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/constants.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/estimation.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/init.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/feature.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/logic.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/indexes.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/utils.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/gene_info.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/r_interface.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/segment_match.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/counter.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/serialization.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto copying velocyto/read.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto creating build/lib.macosx-10.13-x86_64-3.6/velocyto/commands copying velocyto/commands/velocyto.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto/commands copying velocyto/commands/run.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto/commands copying velocyto/commands/init.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto/commands copying velocyto/commands/run_smartseq2.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto/commands copying velocyto/commands/dropest_bc_correct.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto/commands copying velocyto/commands/run_dropest.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto/commands copying velocyto/commands/run10x.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto/commands copying velocyto/commands/_run.py -> build/lib.macosx-10.13-x86_64-3.6/velocyto/commands running build_ext building ‘velocyto.speedboosted’ extension creating build/temp.macosx-10.13-x86_64-3.6 creating build/temp.macosx-10.13-x86_64-3.6/velocyto clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/include/python3.6m -c velocyto/speedboosted.c -o build/temp.macosx-10.13-x86_64-3.6/velocyto/speedboosted.o -fopenmp -ffast-math velocyto/speedboosted.c:633:10: fatal error: ‘numpy/arrayobject.h’ file not found #include “numpy/arrayobject.h” ^~~~~~~~~~~~~~~~~~~~~ 1 error generated. error: command ‘clang’ failed with exit status 1

Looks like a problem with compilers on latest version of Mac OS rather than a velocyto bug … but way beyond my expertise. If anyone else has resolved this come save us!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Pip install on Mac OS gets error: command '/usr/bin/clang ...
CompileError: command '/usr/bin/clang' failed with exit code 1 . The command I run: pip install google-cloud-pubsub==2.1.0 . Here the complete ...
Read more >
Mac error on pip install ends up being clang and xcode
error ERROR : Command errored out with exit status 1: command: /Users/mbbroberg/Develop/chaoss/venv/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[ ...
Read more >
Pip install on Mac OS gets error: command '/usr/bin ... - iTecNote
CompileError: command '/usr/bin/clang' failed with exit code 1 . The command I run: pip install google-cloud-pubsub==2.1.0 . Here the complete error message.
Read more >
MySQL error: command 'clang' failed with exit status 1 macOS ...
MySQL error: command 'clang' failed with exit status 1 macOS Mojave homebrew ... 2 errors generated. ... Problem is caused by the newer...
Read more >
How to fix Error: command '/usr/bin/clang' failed with exit code 1?
What causes this issue? · Outdated macOS version. · Outdated Python/Pip version. · Package availability on Pip. · Issues with the target package ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found