Skip to content

Commit

Permalink
add rfnm_source module to linux and MacOS CI
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexandreRouma committed Jul 16, 2024
1 parent 9ec78da commit 07744e5
Show file tree
Hide file tree
Showing 12 changed files with 109 additions and 13 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/build_all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,9 @@ jobs:
- name: Install libperseus
run: git clone https://github.com/Microtelecom/libperseus-sdr && cd libperseus-sdr && autoreconf -i && ./configure --prefix=/usr/local && make && make install && cd ..

- name: Install librfnm
run: git clone https://github.com/AlexandreRouma/librfnm && cd librfnm && mkdir build && cd build && cmake .. -DCMAKE_BUILD_TYPE=Release && make && make install && cd ..

- name: Install more recent librtlsdr
run: git clone https://github.com/osmocom/rtl-sdr && cd rtl-sdr && mkdir build && cd build && cmake -DCMAKE_OSX_DEPLOYMENT_TARGET=10.15 -DCMAKE_BUILD_TYPE=Release .. && make -j3 LIBRARY_PATH=$(pkg-config --libs-only-L libusb-1.0 | sed 's/\-L//') && sudo make install && cd ../../

Expand Down
11 changes: 10 additions & 1 deletion docker_builds/debian_bookworm/do_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ cd /root
apt update
apt install -y build-essential cmake git libfftw3-dev libglfw3-dev libvolk2-dev libzstd-dev libairspyhf-dev libairspy-dev \
libiio-dev libad9361-dev librtaudio-dev libhackrf-dev librtlsdr-dev libbladerf-dev liblimesuite-dev p7zip-full wget portaudio19-dev \
libcodec2-dev autoconf libtool xxd
libcodec2-dev autoconf libtool xxd libspdlog-dev

# Install SDRPlay libraries
wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.15.1.run
Expand All @@ -25,6 +25,15 @@ make install
ldconfig
cd ..

# Install librfnm
git clone https://github.com/AlexandreRouma/librfnm
cd librfnm
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make -j2
make install

cd SDRPlusPlus
mkdir build
cd build
Expand Down
11 changes: 10 additions & 1 deletion docker_builds/debian_bullseye/do_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ cd /root
apt update
apt install -y build-essential cmake git libfftw3-dev libglfw3-dev libvolk2-dev libzstd-dev libairspyhf-dev libairspy-dev \
libiio-dev libad9361-dev librtaudio-dev libhackrf-dev librtlsdr-dev libbladerf-dev liblimesuite-dev p7zip-full wget portaudio19-dev \
libcodec2-dev autoconf libtool xxd
libcodec2-dev autoconf libtool xxd libspdlog-dev

# Install SDRPlay libraries
wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.15.1.run
Expand All @@ -25,6 +25,15 @@ make install
ldconfig
cd ..

# Install librfnm
git clone https://github.com/AlexandreRouma/librfnm
cd librfnm
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make -j2
make install

cd SDRPlusPlus
mkdir build
cd build
Expand Down
11 changes: 10 additions & 1 deletion docker_builds/debian_buster/do_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ cd /root
apt update
apt install -y build-essential cmake git libfftw3-dev libglfw3-dev libvolk1-dev libzstd-dev libairspyhf-dev libairspy-dev \
libiio-dev libad9361-dev librtaudio-dev libhackrf-dev librtlsdr-dev libbladerf-dev liblimesuite-dev p7zip-full wget portaudio19-dev \
libcodec2-dev autoconf libtool xxd
libcodec2-dev autoconf libtool xxd libspdlog-dev

# Install SDRPlay libraries
wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.15.1.run
Expand All @@ -25,6 +25,15 @@ make install
ldconfig
cd ..

# Install librfnm
git clone https://github.com/AlexandreRouma/librfnm
cd librfnm
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make -j2
make install

cd SDRPlusPlus
mkdir build
cd build
Expand Down
11 changes: 10 additions & 1 deletion docker_builds/debian_sid/do_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ cd /root
apt update
apt install -y build-essential cmake git libfftw3-dev libglfw3-dev libvolk-dev libzstd-dev libairspyhf-dev libairspy-dev \
libiio-dev libad9361-dev librtaudio-dev libhackrf-dev librtlsdr-dev libbladerf-dev liblimesuite-dev p7zip-full wget portaudio19-dev \
libcodec2-dev autoconf libtool xxd
libcodec2-dev autoconf libtool xxd libspdlog-dev

