Hi all,
I am working with gnuradio and usrps on an ubuntu 20.04
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.4 LTS
Release: 20.04
Codename: focal
I usually update my uhd libraries from ettus binaries as described here:
https://files.ettus.com/manual/page_install.html
$ sudo add-apt-repository ppa:ettusresearch/uhd
$ sudo apt-get update
$ sudo apt-get install libuhd-dev libuhd4.1.0 uhd-host
Then I usually build gnuradio from source (I am currently in v3.8).
I DO NOT install gnuradio from repositories!
Today I tried to update the uhd libraries.
First I cleaned up all previous versions:
$ sudo apt-get remove libuhd-dev libuhd4.1.0 uhd-host
$ sudo apt autoremove
$ ldconfig -p | grep uhd
libgnuradio-uhd.so.3.8.5git (libc6,x86-64) =>
/usr/local/lib/libgnuradio-uhd.so.3.8.5git
libgnuradio-uhd.so.3.8.4 (libc6,x86-64) =>
/usr/local/lib/libgnuradio-uhd.so.3.8.4
libgnuradio-uhd.so.3.8.3git (libc6,x86-64) =>
/usr/local/lib/libgnuradio-uhd.so.3.8.3git
libgnuradio-uhd.so (libc6,x86-64) =>
/usr/local/lib/libgnuradio-uhd.so
Then I tried to install the uhd libraries:
$ sudo add-apt-repository -y ppa:ettusresearch/uhd
Hit:1 http://dl.google.com/linux/chrome/deb stable InRelease
Hit:2 http://us.archive.ubuntu.com/ubuntu focal InRelease
Hit:3 http://us.archive.ubuntu.com/ubuntu focal-updates InRelease
Hit:4 http://us.archive.ubuntu.com/ubuntu focal-backports InRelease
Hit:5 http://ppa.launchpad.net/ettusresearch/uhd/ubuntu focal InRelease
Get:6 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Fetched 114 kB in 1s (118 kB/s)
Reading package lists... Done
$ sudo apt-get update
Hit:1 http://dl.google.com/linux/chrome/deb stable InRelease
Hit:2 http://us.archive.ubuntu.com/ubuntu focal InRelease
Hit:3 http://us.archive.ubuntu.com/ubuntu focal-updates InRelease
Hit:4 http://us.archive.ubuntu.com/ubuntu focal-backports InRelease
Hit:5 http://ppa.launchpad.net/ettusresearch/uhd/ubuntu focal InRelease
Get:6 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Fetched 114 kB in 1s (174 kB/s)
Reading package lists... Done
$ sudo apt-get install libuhd4.1.0
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
gnuradio
The following NEW packages will be installed:
libuhd4.1.0
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/3,375 kB of archives.
After this operation, 14.6 MB of additional disk space will be used.
Selecting previously unselected package libuhd4.1.0:amd64.
(Reading database ... 269419 files and directories currently installed.)
Preparing to unpack .../libuhd4.1.0_4.1.0.4-0ubuntu1~focal1_amd64.deb ...
Unpacking libuhd4.1.0:amd64 (4.1.0.4-0ubuntu1~focal1) ...
Setting up libuhd4.1.0:amd64 (4.1.0.4-0ubuntu1~focal1) ...
Processing triggers for libc-bin (2.31-0ubuntu9.9) ...
Now I am trying to install the "uhd-host" library:
$ sudo apt-get install uhd-host
Reading package lists... Done
Building dependency tree
Reading state information... Done
*The following additional packages will be installed:
libuhd4.2.0 python3-ruamel.yaml*
Suggested packages:
gnuradio
The following NEW packages will be installed:
libuhd4.2.0 python3-ruamel.yaml uhd-host
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/7,502 kB of archives.
After this operation, 41.0 MB of additional disk space will be used.
Do you want to continue? [Y/n]
*******I do not understand why it asks to install also the
libuhd4.2.0 library.
If I do that, then I get the following errors:
Y
Selecting previously unselected package libuhd4.2.0:amd64.
(Reading database ... 269464 files and directories currently installed.)
Preparing to unpack .../libuhd4.2.0_4.2.0.0-0ubuntu1~focal1_amd64.deb ...
Unpacking libuhd4.2.0:amd64 (4.2.0.0-0ubuntu1~focal1) ...
dpkg: error processing archive
/var/cache/apt/archives/libuhd4.2.0_4.2.0.0-0ubuntu1~focal1_amd64.deb
(--unpack):
trying to overwrite '/usr/share/uhd/cal/cal_metadata.fbs', which is
also in package libuhd4.1.0:amd64 4.1.0.4-0ubuntu1~focal1
Selecting previously unselected package python3-ruamel.yaml.
Preparing to unpack .../python3-ruamel.yaml_0.15.89-3build1_amd64.deb ...
Unpacking python3-ruamel.yaml (0.15.89-3build1) ...
Selecting previously unselected package uhd-host.
Preparing to unpack .../uhd-host_4.2.0.0-0ubuntu1~focal1_amd64.deb ...
Unpacking uhd-host (4.2.0.0-0ubuntu1~focal1) ...
Errors were encountered while processing:
/var/cache/apt/archives/libuhd4.2.0_4.2.0.0-0ubuntu1~focal1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Alternatively if I try to remove "libuhd4.1.0" and install the latest
"libuhd4.2.0"
$ sudo apt remove libuhd4.1.0
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
libuhd4.1.0
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
After this operation, 14.6 MB disk space will be freed.
Do you want to continue? [Y/n] Y
(Reading database ... 269464 files and directories currently installed.)
Removing libuhd4.1.0:amd64 (4.1.0.4-0ubuntu1~focal1) ...
dpkg: warning: while removing libuhd4.1.0:amd64, directory
'/usr/share/uhd' not empty so not removed
Processing triggers for libc-bin (2.31-0ubuntu9.9) ...
$ sudo apt autoremove
$ sudo apt install libuhd4.2.0
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
gnuradio
The following NEW packages will be installed:
libuhd4.2.0
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/3,453 kB of archives.
After this operation, 15.0 MB of additional disk space will be used.
(Reading database ... 269419 files and directories currently installed.)
Preparing to unpack .../libuhd4.2.0_4.2.0.0-0ubuntu1~focal1_amd64.deb ...
Unpacking libuhd4.2.0:amd64 (4.2.0.0-0ubuntu1~focal1) ...
Setting up libuhd4.2.0:amd64 (4.2.0.0-0ubuntu1~focal1) ...
Processing triggers for libc-bin (2.31-0ubuntu9.9) ...
Now I can easily install the "uhd-host" library
$ sudo apt install uhd-host
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
python3-ruamel.yaml
Suggested packages:
gnuradio
The following NEW packages will be installed:
python3-ruamel.yaml uhd-host
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/4,049 kB of archives.
After this operation, 26.0 MB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Selecting previously unselected package python3-ruamel.yaml.
(Reading database ... 269460 files and directories currently installed.)
Preparing to unpack .../python3-ruamel.yaml_0.15.89-3build1_amd64.deb ...
Unpacking python3-ruamel.yaml (0.15.89-3build1) ...
Selecting previously unselected package uhd-host.
Preparing to unpack .../uhd-host_4.2.0.0-0ubuntu1~focal1_amd64.deb ...
Unpacking uhd-host (4.2.0.0-0ubuntu1~focal1) ...
Setting up python3-ruamel.yaml (0.15.89-3build1) ...
Setting up uhd-host (4.2.0.0-0ubuntu1~focal1) ...
sysctl: cannot open "/etc/sysctl.d/uhd-usrp2.conf": No such file or
directory
Warning: Could not update sysctl settings for network devices.
Processing triggers for man-db (2.9.1-1) ...
I check that everything works with uhd:
$ uhd_find_devices
[INFO] [UHD] linux; GNU C++ version 9.4.0; Boost_107100;
UHD_4.2.0.0-0ubuntu1~focal1
--------------------------------------------------
-- UHD Device 0
--------------------------------------------------
Device Address:
serial: 315C6B2
addr: 192.168.40.2
fpga: HG
name:
product: X310
type: x300
BUT, when I try to install the "libuhd-dev" library I get the
following which
I suspect wants to install the entire gnuradio system from the
repository, which as I said in the beginning I do not want, since I am
usually building it from source.
$ sudo apt-get install libuhd-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
freeglut3 gnuradio gnuradio-dev libgnuradio-analog3.8.1
libgnuradio-audio3.8.1 libgnuradio-blocks3.8.1
libgnuradio-channels3.8.1 libgnuradio-digital3.8.1
libgnuradio-dtv3.8.1 libgnuradio-fec3.8.1
libgnuradio-fft3.8.1 libgnuradio-filter3.8.1 libgnuradio-pmt3.8.1
libgnuradio-qtgui3.8.1
libgnuradio-runtime3.8.1 libgnuradio-trellis3.8.1
libgnuradio-uhd3.8.1 libgnuradio-video-sdl3.8.1
libgnuradio-vocoder3.8.1 libgnuradio-wavelet3.8.1
libgnuradio-zeromq3.8.1 libjs-jquery-ui librtlsdr0
libuhd3.15.0 libvolk2-bin libvolk2-dev libvolk2.2
python-matplotlib-data python3-cycler python3-kiwisolver
python3-matplotlib python3-networkx python3-opengl
python3-pyqt5.qtopengl python3-pyqtgraph rtl-sdr
Suggested packages:
gr-fosphor gr-osmosdr libjs-jquery-ui-docs uhd-doc libvolk2-doc
python-cycler-doc dvipng ffmpeg inkscape
ipython3 python-matplotlib-doc python3-cairocffi python3-gobject
python3-nose python3-tornado
texlive-extra-utils texlive-latex-extra ttf-staypuft
python-networkx-doc python3-gdal python3-pygraphviz
| python3-pydot libgle3 python-pyqtgraph-doc
Recommended packages:
python3-qwt-qt5
The following NEW packages will be installed:
freeglut3 gnuradio gnuradio-dev libgnuradio-analog3.8.1
libgnuradio-audio3.8.1 libgnuradio-blocks3.8.1
libgnuradio-channels3.8.1 libgnuradio-digital3.8.1
libgnuradio-dtv3.8.1 libgnuradio-fec3.8.1
libgnuradio-fft3.8.1 libgnuradio-filter3.8.1 libgnuradio-pmt3.8.1
libgnuradio-qtgui3.8.1
libgnuradio-runtime3.8.1 libgnuradio-trellis3.8.1
libgnuradio-uhd3.8.1 libgnuradio-video-sdl3.8.1
libgnuradio-vocoder3.8.1 libgnuradio-wavelet3.8.1
libgnuradio-zeromq3.8.1 libjs-jquery-ui librtlsdr0
libuhd-dev libuhd3.15.0 libvolk2-bin libvolk2-dev libvolk2.2
python-matplotlib-data python3-cycler
python3-kiwisolver python3-matplotlib python3-networkx
python3-opengl python3-pyqt5.qtopengl
python3-pyqtgraph rtl-sdr
0 upgraded, 37 newly installed, 0 to remove and 0 not upgraded.
Need to get 138 MB of archives.
After this operation, 493 MB of additional disk space will be used.
Do you want to continue? [Y/n]
Can anyone help with this?
I want to just update my uhd to the latest version from ETTUS
repositories and then build gnuradio from source as I used to do.
thanks in advance,
Achilleas