Install error on MacOSx

installation

#1

Hi,

I am very new to nupic and want to try it out. I am trying to install nupic on my Mac using: pip install nupic. Below is my error message, can you please help to see why is this and how I can install it successfully?

Compiling capnp/lib/capnp.pyx because it changed.
[1/1] Cythonizing capnp/lib/capnp.pyx
running install
running build
running build_py
creating build/lib.macosx-10.7-x86_64-2.7
creating build/lib.macosx-10.7-x86_64-2.7/capnp
copying capnp/init.py -> build/lib.macosx-10.7-x86_64-2.7/capnp
copying capnp/_gen.py -> build/lib.macosx-10.7-x86_64-2.7/capnp
copying capnp/version.py -> build/lib.macosx-10.7-x86_64-2.7/capnp
copying capnp/init.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp
copying capnp/c++.capnp -> build/lib.macosx-10.7-x86_64-2.7/capnp
copying capnp/schema.capnp -> build/lib.macosx-10.7-x86_64-2.7/capnp
creating build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
copying capnp/helpers/init.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
copying capnp/helpers/helpers.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
copying capnp/helpers/non_circular.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
copying capnp/helpers/asyncHelper.h -> build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
copying capnp/helpers/capabilityHelper.h -> build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
copying capnp/helpers/checkCompiler.h -> build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
copying capnp/helpers/fixMaybe.h -> build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
copying capnp/helpers/rpcHelper.h -> build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
copying capnp/helpers/serialize.h -> build/lib.macosx-10.7-x86_64-2.7/capnp/helpers
creating build/lib.macosx-10.7-x86_64-2.7/capnp/includes
copying capnp/includes/init.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp/includes
copying capnp/includes/capnp_cpp.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp/includes
copying capnp/includes/schema_cpp.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp/includes
copying capnp/includes/types.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp/includes
creating build/lib.macosx-10.7-x86_64-2.7/capnp/lib
copying capnp/lib/init.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp/lib
copying capnp/lib/capnp.pxd -> build/lib.macosx-10.7-x86_64-2.7/capnp/lib
copying capnp/lib/init.py -> build/lib.macosx-10.7-x86_64-2.7/capnp/lib
copying capnp/lib/pickle_helper.py -> build/lib.macosx-10.7-x86_64-2.7/capnp/lib
copying capnp/lib/capnp.pyx -> build/lib.macosx-10.7-x86_64-2.7/capnp/lib
creating build/lib.macosx-10.7-x86_64-2.7/capnp/templates
copying capnp/templates/module.pyx -> build/lib.macosx-10.7-x86_64-2.7/capnp/templates
copying capnp/templates/setup.py.tmpl -> build/lib.macosx-10.7-x86_64-2.7/capnp/templates
running build_ext
creating var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/tmpbX0QMv
gcc -fno-strict-aliasing -I/anaconda/include -arch x86_64 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -c /var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/tmpbX0QMv/vers.cpp -o var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/tmpbX0QMv/vers.o --std=c++11
/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/tmpbX0QMv/vers.cpp:4:10: fatal error: ‘capnp/common.h’ file not found
#include “capnp/common.h”
^
1 error generated.
WARNING no libcapnp detected or rebuild forced. Will download and build it from source now. If you have C++ Cap’n Proto installed, it may be out of date or is not being detected. Downloading and building libcapnp may take a while.
already have /private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/bundled/capnproto-c++
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: /private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/lib/libkj.a(units.o) has no symbols
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: /private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/lib/libcapnp.a(list.o) has no symbols
building ‘capnp.lib.capnp’ extension
creating build/temp.macosx-10.7-x86_64-2.7
creating build/temp.macosx-10.7-x86_64-2.7/capnp
creating build/temp.macosx-10.7-x86_64-2.7/capnp/lib
gcc -fno-strict-aliasing -I/anaconda/include -arch x86_64 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I. -I/anaconda/include/python2.7 -I/private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/include -c capnp/lib/capnp.cpp -o build/temp.macosx-10.7-x86_64-2.7/capnp/lib/capnp.o --std=c++11
In file included from capnp/lib/capnp.cpp:476:
./capnp/helpers/checkCompiler.h:4:8: warning: “Your compiler supports C++11 but your C++ standard library does not. If your system has libc++ installed (as should be the case on e.g. Mac OSX), try adding -stdlib=libc++ to your CFLAGS (ignore the other warning that says to use CXXFLAGS).” [-W#warnings]
#warning “Your compiler supports C++11 but your C++ standard library does not. If your system has libc++ installed (as should be the case on e.g. Mac OSX), try adding -stdlib=libc++ to your CFLAGS (ignore the other warning that says to use CXXFLAGS).”
^
In file included from capnp/lib/capnp.cpp:476:
In file included from ./capnp/helpers/checkCompiler.h:9:
In file included from /private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/include/capnp/dynamic.h:40:
In file included from /private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/include/capnp/schema.h:33:
In file included from /private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/include/capnp/schema.capnp.h:7:
In file included from /private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/include/capnp/generated-header-support.h:31:
In file included from /private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/include/capnp/layout.h:36:
/private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/include/kj/common.h:54:8: warning: "Your compiler supports C++11 but your C++ standard library does not. If your " "system has libc++ installed (as should be the case on e.g. Mac OSX), try adding " “-stdlib=libc++ to your CXXFLAGS.” [-W#warnings]
#warning "Your compiler supports C++11 but your C++ standard library does not. If your "
^
/private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/build/include/kj/common.h:78:10: fatal error: ‘initializer_list’ file not found
#include <initializer_list>
^
2 warnings and 1 error generated.
error: command ‘gcc’ failed with exit status 1

----------------------------------------

Command “/anaconda/bin/python -u -c “import setuptools, tokenize;file=’/private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/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/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-8uW_gG-record/install-record.txt --single-version-externally-managed --compile” failed with error code 1 in /private/var/folders/d1/5827czq16bsc_232k6_b39f5m4n08x/T/pip-build-IqcKrh/pycapnp/

Thanks a lot!


#2

Please be sure you have installed the C++ 11 standard library.