# Install SDRPlay libraries
wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.15.1.run
Expand All @@ -25,6 +25,15 @@ make install
ldconfig
cd ..

# Install librfnm
git clone https://github.com/AlexandreRouma/librfnm
cd librfnm
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make -j2
make install

cd SDRPlusPlus
mkdir build
cd build
Expand Down
11 changes: 10 additions & 1 deletion docker_builds/ubuntu_bionic/do_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ apt update
# Install dependencies and tools
apt install -y build-essential cmake git libfftw3-dev libglfw3-dev libvolk1-dev libzstd-dev libairspy-dev \
libiio-dev libad9361-dev librtaudio-dev libhackrf-dev librtlsdr-dev libbladerf-dev liblimesuite-dev p7zip-full wget portaudio19-dev \
libcodec2-dev libudev-dev autoconf libtool xxd
libcodec2-dev libudev-dev autoconf libtool xxd libspdlog-dev

# Install SDRPlay libraries
wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.15.1.run
Expand Down Expand Up @@ -51,6 +51,15 @@ make install
ldconfig
cd ..

# Install librfnm
git clone https://github.com/AlexandreRouma/librfnm
cd librfnm
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make -j2
make install

# Fix missing .pc file for codec2
echo 'prefix=/usr/' >> /usr/share/pkgconfig/codec2.pc
echo 'libdir=/usr/include/x86_64-linux-gnu/' >> /usr/share/pkgconfig/codec2.pc
Expand Down
11 changes: 10 additions & 1 deletion docker_builds/ubuntu_focal/do_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ cd /root
apt update
apt install -y build-essential cmake git libfftw3-dev libglfw3-dev libvolk2-dev libzstd-dev libairspyhf-dev libairspy-dev \
libiio-dev libad9361-dev librtaudio-dev libhackrf-dev librtlsdr-dev libbladerf-dev liblimesuite-dev p7zip-full wget portaudio19-dev \
libcodec2-dev autoconf libtool xxd
libcodec2-dev autoconf libtool xxd libspdlog-dev

# Install SDRPlay libraries
wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.15.1.run
Expand All @@ -25,6 +25,15 @@ make install
ldconfig
cd ..

# Install librfnm
git clone https://github.com/AlexandreRouma/librfnm
cd librfnm
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make -j2
make install

cd SDRPlusPlus
mkdir build
cd build
Expand Down
11 changes: 10 additions & 1 deletion docker_builds/ubuntu_jammy/do_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ cd /root
apt update
apt install -y build-essential cmake git libfftw3-dev libglfw3-dev libvolk2-dev libzstd-dev libairspyhf-dev libairspy-dev \
libiio-dev libad9361-dev librtaudio-dev libhackrf-dev librtlsdr-dev libbladerf-dev liblimesuite-dev p7zip-full wget portaudio19-dev \
libcodec2-dev autoconf libtool xxd
libcodec2-dev autoconf libtool xxd libspdlog-dev

# Install SDRPlay libraries
wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.15.1.run
Expand All @@ -25,6 +25,15 @@ make install
ldconfig
cd ..

# Install librfnm
git clone https://github.com/AlexandreRouma/librfnm
cd librfnm
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make -j2
make install

cd SDRPlusPlus
mkdir build
cd build
Expand Down
11 changes: 10 additions & 1 deletion docker_builds/ubuntu_mantic/do_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ cd /root
apt update
apt install -y build-essential cmake git libfftw3-dev libglfw3-dev libvolk-dev libzstd-dev libairspyhf-dev libairspy-dev \
libiio-dev libad9361-dev librtaudio-dev libhackrf-dev librtlsdr-dev libbladerf-dev liblimesuite-dev p7zip-full wget portaudio19-dev \
libcodec2-dev autoconf libtool xxd
libcodec2-dev autoconf libtool xxd libspdlog-dev

# Install SDRPlay libraries
wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.15.1.run
Expand All @@ -25,6 +25,15 @@ make install
ldconfig
cd ..

# Install librfnm
git clone https://github.com/AlexandreRouma/librfnm
cd librfnm
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make -j2
make install

