nixpkgs-suyu/pkgs/applications/radio/gnuradio/rds.nix
Doron Behar ed44b466e6 treewide/(gnuradio plugins): Add log4cpp as it's needed now.
Since gnuradio-runtime is compiled with log4cpp, all plugins that need
gnuradio-runtime (which is all of them probably) need log4cpp as well.

Add python.pkgs.cheetah to inputs of gr-osmosdr as it somehow started to
be needed.
2020-12-05 13:23:00 +02:00

38 lines
1 KiB
Nix

{ stdenv, fetchFromGitHub, cmake, pkgconfig, boost, gnuradio, log4cpp
, makeWrapper, pythonSupport ? true, python, swig
}:
assert pythonSupport -> python != null && swig != null;
stdenv.mkDerivation rec {
pname = "gr-rds";
version = "1.1.0";
src = fetchFromGitHub {
owner = "bastibl";
repo = "gr-rds";
rev = "v${version}";
sha256 = "0jkzchvw0ivcxsjhi1h0mf7k13araxf5m4wi5v9xdgqxvipjzqfy";
};
nativeBuildInputs = [ pkgconfig ];
buildInputs = [
cmake boost gnuradio makeWrapper log4cpp
] ++ stdenv.lib.optionals pythonSupport [ python swig ];
postInstall = ''
for prog in "$out"/bin/*; do
wrapProgram "$prog" --set PYTHONPATH $PYTHONPATH:$(toPythonPath "$out")
done
'';
enableParallelBuilding = true;
meta = with stdenv.lib; {
description = "Gnuradio block for radio data system";
homepage = "https://github.com/bastibl/gr-rds";
license = licenses.gpl2Plus;
platforms = platforms.linux ++ platforms.darwin;
maintainers = with maintainers; [ mog ];
};
}