|
From: | James Hayek |
Subject: | iio Block Errors (WSL) Ubuntu 20.04 LTS |
Date: | Thu, 14 May 2020 08:07:39 -0400 |
After doing the steps outlined above, I ran into the following error.
· Traceback (most recent call last):
· File "/home/jameshayek/GNURadio-Projects/FMReceiver/Simple_FM_Receiver.py", line 35, in <module>
· from gnuradio.qtgui import Range, RangeWidget
· File "/usr/lib/python3/dist-packages/gnuradio/qtgui/__init__.py", line 36, in <module>
· from .qtgui_swig import *
· File "/usr/lib/python3/dist-packages/gnuradio/qtgui/qtgui_swig.py", line 13, in <module>
· from . import _qtgui_swig
· ImportError: libQt5Core.so.5: cannot open shared object file: No such file or directory
I assume this is an issue with mapping the location of swig, so copied the recursive directory to the gnuradio folder as the lesson said if there is a swig import error. Still no luck.
I also thought it was an issue with the qt5 library, so I ran "sudo apt-get install -y qt5-default"
But still no luck.
Is this an issue with Ubuntu 20?
My exact steps are shown below.
1. Moving Post-Install to Pre-Install:
o For Python 3.8 I initially exported the following location to $PYTHONPATH
§ export PYTHONPATH=$PYTHONPATH:/usr/lib/python{PYTHON VERSION}/{site or dist}-packages
· export PYTHONPATH=$PYTHONPATH:/usr/local/lib/python3.8/dist-packages/
o I used the python3.8 folder since GNC > About showed Python 3.8
o I then noticed I must have added the wrong PATH, because find resulted in: “/usr/lib/python3/dist-packages/gnuradio”
o I re-ran the “export” command to include what “find” returned.
2. Installing all “apt install” dependencies:
o sudo apt install libxml2 libxml2-dev bison flex cmake git libaio-dev libboost-all-dev
o sudo apt install liborc-dev
o sudo apt install swig
§ I was under the impression this was not needed for 3.8; however I did have it installed as a failsafe.
o sudo apt install bison flex cmake git libgmp-dev
o Other stuff that I didn’t need but installed anyway
§ sudo apt install libavahi-common-dev libavahi-client-dev
§ sudo apt install libusb-1.0-0-dev
§ sudo apt install doxygen
3. Building from source:
o libiio
§ git clone https://github.com/analogdevicesinc/libiio.git
§ cd libiio
§ cmake ./
§ make
§ sudo make install
§ cd ../
o libad9361-iio
§ git clone https://github.com/analogdevicesinc/libad9361-iio.git
§ cd libad9361-iio
§ cmake ./
§ make
§ sudo make install
§ cd ../
o gr-iio
§ git clone -b upgrade-3.8 https://github.com/analogdevicesinc/gr-iio.git
§ cd gr-iio
§ cmake ./
§ make
§ sudo make install
§ cd ../
§ sudo ldconfig
4. Because it seems like I have a swig import issue, I copied the directory to the gnuradio folder
o sudo cp -r /usr/local/lib/python3/dist-packages/iio/ /usr/lib/python3/dist-packages/gnuradio/
My $PYTHONPATH has the following locations:
[Prev in Thread] | Current Thread | [Next in Thread] |