diff options
author | Eduardo Sánchez Muñoz <esm@eduardosm.net> | 2021-04-03 14:47:43 +0200 |
---|---|---|
committer | Eduardo Sánchez Muñoz <esm@eduardosm.net> | 2021-04-03 14:47:43 +0200 |
commit | 6242f38c3058f5a9136b357d0fa0598c18bd5cae (patch) | |
tree | 2142137d670b25f7d00d57b0fd1f55f4b829f7b9 /pkgs/applications/radio | |
parent | 24abc4bfc475e100bc4c1cc5120474ff7050e124 (diff) |
gnuradio: enable gr-vocoder
Diffstat (limited to 'pkgs/applications/radio')
-rw-r--r-- | pkgs/applications/radio/gnuradio/default.nix | 26 |
1 files changed, 20 insertions, 6 deletions
diff --git a/pkgs/applications/radio/gnuradio/default.nix b/pkgs/applications/radio/gnuradio/default.nix index 13b498e9c469a..cb464bde16ef1 100644 --- a/pkgs/applications/radio/gnuradio/default.nix +++ b/pkgs/applications/radio/gnuradio/default.nix @@ -190,11 +190,10 @@ let runtime = [ SDL ]; cmakeEnableFlag = "GR_VIDEO_SDL"; }; - # codec2 and gsm support is broken with gr3.9: https://github.com/gnuradio/gnuradio/issues/4278 - # gr-vocoder = { - # runtime = [ codec2 gsm ]; - # cmakeEnableFlag = "GR_VOCODER"; - # }; + gr-vocoder = { + runtime = [ codec2 gsm ]; + cmakeEnableFlag = "GR_VOCODER"; + }; gr-wavelet = { cmakeEnableFlag = "GR_WAVELET"; runtime = [ gsl libsodium ]; @@ -234,7 +233,6 @@ stdenv.mkDerivation rec { src nativeBuildInputs buildInputs - cmakeFlags disallowedReferences stripDebugList doCheck @@ -250,6 +248,22 @@ stdenv.mkDerivation rec { } // lib.optionalAttrs (hasFeature "gr-qtgui" features) { inherit (libsForQt5) qwt; }; + cmakeFlags = shared.cmakeFlags + # From some reason, if these are not set, libcodec2 and gsm are not + # detected properly. + ++ lib.optionals (hasFeature "gr-vocoder" features) [ + "-DLIBCODEC2_FOUND=TRUE" + "-DLIBCODEC2_LIBRARIES=${codec2}/lib/libcodec2.so" + "-DLIBCODEC2_INCLUDE_DIRS=${codec2}/include" + "-DLIBCODEC2_HAS_FREEDV_API=ON" + "-DLIBGSM_FOUND=TRUE" + "-DLIBGSM_LIBRARIES=${gsm}/lib/libgsm.so" + "-DLIBGSM_INCLUDE_DIRS=${gsm}/include/gsm" + ] + ++ lib.optionals (hasFeature "volk" features && volk != null) [ + "-DENABLE_INTERNAL_VOLK=OFF" + ] + ; postInstall = shared.postInstall # This is the only python reference worth removing, if needed. |