From 8ddbd146f51d30ab569011c0155da42e50cec9de Mon Sep 17 00:00:00 2001 From: Luigi Cruz Date: Wed, 11 Nov 2020 23:58:21 -0300 Subject: [PATCH] Add airband and limesdr toolbox support --- .../stage4/26-pisdr-limesdr-toolbox/00-run.sh | 19 +++++++++++++++++++ .../stage4/27-pisdr-airband/00-packages-nr | 4 ++++ builder/stage4/27-pisdr-airband/00-run.sh | 16 ++++++++++++++++ builder/stage4/35-pisdr-cleanup/00-run.sh | 5 +++++ .../00-run.sh => 35-pisdr-cleanup/01-run.sh} | 0 5 files changed, 44 insertions(+) create mode 100755 builder/stage4/26-pisdr-limesdr-toolbox/00-run.sh create mode 100644 builder/stage4/27-pisdr-airband/00-packages-nr create mode 100755 builder/stage4/27-pisdr-airband/00-run.sh create mode 100755 builder/stage4/35-pisdr-cleanup/00-run.sh rename builder/stage4/{26-pisdr-udev/00-run.sh => 35-pisdr-cleanup/01-run.sh} (100%) diff --git a/builder/stage4/26-pisdr-limesdr-toolbox/00-run.sh b/builder/stage4/26-pisdr-limesdr-toolbox/00-run.sh new file mode 100755 index 0000000..11d53a1 --- /dev/null +++ b/builder/stage4/26-pisdr-limesdr-toolbox/00-run.sh @@ -0,0 +1,19 @@ +#!/bin/bash -e + +on_chroot << EOF +mkdir -p "/home/${FIRST_USER_NAME}/PiSDR/Software" +cd "/home/${FIRST_USER_NAME}/PiSDR/Software" + +if [ ! -d "limesdr_toolbox" ]; then + git clone https://github.com/luigifcruz/limesdr_toolbox.git +fi + +cd limesdr_toolbox +mkdir -p build +cd build +cmake -GNinja .. +ninja install +ldconfig +cd .. +rm -fr build +EOF \ No newline at end of file diff --git a/builder/stage4/27-pisdr-airband/00-packages-nr b/builder/stage4/27-pisdr-airband/00-packages-nr new file mode 100644 index 0000000..3faf9d6 --- /dev/null +++ b/builder/stage4/27-pisdr-airband/00-packages-nr @@ -0,0 +1,4 @@ +libmp3lame-dev +libshout3-dev +libconfig++-dev +libraspberrypi-dev diff --git a/builder/stage4/27-pisdr-airband/00-run.sh b/builder/stage4/27-pisdr-airband/00-run.sh new file mode 100755 index 0000000..39944e5 --- /dev/null +++ b/builder/stage4/27-pisdr-airband/00-run.sh @@ -0,0 +1,16 @@ +#!/bin/bash -e + +on_chroot << EOF +mkdir -p "/home/${FIRST_USER_NAME}/PiSDR/Software" +cd "/home/${FIRST_USER_NAME}/PiSDR/Software" + +if [ ! -d "RTLSDR-Airband" ]; then + git clone https://github.com/szpajder/RTLSDR-Airband.git +fi + +cd RTLSDR-Airband +export PLATFORM=armv7-generic +export WITH_SOAPYSDR=1 +make install +ldconfig +EOF \ No newline at end of file diff --git a/builder/stage4/35-pisdr-cleanup/00-run.sh b/builder/stage4/35-pisdr-cleanup/00-run.sh new file mode 100755 index 0000000..08af436 --- /dev/null +++ b/builder/stage4/35-pisdr-cleanup/00-run.sh @@ -0,0 +1,5 @@ +#!/bin/bash -e + +on_chroot << EOF +sudo ln -s /usr/local/lib/python3/dist-packages/* /usr/lib/python3/dist-packages || true +EOF \ No newline at end of file diff --git a/builder/stage4/26-pisdr-udev/00-run.sh b/builder/stage4/35-pisdr-cleanup/01-run.sh similarity index 100% rename from builder/stage4/26-pisdr-udev/00-run.sh rename to builder/stage4/35-pisdr-cleanup/01-run.sh