codec2: add freedv support
This commit is contained in:
parent
4fe2fe1a51
commit
3f25fcd660
2 changed files with 17 additions and 1 deletions
|
@ -1,4 +1,11 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake }:
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, cmake
|
||||
, freedvSupport ? false
|
||||
, lpcnetfreedv
|
||||
, codec2
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "codec2";
|
||||
|
@ -13,6 +20,10 @@ stdenv.mkDerivation rec {
|
|||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
buildInputs = lib.optionals freedvSupport [
|
||||
lpcnetfreedv
|
||||
];
|
||||
|
||||
# Install a binary that is used by openwebrx
|
||||
postInstall = ''
|
||||
install -Dm0755 src/freedv_rx -t $out/bin/
|
||||
|
@ -26,6 +37,8 @@ stdenv.mkDerivation rec {
|
|||
cmakeFlags = [
|
||||
# RPATH of binary /nix/store/.../bin/freedv_rx contains a forbidden reference to /build/
|
||||
"-DCMAKE_SKIP_BUILD_RPATH=ON"
|
||||
] ++ lib.optionals freedvSupport [
|
||||
"-DLPCNET=ON"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
|
|
|
@ -28614,6 +28614,9 @@ with pkgs;
|
|||
|
||||
freedv = callPackage ../applications/radio/freedv {
|
||||
inherit (darwin.apple_sdk.frameworks) AppKit AVFoundation Cocoa CoreMedia;
|
||||
codec2 = codec2.override {
|
||||
freedvSupport = true;
|
||||
};
|
||||
};
|
||||
|
||||
freemind = callPackage ../applications/misc/freemind {
|
||||
|
|
Loading…
Reference in a new issue