}

MacOS: fatal error: 'numpy/arrayobject.h' file not found Solution

Created:

Error

fatal error: 'numpy/arrayobject.h' file not found

include "numpy/arrayobject.h"

^ 1 error generated. error: command 'clang' failed with exit status 1

if(typeof __ez_fad_position != 'undefined'){__ez_fad_position('div-gpt-ad-tutorials_technology-medrectangle-3-0')}; Solution ========

Before doing python setup.py install set the CFLAGS value to the following value:

export CFLAGS="-I /usr/local/lib/python2.7/site-packages/numpy/core/include $CFLAGS"

Then re-execute

python setup.py install

CFLAGS will tell gcc where the "numpy/arrayobject.h" is located.