2021-03-15 08:37:03 +00:00
|
|
|
{ lib
|
|
|
|
, fetchFromGitHub
|
|
|
|
, cmake
|
|
|
|
, pkg-config
|
|
|
|
, qt5
|
|
|
|
, gnuradio3_8Minimal
|
|
|
|
, log4cpp
|
|
|
|
, mpir
|
|
|
|
, fftwFloat
|
|
|
|
, alsaLib
|
|
|
|
, libjack2
|
2020-04-24 23:36:52 +00:00
|
|
|
# drivers (optional):
|
2021-03-15 08:37:03 +00:00
|
|
|
, rtl-sdr
|
|
|
|
, hackrf
|
2020-04-24 23:36:52 +00:00
|
|
|
, pulseaudioSupport ? true, libpulseaudio
|
|
|
|
}:
|
|
|
|
|
|
|
|
assert pulseaudioSupport -> libpulseaudio != null;
|
|
|
|
|
2021-03-15 08:37:03 +00:00
|
|
|
gnuradio3_8Minimal.pkgs.mkDerivation rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "gqrx";
|
2021-02-05 17:12:51 +00:00
|
|
|
version = "2.14.4";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "csete";
|
|
|
|
repo = "gqrx";
|
|
|
|
rev = "v${version}";
|
2021-02-05 17:12:51 +00:00
|
|
|
sha256 = "sha256-mMaxu0jq2GaNLWjLsJQXx+zCxtyiCAZQJJZ8GJtnllQ=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-03-15 08:37:03 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
pkg-config
|
|
|
|
qt5.wrapQtAppsHook
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
buildInputs = [
|
2021-03-15 08:37:03 +00:00
|
|
|
log4cpp
|
|
|
|
mpir
|
|
|
|
fftwFloat
|
|
|
|
alsaLib
|
|
|
|
libjack2
|
|
|
|
gnuradio3_8Minimal.unwrapped.boost
|
|
|
|
qt5.qtbase
|
|
|
|
qt5.qtsvg
|
|
|
|
gnuradio3_8Minimal.pkgs.osmosdr
|
|
|
|
rtl-sdr
|
|
|
|
hackrf
|
2021-01-15 22:18:51 +00:00
|
|
|
] ++ lib.optionals pulseaudioSupport [ libpulseaudio ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
install -vD $src/gqrx.desktop -t "$out/share/applications/"
|
2020-12-25 13:55:36 +00:00
|
|
|
install -vD $src/resources/icons/gqrx.svg -t "$out/share/pixmaps/"
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Software defined radio (SDR) receiver";
|
|
|
|
longDescription = ''
|
|
|
|
Gqrx is a software defined radio receiver powered by GNU Radio and the Qt
|
|
|
|
GUI toolkit. It can process I/Q data from many types of input devices,
|
|
|
|
including Funcube Dongle Pro/Pro+, rtl-sdr, HackRF, and Universal
|
|
|
|
Software Radio Peripheral (USRP) devices.
|
|
|
|
'';
|
|
|
|
homepage = "https://gqrx.dk/";
|
|
|
|
# Some of the code comes from the Cutesdr project, with a BSD license, but
|
|
|
|
# it's currently unknown which version of the BSD license that is.
|
|
|
|
license = licenses.gpl3Plus;
|
|
|
|
platforms = platforms.linux; # should work on Darwin / macOS too
|
2020-05-15 21:57:56 +00:00
|
|
|
maintainers = with maintainers; [ bjornfor fpletz ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|