Hi Jim - Great to hear from another OS X GNU Radio user!
 
The issue is likely that MacPorts' 'python' expects its packages to be
installed into /opt/local somewhere, not /usr/local . I sure there's a
way to set various environment variables to find the installed files,
but it's easier to just install them where MacPorts' Python and Apple's
library loader (DYLD) will look for them.
 
Here's what I would recommend *** all from your OOT's build
directory ***:
 
1) "make uninstall" (sudo or not as needed); hopefully this step will
   remove everything from /usr/local that it installed. If not, I'd
   highly recommend removing it by hand.
 
2) if the build directory is separate from the source directory (as we
   recommend), then "rm -rf *". If they are the same, then do "make
   clean" or "make distclean" to remove the build cruft. You do,
   unfortunately, need to start with a clean CMake build.
 
3) Follow the instructions from <
   
http://gnuradio.org/redmine/projects/gnuradio/wiki/MacInstall#Compiling-GNU-Radio-from-Source
   >, but add in to the CMake command line "-
   DCMAKE_INSTALL_PREFIX=/opt/local" (as described towards the end of
   that section in the paragraph starting "By default ..."). You can
   choose some other compiler via changing the "CC=... CXX=..." parts;
   or, just omit them entirely to use the defaults provided by Xcode.
 
3.1) "make"
3.2) "make test"
 
4) "sudo make install" to get your OOT installed into /opt/local ...
   you'll need the "sudo" because you're installing into the normal
   MacPorts area, which by default is owned by "root". If you look
   through where files are installed, they should be into:
 
/opt/local/bin/
/opt/local/lib/
/opt/local/share/gnuradio/
/opt/local/share/cmake/
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2-
.7/site-packages/
 
... and, if not, then I/we need to work on fixing  options to work more
robustly (at least for OS X).
 
Hope this helps! - MLD
 
On Mon, Apr 25, 2016, at 06:22 AM, jim Schimpf wrote:
> I have installed GnuRadio via “port” on OS X 10.11.4 and it runs with
> my RTL dongle.  I am working through the GnuRadio Tutorials and am on
> this one
> (http://gnuradio.org/redmine/projects/gnuradio/wiki/Guided_Tutorial_GNU_Radio_in_Python)
> building new blocks. I have followed the tutorial, building the
> multiply_py_ff block and run it directly in Python which works.  When
> I try to build it so gnuradio-companion can use it all the steps work
> except for the last “sudo ldconfig” as ”ldconfig” is not present. in
> OS X  The block does not appear in the list of available blocks when I
> run gnuradio-companion.
>
> The "make install" ran OK and put things in the right places. How do I
> fix this so the new block appears in gnuradio-companion ?  I searched
> the group and didn’t find a reference to this particular problem.
>
> The make install did write the XML to the block directory that gnuradio-
> companion uses:
>
> -------------------------------
> -- Installing:
> /usr/local/share/gnuradio/grc/blocks/tutorial_multiply_py_ff.xml
>
> Startup of gnuradio-companion
>
> Preferences file: /Users/jim/.gnuradio/grc.conf
> Block paths:
>  /opt/local/share/gnuradio/grc/blocks
>  /Users/jim/.grc_gnuradio
> -------------------------------
>
> Thank you for the help.
>
> Also I am using PyCharm as my Python IDE and found to use it on my
> install of GnuRadio I created a new project and set the Python
> interpreter to /opt/local/bin/python2.7. it then works just fine with
> the GnuRadio python code.
 
_______________________________________________
Discuss-gnuradio mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Reply via email to