discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Discuss-gnuradio] installing new modules


From: Affan Syed
Subject: [Discuss-gnuradio] installing new modules
Date: Thu, 11 Feb 2010 19:35:38 -0800

Hi,

I am trying to install new modules into my gnu radio tree. I have MAC OSX 10.5.5 but on a G4 PPC. Following instructions online that use MacPorts, I have been able to successfully run built-in scripts and verify that all required components of GNU radio are working. However, when compiling and running the example gr-how-to.... I ran into some interesting problems. First, looking at the output of the make install I see that the module gets installed in the /opt/local/Library/ Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/ gnuradio directory. When I try to run the simple qa_howto.py script it fails saying that module howto is no found. Looking at

bash-3.2$ echo $PYTHONPATH
/opt/local/lib/python2.6/site-packages:/usr/local/lib/python2.6/site- packages

I can solve the problem by moving the installed components under the / Frameworks/Python.framework/ tree to /usr/local/lib/python2.6/site- packages/, but that is a hacked up method that whenever I write my code or change it, I have to worry about copying before I am sure that the new module is what is going to be used.

So I edited, what I think is the appropriate portion of my ./bashrc file as follows


export PYTHON_VERSION=`python -V 2>&1 | sed -e 'address@hidden@ @2' | awk '{ print $2 }'`
export PYTHON_ROOT=`which python | sed -e 's@/bin/python@@g'`
export PYTHONPATH=${PYTHON_ROOT}/lib/python${PYTHON_VERSION}/site- packages
if [ ${PYTHON_ROOT} != "/usr/include" ]; then
export PYTHONPATH=${PYTHONPATH}:/usr/local/lib/python$ {PYTHON_VERSION}/site-packages
fi
export PYTHONPATH=${PYTHONPATH}:/opt/local/Library/Frameworks/ Python.framework/Versions/2.6/lib/python2.6/site-packages <--- added by me.

However, even this doesnt help if I do a new make install (and now the $PYTHONPATH includes the directory with the installed files).

So I searched on the gnu radio mailing list, and it appears it has something to do with multiple versions of python installed. I know that I had previous installed python and so when I do a which python

bash-3.2$ which python
/opt/local/bin/python


and my $PATH variable is not pointing to where the Macport has installed python2.6.

echo $PATH
/opt/local/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/X11R6/ bin


What do I have to change (in the configure files or at a larger scale on my system) to make sure my make install puts the new module in the same place the GNU radio is looking at?

Thank you.

regards,
Affan






reply via email to

[Prev in Thread] Current Thread [Next in Thread]