-
Notifications
You must be signed in to change notification settings - Fork 29
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
Fails to compile on Mac OS X, can't find a numpy header file #11
Comments
This answers issue 11 and updates issue 7 This may be more than what you asked for originally, but I thought it may be good for you to be aware of everything I experienced after the initial answer of compilation errors Methods taken to compile on Linux 16.04: Installed via clone instructions in tutorial http://kartikpatel.in/GSoC2017/tutorial/ Placed repo in the “include” directory of my pybombs prefix (not sure if that’s a good place, but it’s worth mentioning in case it matters) mkdir build -Start of custom fixes- Had to change CMakeLists.txt locally by adding the following to the “include directories” section: ${GNURADIO_ALL_INCLUDE_DIRS}/gnuradio/swig Note !: Despite “arrayobject.h” being one directory deeper, the compiler looks for numpy/arrayobject.h so be sure not to go too far in the path name. cmake ../ make At this point gr-bokehgui should be able to completely make and make install, below are instructions to help it function in gnuradio. Updated gnuradio to latest version in github : cd mypybombsprefix/src/gnuradio/ also try ./pybombs update (found in /usr/local/bin ) if possible because it is more thorough in how it updates. Either create ~/.gnuradio/config.conf or sudo vim ~/prefix/etc/gnuradio/conf.d/grc.conf Insert : Install bokeh at the 0.12.6 version (gr-bokehgui is currently using deprecated numpy methods, thus why it’s necessary for this specific version) Via pip (conda instructions are both in the tutorial and bokeh page) : pip install bokeh==0.12.6 Install node, bokeh-node.js sudo apt install node Note ! : If testing functionality using tutorial or test flowgraphs given, gnuradio-companion may throw an error about the server connection. I found this is fixed by moving one of the blocks, pressing the generate button, and then pressing the green play button. To double check if server process actually got killed after ending flowgraph in gnuradio : sudo lsof -i:Port# |
@brjwebb Thanks for the reply. It seems you found a too complex workaround. For other details and suggestions for the tutorial, can you please add the separate issues? It will help me to identify exact points that I should mention. @MattEttus This is a typical numpy issue. Can you check
One workaround to this is to add a link to the global include directory which points to the real numpy include directory (output of this snippet). For example, you can check: andersbll/cudarray#25 (comment) Let me know the updates. |
When building on Mac OS X, the build system fails to find a numpy header:
[ 73%] Building CXX object swig/CMakeFiles/_bokehgui_swig.dir/bokehgui_swigPYTHON_wrap.cxx.o
/Users/mettus/gr-bokehgui/build/swig/bokehgui_swigPYTHON_wrap.cxx:4421:10: fatal error:
'numpy/arrayobject.h' file not found
#include <numpy/arrayobject.h>
^~~~~~~~~~~~~~~~~~~~~
1 error generated.
make[2]: *** [swig/CMakeFiles/_bokehgui_swig.dir/bokehgui_swigPYTHON_wrap.cxx.o] Error 1
make[1]: *** [swig/CMakeFiles/_bokehgui_swig.dir/all] Error 2
make: *** [all] Error 2
The actual location is /usr/local/lib/python2.7/site-packages/numpy/core/include but cmake isn't adding that to the compiler search path for some reason.
The text was updated successfully, but these errors were encountered: