YaK:: Building svxlink on Raspberry Pi [Changes]   [Calendar]   [Search]   [Index]   [PhotoTags]   
[mega_changes]
[photos]

Building svxlink on Raspberry Pi

Using a Pi4 and "Raspbian GNU/Linux 10 (buster)" on June 2, 2020.

Reading dependencies from here: https://github.com/sm0svx/svxlink/blob/master/INSTALL.adoc

I actually installed all of these, but repeated the command just to show you the versions:


# build tools:

root@raspberrypi:~# apt-get install g++ make cmake groff gzip doxygen tar git
cmake is already the newest version (3.13.4-1).
doxygen is already the newest version (1.8.13-10).
g++ is already the newest version (4:8.3.0-1+rpi2).
git is already the newest version (1:2.20.1-2+deb10u3).
groff is already the newest version (1.22.4-3).
gzip is already the newest version (1.9-3).
make is already the newest version (4.2.1-1.2).
tar is already the newest version (1.30+dfsg-6).

# third party libraries

root@raspberrypi:~# apt-get install libsigc++-2.0-dev libpopt-dev tcl-dev tcl-doc libgcrypt20-dev libasound2-dev libgsm1-dev libspeex-dev libqt4-dev
libgcrypt20-dev is already the newest version (1.8.4-5).
libgsm1-dev is already the newest version (1.0.18-2).
libpopt-dev is already the newest version (1.16-12).
libqt4-dev is already the newest version (4:4.8.7+dfsg-18+rpi1).
libsigc++-2.0-dev is already the newest version (2.10.1-2).
libspeex-dev is already the newest version (1.2~rc1.2-1+b2).
tcl-dev is already the newest version (8.6.9+1).
tcl-doc is already the newest version (8.6.9+1).
libasound2-dev is already the newest version (1.1.8-1+rpt1).

# Runtime Dependencies:

root@raspberrypi:~# apt-get install alsa-utils opus-tools
alsa-utils is already the newest version (1.1.8-2).
opus-tools is already the newest version (0.1.10-1).

# More libraries:

root@raspberrypi:~# apt-get install libjsoncpp-dev libcurl4-openssl-dev libopus-dev libopusfile-dev
libcurl4-openssl-dev is already the newest version (7.64.0-4+deb10u1).
libjsoncpp-dev is already the newest version (1.7.4-3).
libopus-dev is already the newest version (1.3-1).
libopusfile-dev is already the newest version (0.9+20170913-1).

# Set the Sticky Bit on /opt so we won't have to install as root:

root@raspberrypi:~# chmod 1777 /opt/

Create the svxlink user:

root@raspberrypi:~# useradd --create-home svxlink

Fetch the svxlink distribution and build it:

pi@raspberrypi:~ $ sudo su - svxlink
svxlink@raspberrypi:~ $
svxlink@raspberrypi:~ $ git clone https://github.com/sm0svx/svxlink.git
Cloning into 'svxlink'...
remote: Enumerating objects: 98, done.
remote: Counting objects: 100% (98/98), done.
remote: Compressing objects: 100% (70/70), done.
remote: Total 31969 (delta 44), reused 44 (delta 28), pack-reused 31871
Receiving objects: 100% (31969/31969), 8.90 MiB | 7.82 MiB/s, done.
Resolving deltas: 100% (23253/23253), done.
svxlink@raspberrypi:~ $
svxlink@raspberrypi:~ $ mkdir svxlink/src/build
svxlink@raspberrypi:~ $ cd svxlink/src/build
svxlink@raspberrypi:~/svxlink/src/build
$svxlink@raspberrypi:~/svxlink/src/build $ cmake -D'CMAKE_INSTALL_PREFIX=/opt/svxlink' -D'SYSCONF_INSTALL_DIR=/opt/svxlink/etc' -D'LOCAL_STATE_DIR=/opt/svxlink/var' -D'USE_QT=NO' ..
-- SvxLink user = svxlink
-- SvxLink group = svxlink
-- With Systemd = OFF
-- Could NOT find RtlSdr (missing: RTLSDR_LIBRARIES RTLSDR_INCLUDE_DIRS)
--   The rtl-sdr library is an optional dependency.
--   Direct USB access to RTL2832u DVB-T/SDR dongles will be
--   unavailable. Access through rtl_tcp will still work though.
-- Package Version = 19.09.1.145.g7c13f03b
-- Configuring done
-- Generating done
-- Build files have been written to: /home/svxlink/svxlink/src/build
svxlink@raspberrypi:~/svxlink/src/build $
svxlink@raspberrypi:~/svxlink/src/build $
svxlink@raspberrypi:~/svxlink/src/build $ make
...
...
...
svxlink@raspberrypi:~/svxlink/src/build $ make install
...
...
...
svxlink@raspberrypi:~/svxlink/src/build $

# Quick check that we have all the dynamic libraries:

svxlink@raspberrypi:~/svxlink/src/build $ LD_LIBRARY_PATH=/opt/svxlink/lib/  /opt/svxlink/bin/svxlink   -xyzzy
        -xyzzy: unknown option
svxlink@raspberrypi:~/svxlink/src/build $

Using yak- laptop and 2019-09-01 maint release:

strick@strick-glaptop:~/go/src/github.com/strickyak/svxlink-maint-2019-09-01/src/build$ cmake -DUSE_QT=NO -DBUILD_STATIC_LIBS=YES  ..
-- Reading versions file...
-- SvxLink user = svxlink
-- SvxLink group = svxlink
-- Could NOT find Opus (missing: Opus_LIBRARY Opus_INCLUDE_DIR)
--   Opus is an optional dependency. The build will complete
--   without it but support for the Opus audio codec will
--   be unavailable.
-- With Systemd = OFF
-- Could NOT find RtlSdr (missing: RTLSDR_LIBRARIES RTLSDR_INCLUDE_DIRS)
--   The rtl-sdr library is an optional dependency.
--   Direct USB access to RTL2832u DVB-T/SDR dongles will be
--   unavailable. Access through rtl_tcp will still work though.
-- Found CURL: /usr/include/x86_64-linux-gnu
-- Found Doxygen: /usr/bin/doxygen (found version "1.8.20") found components: doxygen missing components: dot
-- Found gzip: /usr/bin/gzip
-- Found groff: /usr/bin/groff
-- Package Version = 19.09
-- Configuring done
-- Generating done
-- Build files have been written to: /home/strick/go/src/github.com/strickyak/svxlink-maint-2019-09-01/src/build

$ make
pre)
(unless otherwise marked) Copyright 2002-2014 YakPeople. All rights reserved.
(last modified 2020-12-06)       [Login]
(No back references.)