cd SDRPlusPlus
mkdir build
cd build
Expand Down
13 changes: 11 additions & 2 deletions docker_builds/ubuntu_noble/do_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ cd /root
apt update
apt install -y build-essential cmake git libfftw3-dev libglfw3-dev libvolk-dev libzstd-dev libairspyhf-dev libairspy-dev \
libiio-dev libad9361-dev librtaudio-dev libhackrf-dev librtlsdr-dev libbladerf-dev liblimesuite-dev p7zip-full wget portaudio19-dev \
libcodec2-dev autoconf libtool xxd
libcodec2-dev autoconf libtool xxd libspdlog-dev

# Install SDRPlay libraries
wget https://www.sdrplay.com/software/SDRplay_RSP_API-Linux-3.15.1.run
Expand All @@ -25,10 +25,19 @@ make install
ldconfig
cd ..

# Install librfnm
git clone https://github.com/AlexandreRouma/librfnm
cd librfnm
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make -j2
make install

cd SDRPlusPlus
mkdir build
cd build
cmake .. -DOPT_BUILD_BLADERF_SOURCE=ON -DOPT_BUILD_LIMESDR_SOURCE=ON -DOPT_BUILD_SDRPLAY_SOURCE=ON -DOPT_BUILD_NEW_PORTAUDIO_SINK=ON -DOPT_BUILD_M17_DECODER=ON -DOPT_BUILD_PERSEUS_SOURCE=ON
cmake .. -DOPT_BUILD_BLADERF_SOURCE=ON -DOPT_BUILD_LIMESDR_SOURCE=ON -DOPT_BUILD_SDRPLAY_SOURCE=ON -DOPT_BUILD_NEW_PORTAUDIO_SINK=ON -DOPT_BUILD_M17_DECODER=ON -DOPT_BUILD_PERSEUS_SOURCE=ON -DOPT_BUILD_RFNM_SOURCE=ON
make VERBOSE=1 -j2

cd ..
Expand Down
1 change: 1 addition & 0 deletions make_macos_bundle.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ bundle_install_binary $BUNDLE $BUNDLE/Contents/Plugins $BUILD_DIR/source_modules
bundle_install_binary $BUNDLE $BUNDLE/Contents/Plugins $BUILD_DIR/source_modules/limesdr_source/limesdr_source.dylib
bundle_install_binary $BUNDLE $BUNDLE/Contents/Plugins $BUILD_DIR/source_modules/perseus_source/perseus_source.dylib
bundle_install_binary $BUNDLE $BUNDLE/Contents/Plugins $BUILD_DIR/source_modules/plutosdr_source/plutosdr_source.dylib
bundle_install_binary $BUNDLE $BUNDLE/Contents/Plugins $BUILD_DIR/source_modules/rfnm_source/rfnm_source.dylib
bundle_install_binary $BUNDLE $BUNDLE/Contents/Plugins $BUILD_DIR/source_modules/rfspace_source/rfspace_source.dylib
bundle_install_binary $BUNDLE $BUNDLE/Contents/Plugins $BUILD_DIR/source_modules/rtl_sdr_source/rtl_sdr_source.dylib
bundle_install_binary $BUNDLE $BUNDLE/Contents/Plugins $BUILD_DIR/source_modules/rtl_tcp_source/rtl_tcp_source.dylib
Expand Down
17 changes: 14 additions & 3 deletions source_modules/rfnm_source/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,17 @@ file(GLOB SRC "src/*.cpp")

include(${SDRPP_MODULE_CMAKE})

target_include_directories(rfnm_source PRIVATE "C:/Program Files/RFNM/include")
target_link_directories(rfnm_source PRIVATE "C:/Program Files/RFNM/lib")
target_link_libraries(rfnm_source PRIVATE rfnm)
if (MSVC)
# Lib path
target_link_directories(rfnm_source PRIVATE "C:/Program Files/RFNM/lib/")
target_include_directories(rfnm_source PUBLIC "C:/Program Files/RFNM/include/")
target_link_libraries(rfnm_source PRIVATE rfnm)
else (MSVC)
find_package(PkgConfig)

pkg_check_modules(LIBRFNM REQUIRED librfnm)

target_include_directories(rfnm_source PRIVATE ${LIBRFNM_INCLUDE_DIRS})
target_link_directories(rfnm_source PRIVATE ${LIBRFNM_LIBRARY_DIRS})
target_link_libraries(rfnm_source PRIVATE ${LIBRFNM_LIBRARIES})
endif ()

0 comments on commit 07744e5

Please sign in to comment.